templates/product/suboverview.html.twig line 1

Open in your IDE?
  1. {% extends base_layout() %}
  2. {% if category.oms is not empty and subcategory.oms is not empty %}
  3.     {% if category.combinedCategoryName is not empty %}
  4.         {% set categorieName = category.combinedCategoryName|capitalize %}
  5.     {% else %}
  6.         {% set categorieName = category.oms|capitalize %}
  7.     {% endif %}
  8.     {% set head_title = subcategory.oms ~ ' | ' ~ categorieName %}
  9. {% endif %}
  10. {% block content %}
  11.     {% if category is defined %}
  12.         <script>
  13.             const tooltipTriggerList = document.querySelectorAll('[data-bs-toggle="tooltip"]')
  14.             const tooltipList = [...tooltipTriggerList].map(tooltipTriggerEl => new bootstrap.Tooltip(tooltipTriggerEl))
  15.         </script>
  16.         <div class="container">
  17.             <div class="row">
  18.                 <div class="col-12 col-md-5 col-lg-4 mb-5">
  19.                     <div class="area-col h-auto">
  20.                         <div class="area-col-inner position-relative area-shape-responsive area-shape-default bg-light-grey bg-opacity-50 p-5 submenu my-3">
  21.                             <h3 class="mb-3 text-secondary">{{ 'Filters'|trans }}</h3>
  22.                             <hr>
  23.                             <div class="ms-3">
  24.                                 {% if merken|length > 0 %}
  25.                                     <div class="my-3">
  26.                                         <h4>{{ 'Merken'|trans }}</h4>
  27.                                         <ul class="list-group">
  28.                                             {% for merk in merken %}
  29.                                                 <li class="form-check">
  30.                                                     <input class="form-check-input me-1 filtermerk" type="checkbox" value="{% if merk == 'Overige merken' %}{% else %}{{ merk }}{% endif %}" id="flexCheck{{ loop.index }}">
  31.                                                     <label class="form-check-label" for="flexCheck{{ loop.index }}">
  32.                                                         {{ merk }}
  33.                                                     </label>
  34.                                                 </li>
  35.                                             {% endfor %}
  36.                                         </ul>
  37.                                     </div>
  38.                                 {% endif %}
  39.                                 <div class="my-3">
  40.                                     <h4>{{ 'Stock Status'|trans }}</h4>
  41.                                     <ul class="list-group">
  42.                                         <li class="form-check">
  43.                                             <input class="form-check-input filterstock" type="checkbox" value="2" id="stockCheck1">
  44.                                             <label class="form-check-label" for="stockCheck1">
  45.                                                         <span class="stockgroen ms-1">
  46.                                                             <i class="fas fa-xs fa-circle"></i> {{ 'Op voorraad'|trans }}
  47.                                                         </span>
  48.                                             </label>
  49.                                         </li>
  50.                                         <li class="form-check">
  51.                                             <input class="form-check-input filterstock" type="checkbox" value="1" id="stockCheck2">
  52.                                             <label class="form-check-label" for="stockCheck2">
  53.                                                         <span class="stockoranje ms-1">
  54.                                                         <i class="fas fa-xs  fa-circle"></i> {{ 'Bijna uitverkocht'|trans }}
  55.                                                     </span>
  56.                                             </label>
  57.                                         </li>
  58.                                         <li class="form-check">
  59.                                             <input class="form-check-input filterstock" type="checkbox" value="0" id="stockCheck3">
  60.                                             <label class="form-check-label" for="stockCheck3">
  61.                                                         <span class="stockrood ms-1">
  62.                                                             <i class="fas fa-xs fa-circle"></i> {{ 'Uitverkocht'|trans }}
  63.                                                         </span>
  64.                                             </label>
  65.                                         </li>
  66.                                     </ul>
  67.                                 </div>
  68.                                 <div class="my-3">
  69.                                     <h4>{{ 'Prijs'|trans }}</h4>
  70.                                     <div class="form-check">
  71.                                         <input class="form-check-input filterprice" type="checkbox" value="down" id="flexCheckPriceDown">
  72.                                         <label class="form-check-label" for="flexCheckPriceDown">
  73.                                             {{ 'Laag - Hoog'|trans }}
  74.                                         </label>
  75.                                     </div>
  76.                                     <div class="form-check">
  77.                                         <input class="form-check-input filterprice" type="checkbox" value="up" id="flexCheckPriceUp">
  78.                                         <label class="form-check-label" for="flexCheckPriceUp">
  79.                                             {{ 'Hoog - Laag'|trans }}
  80.                                         </label>
  81.                                     </div>
  82.                                 </div>
  83.                             </div>
  84.                             <svg height="100%" width="100%" xmlns="http://www.w3.org/2000/svg">
  85.                                 <clipPath clipPathUnits="objectBoundingBox" id="shapeyellow">
  86.                                     <path
  87.                                         d="M0.536,0.991 s-0.414,0.038,-0.47,-0.038 C0.013,0.879,-0.009,0.825,0.004,0.696 s0.013,-0.268,0.013,-0.376 C0.018,0.133,0.026,0.017,0.269,0.006 C0.512,-0.005,0.731,-0.001,0.854,0.023 c0.121,0.023,0.14,0.05,0.143,0.241 c0.003,0.192,0.017,0.613,-0.062,0.688 c-0.054,0.051,-0.125,0.042,-0.399,0.038"></path>
  88.                                 </clipPath>
  89.                             </svg>
  90.                         </div>
  91.                     </div>
  92.                     <div class="area-col h-auto">
  93.                         <div class="area-col-inner position-relative area-shape-responsive area-shape-default bg-light-grey bg-opacity-50 p-5 submenu">
  94.                             <h3 class="mb-3 text-secondary">{{ 'Categorieën'|trans }}</h3>
  95.                             {% if subcategoryList is defined %}
  96.                                 <ul class="list-unstyled">
  97.                                     {% for subcat in subcategoryList %}
  98.                                         {% set detailLink = app_product_subgrouplink(category,subcat) %}
  99.                                         <li class="mb-3">
  100.                                             <a href="{{ detailLink }}"
  101.                                                class="position-relative {% if subcat.id == subcategory.id %}active{% endif %}">{{ subcat.oms|capitalize }}
  102.                                                 <span class="material-symbols-outlined inline-icon text-secondary">
  103. chevron_right
  104. </span></a>
  105.                                         </li>
  106.                                     {% endfor %}
  107.                                 </ul>
  108.                             {% endif %}
  109.                             <svg height="100%" width="100%" xmlns="http://www.w3.org/2000/svg">
  110.                                 <clipPath clipPathUnits="objectBoundingBox" id="shapeyellow">
  111.                                     <path
  112.                                         d="M0.536,0.991 s-0.414,0.038,-0.47,-0.038 C0.013,0.879,-0.009,0.825,0.004,0.696 s0.013,-0.268,0.013,-0.376 C0.018,0.133,0.026,0.017,0.269,0.006 C0.512,-0.005,0.731,-0.001,0.854,0.023 c0.121,0.023,0.14,0.05,0.143,0.241 c0.003,0.192,0.017,0.613,-0.062,0.688 c-0.054,0.051,-0.125,0.042,-0.399,0.038"></path>
  113.                                 </clipPath>
  114.                             </svg>
  115.                         </div>
  116.                     </div>
  117.                 </div>
  118.                 <div class="col-12 col-md-7 col-lg-8">
  119.                     <div class="row mb-5">
  120.                         <div class="col-8 mb-3 pt-5 position-relative">
  121.                             {% set categoryLink = app_product_grouplink(category) %}
  122.                             <h1>
  123.                                     {% if category.combinedCategoryName is not empty %}
  124.                                         {% set categorieName = category.combinedCategoryName|capitalize %}
  125.                                     {% else %}
  126.                                         {% set categorieName = category.oms|capitalize %}
  127.                                     {% endif %}
  128.                                     {{ categorieName }}
  129.                                 </h1>
  130.                             <span class="position-absolute top-0 pt-3">
  131.                                 <a href="{% if check_websitesetting('product_document', 'document') %}{{ inotherlang('LocalizedDocument', pimcore_website_config('product_document')) }}{% endif %}">{{ 'Aanbod'|trans }}</a>
  132.                                 /
  133.                                 <a href="{{ categoryLink }}">
  134.                                     {% if category.combinedCategoryName is not empty %}
  135.                                         {% set categorieName = category.combinedCategoryName|capitalize %}
  136.                                     {% else %}
  137.                                         {% set categorieName = category.oms|capitalize %}
  138.                                     {% endif %}
  139.                                     {{ categorieName }}
  140.                                 </a>
  141.                                 /
  142.                                 <span class="text-primary">{{ subcategory.oms|capitalize }}</span>
  143.                             </span>
  144.                         </div>
  145.                         <p class="text-black">{{ category.infoProductGroup }}</p>
  146.                         <h2 class="text-primary">{{ subcategory.oms|capitalize }}</h2>
  147.                         <p class="text-black">{{ subcategory.infoProductSubGroup }}</p>
  148.                     </div>
  149.                     <div class="row g-5 mb-5 row-cols-2 row-cols-md-3 row-cols-lg-4 productoverview">
  150.                         {% for product in productlist %}
  151.                             {% set detailLink = app_product_articlelink(category,subcategory,product) %}
  152.                             {% if product.promotion != true %}
  153.                                 <div class="col">
  154.                                     <div class="media-body text-center">
  155.                                         <a href="{{ detailLink }}">
  156.                                             {% if product.getFotos() is defined %}
  157.                                                 {% if product.getFotos() %}
  158.                                                     <div class="position-relative">
  159.                                                         <img src="{{ product.getFotos().getThumbnail('prod-thumb') }}"
  160.                                                              class="img-fluid">
  161.                                                     </div>
  162.                                                 {% else %}
  163.                                                     <div>
  164.                                                         <img src="/static/img/noimage.png" class="img-fluid">
  165.                                                     </div>
  166.                                                 {% endif %}
  167.                                             {% endif %}
  168.                                             <div class="fw-bold pt-3">
  169.                                                 {{ product.oms }}
  170.                                             </div>
  171.                                         </a>
  172.                                         <div class="d-inline-block">
  173.                                             {% if product.prijs is defined %}
  174.                                                 {% if product.prijs is defined %}
  175.                                                     {% if product.productAPE %}
  176.                                                         € {{ product.prijs|number_format(2, ',', ' ') }} / {{ product.APEeenheid  | trans}}
  177.                                                     {% else %}
  178.                                                         € {{ product.prijs|number_format(2, ',', ' ') }}
  179.                                                     {% endif %}
  180.                                                 {% endif %}
  181.                                             {% endif %}
  182.                                         </div>
  183.                                         <div class="d-inline-block">
  184.                                             {% if product.stock <= 0 %}
  185.                                                 <span class="stockrood ms-1">
  186.                              <a href="#" data-bs-toggle="tooltip" data-bs-title="{{ 'momenteel niet voorradig'|trans }}"
  187.                                 data-bs-placement="right"><i class="fas fa-xs fa-circle"></i></a>
  188.                          </span>
  189.                                             {% elseif product.stock <= product.aantalVerkochtLaatsteMaand %}
  190.                                                 <span class="stockoranje ms-1">
  191.                                 <a href="#" data-bs-toggle="tooltip" data-bs-title="{{ 'beperkte voorraad'|trans }}"
  192.                                    data-bs-placement="right"><i class="fas fa-xs  fa-circle"></i></a></span>
  193.                                             {% elseif product.stock > product.aantalVerkochtLaatsteMaand %}
  194.                                                 <span class="stockgroen ms-1">
  195.                                 <a href="#" data-bs-toggle="tooltip" data-bs-title="{{ 'voldoende vooraad'|trans }}"
  196.                                    data-bs-placement="right"><i class="fas fa-xs fa-circle"></i></a></span>
  197.                                             {% endif %}
  198.                                         </div>
  199.                                         {#
  200.                                         <a href="{{ detailLink }}" class="btn btn-primary">{{ 'Meer lezen'|trans }}</a> #}
  201.                                     </div>
  202.                                 </div>
  203.                             {% else %}
  204.                                 <div class="col">
  205.                                     <div class="media-body text-center">
  206.                                         <a href="{{ detailLink }}">
  207.                                             {% if product.getFotos() is defined %}
  208.                                                 {% if product.getFotos() %}
  209.                                                     <div class="position-relative">
  210.                                                         <img src="{{ product.getFotos().getThumbnail('prod-thumb') }}"
  211.                                                              class="img-fluid">
  212.                                                     </div>
  213.                                                 {% else %}
  214.                                                     <div>
  215.                                                         <img src="/static/img/noimage.png" class="img-fluid">
  216.                                                     </div>
  217.                                                 {% endif %}
  218.                                             {% endif %}
  219.                                             <div class="fw-bold pt-3">
  220.                                                 {{ product.oms }}
  221.                                             </div>
  222.                                         </a>
  223.                                         <div class="d-inline-block">
  224.                                             {% if product.promoprijs is defined %}
  225.                                                 {% if product.promoprijs > 0 %}
  226.                                                     <div class="promoprijs">
  227.                                                         <div class="d-inline-block">
  228.                                                             {% if product.productAPE %}
  229.                                                                 {% set APE = product.prijs * product.AantalPerEenheid %}
  230.                                                                 {% set APEpromo = product.promoprijs * product.AantalPerEenheid %}
  231.                                                                 <strike>€ {{ APE|number_format(2, ',', ' ') }}</strike> <span>€ {{ APEpromo|number_format(2, ',', ' ') }}</span>
  232.                                                             {% else %}
  233.                                                                 <strike>€ {{ product.prijs|number_format(2, ',', ' ') }}</strike> <span>€ {{ product.promoprijs|number_format(2, ',', ' ') }}</span>
  234.                                                             {% endif %}
  235.                                                         </div>
  236.                                                     </div>
  237.                                                 {% else %}
  238.                                                     {% if product.productAPE %}
  239.                                                         {% set APE = product.prijs * product.AantalPerEenheid %}
  240.                                                         <br>€ {{ APE|number_format(2, ',', ' ') }}
  241.                                                     {% else %}
  242.                                                         <br>€ {{ product.prijs|number_format(2, ',', ' ') }}
  243.                                                     {% endif %}
  244.                                                 {% endif %}
  245.                                             {% endif %}
  246.                                         </div>
  247.                                         <div class="d-inline-block">
  248.                                             {% if product.stock <= 0 %}
  249.                                                 <span class="stockrood ms-1">
  250.                              <a href="#" data-bs-toggle="tooltip" data-bs-title="{{ 'momenteel niet voorradig'|trans }}"
  251.                                 data-bs-placement="right"><i class="fas fa-xs fa-circle"></i></a>
  252.                          </span>
  253.                                             {% elseif product.stock <= product.aantalVerkochtLaatsteMaand %}
  254.                                                 <span class="stockoranje ms-1">
  255.                                 <a href="#" data-bs-toggle="tooltip" data-bs-title="{{ 'beperkte voorraad'|trans }}"
  256.                                    data-bs-placement="right"><i class="fas fa-xs  fa-circle"></i></a></span>
  257.                                             {% elseif product.stock > product.aantalVerkochtLaatsteMaand %}
  258.                                                 <span class="stockgroen ms-1">
  259.                                 <a href="#" data-bs-toggle="tooltip" data-bs-title="{{ 'voldoende vooraad'|trans }}"
  260.                                    data-bs-placement="right"><i class="fas fa-xs fa-circle"></i></a></span>
  261.                                             {% endif %}
  262.                                         </div>
  263.                                         {#
  264.                                         <a href="{{ detailLink }}" class="btn btn-primary">{{ 'Meer lezen'|trans }}</a> #}
  265.                                     </div>
  266.                                 </div>
  267.                             {% endif %}
  268.                         {% endfor %}
  269.                     </div>
  270.                     <div class="row">
  271.                         <div class="col-12 pagination">
  272.                             {% include 'includes/pagination-product-ajax.html.twig' %}
  273.                         </div>
  274.                     </div>
  275.                     <div class="row mb-5">
  276.                         <div class="col-12 text-center">
  277.                             {% set categoryLink = app_product_grouplink(category) %}
  278.                             <a class="btn btn-outline-secondary"
  279.                                href="{% if check_websitesetting('product_document', 'document') %}{{ inotherlang('LocalizedDocument', pimcore_website_config('product_document')) }}{% endif %}">
  280.                                 <span class="material-symbols-outlined inline-icon">
  281. chevron_left
  282. </span> {{ 'Terug naar aanbod'|trans }}{# {{ category.oms }} #}
  283.                             </a>
  284.                         </div>
  285.                     </div>
  286.                 </div>
  287.             </div>
  288.         </div>
  289.     {% endif %}
  290. {% endblock %}