templates/Slivki/mobile/header_menu.html.twig line 1

Open in your IDE?
  1. <nav id="headerMenu" class="navbar">
  2.     {% apply spaceless %}
  3.         <ul class="list-unstyled m-0 pt-1 d-flex align-items-center">
  4.             {% set currentPath = app.request.pathinfo %}
  5.             <li class="d-flex {{ currentPath == path('homepage') ? 'active' }}"><img class="mr-1" width="16" src="/images/icon_category.svg"/><a href="#" role="button" data-toggle="modal" data-target="#offerCategoryMenuPopup">Категории</a></li>
  6.             {% include "Slivki/mobile#{regional_template_path}/info_massage_block.html.twig" %}
  7.             {% if getCurrentCity().getID() == constant('Slivki\\Entity\\City::DEFAULT_CITY_ID') %}
  8.                 <li><a href="{{ base_url }}/eda/dostavka-edy?utm_source=main_menu">Доставка еды</a></li>
  9.             {% endif %}
  10.             {% block meOnMap %}
  11.                 <li>
  12.                     <a href="{{ base_url }}/map" target="_blank" class="d-flex pin-maps-header position-relative pr-3 py-1 violet-light-color">
  13.                         <img height="20" src="/images/pin.svg"/>
  14.                         <span>Я на карте</span>
  15.                     </a>
  16.                 </li>
  17.             {% endblock %}
  18.             {% if isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::SALES')) %}
  19.                 <li {{ currentPath == path('sales') ? 'class="active"' }}><a href="{{ base_url }}{{ path('sales') }}">Новости скидок</a></li>
  20.             {% endif %}
  21.             {% if isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::GIFTS')) and getCurrentCity().getID() == constant('Slivki\\Entity\\City::DEFAULT_CITY_ID') %}
  22.                 <li><a href="{{ base_url }}/gift">🎁 Подарки</a></li>
  23.             {% endif %}
  24.             {% set menuItem = getTestMenuItem(2) %}
  25.             {% set landingUrl = '/subscription-landing?utm_source=slivki&utm_medium=button&utm_campaign=slivki-header-mob' %}
  26.             {% if subscription is not null and subscription.status == constant('Slivki\\Bundle\\SubscriptionBundle\\Enum\\SubscriptionStatus::CANCELED') %}
  27.                 {% set landingUrl = '/profile/subscription/manage?utm_source=main_menu' %}
  28.             {% endif %}
  29.             {% set videoGuideURL = getURL(constant('Slivki\\Repository\\SeoRepository::RESOURCE_URL_SALE_CATEGORY'), constant('Slivki\\Entity\\Category::SALE_VIDEO_GUIDE_CATEGORY_ID')) %}
  30.             {% set flierUrl = path('flierLanding') %}
  31.             {% block vacancy %}
  32.                 <li>
  33.                     <a class="vakansii" href="{{ base_url }}/skidki-i-rasprodazhi/vakansii/minsk">Вакансии</a>
  34.                 </li>
  35.             {% endblock %}
  36.             {% if isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::FLIERS')) %}
  37.                 <li {{ currentPath == flierUrl ? 'class="active"' }}><a href="{{ flierUrl }}">Листовки</a></li>
  38.             {% endif %}
  39.             {% if isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::SUBSCRIPTION')) %}
  40.                 <li>
  41.                     <a href="{{ landingUrl }}">⚡️ Подписка</a>
  42.                 </li>
  43.             {% endif %}
  44.             {% if noToken is not defined and is_granted('ROLE_ADMIN_USER') %}
  45.                 <li><a class="text-danger" href="{{ base_url }}/worst">Плохие условия</a></li>
  46.             {% endif %}
  47.         </ul>
  48.     {% endapply %}
  49. </nav>