helloworlder Posted September 14, 2015 Share Posted September 14, 2015 (edited) There is a bug with tax calculation in Prestashop 1.6. I've tested with Prestashop 1.6.0.x. It is very easy to reproduce the bug and it will happen every time. Do it in this order: 1. Make sure that your items have a tax rule set up. 2. Make sure that you have One Page Checkout selected in preferences. 3. Make a new account, pretending that you are a new customer to the site. Do not add an address yet. 4. Add an item to the cart. 5. Start the checkout process. (you will be asked for your address since you haven't added one yet). 6. You will notice even after you have entered your address and go to the next page, the tax will be 0. Always 0. However, when you add another product to the cart, that item's tax is included. Has anyone experienced this issue? The only way I can get around this bug is to hack the theme by adding on top of order-opc.js the call updateAddressSelection(). This will update the tax, but is rather dirty as once you change themes, the fix is lost. Not ideal. If a Presta dev could point out a workaround in the PHP code that would be very appreciated. We have customers purchasing items and paying the goods without tax! :/ Edited September 14, 2015 by helloworlder (see edit history) Link to comment Share on other sites More sharing options...
tuk66 Posted September 14, 2015 Share Posted September 14, 2015 The latest version is now 1.6.1.1. Does this bug appear in this version as well? Link to comment Share on other sites More sharing options...
persos Posted September 21, 2015 Share Posted September 21, 2015 There is a bug with tax calculation in Prestashop 1.6. I've tested with Prestashop 1.6.0.x. It is very easy to reproduce the bug and it will happen every time. Do it in this order: 1. Make sure that your items have a tax rule set up. 2. Make sure that you have One Page Checkout selected in preferences. 3. Make a new account, pretending that you are a new customer to the site. Do not add an address yet. 4. Add an item to the cart. 5. Start the checkout process. (you will be asked for your address since you haven't added one yet). 6. You will notice even after you have entered your address and go to the next page, the tax will be 0. Always 0. However, when you add another product to the cart, that item's tax is included. Has anyone experienced this issue? The only way I can get around this bug is to hack the theme by adding on top of order-opc.js the call updateAddressSelection(). This will update the tax, but is rather dirty as once you change themes, the fix is lost. Not ideal. If a Presta dev could point out a workaround in the PHP code that would be very appreciated. We have customers purchasing items and paying the goods without tax! :/ Also has equal problems with the tax in PS1.6.0.14, would you explain in more details how adding "Call Update address selection ()" on top of order-opc.js Link to comment Share on other sites More sharing options...
helloworlder Posted September 21, 2015 Author Share Posted September 21, 2015 Add updateAddressSelection(); to the top of order-opc.js of your theme, just inside document ready. Link to comment Share on other sites More sharing options...
persos Posted September 22, 2015 Share Posted September 22, 2015 Add updateAddressSelection(); to the top of order-opc.js of your theme, just inside document ready. Is this what you mean? $(document).ready(function(){ updateAddressSelection(); // GUEST CHECKOUT / NEW ACCOUNT MANAGEMENT if ((typeof isLogged == 'undefined' || !isLogged) || (typeof isGuest !== 'undefined' && isGuest)) { if (guestCheckoutEnabled && !isLogged) { Link to comment Share on other sites More sharing options...
helloworlder Posted September 22, 2015 Author Share Posted September 22, 2015 Yes, that looks right. Any luck? Link to comment Share on other sites More sharing options...
persos Posted September 22, 2015 Share Posted September 22, 2015 Yes, that looks right. Any luck? No, I still have problems with taxes. It works when I register a new account, but when I log on to a previously registered account, the price shown without tax. Link to comment Share on other sites More sharing options...
Recommended Posts