Jump to content

Product Reference Not Showing


Recommended Posts

Hi
 
Strange question. Products are displaying no Reference but when I added new products they show the reference.
 
 
 
PS: 1.6.0.9
 
Checking the forums it told me to check product-list.tpl 
 
{*
* 2007-2013 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to [email protected] so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
*  @author PrestaShop SA <[email protected]>
*  @copyright  2007-2013 PrestaShop SA
*  @license    http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
*  International Registered Trademark & Property of PrestaShop SA
*}

{if isset($products)}
{if !isset($without_view_switch)}
<script>
jQuery(document).ready(function($){
    var default_view = "{$theme_options['product_list_layout']}";
		theid = $('a.switcher').attr("id"),
		theproducts = $("ul#product_list"),
		classNames = $('a.switcher').attr('class').split(' '),
		gridthumb = "{$base_dir}themes/control/images/grid-default-thumb.png",
		listthumb = "{$base_dir}themes/control/images/list-default-thumb.png";
	
    if($.cookie('view') !== 'undefined'){
        $.cookie('view', default_view, { expires: 7, path: '/' });
    } 
    function get_grid(){
		$('#gridview').addClass("active");
		$("#listview").removeClass("active");
			
		$("#listview").children("img").attr("src","{$base_dir}themes/control/images/list-view.png");
			
		var theimg = $('#gridview').children("img");
		theimg.attr("src","{$base_dir}themes/control/images/grid-view-active.png");

		theproducts.removeClass("list");
		theproducts.addClass("grid");

		$("img.thumb").attr("src",gridthumb);
    }
    function get_list(){
		$('#listview').addClass("active");
		$("#gridview").removeClass("active");
					
		$("#gridview").children("img").attr("src","{$base_dir}themes/control/images/grid-view.png");
					
		var theimg = $('#listview').children("img");
		theimg.attr("src","{$base_dir}themes/control/images/list-view-active.png");

		theproducts.removeClass("grid")
		theproducts.addClass("list");

		$("img.thumb").attr("src",listthumb);
    }

    if($.cookie('view') == 'list'){ 
		$('#listview').addClass("active");
		$("#gridview").removeClass("active");
					
		$("#gridview").children("img").attr("src","{$base_dir}themes/control/images/grid-view.png");
					
		var theimg = $('#listview').children("img");
		theimg.attr("src","{$base_dir}themes/control/images/list-view-active.png");

		theproducts.removeClass("grid")
		theproducts.addClass("list");

		$("img.thumb").attr("src",listthumb);
    } 

    if($.cookie('view') == 'grid'){ 
		$('#gridview').addClass("active");
		$("#listview").removeClass("active");
			
		$("#listview").children("img").attr("src","{$base_dir}themes/control/images/list-view.png");
			
		var theimg = $('#gridview').children("img");
		theimg.attr("src","{$base_dir}themes/control/images/grid-view-active.png");

		theproducts.removeClass("list");
		theproducts.addClass("grid");

		$("img.thumb").attr("src",gridthumb);
    }

    $('#listview').click(function(e){   
        $.cookie('view', 'list'); 
        get_list();
		e.preventDefault();
    });

    $('#gridview').click(function(e){ 
        $.cookie('view', 'grid'); 
        get_grid();
		e.preventDefault();
    });
	
});
</script>
{/if}
	<!-- Products list -->
	<ul id="product_list" class="nolist grid">
	{foreach from=$products item=product name=products}
		{if $theme_options['global_layout'] == full}
		<li class="col-lg-3 col-sm-4 col-xs-6 col-ms-12">
		{else}
		<li class="col-lg-4 col-sm-6 col-xs-6 col-ms-12">
		{/if}
			<div>

				{if $theme_options['control_quickview'] == '1'}
				<a class="quick-view" href="{$product.link|escape:'html':'UTF-8'}" rel="{$product.link|escape:'html':'UTF-8'}">
					<i class="fa fa-search"></i> {l s='Quick view'}
				</a>
				{/if}

				<p class="icons">
				{if isset($product.new) && $product.new == 1}<span class="new_list">{l s='New'}</span>{/if}
				{if isset($product.on_sale) && $product.on_sale && isset($product.show_price) && $product.show_price && !$PS_CATALOG_MODE}<span class="on_sale_list">{l s='Sale'}</span>
				{elseif isset($product.reduction) && $product.reduction && isset($product.show_price) && $product.show_price && !$PS_CATALOG_MODE}<span class="discount_list">{l s='Promotion'}</span>{/if}
				</p>
				<a class="product_img" href="{$product.link|escape:'html'}"><img class="img-responsive" src="{$link->getImageLink($product.link_rewrite, $product.id_image, 'ph_home')|escape:'html'}" alt="{$product.name|escape:'htmlall':'UTF-8'}" /></a>
				<div class="desc">
					<h3><a href="{$product.link|escape:'html'}" title="{l s='see product'} {$product.name|escape:'htmlall':'UTF-8'}">{$product.name|truncate:55:'...'|escape:'htmlall':'UTF-8'}</a></h3>
					<p class="p_desc">
						{$product.description_short|strip_tags:'UTF-8'|truncate:360:'...'}
					</p>
					{if (!$PS_CATALOG_MODE AND ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))}
						{if isset($product.show_price) && $product.show_price && !isset($restricted_country_mode)}
							<span class="price">
								{if !$priceDisplay}
									{convertPrice price=$product.price}
								{else}
									{convertPrice price=$product.price_tax_exc}
								{/if}

								{hook h="displayProductPriceBlock" product=$product type="price"}
								{hook h="displayProductPriceBlock" product=$product type="unit_price"}

								{if isset($product.reduction) && $product.reduction && $theme_options['control_display_price_wo_reduction']}
									{hook h="displayProductPriceBlock" product=$product type="old_price"}
									<span class="price_without_reduction">
										{convertPrice price=$product.price_without_reduction}
									</span>
								{/if}
							</span>
						{/if}
					{/if}
					
					<div class="displayProductDeliveryTime displayProductPriceBlock">
						{hook h="displayProductDeliveryTime" product=$product}
						{hook h="displayProductPriceBlock" product=$product type="weight"}
					</div>

					<div class="info">
						<div class="buttons-wrapper">
							{if $theme_options['control_display_add2cart']}
                                {if (!isset($product.customization_required) || !$product.customization_required) && ($product.allow_oosp || $product.quantity > 0)}
									{if isset($static_token)}
										<a class="ajax_add_to_cart_button pull-left button yellow" rel="ajax_id_product_{$product.id_product|intval}" href="{$link->getPageLink('cart',false, NULL, "add=1&id_product={$product.id_product|intval}&token={$static_token}", false)|escape:'html'}" title="{l s='Add to cart'}">{l s='Add to cart'}</a>
									{else}
										<a class="ajax_add_to_cart_button pull-left button yellow" rel="ajax_id_product_{$product.id_product|intval}" href="{$link->getPageLink('cart',false, NULL, "add=1&id_product={$product.id_product|intval}", false)|escape:'html'}" title="{l s='Add to cart'}">{l s='Add to cart'}</a>
									{/if}						
								{else}
									
								{/if}
							{/if}

							{if (isset($product.customization_required) && $product.customization_required)}
                                <a class="pull-left button yellow" href="{$product.link|escape:'html':'UTF-8'}" title="{l s='Customize'}">
                                    <span>{l s='Customize'}</span>
                                </a>
                            {/if}


							{if !$product.available_for_order || isset($restricted_country_mode) || $product.quantity < 1 && !$product.allow_oosp}
								{if $theme_options['control_display_noavailable_text']}
									<span class="noavailable_text">{$theme_options['control_noavailable_text']}</a></span>
								{/if}
							{/if}

							{if $theme_options['control_display_view']}
								<a href="{$product.link|escape:'html'}" title="{l s='View product'}" class="pull-right button">{l s='View product'}</a>
							{/if}
						</div>
						{hook h='displayProductCommentsOnList' id_product=$product.id_product}
						{hook h='displayProductListActionsButton' id_product=$product.id_product}
					</div><!-- .info -->
				</div><!-- .desc -->
				<div class="link-col">
					{if (!$PS_CATALOG_MODE AND ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))}
						{if isset($product.show_price) && $product.show_price && !isset($restricted_country_mode)}<span class="price">{if !$priceDisplay}{convertPrice price=$product.price}{else}{convertPrice price=$product.price_tax_exc}{/if}</span>{/if}
					{/if}
					{if $theme_options['control_display_add2cart']}
                        {if (!isset($product.customization_required) || !$product.customization_required) && ($product.allow_oosp || $product.quantity > 0)}
							{if isset($static_token)}
								<a class="ajax_add_to_cart_button pull-left button yellow" rel="ajax_id_product_{$product.id_product|intval}" href="{$link->getPageLink('cart',false, NULL, "add=1&id_product={$product.id_product|intval}&token={$static_token}", false)|escape:'html'}" title="{l s='Add to cart'}">{l s='Add to cart'}</a>
							{else}
								<a class="ajax_add_to_cart_button pull-left button yellow" rel="ajax_id_product_{$product.id_product|intval}" href="{$link->getPageLink('cart',false, NULL, "add=1&id_product={$product.id_product|intval}", false)|escape:'html'}" title="{l s='Add to cart'}">{l s='Add to cart'}</a>
							{/if}						
						{else}
							
						{/if}
					{/if}

					{if (isset($product.customization_required) && $product.customization_required)}
                        <a class="pull-left button yellow" href="{$product.link|escape:'html':'UTF-8'}" title="{l s='Customize'}">
                            <span>{l s='Customize'}</span>
                        </a>
                    {/if}
                    
					{if $theme_options['control_display_view']}	
						<a href="{$product.link|escape:'html'}" title="{l s='View product'}" class="pull-right button">{l s='View product'}</a>
					{/if}
				</div><!-- .link-col -->
			</div>
		</li>
	{/foreach}
	</ul>
	<!-- /Products list -->
{/if}

Alas, no luck :(

 

Link to comment
Share on other sites

×
×
  • Create New...