guillaume2vo Posted October 4, 2015 Share Posted October 4, 2015 sur chaque produit, je veux mettre en % les réductions et elle ne s'affiche pas voici le bout de code. comment faire ? <div class="right-block"> <h5 class="product-name"> {if isset($product.pack_quantity) && $product.pack_quantity}{$product.pack_quantity|intval|cat:' x '}{/if} <a href="{$product.link|escape:'html'}" title="{$product.name|truncate:50:'...'|escape:'htmlall':'UTF-8'}">{$product.name|truncate:35:'...'|escape:'htmlall':'UTF-8'}</a> </h5> <div class="pr-rt"> {if (!$PS_CATALOG_MODE AND ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))} {if isset($FIELD_categoryShowAvgRating) && $FIELD_categoryShowAvgRating || !isset($FIELD_categoryShowAvgRating)} {hook h='displayProductListReviews' product=$product} {/if} <div class="content_price"> {if isset($product.show_price) && $product.show_price && !isset($restricted_country_mode)} {if isset($product.specific_prices) && $product.specific_prices && isset($product.specific_prices.reduction) && $product.specific_prices.reduction} <span class="old-price product-price"> {displayWtPrice p=$product.price_without_reduction} </span> {/if} <span class="price product-price"> {if !$priceDisplay}{convertPrice price=$product.price}{else}{convertPrice price=$product.price_tax_exc}{/if} </span> {if $product.specific_prices.reduction_type == 'percentage'} <span class="price-percent-reduction">-{$product.specific_prices.reduction * 100}%</span> {/if} {/if} </div> {/if} </div> </div> Link to comment Share on other sites More sharing options...
Bakhouche Akram Posted October 4, 2015 Share Posted October 4, 2015 Bonjour, Vous avez bien désactiver le cache smarty ? Link to comment Share on other sites More sharing options...
guillaume2vo Posted October 4, 2015 Author Share Posted October 4, 2015 Oui, je n'ai aucun cache sur mon site, et j'ai meme desactivé le CDN Link to comment Share on other sites More sharing options...
Bakhouche Akram Posted October 4, 2015 Share Posted October 4, 2015 Avant la ligne {if $product.specific_prices.reduction_type == 'percentage'} <span class="price-percent-reduction">-{$product.specific_prices.reduction * 100}%</span> {/if} Essayez : {$$product.specific_prices.reduction_type|print_r} Pour un debug et voir ce qui en sort Link to comment Share on other sites More sharing options...
Bakhouche Akram Posted October 4, 2015 Share Posted October 4, 2015 (edited) Avant la ligne {if $product.specific_prices.reduction_type == 'percentage'} <span class="price-percent-reduction">-{$product.specific_prices.reduction * 100}%</span> {/if} Essayez : {$product.specific_prices.reduction_type|print_r} Pour un debug et voir ce qui en sort Edited October 4, 2015 by Bakhouche Akram (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now