templates/Slivki/delivery/quantity_select.html.twig line 1

Open in your IDE?
  1. <div class="delivery-quantity-select-wrapp">
  2.     <div class="delivery-quantity-select bg-white{{ isMobile is defined ? ' float-right' }}{{ isOption is defined and isOption ? ' delivery-option-quantity-select disabled' }}">
  3.         <div class="input-group input-group-sm">
  4.             <div class="input-group-prepend {{ isBasket is defined  ? '' : 'js-dec-animation'}} ">
  5.                 <button class="{{ isMobile is defined ? 'btn' : 'delivery-btn' }} {{ isOption is defined and isOption ? ' delivery-option-items' }} delivery-change-quantity delivery-dec-quantity" type="button">
  6.                     <img class="delivery-dec-quantity-img" width="14" height="14" src="/images/order_page/dec.svg"/>
  7.                 </button>
  8.             </div>
  9.             {% set offerPrice = dish is defined ? dish.dataBySize is defined ? dish.dataBySize|first[0].offerPrice.value : dish.offerPrice|replace({',': '.'}) %}
  10.             {% if isMobileDevice() %}
  11.                 {% if hasSosediPurchaseForUser is defined (hasSosediPurchaseForUser == false and dish.id == 3178 or hasSosediPurchaseForUser == false and dish.id == 3179) %}
  12.                     <input
  13.                             type="tel"
  14.                             name="count[]"
  15.                             data-price="{{ dish is defined  ? dish.dataBySize is defined ? dish.dataBySize|first[0].regularPrice.value :
  16.                             dish.regularPrice }}"
  17.                             data-offer-price="{{ dish is defined ? dish.dataBySize is defined ? dish.dataBySize|first[0].offerPrice.value : (dish.regularPrice|number_format(2) -  dish.regularPrice|number_format(2)/100*10)|replace({',': '.'}) }}"
  18.                             data-id="{{ dish is defined ? dish.id }}"
  19.                             data-percode="{{ dish is defined and dish.productsPerCode is defined ? dish.productsPerCode : 0 }}"
  20.                             class="form-control {{ isBasket is defined  ? '' : 'js-input-animation'}} delivery-quantity{{ isOption is defined and isOption ? ' option-quantity' }}{{ dish.sauceNeed is defined and dish.sauceNeed ? ' need-sauces' }}"
  21.                             readonly
  22.                             placeholder=""
  23.                             value="{{ dish is defined and dish.inBasketCount is defined ? dish.inBasketCount : 0 }}"
  24.                     >
  25.                 {% else %}
  26.                     <input
  27.                             type="tel"
  28.                             name="count[]"
  29.                             data-price="{{ dish is defined  ? dish.dataBySize is defined ? dish.dataBySize|first[0].regularPrice.value :
  30.                             dish.regularPrice }}"
  31.                             data-offer-price="{{ offerPrice }}"
  32.                             data-id="{{ dish is defined ? dish.id }}"
  33.                             data-percode="{{ dish is defined and dish.productsPerCode is defined ? dish.productsPerCode : 0 }}"
  34.                             class="form-control {{ isBasket is defined  ? '' : 'js-input-animation'}}  delivery-quantity{{ isOption is defined and isOption ? ' option-quantity' }}{{ dish.sauceNeed is defined and dish.sauceNeed ? ' need-sauces' }}"
  35.                             readonly
  36.                             placeholder=""
  37.                             value="{{ dish is defined and  dish.inBasketCount is defined ? dish.inBasketCount : 0 }}"
  38.                     >
  39.                 {% endif %}
  40.             {% else %}
  41.                 <input
  42.                         type="tel"
  43.                         name="count[]"
  44.                         data-price="{{ dish is defined  ? dish.dataBySize is defined ? dish.dataBySize|first[0].regularPrice.value :
  45.                         dish.regularPrice }}"
  46.                         data-offer-price="{{ offerPrice }}"
  47.                         data-id="{{ dish is defined ? dish.id }}"
  48.                         data-percode="{{ dish is defined and dish.productsPerCode is defined ? dish.productsPerCode : 0 }}"
  49.                         class="form-control {{ isBasket is defined  ? '' : 'js-input-animation'}} delivery-quantity{{ isOption is defined and isOption ? ' option-quantity' }}{{ dish.sauceNeed is defined and dish.sauceNeed ? ' need-sauces' }}"
  50.                         readonly
  51.                         placeholder=""
  52.                         value="{{ dish is defined and  dish.inBasketCount is defined ? dish.inBasketCount : 0 }}"
  53.                 >
  54.             {% endif %}
  55.             <div class="input-group-append">
  56.                 <button class="{{ isMobile is defined ? 'btn' : 'delivery-btn' }} delivery-change-quantity delivery-inc-quantity" type="button">
  57.                     {% if showPriceIfNoSelected is defined and showPriceIfNoSelected %}
  58.                         {{ offerPrice }} р
  59.                     {% else %}
  60.                         <img width="14" height="14" src="/images/order_page/inc.svg"/>
  61.                     {% endif %}
  62.                 </button>
  63.             </div>
  64.         </div>
  65.     </div>
  66.     <input type="hidden" name="dishID[]" value="{{ dish is defined ? dish.id }}"/>
  67.     {% if dish.isSticks is defined %}
  68.         <input type="hidden" id="sticksID" value="{{ dish.id }}"/>
  69.     {% endif %}
  70.     {% if dish.isSoySauce is defined %}
  71.         <input type="hidden" id="soySauceID" value="{{ dish.id }}"/>
  72.     {% endif %}
  73.     {% if dish.isGinger is defined %}
  74.         <input type="hidden" id="gingerID" value="{{ dish.id }}"/>
  75.     {% endif %}
  76.     {% if dish.isWasabi is defined %}
  77.         <input type="hidden" id="wasabiID" value="{{ dish.id }}"/>
  78.     {% endif %}
  79. </div>