{if $products|count}
   <div class="top-products-wrapper">
      <h2 class="h5">{t}Aktuálně frčí{/t}</h2>
      <div class="row top-products"
           data-tracking-view='{get_gtm_data encode=true type='ecommerce' method='ProductsImpressions' data=['products' => $products, 'listType' => $listType, 'listId' => $listId]}'>
         {$photo_dimensions = $cfg.Photo.types['top_product'].size}
         {foreach $products->slice(0,3) as $product}
            <div class="col-xl-4 col-xxs-12{if $product@iteration == 2 or $product@iteration == 3} col-md-6{/if}">
               <div class="catalog">
                  <a href="{url s=product IDmodel=$product.model_old_id}#{$product.id}" class=""
                          {if $dbcfg.analytics.google_tag_manager.gtm_dl_version == '2'}
                             data-tracking-click='{get_gtm_data encode=true type='ecommerce' method='ProductClick' data=['product' => $product, 'position' => $product@iteration, 'listType' => $listType, 'listId' => $listId]}'
                          {else}
                             data-tracking-click="{['event'=>'productBox']|json_encode}"
                          {/if}
                     >

                     <img src="{get_photo photo=$product.image size=11}" alt="{$product.title}"
                          class="img-responsive" width="{$photo_dimensions[0]}" height="{$photo_dimensions[1]}">
                     <div class="content">
                        <p class="title-wrapper">
                           <span class="title">{$product.model_short_title}</span>
                           <span class="section">{$product.descr|default:$product.model_section}</span>
                        </p>

                        <div class="price-wrapper">
                           <div class="left">
                              <p class="volumes">
                                 {$product.title|replace:$product.model_title:''}
                              </p>
                              <p class="delivery"> {t}Skladem{/t}</p>
                           </div>

                           <div class="right">
                              {block "price"}
                                 {*{sumDiscount} todo: nefunguje sleva *}
                                 <p class="price">{$product.price_array|format_price}</p>
                              {/block}
                           </div>
                        </div>
                     </div>
                  </a>
               </div>
            </div>
         {/foreach}
      </div>
   </div>
{/if}
