Markus Michalski FAQ

Variant Price Surcharge: Storefront and Cart

Where the variant price surcharge takes effect in the Sylius storefront: product page, product cards, cart, original price, price range filter, and what deliberately stays unchanged.

Deutsche Version

Back to overview

Variant Price Surcharge: Storefront and Cart

The plugin does not change any storefront templates and ships neither storefront routes nor JavaScript of its own. It replaces the Sylius price calculators with decorators. Every place in the storefront that gets prices from these calculators therefore shows the price with the surcharge automatically. You do not need to adapt a theme.

Sylius version Decorated calculators
2.2 sylius.calculator.product_variant_price
2.3 and later sylius.calculator.product_variant_price and additionally sylius.calculator.product_variant_catalog_price, which was added in 2.3 and supplies the prices for the product page, listings, variant selection and API

The plugin detects on its own whether the catalog calculator exists. You do not need to configure anything.

Where the surcharge takes effect

Place Behaviour
Product page Price and original price of the selected variant, as well as the price overview of the variants
Product cards Price of the variant the card shows
Cart and checkout The unit price of each item is set from the calculator whenever the cart is recalculated, so it includes the surcharge
Promotion price range filter The check uses the same calculator

The surcharge depends on the channel of the request. If the channel has its own setting, it applies, otherwise the global one (see Configuration).

Original price and catalog promotions

What stays unchanged

Requirements per channel

Shop API behaviour is described on Shop API and Headless.