susanne52 Posted March 8, 2017 Share Posted March 8, 2017 bonjour, petit problème, mais je ne trouve pas la solution ... j'ai installé un module pour afficher les prix dégressifs. Comme vous voyez sur la photo, la quantité du 2ème prix dégressif reste sur la ligne du premier prix dégressif. Dans l'idéal, cela devrait être : 4 pcs, l'unité à 4,55 € 8 pcs, l'unité à 4,31 € Voici un extrait du tpl : function writeDiscountsContent(price) {ldelim} var discountStr = "<div id=\"discounts_block\" class=\"our_price_display_qd\" style=\"color:black;font-size: 14px;\"><p style=\"line-height: 14px;margin: 0;padding: 0;\">{l s='Quantity Discounts' mod='quantitydiscounts'}</p>"; var discountedPrice = 0; {foreach from=$qd_quantity_discounts item='qd_quantity_discount' name='quantity_discounts'} discountStr += "<span>{$qd_quantity_discount.from_quantity|intval} "; {if $qd_quantity_discount.from_quantity|intval > 1} discountStr += "{l s='quantities' mod='quantitydiscounts'} "; {else} discountStr += "{l s='quantity' mod='quantitydiscounts'} "; {/if} {if $qd_quantity_discount.reduction_type == 'percentage'} if (currencyRate != 0) discountedPrice = price - (price * {$qd_quantity_discount.reduction} * currencyRate); else discountedPrice = price - (price * {$qd_quantity_discount.reduction} ); {elseif $qd_quantity_discount.price > 0} if (currencyRate != 0) discountedPrice = {$qd_quantity_discount.price} * currencyRate; else discountedPrice = {$qd_quantity_discount.price} ; {else} if (currencyRate != 0) discountedPrice = price - ({$qd_quantity_discount.reduction} * currencyRate); else discountedPrice = price - ({$qd_quantity_discount.reduction}); {/if} discountStr +="<span class='mnoz_sleva'>" + formatCurrency(discountedPrice, currencyFormat, currencySign, currencyBlank) + "</span></span>"; {/foreach} discountStr += "</div>"; return discountStr; {rdelim} $(document).ready(function () {ldelim} // remove the legacy quantities div and the tab above it $("#quantityDiscount").prev().css('display','none'); $("#quantityDiscount").css('display','none'); Que dois-je changer pour avoir chaque quantité avec son prix dégressif sur la même ligne ? Je vous remercie beaucoup de votre aide. cordialement Susanne Link to comment Share on other sites More sharing options...
coeos.pro Posted March 8, 2017 Share Posted March 8, 2017 avez vous demandé au webmaster de ce module ? Link to comment Share on other sites More sharing options...
susanne52 Posted March 8, 2017 Author Share Posted March 8, 2017 (edited) leur support est payant, donc je voulais d'abord poser ma question dans ce forum. Auriez-vous une idée ? Edited March 9, 2017 by susanne52 (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