{ifmodule PRODUCTS__SETS}
{insert_products_used_in_sets id=$body.product.id assign='used_in_set'}

{if $used_in_set|count > 0}
   <div class="product-in-set">
      <p class="title">{t}Kupte si tento produkt v setu a ušetříte{/t}</p>
      {$first_set = $used_in_set->current()}
      {$link = "href="|cat:{url s=product IDproduct=$first_set.id}}

      {if $used_in_set|count > 1}
         {$link = $link|cat:" data-focus-opener=\"used-in-set\""}
      {/if}
      {* @formatter:off *}
      <p>{t escape=false odkaz=$link}Tento produkt je možné koupit <a {odkaz}>výhodněji</a>.{/t}</p>
      {* @formatter:on *}
   </div>
   {if $used_in_set|count > 1}
      {include "focus/sets/focus.set-products.tpl" class="used-in-set"}
   {/if}
{/if}
{/ifmodule}
