Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents

Introduction

This plugin integrates VAI Pay as a payment method in your JTL store.

...

Assign VAI Pay to the appropriate shipping methods/countries under Administration → Shipping. The plugin also takes into account any surcharges to the payment method. You can also find a direct link to this on the plugin's help page.

...

In order for the payments made via VAI Pay to be assigned to the orders in JTL-Wawi, extended settings must be made for thisset. For a correct function with VAI Pay, the described JTL workflows are of particular importance, more information on this topic you can be found find here: https://support.vaitrade.de/de-form/articles/3482535-welche-informationen-mussen-auf-meiner-rechnung-vorhanden-sein.

Set up payment method in Wawi 1.6

In JTL WAWI, open the payment method management Zahlungen → Zahlungsarten.

Create "Vai VAI Pay" as the payment method. Note that the payment methods must correspond to the "Displayed name" in the JTL store.

...

Set up the order attribute

Change to Verkauf (F6) und open an order. You can edit the order attributes with

...

Create the Attribute “VaiDealNumber“. Now the transmitted dealNumber is displayed:

...

Customise invoice template

For the additionally required invoice information (delivery address, VAI Pay VAT ID, etc.), the following block must be set in "Rechnungsdruck nach Zahlungseingang":

Code Block
Lieferadresse:
{{ Vorgang.Lieferadresse.Firma }} {{ Vorgang.Lieferadresse.Firmenzusatz }}
{{ Vorgang.Lieferadresse.Straße }} {{ Vorgang.Lieferadresse.PLZ }} {{ Vorgang.Lieferadresse.Ort }} {{ Vorgang.Lieferadresse.Land.NameDeutsch }}
Lieferbedingung: gemäß Incoterms 2010:CIP
Umsatzsteuer ID (VAI Trade GmbH): DE311841845

...

Terms of delivery should only be listed if applicable.

Skonto is not taken into account by the plugin.

...

Setup “Eigenes Feld“ (custom field)

IN JTL-WAWI, open Admin→ “Eigene Felder”

If you have updated from v1.5 to v1.6, you will find the VaiDealNumber under "Automatisch generiert". You can create a new group "VAI Pay" and drag the VaiDealNumber into to structure your fields:

...

Otherwise, create a new field with the name "VaiDealNumber" and the data type "Kurztext":

...

The VaiDealNumber is then displayed in the offer/order on the right side under the tab “Eigene Felder“ (custom fields):

...

Set up payment method in Wawi 1.5

In JTL WAWI, open the payment method management Zahlungen → Zahlungsarten.

Create "VAI Pay" as the payment method. Note that the payment methods must correspond to the "Displayed name" in the JTL store.

...

Set up the order attribute

Change to Verkauf (F6) und open an order. You can edit the order attributes with

...

Create the Attribute “VaiDealNumber“. Now the transmitted dealNumber is displayed:

...

Set up JTL-Workflow

VAI Trade GmbH acts as the buyer to the seller, so unlike other orders, the invoice may not be addressed to the buyer, but must be addressed to VAI Trade instead. Set up a WAWI workflow to automatically change the invoice address of the order to the invoice address of VAI Trade to be defined when an order is created with VAI Pay as the payment type. To do this, proceed as follows:

  1. Set up "

...

  1. VAI Pay" as a payment method.

  2. Open Admin >JTL-Workflows:

    Image Modified

  3. Choose Aufträge:

    Image ModifiedImage Added

    and mark up “Komplett bezahlt”

  4. Create a new Workflow:

    Image Modified

  5. Define conditions:

...

  1. Image Added

    Define for the previously created payment type "

...

  1. VAI Pay" that payments should be processed.

  2. Set up actions:

    Image ModifiedImage Modified

    In Table Address data all variables are listed which have to be changed.

    1. Choose action “Werte setzen“

    2. Specify with "Variable" which value should be changed for
      Auftrag > Zahlungen > Rechnungsadresse > Variable

    3. Specify the new value for Wert.

    4. Option “Feld leeren” is not available, to empty a variable please insert a "-" (minus) as a workaround.

  3. Test Workflow

  4. Save the Workflow

Address data

The setup help is intended to assist you in entering all the required variables.

Variable

Value

Comment

Setup help

Adresszusatz

-

  •  done

Anrede

-

  •  done

Bundesland

-

  •  done

EMail

vaipay@vaitrade.de

  •  done

Fax

-

  •  done

Firma

VAI Trade GmbH

  •  done

Firmenzusatz

-

  •  done

LandISO

DE

  •  done

Landname

Deutschland

  •  done

Mobil

-

  •  done

Name

-

  •  done

Ort

Berlin

  •  done

PLZ

10245

  •  done

Straße

Warschauer Platz 11-13

  •  done

Telefon

+49 30 9599984 20

  •  done

Titel

-

  •  done

Vorname

-

  •  done

ZuHänden

-

up to Wawi 1.5

  •  done

Tabelle: Rechnungsadressdaten

Test WAWI-Workflow

  1. Now test the Wawi workflow on a test order by first creating a test order in your store (cash payment or similar) and transferring it to the WAWI. Set the payment for the order via "Vai Pay" and a payment receipt. Make a note of the order number (e.g. 123).

    Image Removed

  2. Go to JTL-Workflows by choosing Aufträge > Komplett bezahlt > “Auftrag_Komplett bezahlt”

  3. Your workflow actions should look something like this:

    Image Removed

  4. Start the test

    Image Removed

  5. Select an object by searching for order number (e.g. 123)

    Image Removed

  6. Open the order again. The invoice recipient has been changed:

    Image Removed

Set up E-Mail template

As a seller, you have to send the buyer's invoice to the intermediary. In this case, a differentiation based on payment type must be set up in the e-mail template. The correct e-mail address for the transaction has already been set by the workflow. The corresponding DealNumber has been assigned in the incoming payment for the transaction. Open Admin → “Druck- / E-Mail- / Exportvorlagen“

...

Adapt subject

If you have not made any changes to your standard e-mail template, you can use the code as it is. Otherwise, adapt the code or insert your modifications in the ELSE part:

...

The field "ZuHänden" no longer exists as of Wawi 1.6 and can be removed from the workflow.

VAT ID

If you have to show a VAT ID on the invoice, the VAT ID of VAI must also be shown on the invoice. The easiest way is to can enter your VAT ID in the “Firmenzusatz” field:

...

Test WAWI-Workflow

  1. Now test the Wawi workflow on a test order by first creating a test order in your store (cash payment or similar) and transferring it to the WAWI. Set the payment for the order via "VAI Pay" and a payment receipt. Make a note of the order number (e.g. 123).

    Image AddedImage Added
  2. Go to JTL-Workflows by choosing Aufträge > Komplett bezahlt > “Auftrag_Komplett bezahlt”

  3. Your workflow actions should look something like this:

    Image Added

  4. Start the test

    Image Added

  5. Select an object by searching for order number (e.g. 123)

    Image Added

  6. Open the order again. The invoice recipient has been changed:

    Image AddedImage Added

Set up E-Mail template

As a seller, you have to send the buyer's invoice to the intermediary. In this case, a differentiation based on payment type must be set up in the e-mail template. The correct e-mail address for the transaction has already been set by the workflow. The corresponding DealNumber has been assigned in the incoming payment for the transaction. Open Admin → “Druck- / E-Mail- / Exportvorlagen“

...

Select Mailen → Standardvorlage → Bearbeiten. “E-Mail-Vorlagen bearbeiten” opens. Set the subject to “Benutzerdefiniert” to be able to open the advanced settings "...". Make sure that the variable set starting with “Vorgang” is available on the right-hand side. If this is not the case, you use a new standard template. Use the template "Standard (Veraltet)" instead, this template contains the required variable set:

...

Adapt subject

If you have not made any changes to your standard e-mail template, you can use the code as it is. Otherwise, adapt the code or insert your modifications in the ELSE part:

Code Block
{% if Vorgang.Zahlungen.ErstesObjekt.Zahlungsart.Name == "VAI Pay" %}
Rechnung zu VAI-Deal: #{{ Vorgang.Zahlungen.ErstesObjekt.ExterneTransaktionsID }}
{% else %}
Rechnung über "{{ Report.InvoicePosition[0].Name | Truncate: 20 }}"{% case Report.InvoicePosition.Size %}{% when 0%}{% when 1 %}{% when 2 %} und einem weiteren Artikel{% else %} und {{ Report.InvoicePosition.Size | Minus: 1 }} weiteren Artikeln{% endcase%} von {{ Report.Company.CompanyName }}
{% endif %}

Wawi 1.5

Code Block
{% if Vorgang.Zahlungen.ErstesObjekt.Zahlungsart.Name == "VAI Pay" %}
Rechnung zu VAI-Deal: #{% assign Attribute = Vorgang.Auftrag.Attribute | Split: '|' %}{% for Attribut in Attribute %}{% if Attribut contains 'VaiDealNumber' %}{{ Attribut | ReplaceFirst: 'VaiDealNumber=','' }}{% endif %}{% endfor %}
{% else %}
Rechnung über "{{ Report.InvoicePosition[0].Name | Truncate: 20 }}"{% case Report.InvoicePosition.Size %}{% when 0%}{% when 1 %}{% when 2 %} und einem weiteren Artikel{% else %} Rechnungund über "{{ Report.InvoicePosition[0].NameSize | TruncateMinus: 201 }}" weiteren Artikeln{% case endcase%} von {{ Report.InvoicePositionCompany.SizeCompanyName %}}
{% whenendif 0%}%}

Wawi 1.6

Customise Invoice PDF Name

The same applies to the naming of the PDF invoice name. Insert your modifications in the ELSE part at the end of the code line:

Code Block
{% when 1 %}{% when 2 %} und einem weiteren Artikel{% else %} und {{ Report.InvoicePosition.Size | Minus: 1 }} weiteren Artikeln{% endcase%} von {{ Report.Company.CompanyName }}
if Vorgang.Zahlungen.ErstesObjekt.Zahlungsart.Name == "VAI Pay" %}#{{ Vorgang.Zahlungen.ErstesObjekt.ExterneTransaktionsID }}.pdf{% else %}Rechnung-{{ Vorgang.Rechnungsnummer }}.pdf{% endif %}

Customise Invoice PDF Name

...

Wawi 1.5

Code Block
{% if Vorgang.Zahlungen.ErstesObjekt.Zahlungsart.Name == "VaiVAI Pay" %}#{{ Vorgang.Zahlungen.ErstesObjekt.ExterneTransaktionsID }}.pdf{% else %}Rechnung-{{ Vorgang.RechnungsnummerVorgangsid }}.pdf{% endif %}

Wawi 1.6

On operation

Shop

The payment method is integrated in the storefront of the store like a regular JTL store payment method.

...

The JTL workflows, once set up, start automatically during the Wawi reconciliation synchrinization and do not require any further processing during operationoperation.

The plugin also has no further interaction with the Wawi, cancellations must be solved directly with VAI. Furthermore, the plug-in does not respond to a Wawi comparison in the opposite direction.

Customization

The payment method itself has no customizable elements. However, you can specify which color scheme and button text to display on the summary page.

...

Warning

Attention: Only edit the shop's config file if you know what you are doing! Incorrect adjustments here can make your shop inaccessible or (encrypted) data unusable. If in doubt, ask your hoster or service partner for help.

Changelog

(März 2023)

  • Documentation revision

  • Text “Vai Pay” changed to “VAI Pay”

  • Add texts and images for Wawi 1.6

v1.0.2 (Februar 2023)

  • Übermittlung der Shop Bestellnummer

v1.0.1 (Januar 2023)

  • JTL Shop 5.2 Kompatibilität

v1.0.0 (August 2022)

  • Initial Initiales Release

Support und Contact

...