Skip to main content
A subsidy is a balance that you store for an individual customer in the customer database. The shop deducts it from the final total in the basket. Whatever is not used remains available for the next order. This lets you map rewards, credits, bonuses and similar benefits without issuing a voucher for each case. The difference from a voucher: the subsidy is tied to the customer account, not to a code, and the customer does not have to enter anything.

How the subsidy is offset

The shop never deducts more than the order costs. An order total below zero cannot occur as a result.
Offsetting and updating the account are two different things. The shop credits the subsidy in the order and writes the amount used and the remaining amount into the order data. You maintain the account balance itself via the customer import. So check that your merchandise management system actually writes the values from the order data back, otherwise the customer keeps their full balance.

Prerequisite

The subsidy comes from the customer import module. Talk to your WEBSALE representative if you are not using it yet.

Step 1: Activate the function in the shop configuration

Add the CustomerSubvention section to the shop.config.
Name-Txt and Remainder-Txt are not template texts. The shop writes them as labels into the order data, next to the respective amount. Your merchandise management system and your order confirmation access them. You write the texts in the template yourself in step 2.
Reference: CustomerSubvention section

Step 2: Display the account balance in the template

Two tags provide information about the balance.
Use BASKET-SubventionRest for the remaining amount, not WS-SubventionRemainder. As a bracket, WS-SubventionRemainder checks whether the customer has a balance at all, not whether anything is left after this order. A customer who uses up their entire balance then reads “Für Ihre nächste Bestellung bleiben: 0,00 EUR”. BASKET-SubventionRest only applies if there is a real remainder.
As a single tag, both tags return the same amount. The difference lies solely in their behavior as a bracket. If you want to output the amount unconditionally anyway, WS-SubventionRemainder is unproblematic.
Both tags trigger the total calculation if required. You can therefore also use them on pages where the basket has not yet been calculated.
Reference: WS-SubventionAccount · WS-SubventionRemainder · BASKET-SubventionRest

Step 3: Store subsidies per customer

The balance is stored in the customer account in the Subvention field and is set via the customer import. You can find the name of the import parameter in the customer import documentation.
A subsidy applies exactly to the customer in whose account it is stored. Guest customers have no account and therefore cannot receive a subsidy.

What arrives in the order data

If the function is active, the shop writes these fields for each order.
The four fields with _DName and _DValue only appear if the respective amount is not zero. A customer without a remaining balance therefore does not generate a CustomerSubventionRemainder_DName. If your merchandise management system evaluates these fields, it must be able to handle their absence.
The three numeric fields without a name suffix, on the other hand, are always written, even with the value 0.00.
  • Guide: Bonus points
  • Guide: Offering vouchers: Overview