{$quantityDiscounts = $dynamic_filter->getQuantityDiscounts()}

{if $quantityDiscounts}
   <div {if $focus}class="tab-pane{if !$filterFocusTabIsActive} active{/if}" id="quantityDiscounts" role="tabpanel"
        {else}class="filter-row filter-labels"{/if}>

       {if $filter_openers}
          <button type="button" class="filter-label"
                  data-opener="[data-opener-param-quantityDiscounts]">{t}Množstevní slevy{/t}</button>
       {else}
          <p class="filter-label">{t}Množstevní slevy{/t}</p>
       {/if}

      <div {if $filter_openers}class="opener-content" data-opener-param-quantityDiscounts{/if}>
          {foreach $quantityDiscounts as $quantityDiscount}
             <label class="custom-control custom-checkbox"
                    for="dynamic_filter[quantityDiscounts][{$quantityDiscount.piecesFrom}]">
                <input class="custom-control-input" type="checkbox"
                       name="dynamic_filter[quantityDiscounts][{$quantityDiscount.piecesFrom}]"
                       value="{$quantityDiscount.piecesFrom}"
                       data-filter-input="quantityDiscounts" id="dynamic_filter[quantityDiscounts][{$quantityDiscount.piecesFrom}]"
                       {if in_array($quantityDiscount.piecesFrom, $body.dynamic_filter.filterParams->getQuantityDiscounts())}checked{/if}
                >
                <span class="custom-control-indicator"></span>
                <span class="custom-control-text">
                     {t from=$quantityDiscount.piecesFrom}od {from} ks{/t}
                     <small>
                        (<span class="filter-count" data-filter-count="{$quantityDiscount.piecesFrom}">{$quantityDiscount.count}</span>)
                     </small>
                  </span>
             </label>
          {/foreach}
      </div>
   </div>
{/if}