247 lines
12 KiB
HTML
247 lines
12 KiB
HTML
{extends file="layout.tpl"}
|
|
|
|
{block name="init"}
|
|
{$brand_id={brand attr="id"}}
|
|
{/block}
|
|
|
|
{* Body Class *}
|
|
{block name="body-class"}page-brand{/block}
|
|
|
|
{* Page Title *}
|
|
{block name='no-return-functions' append}
|
|
{if $brand_id}
|
|
{loop name="brand.seo.title" type="brand" id=$brand_id limit="1"}
|
|
{$page_title = $META_TITLE}
|
|
{/loop}
|
|
{/if}
|
|
{/block}
|
|
|
|
{* Meta *}
|
|
{block name="meta"}
|
|
{if $brand_id}
|
|
{loop name="brand.seo.meta" type="brand" id=$brand_id limit="1"}
|
|
{include file="includes/meta-seo.html"}
|
|
{/loop}
|
|
{/if}
|
|
{/block}
|
|
|
|
{* Feeds *}
|
|
{block name="feeds"}
|
|
{if $brand_id}
|
|
<link rel="alternate" type="application/rss+xml" title="{intl l='All product in brand %title' title={brand attr='title'}}" href="{url path="/feed/brand/%lang/%brand_id" lang={lang attr='locale'} brand_id=$brand_id}"/>
|
|
{/if}
|
|
{/block}
|
|
|
|
{* Breadcrumb *}
|
|
{block name='no-return-functions' append}
|
|
{if $brand_id}
|
|
{$breadcrumbs = []}
|
|
{if $brand_id}
|
|
{loop type="brand" name="brand-breadcrumb" id=$brand_id limit="1"}
|
|
{$breadcrumbs[] = ['title' => {$TITLE}, 'url'=> {$URL nofilter}]}
|
|
{/loop}
|
|
{else}
|
|
{$breadcrumbs[] = ['title' => {intl l="All brands"}, 'url'=> '']}
|
|
{/if}
|
|
{/if}
|
|
{/block}
|
|
|
|
{block name="main-content"}
|
|
{hook name="brand.top" brand="$brand_id"}
|
|
{if $brand_id}
|
|
<div class="main row">
|
|
{$limit={$smarty.get.limit|default:8}}
|
|
{$product_page={$smarty.get.page|default:1}}
|
|
{$product_order={$smarty.get.order|default:'alpha'}}
|
|
{$mode=$smarty.get.mode|default:'grid'}
|
|
|
|
{hook name="brand.main-top" brand="$brand_id"}
|
|
|
|
<article class="col-main col-md-9 col-md-push-3 {$mode}" role="main" aria-labelledby="main-label">
|
|
|
|
{hook name="brand.content-top" brand="$brand_id"}
|
|
|
|
{loop name="brand.info" type="brand" id=$brand_id limit="1"}
|
|
<section class="brand-description">
|
|
<h1 id="main-label" class="page-header">{$TITLE}</h1>
|
|
|
|
{loop name="brand.image" type="image" source="brand" id={$LOGO_IMAGE_ID} width=218 height=146 resize_mode="borders"}
|
|
<p><img itemprop="image" src="{$IMAGE_URL nofilter}" alt="{$TITLE}"></p>
|
|
{/loop}
|
|
|
|
{if $CHAPO}
|
|
<div class="chapo">
|
|
{$CHAPO}
|
|
</div>
|
|
{/if}
|
|
{if $DESCRIPTION}
|
|
<div class="description">
|
|
{$DESCRIPTION nofilter}
|
|
</div>
|
|
{/if}
|
|
{if $POSTSCRIPTUM}
|
|
<small class="postscriptum">
|
|
{$POSTSCRIPTUM}
|
|
</small>
|
|
{/if}
|
|
</section>
|
|
|
|
{ifloop rel="product_list"}
|
|
<hr/>
|
|
|
|
{assign var="amount" value={count type="product" brand=$ID}}
|
|
<div class="toolbar toolbar-top" role="toolbar">
|
|
<div class="sorter-container clearfix">
|
|
<span class="amount">{if ($amount > 1)}{intl l="%nb Items" nb=$amount}{else}{intl l="%nb Item" nb=$amount}{/if}</span>
|
|
|
|
<span class="limiter">
|
|
<label for="limit-top">{intl l="Show"}</label>
|
|
<select id="limit-top" name="limit">
|
|
<option value="{url current="1" limit="4"}" {if $limit==4}selected{/if}>4</option>
|
|
<option value="{url current="1" limit="8"}" {if $limit==8}selected{/if}>8</option>
|
|
<option value="{url current="1" limit="12"}" {if $limit==12}selected{/if}>12</option>
|
|
<option value="{url current="1" limit="50"}" {if $limit==50}selected{/if}>50</option>
|
|
<option value="{url current="1" limit="100000"}" {if $limit==100000}selected{/if}>{intl l="All"}</option>
|
|
</select>
|
|
<span class="per-page">{intl l="per page"}</span>
|
|
</span><!-- /.limiter -->
|
|
|
|
<span class="sort-by">
|
|
<label for="sortby-top">{intl l="Sort By"}</label>
|
|
<select id="sortby-top" name="sortby">
|
|
{*<option value="{url path="{brand attr="url"}" order="manual"}">{intl l="Position"}</option>*}
|
|
<option value="{url current="1" limit=$limit order="alpha"}" {if $product_order=="alpha"}selected{/if}>{intl l="Name ascending"}</option>
|
|
<option value="{url current="1" limit=$limit order="alpha_reverse"}" {if $product_order=="alpha_reverse"}selected{/if}>{intl l="Name descending"}</option>
|
|
<option value="{url current="1" limit=$limit order="min_price"}" {if $product_order=="min_price"}selected{/if}>{intl l="Price ascending"}</option>
|
|
<option value="{url current="1" limit=$limit order="max_price"}" {if $product_order=="max_price"}selected{/if}>{intl l="Price descending"}</option>
|
|
</select>
|
|
</span><!-- /.sort-by -->
|
|
|
|
<span class="view-mode">
|
|
<span class="view-mode-label sr-only">{intl l="View as"}:</span>
|
|
<span class="view-mode-btn">
|
|
<a href="{url current="1" mode="grid"}" data-toggle="view" role="button" title="{intl l='Grid'}" rel="nofollow" class="btn btn-default btn-grid"><i class="fa fa-th"></i></a>
|
|
<a href="{url current="1" mode="list"}" data-toggle="view" role="button" title="{intl l="List"}" rel="nofollow" class="btn btn-default btn-list"><i class="fa fa-th-list"></i></a>
|
|
</span>
|
|
</span><!-- /.view-mode -->
|
|
</div><!-- /.sorter -->
|
|
</div><!-- /.sorter-container -->
|
|
|
|
<div id="category-products">
|
|
<div class="products-content">
|
|
<ul class="list-unstyled row">
|
|
{loop type="product" name="product_list" brand=$ID limit=$limit page=$product_page order=$product_order}
|
|
{include file="includes/single-product.html" product_id=$ID hasBtn=true hasDescription=true hasQuickView=true width="218" height="146"}
|
|
{/loop}
|
|
</ul>
|
|
</div>
|
|
</div><!-- /#category-products -->
|
|
|
|
<div class="toolbar toolbar-bottom" role="toolbar">
|
|
{if $amount > $limit}
|
|
<div class="pagination-container clearfix" role="pagination" aria-labelledby="pagination-label-{$toolbar}}">
|
|
<strong id="pagination-label-{$toolbar}}" class="pagination-label sr-only">{intl l="Pagination"}</strong>
|
|
<ul class="pagination pagination-sm">
|
|
{if $product_page le 1}
|
|
<li class="disabled">
|
|
<span class="prev"><i class="fa fa-caret-left"></i></span>
|
|
</li>
|
|
{else}
|
|
<li>
|
|
<a href="{url current="1" page={$product_page-1} }" title="{intl l="Previous"}" class="prev"><i class="fa fa-caret-left"></i></a>
|
|
</li>
|
|
{/if}
|
|
|
|
{pageloop rel="product_list"}
|
|
<li{if $PAGE eq $CURRENT} class="active"{/if}>
|
|
<a href="{url current="1" page=$PAGE }"> {$PAGE} </a>
|
|
</li>
|
|
{if $PAGE eq $LAST}
|
|
{if $CURRENT eq $LAST}
|
|
<li class="disabled">
|
|
<span class="next"><i class="fa fa-caret-right"></i></span>
|
|
</li>
|
|
{else}
|
|
<li>
|
|
<a href="{url current="1" page={$NEXT} }" title="{intl l="Next"}" class="next"><i class="fa fa-caret-right"></i></a>
|
|
</li>
|
|
{/if}
|
|
{/if}
|
|
{/pageloop}
|
|
</ul>
|
|
</div>
|
|
{/if}
|
|
</div><!-- /.toolbar toolbar-bottom -->
|
|
{/ifloop}
|
|
|
|
{elseloop rel="product_list"}
|
|
<div class="alert alert-warning">
|
|
{intl l="No products available in this brand"}
|
|
</div>
|
|
{/elseloop}
|
|
|
|
{hook name="brand.content-bottom" brand="$brand_id"}
|
|
{/loop}
|
|
</article>
|
|
|
|
<aside class="col-left col-md-3 col-md-pull-9" role="complementary" itemscope itemtype="http://schema.org/WPSideBar">
|
|
{include file="includes/brand-menu.html"}
|
|
</aside>
|
|
|
|
{hook name="brand.main-bottom" brand="$brand_id"}
|
|
|
|
</div><!-- /.layout -->
|
|
{else}
|
|
<div class="main" id="brands">
|
|
{hook name="brand.main-top"}
|
|
<div class="col-main brands" role="main" aria-labelledby="main-label">
|
|
{hook name="brand.content-top"}
|
|
{ifloop rel="brands"}
|
|
<ul class="list-unstyled">
|
|
{loop name="brands" type="brand" with_prev_next_info="true"}
|
|
<li class="item">
|
|
<article class="row">
|
|
<div class="brand-info col-sm-7">
|
|
{ifloop rel="brand_logo"}
|
|
<a href="{$URL nofilter}" tabindex="-1" class="brand-image overlay col-sm-2">
|
|
{loop name="brand_logo" type="image" source="brand" id={$LOGO_IMAGE_ID} width=218 height=146 resize_mode="borders" limit="1"}
|
|
<img src="{$IMAGE_URL nofilter}" class="img-responsive" alt="{$TITLE}">
|
|
{/loop}
|
|
</a>
|
|
{/ifloop}
|
|
|
|
<h2 class="name"><a href="{$URL nofilter}">{$TITLE}</a></h2>
|
|
{if $CHAPO}
|
|
<div class="short-description">
|
|
{$CHAPO}
|
|
</div>
|
|
{/if}
|
|
</div>
|
|
</article>
|
|
</li>
|
|
{/loop}
|
|
</ul>
|
|
{/ifloop}
|
|
{elseloop rel="brand_logo"}
|
|
|
|
{/elseloop}
|
|
{hook name="brand.content-bottom"}
|
|
</div>
|
|
{hook name="brand.main-bottom"}
|
|
</div>
|
|
{/if}
|
|
{hook name="brand.bottom" brand="$brand_id"}
|
|
{/block}
|
|
|
|
{block name="stylesheet"}
|
|
{hook name="brand.stylesheet"}
|
|
{/block}
|
|
|
|
{block name="after-javascript-include"}
|
|
{hook name="brand.after-javascript-include"}
|
|
{/block}
|
|
|
|
{block name="javascript-initialization"}
|
|
{hook name="brand.javascript-initialization"}
|
|
{/block}
|