templates/Slivki/mobile/offer/details.html.twig line 1

Open in your IDE?
  1. {% set phoneNumbersWithoutGeoLocations = offer.getPhoneNumbersWithoutGeoLocations() %}
  2. {% extends 'Slivki/mobile/base.html.twig' %}
  3. {% block styles %}
  4.     <link rel="stylesheet" href="/css/swiper/swiper.min.css"/>
  5.     <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/fancybox/3.3.5/jquery.fancybox.min.css"/>
  6.     <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.9.0/slick.min.css"/>
  7.     <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.9.0/slick-theme.min.css"/>
  8.     <link rel="stylesheet" href="/admin/plugins/datetimepicker/css/bootstrap-datetimepicker.min.css">
  9.     <link rel="stylesheet" href="/admin/plugins/datatables/jquery.dataTables.min.css"/>
  10.     <link rel="stylesheet" href="/admin/plugins/colorpicker/bootstrap-colorpicker.min.css"/>
  11.     <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.8.0/Chart.min.css">
  12.     {{ parent() }}
  13.     <link href="/css/delivery.min.css?v={{ delivery_css_version }}" rel="stylesheet" type="text/css"/>
  14.     <link href="/mobile/css/offers.min.css?v={{ mobile_offers_css }}" rel="stylesheet" type="text/css"/>
  15.     <link href="/css/foodForGift.css?v={{ food_for_gift_css }}" rel="stylesheet" type="text/css"/>
  16.     <link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"
  17.           rel="stylesheet">
  18.     <link href=" /mobile/css/statistics_modal.css?v=3" rel="stylesheet" type="text/css"/>
  19. {% endblock %}
  20. {% block messenger %}{% endblock %}
  21. {% block ogimage %}
  22.     {% if detailMediaList|length > 0 %}
  23.         <meta property="og:image"
  24.               content="{{ app.request.getSchemeAndHttpHost() }}{{ getImageURL(detailMediaList|first, 522, 322) }}"/>
  25.         <meta property="og:image:width" content="522"/>
  26.         <meta property="og:image:height" content="322"/>
  27.     {% else %}
  28.         {{ parent() }}
  29.     {% endif %}
  30. {% endblock %}
  31. {% set isBatchCodesAllowed = app.user and app.user.isBatchCodesAllowed %}
  32. {% block content %}
  33.     {% set isPickupEnabled = offer.getOnlineOrderSettings().isPickupEnabled() is defined ? offer.getOnlineOrderSettings().isPickupEnabled() %}
  34.     {% set isDeliveryEnabled = offer.getOnlineOrderSettings().isDeliveryEnabled() is defined ? offer.getOnlineOrderSettings().isDeliveryEnabled() %}
  35.     {% if parentCategoryList %}
  36.         {% include 'Slivki/mobile/breadcrumbs.html.twig' with { 'parentCategoryList': parentCategoryList, 'supplierCategoryData': offer.getSupplierCategoryData() } only %}
  37.     {% endif %}
  38.     {% if isPickupEnabled or isDeliveryEnabled %}
  39.         <input id="deliveryMethodEnabled" type="hidden" value="{{ isDeliveryEnabled == '' ? '2' : '1' }}">
  40.     {% endif %}
  41.     <input id="offerPage" type="hidden" value="">
  42.     <input id="offerID" type="hidden" value="{{ offer.getID() }}">
  43.     <input id="isMedicalCenter" type="hidden"
  44.            value="{{ parentCategoryList and parentCategoryList[0].getID() == constant('Slivki\\Entity\\Category::MEDICAL_CENTER_CATEGORY_ID') }}">
  45.     <input type="hidden" id="stock-id" value="{{ offer.getID() }}">
  46.     <input type="hidden" id="stock-link" value="{{ app.request.getSchemeAndHttpHost() ~ app.request.getRequestUri() }}">
  47.     <div type="hidden" id="mobileVersionIndicator"></div>
  48.     {% if app.user and isSubscriber(app.user) %}
  49.         <input id="allowedCodesCountBySubscription" type="hidden" value="{{ allowedCodesCountBySubscription }}">
  50.     {% endif %}
  51.     {% if app.user %}
  52.         <input id="splitTotalCodesCountByUser" type="hidden" value="{{ app.user.getCodesCountByOffer(offer) }}">
  53.         <input type="hidden" id="customerID" value="{{ app.user.getID() }}"/>
  54.     {% endif %}
  55.     <meta content="{{ metaInfo.metaDescription }}"/>
  56.     <div id="offerDetails">
  57.         <div class="collapse-more-button"></div>
  58.         {% set isOfferFavourite = app.user ? app.user.isOfferFavourite(offer) : false %}
  59.         <div class="no-gutters pb-2">
  60.             <div class="col-12 col-sm-4">
  61.                 <div id="offerImageSlider" class="m-0 swiper-container">
  62.                     <div class="back-button" onclick="history.back();">
  63.                         <img src="/images/back-violet.svg"/>
  64.                     </div>
  65.                     {% if app.user() %}
  66.                         <div class="fovoutite-block"
  67.                              onclick="onFavouriteClickOffer({{ offer.getID() }}, {{ isOfferFavourite ? 'true' : 'false' }})">
  68.                             <img width="18" height="18"
  69.                                  src="{{ isOfferFavourite ? '/images/heart_active.svg' : '/images/heart.svg' }}"/>
  70.                         </div>
  71.                     {% endif %}
  72.                     {% if not offer.isWithoutCodes() %}
  73.                         <div class="discount-block">
  74.                             {{ offer.getDiscount() }}
  75.                         </div>
  76.                     {% endif %}
  77.                     {% if is_granted('ROLE_ADMIN') and not offer.isWithoutCodes() %}
  78.                         <div id="statisticsButton" data-toggle="modal" data-target="#statisticOffersPopup">
  79.                             <img width="37" height="37" src="/images/statistics.png"/>
  80.                         </div>
  81.                     {% endif %}
  82.                     <div class="swiper-wrapper"
  83.                          data-pixel={{ offer.getID() == constant('Slivki\\Entity\\Offer::BETERA_OFFER_ID') ? 'https://amc.yandex.ru/show?cmn_id=26372&plt_id=194140&crv_id=464042&evt_t=render&ad_type=banner&rnd=%system.random%' }}>
  84.                         {% set medias = offer.getDetailMedias() %}
  85.                         {% set mediaCount = medias|length %}
  86.                         {% if mediaCount > 1 %}
  87.                             {% for media in medias %}
  88.                                 <div class="swiper-slide">
  89.                                     {% if media.isYoutube() %}
  90.                                         <input class="js-src-video" type="hidden" value="https://www.youtube.com/embed/{{ media.getName() }}">
  91.                                     {% else %}
  92.                                         <img class="img-fluid lazyload" alt="{{ media.getDescription() }}"
  93.                                              src="{{ getImageURL(media, 1044, 644) }}"/>
  94.                                     {% endif %}
  95.                                 </div>
  96.                             {% endfor %}
  97.                         {% elseif mediaCount == 1 %}
  98.                             <div>
  99.                                 <img class="img-fluid lazyload" alt="{{ medias[0].getDescription() }}"
  100.                                      src="{{ getImageURL(medias[0], 1044, 644) }}"/>
  101.                             </div>
  102.                         {% endif %}
  103.                     </div>
  104.                     {% if mediaCount > 1 %}
  105.                         <div class="swiper-pagination mt-2"></div>
  106.                         <div class="swiper-button-next"></div>
  107.                         <div class="swiper-button-prev"></div>
  108.                     {% endif %}
  109.                 </div>
  110.             </div>
  111.             <div class="container-offers">
  112.                 <div class="tags-offers">
  113.                     {% if not offer.isWithoutCodes() %}
  114.                         <div class="tags-offers-item"
  115.                              data-toggle="tooltip"
  116.                              data-placement="top"
  117.                              data-html="true"
  118.                              data-original-title="Взято кодов <br> Всего <a>{{ multiplePoolOfferUsedCodesCount is defined ? multiplePoolOfferUsedCodesCount : usedCodesCount }}</a> </br> За сутки {{ todayPurchaseCount }} </br> За месяц {{ getOfferMonthlyPurchaseCount(offer.getID(), 30) }}">
  119.                             <img src="/images/offers/icon_people.svg"/>
  120.                             <p class="mb-0"><a>{{ multiplePoolOfferUsedCodesCount is defined ? multiplePoolOfferUsedCodesCount : usedCodesCount }}</a></p>
  121.                         </div>
  122.                     {% endif %}
  123.                     <div class="tags-offers-item view-count" class="view-count d-flex"
  124.                          data-toggle="tooltip"
  125.                          data-placement="top"
  126.                          data-html="true"
  127.                          data-original-title="Просмотров  </br> За сутки {{ todayVisitCount }}<br> За месяц <span class='m-0'><a>{{ visitCount }}</a></span>">
  128.                         <img src="/images/offers/statistic_1.svg"/>
  129.                         <p class="mb-0">{{ visitCount }}</p>
  130.                     </div>
  131.                     {% if not offer.isWithoutCodes() %}
  132.                         <div class="tags-offers-item"
  133.                              data-toggle="tooltip"
  134.                              data-placement="top"
  135.                              data-html="true"
  136.                              data-original-title="Кол-во продаж к кол-ву просмотров. <br> Конверсия за 30 дней">
  137.                             <img src="/images/offers/conversion.svg"/>
  138.                             <p class="mb-0">{{ getOfferConversion(offer.getID()) }}%</p>
  139.                         </div>
  140.                     {% endif %}
  141.                     <div class="tags-offers-item rating-block"
  142.                          data-html="true"
  143.                          data-toggle="tooltip"
  144.                          data-placement="top"
  145.                          data-original-title="Рейтинг компании <br> за 90 дней">
  146.                         <span>★</span>
  147.                         <p class="mb-0">{{ offer.getRating() }}</p>
  148.                     </div>
  149.                     {% if not offer.isWithoutCodes() %}
  150.                         <div class="tags-offers-item day-to-end"
  151.                              data-toggle="tooltip"
  152.                              data-placement="top"
  153.                              data-html="true"
  154.                              data-original-title="Дней до окончания <br> действия акции">
  155.                             <img src="/images/offers/icon_time.svg"/>
  156.                             <p class="mb-0">
  157.                                 {% if daysLeft > 0 %}
  158.                                     {{ daysLeft }} {{ ['день', 'дня', 'дней']|plural(daysLeft) }}
  159.                                 {% elseif daysLeft == 0 %}
  160.                                     <input type="hidden" id="daysLeft" value="{{ daysLeft }} &nbsp;"/>
  161.                                     <input type="hidden" id="hoursLeft" value="{{ hoursLeft }} &nbsp;"/>
  162.                                     <input type="hidden" id="minutesLeft" value="{{ minutesLeft }} &nbsp;"/>
  163.                                     <input type="hidden" id="secondsLeft"
  164.                                            value="{{ offer.getActiveTill().diff(date()).format('%s') }}"/>
  165.                                     <span id="hours">{{ hoursLeft }}&nbsp</span>час{{ ['', 'а', 'ов']|plural(hoursLeft) }}&nbsp;
  166.                                 {% endif %}
  167.                             </p>
  168.                         </div>
  169.                     {% endif %}
  170.                 </div>
  171.                 <p class="tittle-offers js-tittle-offer"
  172.                    style="color: {{ offer.getTitleFontColor() }};">{{ offer.getTitle()|raw }}</p>
  173.                 <div class="offers-description">
  174.                     {% if not pastOffer and offer.getFreeCodesCount() > 0 %}
  175.                         <div class="pb-3 d-flex border-bottom-gray">
  176.                             <div class="col px-0 price-services-tittle">Стоимость:</div>
  177.                             <del id="offerRegularPrice"
  178.                                  class="regular-price-offer">{{ offer.getRegularPrice() }}</del>
  179.                             &nbsp;&nbsp;
  180.                             <div class="price-services-new">{{ offer.getOfferPrice()|replace({'(': '<span id="details-offer-price">(', ')': ')</span>'})|raw }}</div>
  181.                             <input type="hidden" id="codeCost" value="{{ codeCost }}">
  182.                         </div>
  183.                     {% else %}
  184.                         <div class="card border-0 mt-3">
  185.                             <div class="card-body p-0 pl-2 text-center">
  186.                                 <i class="slivki-icon-minus-circled text-danger d-block h1 mb-0"></i>
  187.                                 Акция завершена
  188.                             </div>
  189.                         </div>
  190.                     {% endif %}
  191.                 </div>
  192.             </div>
  193.         </div>
  194.         {% if not pastOffer and offer.getFreeCodesCount() > 0 and offer.isOnlineOrderGiftEnabled() and offer.isFoodOnlineOrderAllowedOnSite() %}
  195.             <div class="col my-2">
  196.                 <a class="button-gift" data-toggle="modal" data-target="#choiceGiftModal">
  197.                     <div class="button-gift-text">
  198.                         <p class="mb-0">ЕДА В ПОДАРОК 😋</p>
  199.                         <p class="mb-0">Подарю сам или подарят мне</p>
  200.                     </div>
  201.                 </a>
  202.             </div>
  203.         {% endif %}
  204.         {% if not pastOffer and offer.isGiftCertificateOnlineOrderAllowedOnSite() and isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::SLIVKI_PAY_FOR_CERTIFICATE'))
  205.         %}
  206.             <div class="col my-2">
  207.                 {% if app.user %}
  208.                     <a class="button-gift" href="/virtual-wallet-pay">
  209.                         <div class="button-gift-text">
  210.                             <p class="mb-0">ТЕПЕРЬ МОЖНО</p>
  211.                             <p class="mb-0 color-violet">ОПЛАТИТЬ SLIVKI.PAY</p>
  212.                         </div>
  213.                         <div class="button-gift-item-button">
  214.                             <div class="new">NEW</div>
  215.                         </div>
  216.                     </a>
  217.                 {% else %}
  218.                     <a class="button-gift"  data-toggle="modal" data-target=".modal-auth">
  219.                         <div class="button-gift-text">
  220.                             <p class="mb-0">ТЕПЕРЬ МОЖНО</p>
  221.                             <p class="mb-0 color-violet">ОПЛАТИТЬ SLIVKI.PAY</p>
  222.                         </div>
  223.                         <div class="button-gift-item-button">
  224.                             <div class="new">NEW</div>
  225.                         </div>
  226.                     </a>
  227.                 {% endif %}
  228.             </div>
  229.         {% endif %}
  230.         {% if offer.isFoodOnlineOrderAllowedOnSite() and  offer.getOnlineOrderSettings() is not null and offer.getOnlineOrderSettings().allowedPaymentMethods['delivery'][4] == 1 and isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::SLIVKI_PAY')) and not pastOffer or
  231.             offer.isFoodOnlineOrderAllowedOnSite() and offer.getOnlineOrderSettings() is not null and offer.getOnlineOrderSettings().allowedPaymentMethods['pickup'][4] == 1 and isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::SLIVKI_PAY')) and not pastOffer %}
  232.             <div class="col my-2">
  233.                 {% if app.user %}
  234.                     <a class="button-gift" href="/virtual-wallet-pay">
  235.                         <div class="button-gift-text">
  236.                             <p class="mb-0">ТЕПЕРЬ МОЖНО</p>
  237.                             <p class="mb-0 color-violet">ОПЛАТИТЬ SLIVKI.PAY</p>
  238.                         </div>
  239.                         <div class="button-gift-item-button">
  240.                             <div class="new">NEW</div>
  241.                         </div>
  242.                     </a>
  243.                 {% else %}
  244.                     <a class="button-gift"  data-toggle="modal" data-target=".modal-auth">
  245.                         <div class="button-gift-text">
  246.                             <p class="mb-0">ТЕПЕРЬ МОЖНО</p>
  247.                             <p class="mb-0 color-violet">ОПЛАТИТЬ SLIVKI.PAY</p>
  248.                         </div>
  249.                         <div class="button-gift-item-button">
  250.                             <div class="new">NEW</div>
  251.                         </div>
  252.                     </a>
  253.                 {% endif %}
  254.             </div>
  255.         {% endif %}
  256.         <div class="sticky-element">
  257.             <div class="sticky-anchor"></div>
  258.             <div id="offerNavigation">
  259.                 <ul class="nav-list">
  260.                     <li class="nav-item"><a href="#offerDescriptionTab" class="nav-links active">
  261.                             Условия
  262.                         </a>
  263.                     </li>
  264.                     <li class="nav-item"><a href="#offerAddressTab" class="nav-links ">
  265.                             Контакты
  266.                         </a>
  267.                     </li>
  268.                     <li class="nav-item"><a href="#offerCommentTab" class="nav-links"><span></span>
  269.                             Отзывы
  270.                         </a>
  271.                     </li>
  272.                 </ul>
  273.             </div>
  274.         </div>
  275.         <div id="offerAccordion" class="accordion mt-2 px-2">
  276.             {% if not offer.isWithoutCodes() %}
  277.                 <div id="fixedButtonsBottom" class="accordion fixed py-3">
  278.                     {% if not offer.isBuyCodeDisable() %}
  279.                         <div id="buyButtonCard" class="card">
  280.                             <div class="card-header">
  281.                                 {% if offer.getID() == constant('Slivki\\Entity\\Offer::BOOKING_OFFER_ID') %}
  282.                                     <a href="#" class="m-0 card-link bg-slivki" data-toggle="modal"
  283.                                        data-target="#bookingItemPopup">
  284.                                         {{ offer.getBuyCodeButtonText() and offer.getBuyCodeButtonText() != '' ? offer.getBuyCodeButtonText() : 'Забронировать номер' }}
  285.                                     </a>
  286.                                 {% else %}
  287.                                     {% if not pastOffer and freeCodesCount > 0 %}
  288.                                         {% if not app.user %}
  289.                                             <a href="#" class="m-0 card-link bg-slivki by-code-button text-uppercase"
  290.                                                onclick="$('.modal-auth').modal()">
  291.                                                 {% if offerIsFreeForUser %}
  292.                                                     БЕСПЛАТНЫЙ ПРОМОКОД
  293.                                                 {% else %}
  294.                                                     {{ buyButtonLabel }}
  295.                                                 {% endif %}
  296.                                             </a>
  297.                                         {% else %}
  298.                                             <a href="javascript:void(0)" id="buyCodeButtonFake"
  299.                                                class="m-0 d-none card-link bg-slivki by-code-button">
  300.                                                 <img class="fixed-size" width="14" src="/images/loading-animation.gif"
  301.                                                      alt=""/>
  302.                                             </a>
  303.                                             {% if (offer.getID() == constant('Slivki\\Entity\\Offer::PETROL_OFFER_ID')) %}
  304.                                                 <a href="#"
  305.                                                    onclick="showFakeButton(); if (window.google_tag_manager) {ga('send', 'event', 'Buy code', 'Click', '{{ getURL("Slivki:Default:details", offer.getID()) }}');} document.location='/oplata-promokoda-azs'"
  306.                                                    class="m-0 card-link bg-slivki by-code-button" id="buyCodeButton">
  307.                                                     {% if offerIsFreeForUser %}
  308.                                                         БЕСПЛАТНЫЙ ПРОМОКОД
  309.                                                     {% else %}
  310.                                                         {{ buyButtonLabel }}
  311.                                                     {% endif %}
  312.                                                 </a>
  313.                                             {% else %}
  314.                                                 {% if isAllowedByOnlyCode %}
  315.                                                     {% if app.user and (isSubscriber(app.user) or isBatchCodesAllowed) and not offerIsFreeForUser and not offer.isBuyCodeInAppOnly() %}
  316.                                                         <a href="#" onclick="$('#buyPromoPopup').modal()"
  317.                                                            class="m-0 card-link bg-slivki by-code-button text-uppercase my-1"
  318.                                                            id="buyCodeButton">
  319.                                                             {{ buyButtonLabel }}
  320.                                                         </a>
  321.                                                     {% else %}
  322.                                                         {% if not app.user %}
  323.                                                             <a href="#" onclick="$('.modal-auth').modal()"
  324.                                                                class="m-0 card-link bg-slivki by-code-button text-uppercase my-1"
  325.                                                                id="buyCodeButton">
  326.                                                                 {{ buyButtonLabel }}
  327.                                                             </a>
  328.                                                         {% endif %}
  329.                                                         {% if offer.isBuyCodeInAppOnly() %}
  330.                                                             <a class="m-0 card-link bg-slivki by-code-button text-uppercase my-1"
  331.                                                                id="buyCodeButton"
  332.                                                                onclick="$('#byCodesAlwaysApp').modal()">
  333.                                                                 {{ buyButtonLabel }}
  334.                                                             </a>
  335.                                                         {% elseif not offer.isBuyCodeInAppOnly() %}
  336.                                                             {% if isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::PAYMENT_PAYME')) or isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::PAYMENT_CLICK')) %}
  337.                                                                 <a href="#"
  338.                                                                    class="m-0 card-link bg-slivki by-code-button text-uppercase my-1"
  339.                                                                    id="buyCodeButtonPayMeMobile"
  340.                                                                    data-target="#buyPromoPopupPayMe"
  341.                                                                    data-toggle="modal">
  342.                                                                     {{ buyButtonLabel }}
  343.                                                                 </a>
  344.                                                             {% else %}
  345.                                                                 <a href="#"
  346.                                                                    onclick="if (window.google_tag_manager) {ga('send', 'event', 'Buy code', 'Click', '{{ getURL("Slivki:Default:details", offer.getID()) }}');} showFakeButton();ym(20933521,'reachGoal','getcode-click'); document.location='{{ buyCodePopup == '#confirmBox' and canBuyFromBalance ? '/oplata-balance/' : '/oplata/' }}{{ offer.getID() }}'"
  347.                                                                    class="m-0 card-link bg-slivki by-code-button text-uppercase my-1"
  348.                                                                    id="buyCodeButton">
  349.                                                                     {{ buyButtonLabel }}
  350.                                                                 </a>
  351.                                                             {% endif %}
  352.                                                         {% endif %}
  353.                                                     {% endif %}
  354.                                                 {% endif %}
  355.                                             {% endif %}
  356.                                         {% endif %}
  357.                                     {% else %}
  358.                                         <a href="{{ categoryURL }}" class="m-0 card-link bg-slivki color-white">Посмотреть
  359.                                             похожие предложения</a>
  360.                                     {% endif %}
  361.                                 {% endif %}
  362.                             </div>
  363.                         </div>
  364.                     {% endif %}
  365.                     {% if items|length > 0 %}
  366.                         <div id="buyItemsButtonCard" class="card">
  367.                             <div class="card-header">
  368.                                 <a href="#" id="buyItemsButton" class="m-0 card-link bg-slivki" data-toggle="modal"
  369.                                    data-target="#offerItemsPopup">
  370.                                     {{ offer.getBuyItemsButtonText() and offer.getBuyItemsButtonText() != '' ? offer.getBuyItemsButtonText() : 'Оплатить сейчас по карте' }}
  371.                                 </a>
  372.                             </div>
  373.                         </div>
  374.                     {% endif %}
  375.                     {% if hasDelivery is defined and offer.getFreeCodesCount() > 0 %}
  376.                         <div id="deliveryButtonCard" class="card">
  377.                             <div class="card-header bg-transparent">
  378.                                 {% if not app.user %}
  379.                                     {% if offer.isTireOnlineOrderAllowedOnSite() %}
  380.                                         <a id="deliveryBtn" href="#" onclick="$('.modal-auth').modal()"
  381.                                            class="online-zapis js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  382.                                             Онлайн-запись
  383.                                         </a>
  384.                                     {% endif %}
  385.                                     {% if constant('Slivki\\Entity\\Offer::FREESTYLE_CERTIFICATE_OFFER_ID') == offer.getID() %}
  386.                                         <a href="#" onclick="$('.modal-auth').modal()"
  387.                                            class="card-link ml-0 py-3 bg-violet text-white rounded-14 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  388.                                             ПОЛУЧИТЬ СКИДКУ {{ offer.getDiscount() }}
  389.                                         </a>
  390.                                     {% else %}
  391.                                         {% if offer.isGiftCertificateOnlineOrderAllowedOnSite() and not offer.isFoodOnlineOrderAllowedOnSite() and offer.getID() != 283213 and offer.getID() != 288763 and offer.getID() != 288779 and offer.getID() != 288772 %}
  392.                                             <a id="deliveryBtn" href="{{ deliveryLink }}"
  393.                                                class="js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  394.                                                 Оплатить онлайн {{ offer.getDiscount() }}
  395.                                             </a>
  396.                                         {% elseif offer.isGiftCertificateOffer() and offer.getID() == 288763 or offer.isGiftCertificateOffer() and offer.getID() == 288779 or offer.isGiftCertificateOffer() and offer.getID() == 288772 %}
  397.                                             <a id="deliveryBtn" href="{{ deliveryLink }}"
  398.                                                class="js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  399.                                                 Получить скидку {{ offer.getDiscount() }}
  400.                                             </a>
  401.                                         {% elseif not offer.isGiftCertificateOffer() and not offer.isTireOnlineOrderAllowedOnSite() %}
  402.                                             <a id="deliveryBtn" href="{{ deliveryLink }}"
  403.                                                class="js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  404.                                                 Заказать онлайн {{ offer.getDiscount() }}
  405.                                             </a>
  406.                                         {% endif %}
  407.                                     {% endif %}
  408.                                 {% else %}
  409.                                     {% if offer.isTireOnlineOrderAllowedOnSite() %}
  410.                                         <a id="deliveryBtn" href="{{ offer.getOnlineRegistrationLink() }}"
  411.                                            class="online-zapis js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  412.                                             Онлайн-запись
  413.                                         </a>
  414.                                     {% endif %}
  415.                                     {% if offer.getID() in constant('Slivki\\Entity\\Offer::FREESTYLE_OFFER_IDS') %}
  416.                                         {% set deliveryBuyOnlyCodeLink = getLinkGiftCertificateOnlineOrderByOnlyCode(offer) %}
  417.                                         <a href="{{ deliveryBuyOnlyCodeLink }}"
  418.                                            onclick="document.location = `{{ deliveryBuyOnlyCodeLink }}`"
  419.                                            class="card-link ml-0 py-3 bg-violet text-white rounded-14 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  420.                                             ПОЛУЧИТЬ СКИДКУ {{ offer.getDiscount() }}
  421.                                         </a>
  422.                                     {% else %}
  423.                                         {% if offer.isGiftCertificateOnlineOrderAllowedOnSite() and not offer.isFoodOnlineOrderAllowedOnSite() %}
  424.                                             {% if offer.isGiftCertificateOnlineOrderAllowedOnSite() and offer.getID() != 283213 and offer.getID() != 288763 and offer.getID() != 288779 and offer.getID() != 288772 or offer.isGiftCertificateOffer() and not offer.isFoodOnlineOrderAllowedOnSite() %}
  425.                                                 <a href="{{ getLinkGiftCertificateOnlineOrder(offer) }}"
  426.                                                    onclick="document.location = `{{ getLinkGiftCertificateOnlineOrder(offer) }}`"
  427.                                                    class="js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  428.                                                     Оплатить онлайн {{ offer.getDiscount() }}
  429.                                                 </a>
  430.                                             {% elseif offer.isGiftCertificateOffer() and offer.getID() == 288763 or offer.isGiftCertificateOffer() and offer.getID() == 288779 or offer.isGiftCertificateOffer() and offer.getID() == 288772 %}
  431.                                                 <a href="{{ getLinkGiftCertificateOnlineOrder(offer) }}"
  432.                                                    onclick="document.location = `{{ getLinkGiftCertificateOnlineOrder(offer) }}`"
  433.                                                    class="js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  434.                                                     Получить скидку {{ offer.getDiscount() }}
  435.                                                 </a>
  436.                                             {% endif %}
  437.                                         {% else %}
  438.                                             {% if not offer.isTireOnlineOrderAllowedOnSite() %}
  439.                                                 <a href="{{ deliveryLink }}"
  440.                                                    onclick="document.location = `{{ deliveryLink }}`"
  441.                                                    class="js-buy-online card-link py-3 bg-violet text-white rounded-14 mx-0 text-uppercase{{ not offer.hasFreeCodes() ? ' opacity-05' }}">
  442.                                                     Заказать онлайн {{ offer.getDiscount() }}
  443.                                                 </a>
  444.                                             {% endif %}
  445.                                         {% endif %}
  446.                                     {% endif %}
  447.                                 {% endif %}
  448.                             </div>
  449.                         </div>
  450.                     {% endif %}
  451.                 </div>
  452.             {% endif %}
  453.             <div class="container-offers my-0 mx-0">
  454.                 <div id="offerDescriptionTab" class="mx-2 active" style="max-height: fit-content;">
  455.                     <div class="offer-titles mt-2"><h5>Условия</h5></div>
  456.                     {% if not offer.isWithoutCodes() and offer.getID() != 140553 %}
  457.                         {% set codeTill = offer.getCodeActiveTill() %}
  458.                         {% set codeFrom = offer.getActiveTill()|date_modify('-1 day') %}
  459.                         {% set codeFrom = codeFrom > codeTill ? codeTill : codeFrom %}
  460.                         {% if not offer.isHideFeatures() %}
  461.                             <p>- Получить промокод можно до {{ codeFrom|date('d.m') }}, воспользоваться {{ offer.getID() != 134390 ? 'до' }} {{ codeTill|date('d.m.y') }}.
  462.                             <br/>
  463.                         {% endif %}
  464.                         {% if offer.isShowPriceInConditions() and not offerIsFreeForUser %}
  465.                             - Стоимость промокода: {{ codeCost }} руб.
  466.                         {% endif %}</p>
  467.                     {% endif %}
  468.                     {{ offer.getConditions()|raw }}
  469.                     {# Таблица с прейскурантом для акции с квестами "Ящик Пандоры" #}
  470.                     {% if offer.getID() == 143528 %}
  471.                         <br>
  472.                         {% include 'Slivki/offers/table_for_pandorra_box_offer2.html.twig' %}
  473.                         <br>
  474.                     {% elseif offer.getID() == 282234 %}
  475.                         {% include 'Slivki/offers/table_for_pandorra_box_offer4.html.twig' %}
  476.                     {% endif %}
  477.                     {% if not offer.isHideFeatures() %}
  478.                         {% if not offer.isWithoutCodes() %}
  479.                             {% include "Slivki#{regional_template_path}/phrase_subscription_in_offer_page.html.twig" %}
  480.                         {% endif %}
  481.                         <br>
  482.                         <div class="offer-titles"><h5>Особенности</h5></div>
  483.                         <div class="offer-details-conditions">
  484.                             {% if not offer.isWithoutCodes() %}
  485.                                 - Скидка предоставляется только при наличии промокода.
  486.                             {% endif %}
  487.                             {{ offer.getFeatures()|raw }}
  488.                         </div>
  489.                         - Поставщик несет полную ответственность перед потребителем за достоверность информации.
  490.                     {% endif %}
  491.                     <div id="endOfOfferCondition"></div>
  492.                 </div>
  493.             </div>
  494.             {% if offer.getShopMedias()|length > 0 %}
  495.                 <div class="gallery-title offer-titles"><h5>Галерея</h5></div>
  496.             {% endif %}
  497.             <div class="my-4 screenshots {{ offer.getShopMedias()|length == 0 or freeCodesCount == 0 ? 'empty' }}">
  498.                 {% if offer.getShopMedias()|length > 0 %}
  499.                     <div class="screenshot-container">
  500.                         {% if  galleryVideos.getVideos() is defined and galleryVideos.getVideos()|length > 0 %}
  501.                             <div class="screenshot screenshot-story" data-toggle="modal"
  502.                                  data-target="#detailsStoryPopup">
  503.                                 <img src="{{ galleryVideos.getImageUrl() }}" width="158"
  504.                                      alt="Видео" border="0"/>
  505.                                 <div class="screenshot-story-btn"></div>
  506.                                 <div class="screenshot-story-tittle">{{ galleryVideos.getTitle() }}</div>
  507.                             </div>
  508.                         {% endif %}
  509.                         {% for media in offer.getShopMedias() %}
  510.                             <div class="screenshot">
  511.                                 <a data-fancybox="gallery1" href="{{ getImageURL(media, 0, 0) }}"
  512.                                    title="{{ media.getDescription() }}">
  513.                                     <img src="{{ getImageURL(media, 300, 0) }}" width="158"
  514.                                          alt="{{ media.getDescription() }}" border="0"/>
  515.                                 </a>
  516.                             </div>
  517.                         {% endfor %}
  518.                     </div>
  519.                 {% endif %}
  520.             </div>
  521.             <div id="examplesOfWorksBlock" class="examples-block-mobile">
  522.                 <div class="headerBlockCategory examples d-none bg-white px-0 pb-0 examples-block-mobile-header">
  523.                     <div class="offer-titles m-0"><h5>Фото
  524.                             работ{# <div class="example-of-works-count-container"><span>1234</span></div> #}</h5></div>
  525.                     <div class="examples-works-tooltip-filter">
  526.                         <div class="tooltip-content">
  527.                             <div class="tooltip-title border-bottom-f d-flex">Показать сначала:</div>
  528.                             {% for key,sortItem in constant('Slivki\\Paginator\\WorkExample\\WorkExamplePaginatorInterface::SORT') %}
  529.                                 <div class="radio">
  530.                                     <input id="filter{{ key }}" type="radio" name="filter"
  531.                                            data-direction="{{ sortItem.direction }}"
  532.                                            value="{{ sortItem.field }}" {{ loop.first ? 'checked' }}>
  533.                                     <label for="filter{{ key }}" class="cursor-pointer">{{ sortItem.name }}</label>
  534.                                 </div>
  535.                             {% endfor %}
  536.                             <div class="tooltip-title border-top-f d-flex">Диапазон цены:</div>
  537.                             <div id="workExamplePriceRangeInputs" class="price-range-inputs d-flex">
  538.                                 <div class="price-range-input"><input type="number" placeholder="Цена от" id="priceFrom"
  539.                                                                       name="priceFrom" min="0" max="199" step="1"></div>
  540.                                 <div class="price-range-input"><input type="number" placeholder="Цена до" id="priceTo"
  541.                                                                       name="priceTo" min="0" max="200" step="1"></div>
  542.                             </div>
  543.                             <div id="workExampleRangeSlider" class="range-slider">
  544.                                 <div class="range-labels">
  545.                                     <span id="workSimplesRangeLableStart" class="range-label range-label-start"></span>
  546.                                     <span>-</span>
  547.                                     <span id="workSimplesRangeLableEnd" class="range-label range-label-end"></span>
  548.                                 </div>
  549.                                 <input class="work-simples-input" type="range" min="" value="0" max="" name=""
  550.                                        id="startRange">
  551.                                 <input class="work-simples-input" type="range" min="" value="" max="" name=""
  552.                                        id="finishRange">
  553.                                 <div class="track-wrapper">
  554.                                     <div class="track"></div>
  555.                                     <div id="workSimplesSliderBetween" class="range-between"></div>
  556.                                     <div id="workSimplesTumbLeft" class="thumb left"></div>
  557.                                     <div id="workSimplesTumbRight" class="thumb right"></div>
  558.                                 </div>
  559.                             </div>
  560.                             <div id="buttonFilterBoxExamplesWork" class="buttonFilterBox">Показать</div>
  561.                         </div>
  562.                         <div id="buttonFilterBoxExamplesWork" class="d-flex cursor-pointer">Сортировка<img width="25" class="pl-2" src="/images/sort_image.svg"/></div>
  563.                     </div>
  564.                 </div>
  565.                 {% include 'Slivki/works-examples/examples_of_works_gallery.html.twig' %}
  566.             </div>
  567.             <div id="beautyMastersBlock" class="beauty-masters-container beauty-masters-offer mob">
  568.                 <div id="beautyMastersHeader"
  569.                      class="tittleBlockCategory position-relative offer-titles mb-2 mt-0 d-none">
  570.                     <h5> {{ parentCategoryList and parentCategoryList[0].getID() == constant('Slivki\\Entity\\Category::MEDICAL_CENTER_CATEGORY_ID') ? 'Врачи' : 'Найти своего мастера' }}</h5>
  571.                 </div>
  572.                 {% include 'Slivki/beauty/beauty_masters.html.twig' %}
  573.             </div>
  574.             <div id="offersDescription" class="offers-conditions mt-2 js-parallax-banner-after"
  575.                  style="padding-bottom: 22px;">
  576.                 {% if offer.isShowProductsInOfferDescription() %}
  577.                     <div id="foodItemsBlock" class="my-3">
  578.                         <div class="offer-titles mt-2"><h5>Описание</h5></div>
  579.                         {% if isPickupEnabled and isDeliveryEnabled %}
  580.                             <div id="fixedFiltersOffer" class="w-auto px-2 d-flex"
  581.                                  style="position: relative;background: linear-gradient(180deg, #A839FF 0%, #6747e5 100%), #6747E5;border-radius: 8px;padding: 10px 0;">
  582.                                 <div class="w-100 switch-delivery-pickup-block px-0 ">
  583.                                     <a data-type-delivery="1"
  584.                                        class="switch-delivery-pickup-item button-tab-delivery delivery-type active">
  585.                                         <p class="m-0">Доставка</p>
  586.                                         <small>удобно👌</small>
  587.                                     </a>
  588.                                     <a data-type-delivery="2"
  589.                                        class="switch-delivery-pickup-item pickup-type button-tab-pickup">
  590.                                         <p class="m-0"> Самовывоз</p>
  591.                                         <small>еще дешевле🔥</small>
  592.                                     </a>
  593.                                 </div>
  594.                             </div>
  595.                         {% endif %}
  596.                         <div id="foodBlock"></div>
  597.                         <div id="foodOptionsBlock"></div>
  598.                     </div>
  599.                 {% endif %}
  600.                 <div class="description" id="descriptionText">
  601.                     {% for offerDescription in offer.getDescriptionList() %}
  602.                         {% set offerDescriptionSliderImages = offerDescription.getEntityDescriptionSliderImages() %}
  603.                         {% if offerDescriptionSliderImages|length > 0 %}
  604.                             <div class="sale-description-carousel">
  605.                                 <div id="saleDescriptionSliderFor{{ offerDescription.getID() }}"
  606.                                      class="sale-description-slider-for">
  607.                                     {% for offerDescriptionSliderImage in offerDescriptionSliderImages %}
  608.                                         <div><img data-lazy="{{ offerDescriptionSliderImage.getImageUrl() }}"/>
  609.                                         </div>
  610.                                     {% endfor %}
  611.                                 </div>
  612.                             </div>
  613.                         {% endif %}
  614.                         {{ addLazyAndLightboxImagesInDescription(offerDescription.getDescription())|raw }}
  615.                     {% endfor %}
  616.                 </div>
  617.             </div>
  618.             <div id="offerAddressTab" class="mx-1 mt-5">
  619.                 <div class="offer-titles"><h5 class="mb-2">Контакты</h5></div>
  620.                 <div class="mb-4 logo-title">
  621.                     {{ offer.getLogo()|raw }}
  622.                 </div>
  623.                 <div class="p-m-0">
  624.                     {% if geoLocations.count() > 0 %}
  625.                         {% if geoLocations|length > 0 %}
  626.                             <div class="geo-location-block">
  627.                                 {% include 'Slivki/offers/geo_location_data.html.twig' with {'offer': offer} only %}
  628.                                 <div class="distance d-none" style="display: block">
  629.                                     <i class="slivki-icon slivki-icon-direction"></i> <img class='ajaxLoader'
  630.                                                                                            src='/images/ajax-loader-16x16.gif'
  631.                                                                                            alt='Загрузка...'/><span></span>
  632.                                 </div>
  633.                                 <div id="offerGeoLocationData" data-json="{{ offerGeoLocationData }}"></div>
  634.                                 <div id="offerMapWrapper" class="category-map-wrapper my-3">
  635.                                     <div id="offerMap" class="category-map"></div>
  636.                                     <a id="setUserLocationBtn" href="#">Указать местоположение</a>
  637.                                     <div id="zoomIn"></div>
  638.                                     <div id="zoomOut"></div>
  639.                                     <a id="mapEnterFullscreen" href="#" class="fullscreen-map-button">Развернуть</a>
  640.                                     <a id="mapExitFullscreen" href="#" class="fullscreen-map-button">Свернуть</a>
  641.                                 </div>
  642.                             </div>
  643.                         {% endif %}
  644.                     {% endif %}
  645.                     {% for geoLocation in geoLocations %}
  646.                         <div class="mb-3 my-3">
  647.                             <div class="sf-bold-font">{{ geoLocation.getCity() }}, {{ geoLocation.getStreet() }}
  648.                                 , {{ geoLocation.getHouse() }} {{ geoLocation.getLabel() }}</div>
  649.                             {% set phoneNumbers = geoLocation.getPhoneNumbers() %}
  650.                             {% if phoneNumbers|length > 0 %}
  651.                             {% endif %}
  652.                             {% for phoneNumber in phoneNumbers %}
  653.                                 {% include 'Slivki/mobile/offer/phone_number_btn.html.twig' with {'phoneNumber': phoneNumber, 'geoLocation': geoLocation} only %}
  654.                             {% endfor %}
  655.                             {% if geoLocation is defined and geoLocation.getCallbackChatId() and geoLocation.getCallbackChatId() != '' %}
  656.                                 <div class="callback-button" data-id="{{ geoLocation.getId() }}">Обратный звонок</div>
  657.                             {% endif %}
  658.                             {% if geoLocation.getWorkingHours()|trim != '' %}
  659.                                 <div>Время работы:</div> {{ geoLocation.getWorkingHours()|raw }}
  660.                             {% endif %}
  661.                         </div>
  662.                     {% endfor %}
  663.                     {% if phoneNumbersWithoutGeoLocations|length > 0 %}
  664.                     {% if geoLocations|length > 0 %}
  665.                         <br>
  666.                     {% endif %}
  667.                     <div id="phoneOffers" class="mb-2">
  668.                         <div class="mb-2">
  669.                             <strong>Телефон{{ phoneNumbersWithoutGeoLocations|length > 1 ? 'ы' }}:</strong>
  670.                         </div>
  671.                         {% for phoneNumber in phoneNumbersWithoutGeoLocations %}
  672.                             {% include 'Slivki/mobile/offer/phone_number_btn.html.twig' with {'phoneNumber': phoneNumber} only %}
  673.                         {% endfor %}
  674.                     </div>
  675.                 </div>
  676.                 {% endif %}
  677.                 {% set commonWoringHours = offer.getCommonWorkingHours() %}
  678.                 {% if commonWoringHours != '' %}
  679.                     <br>
  680.                     <div><strong>Время работы:</strong></div>
  681.                     {{ commonWoringHours|raw }}
  682.                     <br><br>
  683.                 {% endif %}
  684.                 {{ offer.getLegal()|raw }}
  685.                 <div class="offer-titles offer-titles-mobile mt-0 mb-0"><h5 class="mt-0 mb-0">Написать</h5></div>
  686.                 <div class="col px-0">
  687.                     <a class="tg-button offer-phone-mob btn btn-block bg-slivki text-white py-1 no-decoration my-2 d-flex justify-content-center align-items-center"
  688.                        href="https://t.me/{{ offer.getTelegram() != null ? offer.getTelegram() : 'slivkislivkiby' }}"
  689.                        style="width: 200px">
  690.                         <img class="mr-2" src="/images/tg.svg" width="20" height="18">
  691.                         <span class="float-right">Telegram</span>
  692.                     </a>
  693.                     {% set viberNumber = offer.getViber() != null ? offer.getViber() : '+375295084444' %}
  694.                     <a class="vb-button offer-phone-mob btn btn-block bg-slivki text-white py-1 no-decoration my-2 d-flex justify-content-center align-items-center"
  695.                        href='viber://chat?number="  {{ viberNumber }} "'
  696.                        style="width: 200px">
  697.                         <img class="mr-2" src="/images/vb.svg" width="20" height="18">
  698.                         <span class="float-right">Viber</span>
  699.                     </a>
  700.                 </div>
  701.             </div>
  702.             {% include 'Slivki/offers/share.html.twig' %}
  703.         </div>
  704.         <div id="offerCommentTab" class="pt-2 px-0">
  705.             <div>
  706.                 {{ comments|raw }}
  707.             </div>
  708.         </div>
  709.     </div>
  710.     </div>
  711.     {% if preview %}
  712.         <input type="hidden" id="offerPreview" value="1">
  713.     {% else %}
  714.         <input type="hidden" id="offerPreview" value="0">
  715.     {% endif %}
  716.     </div>
  717.     {% if showGlobalcard %}
  718.         {% include 'Slivki/mobile/offer/globalcard.html.twig' %}
  719.     {% elseif showGlobalcardFitness %}
  720.         {% include 'Slivki/mobile/offer/globalcard_fitness.html.twig' %}
  721.     {% endif %}
  722. {% endblock %}
  723. {% block popup %}
  724.     {% include 'Slivki/popups/header_offers.html.twig' %}
  725.     {% include 'Slivki/popups/mail_offers.html.twig' %}
  726.     {% include 'Slivki/popups/callback.html.twig' %}
  727.     {% include "Slivki#{regional_template_path}/jivosite/modal_mobile.html.twig" %}
  728.     {% if  galleryVideos.getVideos() is defined and galleryVideos.getVideos()|length > 0 %}
  729.         {% include 'Slivki/popups/details-story-popup.html.twig' %}
  730.     {% endif %}
  731.     {% include 'Slivki/orderAsGift/foodForGift.html.twig' with {'deliveryLink': deliveryLink} %}
  732.     {% if isServerFeatureEnabled(constant('Slivki\\Enum\\SwitcherFeatures::PAYMENT_PAYME')) %}
  733.         {% include 'Slivki/uz/mobile/buy_promo.twig' %}
  734.     {% endif %}
  735.     {% if app.user %}
  736.         {% include 'Slivki/popups/rating_edit_popup.html.twig' %}
  737.         {% include 'Slivki/mobile/popup/popup_subscription_limited.html.twig' %}
  738.         {% include 'Slivki/mobile/subscription/buy_promo_popup.html.twig' %}
  739.         {% include 'Slivki/mobile/popup/confirm_subscription_card_popup.html.twig' with {'creditCards': app.user.getActiveCreditCards()} %}
  740.         {% include 'Slivki/mobile/popup/buy_codes_avways_app.html.twig' %}
  741.         {% include 'Slivki/popups/add_favourite_popup.html.twig' %}
  742.         {% include 'Slivki/popups/delete_favourite_popup.html.twig' %}
  743.         {% include 'Slivki/popups/delete_comment_popup.html.twig' with {id: 'deleteCommentConfirmPopup'} %}
  744.     {% else %}
  745.         {% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
  746.     {% endif %}
  747.     {% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
  748.     {% include 'Slivki/mobile/popup/add_comment_popup.html.twig' %}
  749.     {% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
  750.     {% include 'Slivki/popups/comment_censor_message.html.twig' with {'id': 'commentCensorMessage'} %}
  751.     {% include 'Slivki/mobile/share_block.html.twig' %}
  752.     {% include 'Slivki/mobile/popup/statistics_popup.html.twig' %}
  753.     {% include 'Slivki/mobile/delivery/modal/details.html.twig' with {'isOfferPage': true} %}
  754.     {% if items|length > 0 %}
  755.         {% include 'Slivki/mobile/offer/extension/item/items_popup.html.twig' %}
  756.     {% endif %}
  757.     {% if offer.getID() == constant('Slivki\\Entity\\Offer::BOOKING_OFFER_ID') %}
  758.         {% include 'Slivki/mobile/offer/booking_popup.html.twig' %}
  759.     {% endif %}
  760.     {{ parent() }}
  761.     {% if offer.isGiftCertificateOffer() %}
  762.         {% include 'Slivki/popups/step_buy_certificate.twig' with {'deliveryLink': deliveryLink} %}
  763.     {% endif %}
  764.     {% include 'Slivki/mobile/popup/loading_popup.html.twig' %}
  765.     {% include 'Slivki/mobile/popup/contact_popup.html.twig' %}
  766. {% endblock %}
  767. {% block brandingBanner %}
  768.     {% if not (app.user and app.user.hasRole(constant('\\Slivki\\Entity\\UserGroup::ROLE_ADS_FREE'))) %}
  769.         {% set brandingBanner = getBrandingBanner(app.user, brandingBannerCategoryIDs is defined ? brandingBannerCategoryIDs : [], offer is defined ? offer.getID()) %}
  770.         {% if brandingBanner and brandingBanner.getMobileDivider() %}
  771.             <input type="hidden" id="brandingBannerImage" value="{{ brandingBanner.getMobileDivider() }}"
  772.                    data-oid="{{ brandingBanner.getID() }}" data-id="{{ brandingBanner.getBannerID() }}"
  773.                    data-branding="{{ brandingBanner.getBannerID() }}" data-url="{{ brandingBanner.getUrl()|trim }}"
  774.                    data-right-side-url="{{ brandingBanner.getRightSideUrl()|trim }}">
  775.         {% endif %}
  776.     {% endif %}
  777. {% endblock %}
  778. {% block javascripts %}
  779.     {{ parent() }}
  780.     <script src="/js/jquery.jcarousel.min.js?v=1"></script>
  781.     <script src="/js/story-slider/story-slider-js.js?v={{ story_slider_js_version }}"></script>
  782.     <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.lazyload/1.9.1/jquery.lazyload.min.js"
  783.             integrity="sha512-jNDtFf7qgU0eH/+Z42FG4fw3w7DM/9zbgNPe3wfJlCylVDTT3IgKW5r92Vy9IHa6U50vyMz5gRByIu4YIXFtaQ=="
  784.             crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  785.     <script type="text/javascript">
  786.         $(function () {
  787.             $('#floatingBanner').addClass('offer-details-floating-banner');
  788.         });
  789.     </script>
  790.     <!-- Moment -->
  791.     <script src="/admin/plugins/moment/moment-with-locales.js"></script>
  792.     <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.8.0/Chart.bundle.min.js"></script>
  793.     <script src="https://cdnjs.cloudflare.com/ajax/libs/fancybox/3.3.5/jquery.fancybox.min.js"></script>
  794.     <script src="/js/swiper-js/swiper.min.js"></script>
  795.     <script src="/js/offer-new.js?v={{ offer_new_js_version }}"/>
  796.     <script src="https://api-maps.yandex.ru/2.1/?lang=ru_RU" type="text/javascript"></script>
  797.     <script src="https://yastatic.net/es5-shims/0.0.2/es5-shims.min.js"></script>
  798.     <script src="https://yastatic.net/share2/share.js"></script>
  799.     <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.countdown/2.2.0/jquery.countdown.js"></script>
  800.     <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.maskedinput/1.4.1/jquery.maskedinput.min.js"></script>
  801.     <script src="https://cdnjs.cloudflare.com/ajax/libs/fecha/2.3.3/fecha.min.js"></script>
  802.     <script src="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.9.0/slick.min.js"></script>
  803.     <!-- date-time-picker -->
  804.     <script src="/admin/plugins/datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
  805.     <!-- colorpicker -->
  806.     <script src="/admin/plugins/colorpicker/bootstrap-colorpicker.min.js"></script>
  807.     <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-toast-plugin/1.3.2/jquery.toast.min.js"
  808.             integrity="sha512-zlWWyZq71UMApAjih4WkaRpikgY9Bz1oXIW5G0fED4vk14JjGlQ1UmkGM392jEULP8jbNMiwLWdM8Z87Hu88Fw=="
  809.             crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  810.     <script src="/mobile/js/offer.min.js?v={{ offer_js_version }}"></script>
  811.     <script type="text/javascript" src="/js/statistics_offer/statistics_offer.js?v={{ statistics_offer_js_version }}"
  812.             charset="utf-8"></script>
  813.     <script src="https://cdnjs.cloudflare.com/ajax/libs/easy-pie-chart/2.1.6/jquery.easypiechart.min.js"
  814.             integrity="sha512-DHNepbIus9t4e6YoMBSJLwl+nnm0tIwMBonsQQ+W9NKN6gVVVbomJs9Ii3mQ+HzGZiU5FyJLdnAz9a63ZgZvTQ=="
  815.             crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  816.     <script src="https://cdnjs.cloudflare.com/ajax/libs/easy-pie-chart/2.1.6/easypiechart.min.js"
  817.             integrity="sha512-1yldf7W5suy0ko2u4OGU1qyeGrzh9+A3uyWGH4ws8MbndaWxZsgnzy6uqqBq7NUU/ImI1Js5kqDbunovCN1JqA=="
  818.             crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  819.     <script src="/js/ajaxupload.3.5.js?v=1"></script>
  820.     <script src="/js/mobile-rating.js?v=2"></script>
  821.     <script>
  822.         uploadPhoto('/comment/image_upload', '/comment/image_remove');
  823.         initImageRemove();
  824.     </script>
  825.     <script type="text/javascript">
  826.         {% if app.request.query.has('checkOrder') %}
  827.         initCheckOfferOrderStatus({{ app.request.get('checkOrder') }});
  828.         {% endif %}
  829.     </script>
  830.     <script src="/js/offer/offerDescriptionItems.js?v={{ offer_description_items_js_version }}"></script>
  831.     <script type="module" src="/js/work_examples/work_examples.js?v={{ work_examples_js_version }}"></script>
  832.     <script type="module" src="/js/beauty/masters.js?v={{ beauty_masters_js_version }}"></script>
  833. {% endblock %}
  834. {% block RTBHouse %}
  835.     <script>
  836.         try {
  837.             (function () {
  838.                 var prefix = "", hash = "TS5TS2S9bdSbgKBA4Q2H", rtbhTags = [];
  839.                 rtbhTags.push("pr_" + hash + "_offer_" + document.getElementById('offerID').value);
  840.                 rtbhTags.push("pr_" + hash + "_uid_" + document.getElementById('rtbhUID').value);
  841.                 var key = "__rtbhouse.lid", lid = window.localStorage.getItem(key);
  842.                 if (!lid) {
  843.                     lid = "";
  844.                     var pool = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
  845.                     for (var i = 0; i < 20; i++) lid += pool.charAt(Math.floor(Math.random() * pool.length));
  846.                     window.localStorage.setItem(key, lid);
  847.                 }
  848.                 rtbhTags.push("pr_" + hash + "_lid_" + lid);
  849.                 var ifr = document.createElement("iframe"),
  850.                     sr = encodeURIComponent(document.referrer ? document.referrer : ""),
  851.                     su = encodeURIComponent(document.location.href ? document.location.href : ""),
  852.                     ifrSrc = "https://" + prefix + "creativecdn.com/tags?type=iframe",
  853.                     tmstmp = encodeURIComponent("" + Date.now());
  854.                 for (var i = 0; i < rtbhTags.length; i++) {
  855.                     ifrSrc += "&id=" + encodeURIComponent(rtbhTags[i]);
  856.                 }
  857.                 ifrSrc += "&su=" + su + "&sr=" + sr + "&ts=" + tmstmp;
  858.                 ifr.setAttribute("src", ifrSrc);
  859.                 ifr.setAttribute("width", "1");
  860.                 ifr.setAttribute("height", "1");
  861.                 ifr.setAttribute("scrolling", "no");
  862.                 ifr.setAttribute("frameBorder", "0");
  863.                 ifr.setAttribute("style", "display:none");
  864.                 ifr.setAttribute("referrerpolicy", "no-referrer-when-downgrade");
  865.                 if (document.body) {
  866.                     document.body.appendChild(ifr);
  867.                 } else {
  868.                     window.addEventListener('DOMContentLoaded', function () {
  869.                         document.body.appendChild(ifr);
  870.                     });
  871.                 }
  872.             })();
  873.         } catch (e) {
  874.         } </script>
  875. {% endblock %}