custom/plugins/ApoShop/src/Resources/views/storefront/page/product-detail/buy-widget.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/page/product-detail/buy-widget.html.twig' %}
  2. {% block page_product_detail_buy_inner %}
  3.     {% block page_product_detail_headline %}
  4.         <div class="row align-items-center product-detail-headline">
  5.             {% sw_include '@Storefront/storefront/page/product-detail/headline.html.twig' %}
  6.         </div>
  7.     {% endblock %}
  8.     {% block page_product_detail_reviews %}
  9.         {% if page.product.ratingAverage > 0 and page.reviews.totalReviews > 0 and config('core.listing.showReview') %}
  10.             <div class="product-detail-reviews">
  11.                 {% sw_include '@Storefront/storefront/component/review/rating.html.twig' with {
  12.                     points: page.product.ratingAverage,
  13.                     style: 'text-primary'
  14.                 } %}
  15.                 <a {{ dataBsToggleAttr }}="tab"
  16.                     class="product-detail-reviews-link"
  17.                     data-offcanvas-tabs="true"
  18.                     data-remote-click="true"
  19.                     data-remote-click-options='{{ remoteClickOptions|json_encode }}'
  20.                     href="#review-tab-pane"
  21.                     aria-controls="review-tab-pane">
  22.                     {{ page.reviews.totalReviews }}
  23.                     {{ "detail.reviewLinkText"|trans({'%count%': page.reviews.totalReviews})|sw_sanitize }}
  24.                 </a>
  25.             </div>
  26.         {% endif %}
  27.     {% endblock %}
  28.     
  29.     <div class="stock">
  30.         <p class="showinstock">Aviability:</p>
  31.             {% if page.product.custom_itweb_exclude_api == true %}
  32.                 {% elseif page.product.stock and page.product.availableStock > 0 %}
  33.                     <p class="stockitem">
  34.                         <i class="fa-solid fa-check"></i> In Stock
  35.                     </p>
  36.                 {% else %}
  37.                     {% if page.product.stock == 1 %}
  38.                         <p class="stockitem">
  39.                             <i class="fa-solid fa-check"></i>  In Stock
  40.                         </p>
  41.                     {% else %}
  42.                         <p class="outstock">
  43.                             <i class="fa-solid fa-x"></i> Out of Stock
  44.                         </p>
  45.                     {% endif %} 
  46.             {% endif %}
  47.     </div>
  48.     <div class="js-magnifier-zoom-image-container">
  49.         {% block page_product_detail_rich_snippets %}
  50.             {% block page_product_detail_rich_snippets_brand %}
  51.                 {% if page.product.manufacturer %}
  52.                     <div itemprop="brand" itemtype="https://schema.org/Brand" itemscope>
  53.                         <meta itemprop="name" content="{{ page.product.manufacturer.translated.name }}" />
  54.                     </div>
  55.                 {% endif %}
  56.             {% endblock %}
  57.             {% block page_product_detail_rich_snippets_gtin13 %}
  58.                 {% if page.product.ean %}
  59.                     <meta itemprop="gtin13"
  60.                           content="{{ page.product.ean }}"/>
  61.                 {% endif %}
  62.             {% endblock %}
  63.             {% block page_product_detail_rich_snippets_mpn %}
  64.                 {% if page.product.manufacturerNumber %}
  65.                     <meta itemprop="mpn"
  66.                           content="{{ page.product.manufacturerNumber }}"/>
  67.                 {% endif %}
  68.             {% endblock %}
  69.             {% block page_product_detail_rich_snippets_weight %}
  70.                 {% if page.product.weight %}
  71.                     <meta itemprop="weight"
  72.                           content="{{ page.product.weight }} kg"/>
  73.                 {% endif %}
  74.             {% endblock %}
  75.             {% block page_product_detail_rich_snippets_height %}
  76.                 {% if page.product.height %}
  77.                     <meta itemprop="height"
  78.                           content="{{ page.product.height }} mm"/>
  79.                 {% endif %}
  80.             {% endblock %}
  81.             {% block page_product_detail_rich_snippets_width %}
  82.                 {% if page.product.width %}
  83.                     <meta itemprop="width"
  84.                           content="{{ page.product.width }} mm"/>
  85.                 {% endif %}
  86.             {% endblock %}
  87.             {% block page_product_detail_rich_snippets_depth %}
  88.                 {% if page.product.length %}
  89.                     <meta itemprop="depth"
  90.                           content="{{ page.product.length }} mm"/>
  91.                 {% endif %}
  92.             {% endblock %}
  93.             {% block page_product_detail_rich_snippets_release_date %}
  94.                 <meta itemprop="releaseDate"
  95.                       content="{{ page.product.releaseDate|format_date(pattern="Y-MM-dd", locale=app.request.locale) }}"/>
  96.             {% endblock %}
  97.         {% endblock %}
  98.         {% if not feature('FEATURE_NEXT_16992') %}
  99.             {% block page_product_detail_not_available %}
  100.             {% endblock %}
  101.         {% endif %}
  102.         {% block page_product_detail_buy_container %}
  103.             <div itemprop="offers"
  104.                  itemscope
  105.                  itemtype="{% if page.product.calculatedPrices|length > 1 %}http://schema.org/AggregateOffer{% else %}http://schema.org/Offer{% endif %}">
  106.                 {% block page_product_detail_data %}
  107.                     {% block page_product_detail_data_rich_snippet_url %}
  108.                         <meta itemprop="url"
  109.                               content="{{ seoUrl('frontend.detail.page', { productId: page.product.id }) }}"/>
  110.                     {% endblock %}
  111.                     {% block page_product_detail_data_rich_snippet_price_range %}
  112.                         {% if page.product.calculatedPrices|length > 1 %}
  113.                             {% set lowestPrice = false %}
  114.                             {% set highestPrice = false %}
  115.                             {% for price in page.product.calculatedPrices %}
  116.                                 {% if not lowestPrice or price.unitPrice < lowestPrice %}
  117.                                     {% set lowestPrice = price.unitPrice %}
  118.                                 {% endif %}
  119.                                 {% if not highestPrice or price.unitPrice > highestPrice %}
  120.                                     {% set highestPrice = price.unitPrice %}
  121.                                 {% endif %}
  122.                             {% endfor %}
  123.                             <meta itemprop="lowPrice" content="{{ lowestPrice }}"/>
  124.                             <meta itemprop="highPrice" content="{{ highestPrice }}"/>
  125.                             <meta itemprop="offerCount" content="{{ page.product.calculatedPrices|length }}"/>
  126.                         {% endif %}
  127.                     {% endblock %}
  128.                     {% block page_product_detail_data_rich_snippet_price_currency %}
  129.                         <meta itemprop="priceCurrency"
  130.                               content="{{ context.currency.translated.shortName }}"/>
  131.                     {% endblock %}
  132.                     {% block page_product_detail_price %}
  133.                         <div class="product-detail-price-container">
  134.                             {% sw_include '@Storefront/storefront/page/product-detail/buy-widget-price.html.twig' %}
  135.                         </div>
  136.                     {% endblock %}
  137.                     <span class="price-unit-reference-content">
  138.                         {% set price = page.product.calculatedPrice %}
  139.                         {% set purchaseUnit = page.product.purchaseUnit ?: 1 %}
  140.                         {% for  test in page.product.variation  %}
  141.                             {% set priceValue = price.unitPrice %}
  142.                             Grundpreis: {{ (priceValue * 10) | number_format(2) }}{{ context.currency.symbol }} / 1KG
  143.                             {# {% set packageOpt = test.option|split(' ')[0] %}
  144.                             {% if 'X' in packageOpt  %}
  145.                                 {% set packageOpt = packageOpt|split('X')[1] %}
  146.                             {% endif %}
  147.                             {% if 'St' in test.option %}
  148.                                 Grundpreis: {{ (price.unitPrice / packageOpt)|number_format(2)}}{{ context.currency.symbol }} / 1 St
  149.                             {% elseif 'ml' in test.option %}
  150.                                 Grundpreis: {{ (price.unitPrice / packageOpt * 1000)|number_format(2)}}{{ context.currency.symbol }} / 1L
  151.                             {% elseif 'gr' in test.option or 'g' in test.option %}
  152.                                 Grundpreis: {{ (price.unitPrice / packageOpt * 1000)|number_format(2)}}{{ context.currency.symbol }} / 1KG
  153.                             {% endif %} #}
  154.                         {% endfor %}
  155.                     </span>
  156.                     {% block page_product_detail_tax %}
  157.                         <div class="product-detail-tax-container">
  158.                             {% if context.taxState == "gross" %}
  159.                                 {% set taxText = "general.grossTaxInformation"|trans|sw_sanitize %}
  160.                             {% else %}
  161.                                 {% set taxText = "general.netTaxInformation"|trans|sw_sanitize %}
  162.                             {% endif %}
  163.                             <p class="product-detail-tax">
  164.                                 {% block page_product_detail_tax_link %}
  165.                                     <a class="product-detail-tax-link"
  166.                                        href="{{ path('frontend.cms.page',{ id: config('core.basicInformation.shippingPaymentInfoPage') }) }}"
  167.                                        title="{{ taxText }}"
  168.                                        {{ dataBsToggleAttr }}="modal"
  169.                                        data-url="{{ path('frontend.cms.page',{ id: config('core.basicInformation.shippingPaymentInfoPage') }) }}">
  170.                                         {{ taxText }}
  171.                                     </a>
  172.                                 {% endblock %}
  173.                             </p>
  174.                         </div>
  175.                     {% endblock %}
  176.                         {% block page_product_detail_tax_new %}
  177.                         <div class="product-detail-tax-container">
  178.                            <span class="detail--additional-orderbasketfields-input detail--additional-orderbasketfields-input-1"> <span class="detail--additional-orderbasketfields-inputs-checkbox"> <input type="checkbox" class="checkbox detail--additional-orderbasketfields-checkbox-1 "> <input type="hidden" name="sAdditionalOrderBasketField1" value="Nein" class="is--hidden detail--additional-orderbasketfields-checkbox-hidden-1" data-type="checkbox"> </span> <span class="detail--additional-orderbasketfields-inputs-checkbox-label"> <label class="detail--label--additional-orderbasketfield-1-after">Artikel vakuumieren</label> </span> </span>
  179.                         </div>
  180.                     {% endblock %}
  181.                     {% set remoteClickOptions = {
  182.                         selector: "#review-tab",
  183.                         scrollToElement: true
  184.                     } %}
  185.                     {% block page_product_detail_delivery_informations %}
  186.                         <div class="product-detail-delivery-information">
  187.                             {% sw_include '@Storefront/storefront/component/delivery-information.html.twig' %}
  188.                         </div>
  189.                     {% endblock %}
  190.                 {% endblock %}
  191.                 {% block page_product_detail_configurator_include %}
  192.                     {% if page.product.parentId and page.configuratorSettings|length > 0 %}
  193.                         <div class="product-detail-configurator-container">
  194.                             {% sw_include '@Storefront/storefront/page/product-detail/configurator.html.twig' %}
  195.                         </div>
  196.                     {% endif %}
  197.                 {% endblock %}
  198.                 {% block page_product_detail_buy_form %}
  199.                     {% if page.product.active %}
  200.                         <div class="product-detail-form-container">
  201.                             {% sw_include '@Storefront/storefront/page/product-detail/buy-widget-form.html.twig' %}
  202.                         </div>
  203.                     {% endif %}
  204.                 {% endblock %}
  205.             </div>
  206.         {% endblock %}
  207.         {# {% if config('core.cart.wishlistEnabled') %}
  208.             {% block page_product_detail_wishlist %}
  209.                 {% sw_include '@Storefront/storefront/component/product/card/wishlist.html.twig' with {
  210.                     showText: true,
  211.                     size: 'md',
  212.                     productId: page.product.id
  213.                 } %}
  214.             {% endblock %}
  215.         {% endif %} #}
  216.         {# {% block page_product_detail_ordernumber_container %}
  217.             {% if page.product.productNumber %}
  218.                 <div class="product-detail-ordernumber-container">
  219.                     {% block page_product_detail_ordernumber_label %}
  220.                         <span class="product-detail-ordernumber-label">
  221.                             {{ "detail.productNumberLabel"|trans|sw_sanitize }}
  222.                         </span>
  223.                     {% endblock %}
  224.                     {% block page_product_detail_ordernumber %}
  225.                         <meta itemprop="productID"
  226.                               content="{{ page.product.id }}"/>
  227.                         <span class="product-detail-ordernumber"
  228.                               itemprop="sku">
  229.                             {{ page.product.productNumber }}
  230.                         </span>
  231.                     {% endblock %}
  232.                 </div>
  233.             {% endif %}
  234.         {% endblock %} #}
  235.     </div>
  236. <div class="pzn-details" >
  237.         <div class="prod-item">
  238.             <div><img src="/media/ee/01/f9/1678444394/Gruppe 21.svg"></div>
  239.             <p>{{ 'pzn-section' | trans | raw}}</p>
  240.             <p>{{page.product.productNumber}}</p>
  241.         </div>
  242.         <div class="prod-item">
  243.             <div><img src="/media/b2/78/20/1678444394/Gruppe 24.svg"></div>
  244.             <p>{{ 'herstller-section' | trans | raw}}</p>
  245.             <p>{{page.product.manufacturer.translated.name}}</p>
  246.         </div>
  247.          {% if product.pdfUrl is defined %}
  248.          <div class="prod-item">
  249.             <div><img src="/media/6d/58/fe/1678444394/Gruppe 25.svg"></div>
  250.             <p>{{ 'receipt-section' | trans | raw}}</p>
  251.                 <a href="{{ product.pdfUrl }}" download>
  252.                     <button>Download PDF</button>
  253.                 </a>
  254.             {# <p><b>Download PDF</b></p> #}
  255.         </div>
  256.         {% endif %}
  257.     </div>
  258. {% endblock %}