0
有沒有簡單的方法從數據庫中檢索「產品包」?我想在不同的類別中顯示所有產品包組合。如何從Prestashop的數據庫中獲取特定產品
如果我可以禁用這個包出現在其他類別中,那將會很棒。如果它變得太複雜,我沒有問題。
由於我使用自定義模板,因此我提供了一個關於如何在Prestashop 1.6.1.4中顯示產品的代碼示例。
<div class ='cate_title'>
{foreach from=$productCates item=productCate name=posTabCategory}
<div id="tabtitle_{$productCate.id}" class="tab_title">
<h2>
<span>{$productCate.name}</span>
</h2>
</div>
{/foreach}
</div>
<ul class="tab_cates">
{$count=0}
{foreach from=$productCates item=productCate name=posTabCategory}
<li data-title="tabtitle_{$productCate.id}" rel="tab_{$productCate.id}" {if $count==0} class="active" {/if} > {$productCate.name}</li>
{$count= $count+1}
{/foreach}
</ul>
</div>
<div class="tab1_container">
{foreach from=$productCates item=productCate name=posTabCategory}
<div id="tab_{$productCate.id}" class="tab_category">
<div class="row">
<div class="productTabCategorySlider1">
{foreach from=$productCate.product item=product name=posTabCategory}
<div class="cate_item">
<div class="item-inner">
<a class ="bigpic_{$product.id_product}_tabcategory product_image" href="{$product.link|escape:'html'}" title="{$product.name|escape:html:'UTF-8'}"><img class="img-responsive" src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'home_default')|escape:'html'}" alt="{$product.name|escape:html:'UTF-8'}" />
..............................
...............................