custom/plugins/TwigelSportB2b/src/Resources/views/storefront/component/product/listing.html.twig line 1

Open in your IDE?
  1. {% sw_extends "@Storefront/storefront/component/product/listing.html.twig" %}
  2. {% block element_product_listing_col %}
  3.     {% for product in searchResult %}
  4.         {% set customerBusiness = false %}
  5.         {% set tagId = config('TwigelSportB2B.config.productTag') %}
  6.         {% if context.customer and context.customer.groupId %}
  7.             {% if context.customer.groupId in config('TwigelSportLabel.config.businessGroups') %}
  8.                 {% set customerBusiness = true %}
  9.             {% endif %}
  10.         {% endif %}
  11.         {% set productTag = product.tagIds %}
  12.         {% if tagId in productTag %}
  13.             {% if customerBusiness %}
  14.                 <div class="cms-listing-col {{ listingColumns }}">
  15.                     {% sw_include '@Storefront/storefront/component/product/card/box.html.twig' with {
  16.                         'layout': boxLayout,
  17.                         'displayMode': displayMode
  18.                     } %}
  19.                 </div>
  20.             {% endif %}
  21.         {% else %}
  22.             <div class="cms-listing-col {{ listingColumns }}">
  23.                 {% block element_product_listing_box %}
  24.                     {% sw_include '@Storefront/storefront/component/product/card/box.html.twig' with {
  25.                         'layout': boxLayout,
  26.                         'displayMode': displayMode
  27.                     } %}
  28.                 {% endblock %}
  29.             </div>
  30.         {% endif %}
  31.     {% endfor %}
  32. {% endblock %}