For the complete documentation index, see llms.txt. This page is also available as Markdown.

Discount badge

The discount badge points out reduced products – in the product box on listing pages and on the product page (gallery or buybox).

Discount

The "Discount" of a product is calculated from the difference between the "List price" and the "Price". For more information, see the Shopware documentation.


Configuration

Theme configuration

Listing pages

  1. Go to the "Listing pages" tab

  2. Expand the "Product badges (in the product box)" block

  3. Scroll to the section "Badge: Discount badge"

  4. Enable the configuration "Show discount badge"

  5. Save your changes after editing

Product pages

  1. Go to the "Product pages" tab

  2. Expand the "Product badges (in the image gallery or buy box)" block

  3. Scroll to the section "Badge: Discount badge"

  4. Set the configuration "Show discount badge" to "show in the image gallery" or "show in the buy box"

  5. Save your changes after editing

Note: The badge is displayed if the product has a "List price" that results in a discount (not for price ranges or "from" prices) – provided the discount badge is enabled. The ThemeWare® badge only appears if the ThemeWare® mode is selected in the "Discount badge (Product badges)" setting; otherwise Shopware's default badge is used.


Options

You control how the discount is displayed in the "Content" tab:

Tab "Content" => Block "Product badges" => Section "Badge: Discount badge"

  • Content: Defines how the discount is shown – e.g. "% (default)", "-25 %", "25 % saved", "-35 €" or "35 € saved".

  • Round number: Defines the rounding of the value – "0.12 (default)", "0.1" or "0".


Summary

Theme configuration

  • Tab "Listing pages" => Block "Product badges (in the product box)" => Section "Badge: Discount badge" => Show discount badge

  • Tab "Product pages" => Block "Product badges (in the image gallery or buy box)" => Section "Badge: Discount badge" => Show discount badge

  • Tab "Content" => Block "Product badges" => Section "Badge: Discount badge" => Content

  • Tab "Content" => Block "Product badges" => Section "Badge: Discount badge" => Round number

Snippets

  • twt.extension.discountBadge.discount

    • %discount% is replaced by the discount.

  • twt.extension.discountBadge.discountShort

    • %discount% is replaced by the discount.

    • %currency% is replaced by the current currency symbol.

  • twt.extension.discountBadge.percentage

    • %discount% is replaced by the percentage discount.

  • twt.extension.discountBadge.percentageShort

    • %discount% is replaced by the percentage discount.

    • %currency% is replaced by the current currency symbol.

Last updated

Was this helpful?