tumil Posted July 14, 2017 Share Posted July 14, 2017 (edited) Hi, because of how my software (it links Prestashop to my database) works, I need to apply price drops by adding discounts to particular groups of clients instead of using specific prices. The problem was that because of that method, the old prices didn't show up, the reduction percent didn't show up. Just the new, lowered price and a potential customer couldn't know that the product's price is reduced. I managed to display old prices and these reduction percentages by editing some code e.g. in product.tpl I have added "$group_reduction == 0" to the IF instruction which determined the display of the information of the sale AND! I simply used such code {if $productPriceWithoutReduction > $productPrice}{convertPrice price=$productPriceWithoutReduction}{/if} to display the old price And it worked like a charm But now I have to achieve that in the other store. And this store has another theme which doesn't seem to work the same way. The previous shop (which worked) was LEO EXIST template, this is WAREHOUSE theme. And in this theme $productPriceWithoutReduction doesn't refer to the old price - the one that isn't affected by the group reductions. $productPriceWithoutReduction and $productPrice are just the same prices and I cannot compare them anyway in the IF instruction. I suspect that the theme just handle this $productPriceWithoutReduction in a different way, which skips the group reduction. How can I handle it to behave the same way the other theme does? Would I need to edit something in "classes". I don't know much about it and I would appreciate your help. TL;DR $productPriceWithoutReduction in Product.tpl doesn't take group reduction into account in my theme, while it did in the other theme. I NEED it to be dependent on the group reduction and I don't know how to achieve it UPDATE: I should add that the shop which handles it well is based on Prestashop 1.6.0.14. The other shop which doesn't work the right way is Prestashop 1.6.1.6 Edited July 14, 2017 by tumil (see edit history) Link to comment Share on other sites More sharing options...
tumil Posted July 18, 2017 Author Share Posted July 18, 2017 Anyone? Still cannot handle this problem Link to comment Share on other sites More sharing options...
tumil Posted July 20, 2017 Author Share Posted July 20, 2017 Bump. I need a way to display the price from before the group reduction Link to comment Share on other sites More sharing options...
metacreo Posted October 13, 2017 Share Posted October 13, 2017 Check product.tpl Replace: productpricewithoutreductionWith: productPriceWithoutReduction I think the prestashop team doing this intentionally and won kill good template. 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