Blooregard1984 Posted November 28, 2011 Share Posted November 28, 2011 Sorry for the long description but I'll try to be as specific as possible. For some reason the price displayed on the product page is showing an incorrect lower value but only when using a customer group discount, it does not happen when I use the default customer group (0%). When the product is added to cart, the cart displays the correct price and also the product list page is unaffected and shows the correct price. The problem is present in both version 1.4.4.0 and the latest version 1.4.5.1 and appears in both Internet Explorer and Firefox. I have attemted to fix this after researching similar problems on the forum pages but to no avail. I have checked the currency conversion rate but this is set to "1" as I only have one currency. I have included three screenshots to help illustrate the problem. The correct price displays on the product page whilst the page is loading, then it changes to the incorrect lower price. If I check the source code of the page the price is correct within the source code. Also, just to clarify, the wrong price is displayed in both the prestashop default theme and my custom theme. Link to comment Share on other sites More sharing options...
coyners25 Posted December 14, 2011 Share Posted December 14, 2011 Hi, DId you manage to get this resolved? Im having the same issue Tks Alan Link to comment Share on other sites More sharing options...
Mike Kranzler Posted December 14, 2011 Share Posted December 14, 2011 Hi Blooregard, Could you please check the settings for that product in the 3rd tab, Prices, to see if there is any sort of specific price set right now? -Mike Link to comment Share on other sites More sharing options...
PrestaMagic Posted December 15, 2011 Share Posted December 15, 2011 I'm having the same issue. Have culled through product.js and see that productPrice is taking the discount off the default product price, but adding in the full combination price without discount. For instance: Group1 has a 30% discount. The price of an item is $200 by default. One of the combinations adds $100 to the price. So, when logged in with a Group1 member, the price that is shown when choosing the $100 attribute is $240 instead of $210. It should be $210 ($200 - $60=$140, plus $100-$30=$70), not $240 ($200-$60=$140 plus $100). You see? productPrice in product.js is not deducting the group discount from the combination price addition. Any ideas on how to correct would save me hours and hours. I would even write a small rap for the solution. Link to comment Share on other sites More sharing options...
Mike Kranzler Posted December 15, 2011 Share Posted December 15, 2011 Hi jayzee, I'm going to look into this for you, on the condition that you promise to write that rap and post it here . We may even get you some publicity by posting it on Facebook and Twitter! Let me see what I can find for you. -Mike Link to comment Share on other sites More sharing options...
PrestaMagic Posted December 15, 2011 Share Posted December 15, 2011 yo yo my man Miiiiiiiiiiyyyyk is in da hiz-house! Thanks, I'll dig deeper into the js too and see what I can find. Link to comment Share on other sites More sharing options...
Mike Kranzler Posted December 15, 2011 Share Posted December 15, 2011 Hi jayzee, I just set this up on a clean test environment and it worked fine for me. Could you PM me with your Back Office login details (username, password and admin URL) so that I can compare our settings and try to locate where the issue may be occurring? In the meantime though, I hope you've got your beatbox handy; I'm personally partial to Biz Markie . -Mike Link to comment Share on other sites More sharing options...
PrestaMagic Posted December 15, 2011 Share Posted December 15, 2011 Thanks Mike, just PMd you with the information. It's a bit maddening and is impacting my deadline now , thanks for your help! Link to comment Share on other sites More sharing options...
Mike Kranzler Posted December 15, 2011 Share Posted December 15, 2011 Hi jayzee, I'm not sure if this is the only thing causing this issue, but I noticed something that may be leading to some confusion in the final calculation: In your Combinations Generator, I noticed that you have 4 different features with a $44 price impact, and only one with a different value ($211 for satin nickel). So essentially, every single combination that does NOT include the satin nickel canopy and stem would have the exact same price, which would be $44 more than the base price you have set at $425. While I cannot guarantee that this will completely fix the issue, I would suggest that you adjust your combinations to reflect no price impacts except the satin nickel attribute, which you would instead set at a price impact of $167 instead of $211, with the default, pre-tax retail price set at $469 instead of $425. Again, I can't guarantee that this, in and of itself, will immediately fix anything, but it will allow me to clear up some confusion on what is leading to this issue, while also simplifying your own sales process. Once you've done that, please let me know and I'll be happy to take a look at it once again. -Mike Link to comment Share on other sites More sharing options...
PrestaMagic Posted December 15, 2011 Share Posted December 15, 2011 Hi Mike, I appreciate your help with this. Yeah, I can't do this as it violates business rules and would require a wholesale change of pricing structure. I guess I just will have to figure out how to accommodate this somehow. Would this be considered a bug? I didn't expect this to have to be dinked around with so much. Thanks! Link to comment Share on other sites More sharing options...
PrestaMagic Posted December 15, 2011 Share Posted December 15, 2011 I think this refers to the same behavior but was corrected in 1.4.2? http://forge.prestashop.com/browse/PSCFI-1283 Link to comment Share on other sites More sharing options...
Mike Kranzler Posted December 15, 2011 Share Posted December 15, 2011 Hi jayzee, I'm going to check with Franck, the developer from that report, tomorrow in order to see what he may have done in the past to fix this. So you'd better be ready to get rapping, because I'm hoping to get this taken care of for you tomorrow! -Mike Link to comment Share on other sites More sharing options...
PrestaMagic Posted December 15, 2011 Share Posted December 15, 2011 Ok my homeboyyyyyzzz, here's how this sistah rolls. I fixed it. But it will take a bit of mad skeelz to make it happen. First off, in your product.tpl, add a line at the bottom that goes: <div id="group_reduction" style="display:none">{$group_reduction}</div> This will hold your group_reduction amount in a div tag that can be accessed in product.js. Then, in product.js (locations vary by theme), look for line 118. Add this just above it: var group_reduction = $('#group_reduction').html(); and modify selectedCombination['price'] = combinations[combination]['price']; to selectedCombination['price'] = combinations[combination]['price']*group_reduction; This will multiply the combination price by the group reduction price, thereby giving you the correct price for the attribute. EDIT: This fix won't withstand an upgrade, so make sure you document for the future. Hope this helps someone out there. I won't mark this [solved] since I was not the OP. Link to comment Share on other sites More sharing options...
o_delja Posted April 24, 2012 Share Posted April 24, 2012 Ok my homeboyyyyyzzz, here's how this sistah rolls. I fixed it. But it will take a bit of mad skeelz to make it happen. First off, in your product.tpl, add a line at the bottom that goes: <div id="group_reduction" style="display:none">{$group_reduction}</div> This will hold your group_reduction amount in a div tag that can be accessed in product.js. Then, in product.js (locations vary by theme), look for line 118. Add this just above it: var group_reduction = $('#group_reduction').html(); and modify selectedCombination['price'] = combinations[combination]['price']; to selectedCombination['price'] = combinations[combination]['price']*group_reduction; This will multiply the combination price by the group reduction price, thereby giving you the correct price for the attribute. EDIT: This fix won't withstand an upgrade, so make sure you document for the future. Hope this helps someone out there. I won't mark this [solved] since I was not the OP. Hello PrestaMagic, Thank you for the post but I have made all changes and still do not see that price being corrected. Please advise. Thanks a lot. Link to comment Share on other sites More sharing options...
Recommended Posts