custom/plugins/MaxiaListingVariants6/src/Resources/views/storefront/component/product/card/price-unit.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/component/product/card/price-unit.html.twig' %}
  2. {# Remove price range if quick buy is active #}
  3. {% block component_product_box_price_info %}
  4.     {% set baseConfig = context.extensions.maxiaListingVariants %}
  5.     {% set variantsConfig = product.extensions.maxiaListingVariants %}
  6.     {% if baseConfig.pluginEnabled and product.parentId and variantsConfig.quickBuyActive
  7.         and variantsConfig.selection is not empty %}
  8.         {% set productOriginal = product %}
  9.         {% set product = {
  10.             priceRange: false,
  11.             calculatedPrice: (product.calculatedPrices.count > 0) ? product.calculatedPrices.first : product.calculatedPrice,
  12.             calculatedPrices: null,
  13.             calculatedListingPrice: product.calculatedListingPrice,
  14.             calculatedCheapestPrice: product.calculatedCheapestPrice,
  15.             packUnit: product.packUnit,
  16.             unit: product.unit,
  17.             purchaseUnit: product.purchaseUnit,
  18.             translated: product.translated
  19.         } %}
  20.     {% endif %}
  21.     {{ parent() }}
  22.     {% if baseConfig.pluginEnabled and variantsConfig.quickBuyActive %}
  23.         {% set product = productOriginal %}
  24.     {% endif %}
  25. {% endblock %}