custom/plugins/FuerstenbergPorzellan/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. {% block component_product_box_price_unit %}{% endblock %}
  3. {% block component_product_box_price %}
  4.     <div class="product-price-wrapper">
  5.         {% set price = real %}
  6.         {% set isListPrice = price.listPrice.percentage > 0 %}
  7.         {% set isRegulationPrice = price.regulationPrice != null %}
  8.         {% if displayFrom or (displayParent and displayFromVariants) %}
  9.             {{ "listing.listingTextFrom"|trans|sw_sanitize }}
  10.         {% endif %}
  11.         <span class="product-price{% if isListPrice and not displayFrom and not displayFromVariants %} with-list-price{% endif %}">
  12.             {{ price.unitPrice|currency }}{{ "general.star"|trans|sw_sanitize }}
  13.             {% if isListPrice and not displayFrom and not displayFromVariants %}
  14.                 {% set afterListPriceSnippetExists = "listing.afterListPrice"|trans|length > 0 %}
  15.                 {% set beforeListPriceSnippetExists = "listing.beforeListPrice"|trans|length > 0 %}
  16.                 {% set hideStrikeTrough = beforeListPriceSnippetExists or afterListPriceSnippetExists %}
  17.                 <span class="list-price{% if hideStrikeTrough %} list-price-no-line-through{% endif %}">
  18.                     {% if beforeListPriceSnippetExists %}{{ "listing.beforeListPrice"|trans|trim|sw_sanitize }}{% endif %}
  19.                     <span class="list-price-price">{{ price.listPrice.price|currency }}{{ "general.star"|trans|sw_sanitize }}</span>
  20.                     {% if afterListPriceSnippetExists %}{{ "listing.afterListPrice"|trans|trim|sw_sanitize }}{% endif %}
  21.                     <span class="list-price-percentage">{{ "detail.listPricePercentage"|trans({'%price%': price.listPrice.percentage })|sw_sanitize }}</span>
  22.                 </span>
  23.             {% endif %}
  24.         </span>
  25.         {% if isRegulationPrice %}
  26.             <span class="product-price with-regulation-price">
  27.                 {% if isListPrice %}<br/>{% endif %}<span class="regulation-price">{{ "general.listPricePreviously"|trans({'%price%': price.regulationPrice.price|currency }) }}{{ "general.star"|trans|sw_sanitize }}</span>
  28.             </span>
  29.         {% endif %}
  30.     </div>
  31. {% endblock %}