templates/frontend-eforum/_partials/nav.html.twig line 1

Open in your IDE?
  1. <aside class="product-nav d-none d-md-block" id="product-nav">
  2.     <header class="product-nav__header">
  3.         <h2 class="product-nav__title">
  4.             <small class="product-nav__category">
  5.                 {% if product.categories is not empty  %}
  6.                     {{ product.categories|first }}
  7.                 {% endif %}
  8.             </small>
  9.             {% if product.title is not empty %}
  10.                 {{ product.title }}
  11.             {% endif %}
  12.         </h2>
  13.     </header>
  14.     <div class="product-nav__items">
  15.         <nav class="nav nav-tabs flex-column product-nav__list" role="tablist">
  16.             {% for item in list %}
  17.                 <a href="#{{ item.id }}" class="nav-link product-nav__link">{{ item.menuText }}</a>
  18.             {% endfor %}
  19.         </nav>
  20.     </div>
  21.     <footer class="product-nav__footer">
  22.         {% if productVariants is defined and productVariants is not empty %}
  23.             {% set productVariant = productVariants|first %}
  24.             {% for checkProductVariant in productVariants %}
  25.                 {% if checkProductVariant.checkIfIsDefaultChecked(loop.first) %}
  26.                     {% set productVariant = checkProductVariant %}
  27.                 {% endif %}
  28.             {% endfor %}
  29.             <div class="product-nav__current-product"
  30.                  data-productVariantNoComplete="{{ productVariant.productVariantNoComplete }}"
  31.                  data-productAssociationId="{{ product.id }}"
  32.                  data-redirecttocart="false"
  33.                  data-hidesuccessalert="false"
  34.                  {% if product.checkCouponDefault(productVariant) %}data-coupon="{{ product.couponDefault.code }}"{% endif %}
  35.             >
  36.                 <div class="product-nav__footerInfo">
  37.                     <h3>{{ productVariant.tradeName }}</h3>
  38.                     <ul class="product-nav__price">
  39.                         {% if product.checkCouponDefault(productVariant) %}
  40.                             <li class="product-nav__price-item">
  41.                                 {{ productVariant.getFullPriceAfterCoupon('net', product.couponDefault, true) }} zł netto
  42.                             </li>
  43.                             <li class="product-nav__price-item">
  44.                                 {{ productVariant.getFullPriceAfterCoupon('gross', product.couponDefault, true) }} zł brutto
  45.                             </li>
  46.                         {% else %}
  47.                             <li class="product-nav__price-item">
  48.                                 {{ productVariant.getFullPrice('net', true) }} zł netto
  49.                             </li>
  50.                             <li class="product-nav__price-item">
  51.                                 {{ productVariant.getFullPrice('gross', true) }} zł brutto
  52.                             </li>
  53.                         {% endif %}
  54.                     </ul>
  55.                 </div>
  56.                 {% if productVariants|length > 1 %}
  57.                     <a href="#change-product"
  58.                        class="product-nav__change jsToggleProductPreview"
  59.                        data-url="{{ path('efProductPreview', {'productAssociationId': product.id, 'type': 'changeSubscriptions'}) }}"
  60.                        data-type="subscription">
  61.                         <i class="icon icon--shuffle"></i>
  62.                         zmień
  63.                     </a>
  64.                 {% endif %}
  65.             </div>
  66.         {% endif %}
  67.         <button type="button" id="add-to-cart"
  68.                 class="button button--bordered button--with-arrow product-nav__add">
  69.             Dodaj do koszyka
  70.         </button>
  71.     </footer>
  72. </aside>