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

Open in your IDE?
  1.     <div class="product-price-table">
  2.         {% if product.calculatedPrices|length > 1 %}
  3.             <div class="category-price-table-container">
  4.                 <div class="category-price-table-container-inner">
  5.                     
  6.                     <table class="category-price-table">
  7.                     
  8.                         <thead class="product-block-prices-head">
  9.                             {% block page_product_detail_price_block_table_head_inner %}
  10.                                 <tr class="product-block-prices-row">
  11.                                     <th scope="col" class="product-block-prices-cell">
  12.                                         {{ "detail.dataColumnQuantity"|trans|sw_sanitize }}
  13.                                     </th>
  14.                                     <th scope="col" class="product-block-prices-cell">
  15.                                         {{ "detail.dataColumnPrice"|trans|sw_sanitize }}
  16.                                     </th>
  17.                                     {% if page.product.calculatedPrice.referencePrice %}
  18.                                         <th scope="col" class="product-block-prices-cell">
  19.                                             {{ "detail.dataColumnReferencePrice"|trans|sw_sanitize }}
  20.                                         </th>
  21.                                     {% endif %}
  22.                                 </tr>
  23.                             {% endblock %}
  24.                         </thead>                
  25.                     
  26.                     
  27.                         <tbody class="product-block-prices-body">
  28.                             {% set isFirstLoop = true %}
  29.                             {% for price in product.calculatedPrices %}
  30.                                 
  31.                                 {% set abStaffel = product.minPurchase %}
  32.                                     
  33.                                 {% if loop.index > 1 %}
  34.                                     {% set idx = loop.index - 2 %}
  35.                                     {% set pArr = product.calculatedPrices %}
  36.                                     {% set abStaffel = pArr.elements[idx].quantity + 1 %}
  37.                                         
  38.                                         
  39.                                     {% if abStaffel >= product.minPurchase %}
  40.                                         <tr class="product-block-prices-row staffelRow noselect{% if isFirstLoop %} active{% endif %}"
  41.                                             data-sr="{{ abStaffel }}" 
  42.                                             data-pr="{{ price.unitPrice }}"
  43.                                             itemprop="offers" itemscope
  44.                                             itemtype="https://schema.org/Offer">
  45.                                     
  46.                                             <th scope="row" class="product-block-prices-cell product-block-prices-cell-thin">
  47.                                                 <meta itemprop="priceCurrency" content="{{ page.header.activeCurrency.translated.shortName }}" />
  48.                                                 <meta itemprop="price" content="{{ price.unitPrice }}" />
  49.                                                 <link itemprop="availability" href="https://schema.org/InStock" />
  50.                                                     {{ "detail.priceDataInfoFrom"|trans|sw_sanitize }}
  51.                                                     <span class="product-block-prices-quantity">{{ abStaffel }}</span>
  52.                                             </th>
  53.                                             <td class="product-block-prices-cell">
  54.                                                 {% sw_include '@Storefront/storefront/component/product/block-price.html.twig' with {
  55.                                                     price: price
  56.                                                 } only %}
  57.                                             </td>
  58.                                             {% if price.referencePrice is not null %}
  59.                                                 <td class="product-block-prices-cell product-block-prices-cell-thin">
  60.                                                     {{ price.referencePrice.price|currency }}{{ "general.star"|trans|sw_sanitize }} / {{ price.referencePrice.referenceUnit }} {{ price.referencePrice.unitName }}
  61.                                                 </td>
  62.                                             {% endif %}
  63.                                             
  64.                                         </tr>
  65.                                         {% set isFirstLoop = false %}
  66.                                     {% endif %}
  67.                                 {% endif %}
  68.                             {% endfor %}
  69.                         </tbody>
  70.                     </table>
  71.                 </div>
  72.             </div>
  73.         {% endif %}
  74.     
  75.     </div>