custom/plugins/GrimmTheme/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_ordernumber_container %}
  3. {# customizedProducts.priceLabelNotice would otherwise be in here but not needed #}
  4. {% endblock %}
  5. {% block page_product_detail_buy_container %}
  6.     <div itemprop="offers"
  7.             itemscope
  8.             itemtype="{% if page.product.calculatedPrices|length > 1 %}http://schema.org/AggregateOffer{% else %}http://schema.org/Offer{% endif %}">
  9.         {% block page_product_detail_data %}
  10.             {% block page_product_detail_data_rich_snippet_url %}
  11.                 <meta itemprop="url"
  12.                         content="{{ seoUrl('frontend.detail.page', { productId: page.product.id }) }}"/>
  13.             {% endblock %}
  14.             {% block page_product_detail_data_rich_snippet_price_range %}
  15.                 {% if page.product.calculatedPrices|length > 1 %}
  16.                     {% set lowestPrice = false %}
  17.                     {% set highestPrice = false %}
  18.                     {% for price in page.product.calculatedPrices %}
  19.                         {% if not lowestPrice or price.unitPrice < lowestPrice %}
  20.                             {% set lowestPrice = price.unitPrice %}
  21.                         {% endif %}
  22.                         {% if not highestPrice or price.unitPrice > highestPrice %}
  23.                             {% set highestPrice = price.unitPrice %}
  24.                         {% endif %}
  25.                     {% endfor %}
  26.                     <meta itemprop="lowPrice" content="{{ lowestPrice }}"/>
  27.                     <meta itemprop="highPrice" content="{{ highestPrice }}"/>
  28.                     <meta itemprop="offerCount" content="{{ page.product.calculatedPrices|length }}"/>
  29.                 {% endif %}
  30.             {% endblock %}
  31.             {% block page_product_detail_data_rich_snippet_price_currency %}
  32.                 <meta itemprop="priceCurrency"
  33.                         content="{{ context.currency.translated.shortName }}"/>
  34.             {% endblock %}
  35.             
  36.             {% block page_product_detail_tax %}
  37.             {% endblock %}
  38.             {% set remoteClickOptions = {
  39.                 selector: "#review-tab",
  40.                 scrollToElement: true
  41.             } %}
  42.             {% block page_product_detail_reviews %}
  43.                 {% if page.product.ratingAverage > 0 and page.reviews.totalReviews > 0 and config('core.listing.showReview') %}
  44.                     <div class="product-detail-reviews">
  45.                         {% sw_include '@Storefront/storefront/component/review/rating.html.twig' with {
  46.                             points: page.product.ratingAverage,
  47.                             style: 'text-primary'
  48.                         } %}
  49.                         <a data-toggle="tab"
  50.                             class="product-detail-reviews-link"
  51.                             data-offcanvas-tabs="true"
  52.                             data-remote-click="true"
  53.                             data-remote-click-options='{{ remoteClickOptions|json_encode }}'
  54.                             href="#review-tab-pane"
  55.                             aria-controls="review-tab-pane">
  56.                             {{ page.reviews.totalReviews }}
  57.                             {{ "detail.reviewLinkText"|trans({'%count%': page.reviews.totalReviews})|sw_sanitize }}
  58.                         </a>
  59.                     </div>
  60.                 {% endif %}
  61.             {% endblock %}
  62.             
  63.             {% block page_product_detail_buy_redirect_input %}
  64.                 {# fallback redirect back to detail page is deactivated via js #}
  65.                 <input type="hidden"
  66.                         name="redirectTo"
  67.                         value="frontend.detail.page">
  68.                 <input type="hidden"
  69.                         name="redirectParameters"
  70.                         data-redirect-parameters="true"
  71.                         value='{"productId": "{{ product.id }}"}'>
  72.             {% endblock %}
  73.             {% block page_product_detail_delivery_informations %}
  74.                 {# moved to buywidget form #}
  75.             {% endblock %}
  76.         {% endblock %}
  77.         {# BREITE LĂ„NGE #}
  78.         {# in index.html.twig verschoben #}
  79.         {% block page_product_detail_configurator_include %}
  80.             {% if page.product.parentId and page.configuratorSettings|length > 0 %}
  81.                 {# <div class="product-detail-configurator-container test">
  82.                     {% sw_include '@Storefront/storefront/page/product-detail/configurator.html.twig' %}
  83.                 </div> #}
  84.             {% endif %}
  85.         {% endblock %}
  86.         {# KONFIGURATION #}
  87.         {% block page_product_detail_buy_form %}
  88.             {# SD-4986 #}
  89.             {% if product.translated.customFields.grimm_customfields_productRequest_only %}
  90.                 <p>{{"detail.extraInfoRequestOnly"|trans|sw_sanitize}}</p>
  91.             {% endif %}
  92.             {{ parent() }}
  93.             {% set buyable = product.available and product.childCount <= 0 and product.calculatedMaxPurchase > 0 %}
  94.             {% if buyable == false %}
  95.                 <p>{{ "product.info.notAvailable"|trans|sw_sanitize }}</p>
  96.             {% endif %}
  97.         {% endblock %}
  98.     </div>
  99. {% endblock %}
  100. {% block page_product_detail_wishlist %}
  101. {# in previous block #}
  102. {% endblock %}