first commit
This commit is contained in:
14
web/templates/x/components/badges.tpl
Normal file
14
web/templates/x/components/badges.tpl
Normal file
@@ -0,0 +1,14 @@
|
||||
<div class="badges">
|
||||
<div class="fc icons_delivery">
|
||||
<span>Doprava zdarma <br>od {$free_delivery|format_price}</span>
|
||||
</div>
|
||||
<div class="fc icons_store">
|
||||
<span>Kamenná prodejna <br>ve Vrchlabí</span>
|
||||
</div>
|
||||
<div class="fc icons_trophy">
|
||||
<span>Věrnostní program <br>pro zákazníky</span>
|
||||
</div>
|
||||
<div class="fc icons_package">
|
||||
<span>99 % zboží <br>máme skladem</span>
|
||||
</div>
|
||||
</div>
|
||||
188
web/templates/x/components/block.autocomplete.tpl
Normal file
188
web/templates/x/components/block.autocomplete.tpl
Normal file
@@ -0,0 +1,188 @@
|
||||
{block "productsearch-template"}
|
||||
<script id="productSearch" type="text/x-dot-template">
|
||||
{$redirectUrl = {path('kupshop_content_redirect_redirect_1')}}
|
||||
<div class="container autocomplete-inner">
|
||||
{literal}
|
||||
{{? it.items.Produkty || it.items.Kategorie || it.items.Vyrobci || it.items.Clanky || it.items.Stranky }}
|
||||
|
||||
<div class="autocomplete-wrapper">
|
||||
{{? it.items.Kategorie }}
|
||||
<div class="autocomplete-categories">
|
||||
{/literal}
|
||||
<p class="title-default">{t}Kategorie{/t}</p>
|
||||
{literal}
|
||||
<ul>
|
||||
{{~it.items.Kategorie.items :item :index}}
|
||||
<li data-autocomplete-item="section">
|
||||
<a href="{/literal}{$redirectUrl}{literal}?type=category&id={{=item.id}}">{{=item.label}}</a>
|
||||
</li>
|
||||
{{~}}
|
||||
</ul>
|
||||
</div>
|
||||
{{?}}
|
||||
|
||||
{{? it.items.Vyrobci }}
|
||||
<div class="autocomplete-categories">
|
||||
<p class="title-default">{/literal}{t}Značky{/t}{literal}</p>
|
||||
<ul>
|
||||
{{~it.items.Vyrobci.items :item :index}}
|
||||
<li data-autocomplete-item="section">
|
||||
<a href="{/literal}{$redirectUrl}{literal}?type=producer&id={{=item.id}}">{{=item.label}}</a>
|
||||
</li>
|
||||
{{~}}
|
||||
</ul>
|
||||
</div>
|
||||
{{?}}
|
||||
|
||||
{{? it.items.Produkty }}
|
||||
<div class="autocomplete-products">
|
||||
{/literal}
|
||||
<p class="title-default">{t}Produkty{/t}</p>
|
||||
{literal}
|
||||
<ul>
|
||||
{{~it.items.Produkty.items :item :index}}
|
||||
{{? index < 4 }}
|
||||
<li class="autocomplete-product-item" data-autocomplete-item="product">
|
||||
<a href="{/literal}{$redirectUrl}{literal}?type=product&id={{=item.id}}">
|
||||
<div class="img">
|
||||
{{? item.image }}
|
||||
<img src="{{=item.image}}" alt="{{=item.label}}" class="img-fluid">
|
||||
{{??}}
|
||||
<img src="/common/static/images/no-img.png" alt="{{=item.label}}" class="img-fluid">
|
||||
{{?}}
|
||||
</div>
|
||||
<span class="title">{{=item.label}}</span>
|
||||
{/literal}
|
||||
{block "autocomplete-price"}
|
||||
{if $isB2BUser}
|
||||
{literal}
|
||||
{{? item.price }}
|
||||
<span class="price">{{=item.price_without_vat}}</span>
|
||||
{{?}}
|
||||
{/literal}
|
||||
{else}
|
||||
{literal}
|
||||
{{? item.price }}
|
||||
<span class="price">{{=item.price}}</span>
|
||||
{{?}}
|
||||
{/literal}
|
||||
{/if}
|
||||
{/block}
|
||||
{literal}
|
||||
</a>
|
||||
</li>
|
||||
{{?}}
|
||||
{{~}}
|
||||
</ul>
|
||||
</div>
|
||||
{{?}}
|
||||
|
||||
{/literal}
|
||||
<div class="ac-showall d-showall" data-autocomplete-item="show-all">
|
||||
<a href="" class="btn btn-primary btn-block">{t}Zobrazit všechny výsledky{/t}</a>
|
||||
</div>
|
||||
{literal}
|
||||
</div>
|
||||
|
||||
<div class="autocomplete-side">
|
||||
{{? it.items.Clanky }}
|
||||
<div class="autocomplete-articles">
|
||||
<p class="title-default">{/literal}{t}Články{/t}{literal}</p>
|
||||
<ul>
|
||||
{{~it.items.Clanky.items :item :index}}
|
||||
{{? index < 2 }}
|
||||
<li data-autocomplete-item="section">
|
||||
<a href="{/literal}{$redirectUrl}{literal}?type=article&id={{=item.id}}">
|
||||
{{? item.photo }}
|
||||
<img src="{{=item.photo}}" alt="{{=item.label}}" width="200" height="143" class="img-fluid">
|
||||
{{?}}
|
||||
{{=item.label}}
|
||||
</a>
|
||||
</li>
|
||||
{{?}}
|
||||
{{~}}
|
||||
</ul>
|
||||
</div>
|
||||
{{?}}
|
||||
{{? it.items.Stranky }}
|
||||
<div class="autocomplete-pages">
|
||||
<p class="title-default">{/literal}{t}Ostatní{/t}{literal}</p>
|
||||
<ul>
|
||||
{{~it.items.Stranky.items :item :index}}
|
||||
<li data-autocomplete-item="section">
|
||||
<a href="{{=item.url}}">
|
||||
{{=item.label}}
|
||||
</a>
|
||||
</li>
|
||||
{{~}}
|
||||
</ul>
|
||||
</div>
|
||||
{{?}}
|
||||
{/literal}
|
||||
<div class="ac-showall resp-showall" data-autocomplete-item="show-all">
|
||||
<a href="" class="btn btn-primary btn-block">{t}Zobrazit všechny výsledky{/t}</a>
|
||||
</div>
|
||||
{literal}
|
||||
</div>
|
||||
|
||||
{/literal}{* todo stránky *}{literal}
|
||||
|
||||
{{??}}
|
||||
<div class="autocomplete-noresult">
|
||||
<p>
|
||||
{/literal}
|
||||
{t}Žádný výsledek{/t}
|
||||
{literal}
|
||||
</p>
|
||||
</div>
|
||||
{{?}}
|
||||
{/literal}
|
||||
</div>
|
||||
</script>
|
||||
{/block}
|
||||
|
||||
{block "productsearch-script-outer"}
|
||||
{$preloadActive = !empty($dbcfg.fulltext.preload.products) || !empty($dbcfg.fulltext.preload.sections) || !empty($dbcfg.fulltext.preload.producers)}
|
||||
<script>
|
||||
{block "productsearch-script"}
|
||||
{ifmodule LUIGIS_BOX}
|
||||
var lb = '{$dbcfg.analytics.luigis_box.id|escape:'javascript'}';
|
||||
var lb_enabled = '{$dbcfg.analytics.luigis_box.search}';
|
||||
if (lb_enabled == 'A') {
|
||||
lb_enabled = '{if getAdminUser()}Y{else}N{/if}';
|
||||
}
|
||||
lb_enabled = (lb_enabled == 'Y');
|
||||
wpj.onReady.push(function() {
|
||||
if (!lb_enabled || wpj.storage.cookies.getItem('convert_lb_disable')) { // AB test
|
||||
$('[data-search-input]').productSearch({if $preloadActive}{
|
||||
preload: "{path('kupshop_catalog_search_searchpreload')}"
|
||||
}{/if});
|
||||
} else {
|
||||
$('[data-search-input]').productSearchLuigi({
|
||||
trackerId: lb,
|
||||
preload: "{path('kupshop_luigisbox_search_searchpreload')}",
|
||||
{if $ctrl.user}
|
||||
modifyData: (data, attributes) => {
|
||||
data.price = attributes.price_registered ?? data.price;
|
||||
return data;
|
||||
}
|
||||
{/if}
|
||||
});
|
||||
}
|
||||
});
|
||||
{elsemodule}
|
||||
wpj.onReady.push(function () {
|
||||
$('[data-search-input]').productSearch({
|
||||
{if $preloadActive}
|
||||
preload: "{path('kupshop_catalog_search_searchpreload')}",
|
||||
{/if}
|
||||
{ifmodule LOCALE_PREFIX}
|
||||
localePrefix: "/{$ctrl.active_language}",
|
||||
{/ifmodule}
|
||||
});
|
||||
});
|
||||
{/ifmodule}
|
||||
{/block}
|
||||
</script>
|
||||
{/block}
|
||||
|
||||
44
web/templates/x/components/block.b2b-panel.tpl
Normal file
44
web/templates/x/components/block.b2b-panel.tpl
Normal file
@@ -0,0 +1,44 @@
|
||||
<div class="b2b-panel">
|
||||
<div class="container">
|
||||
<div class="b2b-panel-inner">
|
||||
<div class="b2b-panel-icon">
|
||||
<span class="fc icons_user"></span>
|
||||
<p>
|
||||
{t}B2B klient{/t}
|
||||
<strong>
|
||||
{if $ctrl.firm}
|
||||
{$ctrl.firm}
|
||||
{elseif $ctrl.name && $ctrl.surname}
|
||||
{$ctrl.name} {$ctrl.surname}
|
||||
{else}
|
||||
{$ctrl.email}
|
||||
{/if}
|
||||
</strong>
|
||||
</p>
|
||||
</div>
|
||||
{block "b2b-panel-stats"}
|
||||
<div class="b2b-panel-icon">
|
||||
{get_stats type='user_spending' year=$smarty.now|date_format:"%Y" assign="user_spending"}
|
||||
<span class="fc icons_stats"></span>
|
||||
<p>
|
||||
{t}Obrat{/t} {$smarty.now|date_format:"%Y"}
|
||||
<strong>{$user_spending|format_price}</strong>
|
||||
</p>
|
||||
</div>
|
||||
{/block}
|
||||
<div class="b2b-panel-menu">
|
||||
<p>{t}Rychlý přístup{/t}</p>
|
||||
<ul class="list-inline">
|
||||
<li><a href="{path('account')}">{t}Můj účet{/t}</a></li>
|
||||
<li><a href="{path('orders')}">{t}Moje objednávky{/t}</a></li>
|
||||
{ifmodule WATCHDOG}
|
||||
<li><a href="{url s=category campaign="W"}">{t}Hlídané zboží{/t}</a></li>
|
||||
{/ifmodule}
|
||||
<li><a href="{url s=cart}">{t}Import objednávky{/t}</a></li>
|
||||
<li class="repeat-order"><a href="{path('orders')}"><span class="fc icons_repeat"></span>{t}Opakovat objednávku{/t}</a></li> {* todo *}
|
||||
{block "b2b-panel-menu-additional"}{/block}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
12
web/templates/x/components/block.js-add-to-favorites.tpl
Normal file
12
web/templates/x/components/block.js-add-to-favorites.tpl
Normal file
@@ -0,0 +1,12 @@
|
||||
{if !$product}
|
||||
{$product = $body.product}
|
||||
{/if}
|
||||
|
||||
{$js_favorites = [
|
||||
'productId' => intval($product.id),
|
||||
'title' => "{$product.title}",
|
||||
'gtmAddToWishlist' => {get_gtm_data encode=true type='ecommerce' method='AddToWishList' data=['products' => [$product], 'listType' => $listType, 'listId' => $listId]}
|
||||
]}
|
||||
<div data-js-favorites-product="{$js_favorites|json_encode}">
|
||||
<a href="{url s=login}" class="cart-signin btn-favorites"><span class="fc icons_heart"></span><span class="text">{$favorties_text|default:"{t}Přidat mezi oblíbené{/t}"}</span></a>
|
||||
</div>
|
||||
8
web/templates/x/components/block.product.submenu.tpl
Normal file
8
web/templates/x/components/block.product.submenu.tpl
Normal file
@@ -0,0 +1,8 @@
|
||||
{if $submenu_products.products|count}
|
||||
{$submenuProductsPhotos = $submenu_products.products->fetchPhotos(2)}
|
||||
<div class="submenu-product">
|
||||
{foreach $submenu_products.products as $product}
|
||||
{include 'components/block.products.item.tpl'}
|
||||
{/foreach}
|
||||
</div>
|
||||
{/if}
|
||||
16
web/templates/x/components/block.products.carousel.tpl
Normal file
16
web/templates/x/components/block.products.carousel.tpl
Normal file
@@ -0,0 +1,16 @@
|
||||
{if $products|count}
|
||||
<div class="products-carousel-wrapper" id="{$id}">
|
||||
<div class="container">
|
||||
<div data-wpj-carousel
|
||||
data-tracking-view='{get_gtm_data encode=true type='ecommerce' method='ProductsImpressions' data=['products' => $products, 'listType' => $listType, 'listId' => $listId]}'>
|
||||
{$products->fetchVariations(true)|silent}
|
||||
{$products->fetchPhotos(2)|silent}
|
||||
{foreach $products as $product}
|
||||
<div class="{$catalog_class|default:'col-xl-3 col-sm-4 col-xxs-6'}">
|
||||
{include "components/block.products.item.tpl"}
|
||||
</div>
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
6
web/templates/x/components/block.products.home.tpl
Normal file
6
web/templates/x/components/block.products.home.tpl
Normal file
@@ -0,0 +1,6 @@
|
||||
{if $products|count}
|
||||
<div class="container">
|
||||
<h2 class="text-center">{$title}</h2>
|
||||
</div>
|
||||
{include "components/block.products.carousel.tpl"}
|
||||
{/if}
|
||||
73
web/templates/x/components/block.products.item.tpl
Normal file
73
web/templates/x/components/block.products.item.tpl
Normal file
@@ -0,0 +1,73 @@
|
||||
<div class="catalog-outer">
|
||||
|
||||
<div class="catalog">
|
||||
{calc_product_discount product=$product assign='discount'}
|
||||
|
||||
{if $body.category.campaign_codes['F']}
|
||||
<a href="{url s=favorite IDp=$product.id acn=delete}" class="favourites-delete">
|
||||
<span class="fc lightbox_close"></span>
|
||||
</a>
|
||||
{/if}
|
||||
|
||||
<a href="{url s=product IDproduct=$product.id TITLE=$product.title}" class="product-link"{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]}'{/if}>
|
||||
<div class="img">
|
||||
<img src="{get_photo photo=$product.image size='product_catalog'}"
|
||||
width="{$cfg.Photo.types.product_catalog.size[0]}" height="{$cfg.Photo.types.product_catalog.size[1]}"
|
||||
class="img-responsive" alt="{$product.title}">
|
||||
</div>
|
||||
|
||||
<div class="catalog-flags flags">
|
||||
{block "catalog-flags"}
|
||||
{foreach $cfg.Products.Flags as $id => $flag}
|
||||
{if $product.campaign_codes[$id] and $flag.catalog_class}
|
||||
<span class="flag flag-{$flag.catalog_class}">{$flag.singular}</span>
|
||||
{/if}
|
||||
{/foreach}
|
||||
|
||||
{if $discount.discount->asFloat() >= 1}
|
||||
<span class="flag flag-discount" data-flag>-{$discount.discount->asFloat()|round} %</span>
|
||||
{/if}
|
||||
|
||||
{get_stats type='free_delivery' with_empty_purchasestate=true assign='free_delivery'}
|
||||
{if $free_delivery and $free_delivery->lowerThan($product.productPrice.value_with_vat)}
|
||||
<span class="flag flag-free-delivery">{t}Doprava zdarma{/t}</span>
|
||||
{/if}
|
||||
{/block}
|
||||
</div>
|
||||
|
||||
{include "components/block.products.review-stars.tpl"}
|
||||
|
||||
<p class="delivery delivery-{$product.deliveryTime}">
|
||||
{$product.deliveryTimeText}
|
||||
</p>
|
||||
|
||||
<h3 class="heading-reset title">
|
||||
{$product.title nofilter}
|
||||
</h3>
|
||||
|
||||
<p class="price">
|
||||
{if $discount.priceOriginal}
|
||||
<del class="strike-price" data-price-common>{$discount.priceOriginal|format_price}</del>
|
||||
{/if}
|
||||
|
||||
<strong>
|
||||
{if $isB2BUser}
|
||||
{if $product.price_array.price_without_vat->lessThan($product.priceMax.price_without_vat) and $product.variations|count}{t}od{/t}{/if}
|
||||
{$product.productPrice.value_without_vat|format_price}
|
||||
<small>{t}bez DPH{/t}</small>
|
||||
{else}
|
||||
{$product.productPrice|format_price}
|
||||
{/if}
|
||||
</strong>
|
||||
|
||||
{if $isB2BUser}
|
||||
{if $discount.retailPrice}
|
||||
<span class="price-moc">{t}MOC{/t} {$discount.retailPrice|format_price} {t}s DPH{/t}</span>
|
||||
{/if}
|
||||
{/if}
|
||||
</p>
|
||||
</a>
|
||||
|
||||
{include "block.products.variations.tpl"}
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,16 @@
|
||||
{encore_entry_script_tags entry='last_visited_products'}
|
||||
|
||||
{$params = []}
|
||||
{if $listType}{$params['listType'] = $listType}{/if}
|
||||
{if $listId}{$params['listId'] = $listId}{/if}
|
||||
|
||||
<script>
|
||||
wpj.onReady.push(function () {
|
||||
var placeholder = document.querySelector('.last-visited-products-placeholder');
|
||||
if (placeholder) {
|
||||
wpj.lastVisitedProducts.initLazy(placeholder, {$body.product.id|default:'null'}, {$params|@json_encode nofilter});
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="last-visited-products-placeholder"></div>
|
||||
17
web/templates/x/components/block.products.last-visited.tpl
Normal file
17
web/templates/x/components/block.products.last-visited.tpl
Normal file
@@ -0,0 +1,17 @@
|
||||
{if $last_visited_products.products|count}
|
||||
<div class="last-visited-products-wrapper">
|
||||
<div class="container">
|
||||
<h3 class="text-center">{t}Naposledy prohlédnuté{/t}</h3>
|
||||
<div class="last-visited-products-overlay">
|
||||
<div class="last-visited-products">
|
||||
{ifmodule PRODUCTS_VARIATIONS}
|
||||
{$last_visited_products.products->fetchVariations(true)|silent}
|
||||
{/ifmodule}
|
||||
{foreach $last_visited_products.products as $product}
|
||||
{include 'components/block.products.item.tpl'}
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
12
web/templates/x/components/block.products.review-stars.tpl
Normal file
12
web/templates/x/components/block.products.review-stars.tpl
Normal file
@@ -0,0 +1,12 @@
|
||||
{if $cfg.Modules.reviews.show_in_category or $product.rating}
|
||||
<div class="x-review-stars-wrapper">
|
||||
{if $product.rating.rating_count}
|
||||
<div class="review-stars">
|
||||
{for $i=1 to 5}
|
||||
<i class="fc {if $i > $product.rating.rating|round}icons_star_empty{else}icons_star_full{/if}"></i>
|
||||
{/for}
|
||||
</div>
|
||||
<span class="reviews-count">{$product.rating.rating_count}x</span>
|
||||
{/if}
|
||||
</div>
|
||||
{/if}
|
||||
9
web/templates/x/components/block.search.inline.tpl
Normal file
9
web/templates/x/components/block.search.inline.tpl
Normal file
@@ -0,0 +1,9 @@
|
||||
<div class="header-search-inline">
|
||||
<form method="get" action="{url s=search}">
|
||||
<input type="text" name="search" value="{$body.search}" maxlength="100" class="form-control autocomplete-control"
|
||||
placeholder="{$input_placeholder|default:"{t}Vyhledat...{/t}"}" autocomplete="off" data-search-input>
|
||||
<button name="submit" type="submit" value="{t}Hledat{/t}"
|
||||
class="btn btn-search {$btn_class|default:"fc icons_search"}">{$btn_text}</button>
|
||||
{* todo vyhodit ikonku z enginu *}
|
||||
</form>
|
||||
</div>
|
||||
14
web/templates/x/components/block.search.tpl
Normal file
14
web/templates/x/components/block.search.tpl
Normal file
@@ -0,0 +1,14 @@
|
||||
<div class="header-search-outer">
|
||||
<div class="header-search-inner" data-search-form>
|
||||
<div class="container">
|
||||
<form method="get" role="search" action="{url s=search}">
|
||||
<input type="text" name="search" value="{$body.search}" maxlength="100" class="form-control autocomplete-control"
|
||||
placeholder="{$input_placeholder|default:"{t}Hledaný výraz{/t}"}" aria-label="{$input_placeholder|default:"{t}Hledaný výraz{/t}"}" autocomplete="off" data-search-input>
|
||||
<button name="submit" type="submit" value="{t}Hledat{/t}" class="btn {$btn_search_class|default:"btn-primary btn-block"}"><span>{t}Hledat{/t}</span></button>
|
||||
<button class="search-toggle" data-toggle="search"><i class="fc lightbox_close"></i></button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{include "components/block.autocomplete.tpl"}
|
||||
22
web/templates/x/components/block.search.v2.tpl
Normal file
22
web/templates/x/components/block.search.v2.tpl
Normal file
@@ -0,0 +1,22 @@
|
||||
<div class="header-search-outer">
|
||||
<div class="header-search-inner" data-search-form>
|
||||
{block "search-responsive-header"}
|
||||
<div class="search-responsive-header">
|
||||
<button data-toggle="search">
|
||||
<span class="fc {$close_icon|default:'lightbox_close'}"></span>
|
||||
<span>{t}Vyhledat{/t}</span>
|
||||
</button>
|
||||
</div>
|
||||
{/block}
|
||||
<div class="container">
|
||||
<form method="get" action="{url s=search}">
|
||||
<input type="text" name="search" value="{$body.search}" maxlength="100" class="form-control autocomplete-control"
|
||||
placeholder="{$input_placeholder|default:"{t}Hledaný výraz{/t}"}" autocomplete="off" data-search-input data-search-input-resp tabindex="{$input_tabindex|default:0}">
|
||||
<button name="submit" type="submit" value="{t}Hledat{/t}"></button>
|
||||
<button class="search-clear" data-search-clear tabindex="{$input_tabindex|default:0}" aria-label="{t}Smazat{/t}"><i class="fc {$close_icon|default:'lightbox_close'}"></i></button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{include "components/block.autocomplete.tpl"}
|
||||
34
web/templates/x/components/block.slider.home-product.tpl
Normal file
34
web/templates/x/components/block.slider.home-product.tpl
Normal file
@@ -0,0 +1,34 @@
|
||||
<div class="catalog-outer">
|
||||
<div class="catalog">
|
||||
{calc_product_discount product=$product assign='discount'}
|
||||
|
||||
<a href="{url s=product IDproduct=$product.id TITLE=$product.title}" class="product-link">
|
||||
<div class="img">
|
||||
<img src="{get_photo photo=$product.image size='product_catalog'}"
|
||||
width="{$cfg.Photo.types.product_catalog.size[0]}" height="{$cfg.Photo.types.product_catalog.size[1]}"
|
||||
class="img-responsive" alt="{$product.title}">
|
||||
</div>
|
||||
|
||||
<div class="catalog-flags flags">
|
||||
{block "catalog-flags"}
|
||||
{if $discount.discount->asFloat() >= 1}
|
||||
<span class="flag flag-discount">-{$discount.discount->asFloat()|round} %</span>
|
||||
{/if}
|
||||
{/block}
|
||||
</div>
|
||||
|
||||
<h3 class="heading-reset title">
|
||||
{$product.title nofilter}
|
||||
</h3>
|
||||
|
||||
<p class="price">
|
||||
{if $discount.priceOriginal}
|
||||
<del class="strike-price">{$discount.priceOriginal|format_price}</del>
|
||||
{/if}
|
||||
<strong>
|
||||
{$product.productPrice|format_price}
|
||||
</strong>
|
||||
</p>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
11
web/templates/x/components/block.social.tpl
Normal file
11
web/templates/x/components/block.social.tpl
Normal file
@@ -0,0 +1,11 @@
|
||||
<div class="{$social_class}">
|
||||
{foreach $dbcfg.social as $name => $link}
|
||||
{if $link}
|
||||
<a href="{$link}" target="_blank" title="{$name|capitalize}" class="fc icons_{$name}">
|
||||
{if !$hide_title}
|
||||
<span>{$name}</span>
|
||||
{/if}
|
||||
</a>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</div>
|
||||
18
web/templates/x/components/block.switcher.tpl
Normal file
18
web/templates/x/components/block.switcher.tpl
Normal file
@@ -0,0 +1,18 @@
|
||||
<div class="header-switcher">
|
||||
{if !$hide_language}
|
||||
{$flag = $ctrl.active_language}
|
||||
<a href="" data-focus-opener="language-switcher" class="header-language">
|
||||
<img src="/common/static/images/flags/{$flag|replace:"en":"gb"}.svg" loading="lazy" width="17" height="17" class="img-responsive" alt="">
|
||||
<span>
|
||||
{$ctrl.active_language|replace:"cs":"cz"|upper}
|
||||
</span>
|
||||
</a>
|
||||
{/if}
|
||||
{if !$hide_currency}
|
||||
<a href="" data-focus-opener="currency-switcher" class="header-currency">
|
||||
<span>
|
||||
{$ctrl.active_currency|replace:"Kč":"CZK"}
|
||||
</span>
|
||||
</a>
|
||||
{/if}
|
||||
</div>
|
||||
17
web/templates/x/components/breadcrumbs.tpl
Normal file
17
web/templates/x/components/breadcrumbs.tpl
Normal file
@@ -0,0 +1,17 @@
|
||||
{block breadcrumbs}
|
||||
<ul class="breadcrumbs {$class}">
|
||||
{foreach $breadcrumbs as $item}
|
||||
{if $item.link and $item@index == 0 and !$hide_home}
|
||||
<li><a href="{$item.link}" title="{t}Zpět na úvod{/t}">{$home|default:"{t}Úvod{/t}"}</a></li>
|
||||
{elseif $item@last and !$hide_last}
|
||||
<li class="active">{$item.text}</li>
|
||||
{elseif $item.link and $item.link != "{url s=index}"}
|
||||
<li><a href="{$item.link}" title="{t kategorii=$item.text}Zpět na {kategorii}{/t}">{$item.text}</a></li>
|
||||
{/if}
|
||||
{foreachelse}
|
||||
<li>
|
||||
<a href="{url s=index}" title="{t}Zpět na úvod{/t}">{$home|default:"{t}Úvod{/t}"}</a>
|
||||
</li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
{/block}
|
||||
18
web/templates/x/components/cartbox-hover.tpl
Normal file
18
web/templates/x/components/cartbox-hover.tpl
Normal file
@@ -0,0 +1,18 @@
|
||||
{if $smarty.get.s != 'ordering' or isAjax()}
|
||||
<div class="cartbox">
|
||||
<div data-reload="cartinfo-products">
|
||||
{if $cartInfo.totalPieces >= 1}
|
||||
<div class="cartbox-title">
|
||||
<p>{t}Nákupní košík{/t}</p>
|
||||
<p>{$cartInfo.totalPrice}</p>
|
||||
</div>
|
||||
{include "block.products.cart-box.tpl" items=$cartInfo.items count=2}
|
||||
|
||||
{if !$isDealer}
|
||||
{include "components/shipping-progress.tpl" cartPrice=$cartInfo.totalPriceWithVat_array.value_with_vat}
|
||||
{/if}
|
||||
<a href="{url s=cart}" class="btn btn-block {$tpl_vars.cartbox_btn|default:'btn-primary'}">{t}Přejít do košíku{/t}</a>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
49
web/templates/x/components/cartbox-sidebar.tpl
Normal file
49
web/templates/x/components/cartbox-sidebar.tpl
Normal file
@@ -0,0 +1,49 @@
|
||||
<div class="cartbox-focus {if $no_simplebar}custom-scrollbar{/if}" data-cartbox>
|
||||
{block "cartbox-header"}
|
||||
<div class="cartbox-header">
|
||||
{block 'cartbox-title'}
|
||||
<p class="h3">{t}Nákupní košík{/t}</p>
|
||||
{/block}
|
||||
{block 'cartbox-hide'}
|
||||
<a href="#" class="fc lightbox_close" data-cartbox-hide></a>
|
||||
{/block}
|
||||
</div>
|
||||
{/block}
|
||||
|
||||
<div class="cartbox-product-list" {if !$no_simplebar}data-simplebar data-simplebar-auto-hide="false"{/if}>
|
||||
<div data-reload="cartbox-products">
|
||||
{if $cartInfo.items}
|
||||
{include "block.products.cart-box.tpl" items=$cartInfo.items image_size=$image_size count=$items_count}
|
||||
{else}
|
||||
<p class="no-items">{t}V košíku nemáte žádné zboží.{/t}</p>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="cartbox-footer">
|
||||
<div data-reload="cartbox-footer">
|
||||
{block "cartbox-footer"}
|
||||
{if !$isDealer}
|
||||
{include "components/shipping-progress.tpl" cartPrice=$cartInfo.totalPriceWithVat_array.value_with_vat}
|
||||
{/if}
|
||||
{block 'price-summary'}
|
||||
<div class="price-title">{t}Mezisoučet{/t}
|
||||
<strong class="total-price h3">{$cartInfo.totalPrice}</strong>
|
||||
|
||||
{*{get_cart_savings assign='cartSavings'}
|
||||
{if $cartSavings->isPositive()}
|
||||
<span>{t}Ušetříte{/t} {$cartSavings|format_price}</span>
|
||||
{/if}*}
|
||||
</div>
|
||||
{/block}
|
||||
|
||||
{block 'cartbox-btns'}
|
||||
<a href="{url s=cart}" class="btn btn-block btn-primary{if $cartInfo.totalPieces == 0} disabled{/if}">{t}Do košíku{/t}</a>
|
||||
{/block}
|
||||
{/block}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cartbox-bg" data-cartbox></div>
|
||||
<div class="cartbox-overlay" data-cartbox data-cartbox-hide></div>
|
||||
83
web/templates/x/components/header.tpl
Normal file
83
web/templates/x/components/header.tpl
Normal file
@@ -0,0 +1,83 @@
|
||||
{include "components/infoPanel.tpl"}
|
||||
{block "header-top"}
|
||||
<div class="header-top">
|
||||
<div class="container-fluid display-flex">
|
||||
<p>{t}Máte nějaký dotaz?{/t} <a href="tel:{$dbcfg.shop_phone}">{$dbcfg.shop_phone}</a> <a
|
||||
href="mailto:{$dbcfg.shop_email}">{$dbcfg.shop_email}</a></p>
|
||||
|
||||
<div class="top-menu-wrapper">
|
||||
{insert_menu label="menu_header" level_max=0}
|
||||
{if $cfg.tpl.language_currency_switcher}
|
||||
{include "components/block.switcher.tpl" hide_language=false hide_currency=false}
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
<header class="header {block "header-class"}{/block}">
|
||||
<div class="container-fluid display-flex">
|
||||
|
||||
<div class="header-burger header-icon">
|
||||
{ifmodule "JS_MENU"}
|
||||
<button type="button" onclick="window.wpj.mobilemenu.open()">
|
||||
<span class="fc icons_burger"></span>
|
||||
</button>
|
||||
{elsemodule}
|
||||
<button type="button" data-toggle="burger">
|
||||
<span class="fc icons_burger"></span>
|
||||
</button>
|
||||
{/ifmodule}
|
||||
</div>
|
||||
|
||||
<a href="{url s=index}" title="{$dbcfg.index_title}" class="logo">
|
||||
<img src="/templates/images/logo.svg" alt="{$dbcfg.index_title}" class="img-responsive">
|
||||
</a>
|
||||
|
||||
<div class="header-sections">
|
||||
{block "tpl-vars"}
|
||||
{$tpl_vars.submenu_v = $cfg.tpl.submenu.version}
|
||||
{/block}
|
||||
|
||||
{if $tpl_vars.submenu_v == 2}
|
||||
{$level_max = 2}
|
||||
{else}
|
||||
{$level_max = 1}
|
||||
{/if}
|
||||
{insert_sections template="block.sections.header.tpl" level_max=$level_max}
|
||||
|
||||
</div>
|
||||
|
||||
<div class="header-icons">
|
||||
<div class="header-search header-icon">
|
||||
<a href="{url s=search}" data-toggle="search">
|
||||
<span class="fc icons_search"></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
{* pokud tohle odkopíruješ, smaž `ifmodule` a nech jen tu verzi, co používáš (JS nebo klasik) *}
|
||||
{ifmodule "JS_SHOP"}
|
||||
<div class="header-login header-icon" id="js-shop-user">
|
||||
<a href="{url s=login}" class="cart-signin">
|
||||
<span class="fc icons_user"></span>
|
||||
</a>
|
||||
</div>
|
||||
{include "components/jsShop.cartInfo.tpl"}
|
||||
{elsemodule}
|
||||
<div class="header-login header-icon {if !$ctrl.logged}cart-signin{/if}">
|
||||
<a href="{if !$ctrl.logged}{url s=login}{else}{url s=account}{/if}">
|
||||
<span class="fc icons_user">{if $ctrl.logged}<span class="logged"></span>{/if}</span>
|
||||
</a>
|
||||
</div>
|
||||
{insert_cart_info}
|
||||
{/ifmodule}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{if $cfg.tpl.header_search.version == 2}
|
||||
{include "components/block.search.v2.tpl"}
|
||||
{else}
|
||||
{include "components/block.search.tpl"}
|
||||
{/if}
|
||||
</header>
|
||||
|
||||
{block "header-sticky-helper"}{/block}
|
||||
10
web/templates/x/components/instafeed.tpl
Normal file
10
web/templates/x/components/instafeed.tpl
Normal file
@@ -0,0 +1,10 @@
|
||||
<div class="instafeed-wrapper">
|
||||
<div class="instafeed-header">
|
||||
<h3>
|
||||
{$title|default:"{t}Naše sociální sítě{/t}"}
|
||||
</h3>
|
||||
{include "components/block.social.tpl" social_class='social-links'}
|
||||
</div>
|
||||
|
||||
<div id="instafeed" class="instafeed"></div>
|
||||
</div>
|
||||
67
web/templates/x/components/pager.tpl
Normal file
67
web/templates/x/components/pager.tpl
Normal file
@@ -0,0 +1,67 @@
|
||||
{if $pager.count > 1 or isAjax()}
|
||||
{$tmp = $pager->setPageInside(2)}
|
||||
<div data-loader-wrapper> {* neodstranovat div, je tu kvuli JS *}
|
||||
<div class="page-loader-wrapper" data-loader-content>
|
||||
{if $load_button and $pager.number < $pager.count}
|
||||
<button class="btn btn-loader no-js-hide" data-filter-loader>
|
||||
{$loader_text|default:"{t}Načíst další{/t}"}
|
||||
</button>
|
||||
{/if}
|
||||
|
||||
<ul class="pagination">
|
||||
<li>
|
||||
{$pg = $pager.number - 1}
|
||||
|
||||
<a {if $pager.number > 1}href="{$pager->getUrl(["page" => $pg])}"{/if}
|
||||
class="{$btn_pager_class|default:"btn btn-pager"} btn-pager-prev"
|
||||
data-filter-page="{$pg}" {if $pager.number == 1}disabled{/if}>
|
||||
{if $show_arrows}
|
||||
<i class="fc lightbox_left"></i>
|
||||
{else}
|
||||
<span>{t}Předchozí{/t}</span>
|
||||
{/if}
|
||||
</a>
|
||||
</li>
|
||||
|
||||
{if $pager.first}
|
||||
{for $page=1 to $pager.pageSideCount}
|
||||
<li><a href="{$pager->getUrl(["page" => $page ])}" data-filter-page="{$page}">{$page}</a></li>
|
||||
{/for}
|
||||
{if $pager.firstDots}
|
||||
<li>…</li>
|
||||
{/if}
|
||||
{/if}
|
||||
|
||||
{for $page=$pager.number-$pager.pageInsideCount to $pager.number+$pager.pageInsideCount}
|
||||
{if $page > 0 and $page <= $pager.count}
|
||||
<li {if $pager.number == $page}class="active"{/if}>
|
||||
<a href="{$pager->getUrl(["page" => $page ])}" data-filter-page="{$page}">{$page}</a>
|
||||
</li>
|
||||
{/if}
|
||||
{/for}
|
||||
|
||||
{if $pager.last}
|
||||
{if $pager.lastDots}
|
||||
<li>…</li>
|
||||
{/if}
|
||||
{for $page=$pager.count-$pager.pageSideCount+1 to $pager.count}
|
||||
<li><a href="{$pager->getUrl(["page" => $page ])}" data-filter-page="{$page}">{$page}</a></li>
|
||||
{/for}
|
||||
{/if}
|
||||
|
||||
<li>
|
||||
{$pg = $pager.number + 1}
|
||||
<a {if $pager.number < $pager.count}href="{$pager->getUrl(["page" => $pg])}"{/if}
|
||||
class="{$btn_pager_class|default:"btn btn-pager"} btn-pager-next"
|
||||
data-filter-page="{$pg}" {if $pager.number == $pager.count}disabled{/if}>
|
||||
{if $show_arrows}
|
||||
<i class="fc lightbox_right"></i>
|
||||
{else}
|
||||
<span>{t}Další{/t}</span>
|
||||
{/if}
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
79
web/templates/x/components/sections.responsive.links.tpl
Normal file
79
web/templates/x/components/sections.responsive.links.tpl
Normal file
@@ -0,0 +1,79 @@
|
||||
{function sectionsRespTree}
|
||||
{foreach $sectionList as $item}
|
||||
{$photo_dimensions = $cfg.Photo.types["subsections"].size}
|
||||
<li class="nav-item nav-item-{$item.id}" data-level="{$item.level}">
|
||||
{if $item.submenu}
|
||||
<span class="toggle-sub">
|
||||
{block "sections-responsive-image"}
|
||||
{if $item.level > 0 and $item.photo}
|
||||
<span class="figure">
|
||||
<img src="{get_photo photo=$item.photo type=section size='subsections'}"
|
||||
loading="lazy" alt="{$item.title_short}" width="{$photo_dimensions[0]}" height="{$photo_dimensions[1]}"
|
||||
class="img-responsive">
|
||||
</span>
|
||||
{/if}
|
||||
{/block}
|
||||
{$item.title_short}
|
||||
</span>
|
||||
<ul class="sub-nav">
|
||||
{block "sections-responsive-subnav"}
|
||||
<li class="sub-heading toggle-back">{t}zpět{/t}</li>
|
||||
{sectionsRespTree sectionList=$item.submenu}
|
||||
<li class="sub-heading nav-item nav-item-{$item.id}">
|
||||
<a href="{url s=category IDcat=$item.id}">
|
||||
<span>{t}Všechny produkty{/t}</span>
|
||||
<span class="fc icons_allproducts"></span>
|
||||
</a>
|
||||
</li>
|
||||
{/block}
|
||||
</ul>
|
||||
{else}
|
||||
<a href="{url s=category IDcat=$item.id}" class="sub-item">
|
||||
{block "sections-responsive-image"}
|
||||
{if $item.level > 0 and $item.photo}
|
||||
<span class="figure">
|
||||
<img src="{get_photo photo=$item.photo type=section size='subsections'}"
|
||||
loading="lazy" alt="{$item.title_short}" width="{$photo_dimensions[0]}" height="{$photo_dimensions[1]}"
|
||||
class="img-responsive">
|
||||
|
||||
</span>
|
||||
{/if}
|
||||
{/block}
|
||||
{$item.title_short}
|
||||
</a>
|
||||
{/if}
|
||||
</li>
|
||||
{/foreach}
|
||||
{/function}
|
||||
|
||||
{if not $fromCache}
|
||||
<ul class="nav list-unstyled">
|
||||
{sectionsRespTree sectionList=$categories}
|
||||
</ul>
|
||||
{else}
|
||||
{if $selection}
|
||||
<script>
|
||||
wpj.onReady.push(function () {
|
||||
var hasChildSelection = false;
|
||||
var $sectionsResponsive = $("[data-sections-responsive]");
|
||||
|
||||
{foreach $selection as $item}
|
||||
{if $item@last}
|
||||
if ($sectionsResponsive.find(".nav-item-{$item}").closest('.sub-nav').length) {
|
||||
hasChildSelection = true;
|
||||
}
|
||||
$sectionsResponsive.find(".nav-item-{$item}").addClass('active').closest(".active-parent").removeClass("active-parent").addClass("active");
|
||||
{else}
|
||||
$sectionsResponsive.find(".nav-item-{$item}").addClass("active-parent");
|
||||
{/if}
|
||||
{/foreach}
|
||||
|
||||
if (hasChildSelection) {
|
||||
$sectionsResponsive.addClass("has-child-selection");
|
||||
} else {
|
||||
$sectionsResponsive.removeClass("has-child-selection");
|
||||
}
|
||||
});
|
||||
</script>
|
||||
{/if}
|
||||
{/if}
|
||||
22
web/templates/x/components/sections.responsive.tpl
Normal file
22
web/templates/x/components/sections.responsive.tpl
Normal file
@@ -0,0 +1,22 @@
|
||||
<div class="sections-responsive" data-sections-responsive>
|
||||
{block "sections-responsive-header"}
|
||||
<div class="sections-responsive-header">
|
||||
<button data-toggle="burger">
|
||||
<span class="fc lightbox_close"></span>
|
||||
<span>{t}Zavřít{/t}</span>
|
||||
</button>
|
||||
<div class="responsive-switcher">
|
||||
{if $cfg.tpl.language_currency_switcher}
|
||||
{include "components/block.switcher.tpl" hide_language=false hide_currency=false}
|
||||
{/if}
|
||||
</div>
|
||||
{block "sections-responsive-header-additional"}
|
||||
{/block}
|
||||
</div>
|
||||
{/block}
|
||||
{insert_sections template="components/sections.responsive.links.tpl" level=$level|default:0}
|
||||
{block 'additional-menu-items'}
|
||||
{insert_menu label="menu_header" level_max=0 menu_class='resp-menu-additional' ul_class='nav list-unstyled'}
|
||||
{/block}
|
||||
</div>
|
||||
<div class="menu-focus"></div>
|
||||
25
web/templates/x/components/shipping-progress.tpl
Normal file
25
web/templates/x/components/shipping-progress.tpl
Normal file
@@ -0,0 +1,25 @@
|
||||
{get_stats type='cart_free_delivery' assign='free_delivery'}
|
||||
|
||||
{if $free_delivery and $free_delivery->isPositive() and $cartPrice}
|
||||
<div class="shipping-progress">
|
||||
<span class="fc {$fonticon|default:"icons_delivery"}"></span>
|
||||
<p>
|
||||
{if $free_delivery->lowerThanOrEqual($cartPrice) or $body.freeShipping or $cartInfo.freeShipping}
|
||||
<strong> {t}Dopravu máte zdarma{/t}</strong>
|
||||
{else}
|
||||
{t}K dopravě zdarma zbývá{/t}
|
||||
<strong>{$free_delivery->sub($cartPrice)|format_price:"ceil=no;decimal=dynamic"}</strong>
|
||||
{/if}
|
||||
</p>
|
||||
|
||||
<div class="shipping-bar">
|
||||
{if $free_delivery->lowerThanOrEqual($cartPrice) or $body.freeShipping or $cartInfo.freeShipping}
|
||||
<span></span>
|
||||
{else}
|
||||
{$barwidth=($cartPrice->div($free_delivery)->asFloat())*100}
|
||||
<span style="width: {$barwidth|round}%"></span>
|
||||
{/if}
|
||||
</div>
|
||||
{block 'additional'}{/block}
|
||||
</div>
|
||||
{/if}
|
||||
19
web/templates/x/components/slider.articles.tpl
Normal file
19
web/templates/x/components/slider.articles.tpl
Normal file
@@ -0,0 +1,19 @@
|
||||
{foreach $slider.images as $image}
|
||||
{if $image.link}
|
||||
<a href="{$image.link}" class="articles-sm-side"
|
||||
{if $dbcfg.analytics.google_tag_manager.active_fe_events == 'Y'}
|
||||
data-tracking-view='{get_gtm_data type='ecommerce' method='PromotionImpression' encode=true data=['slider' => $slider, 'position' => $image@iteration]}'
|
||||
data-tracking-click='{get_gtm_data encode=true type='ecommerce' method='PromotionClick' data=['slider' => $slider, 'slide' => $image, 'position' => $image@iteration]}'
|
||||
{/if}>
|
||||
<img src="{get_photo photo=$image.photo size=$slider_size|default:'slider'}" alt="">
|
||||
</a>
|
||||
{else}
|
||||
<div class="articles-sm-side"
|
||||
{if $dbcfg.analytics.google_tag_manager.active_fe_events == 'Y'}
|
||||
data-tracking-view='{get_gtm_data type='ecommerce' method='PromotionImpression' encode=true data=['slider' => $slider, 'position' => $image@iteration]}'
|
||||
{/if}>
|
||||
<img src="{get_photo photo=$image.photo size=$slider_size|default:'slider'}" alt="">
|
||||
</div>
|
||||
{/if}
|
||||
{break}
|
||||
{/foreach}
|
||||
Reference in New Issue
Block a user