Zen Cart Logo
Forums / Bug Reports / 155e rounding issue after adding new product

155e rounding issue after adding new product

Views: 669

Results 1 to 2 of 2
5 Sep 2017, 6:23 PM
#1
bramf avatar

bramf

New Zenner

Join Date:
Apr 2017
Location:
Netherlands
Posts:
20
Plugin Contributions:
0

155e rounding issue after adding new product

On my 1.55e webshop I have a GIFT product with a price of 25,00 euro (which is including 21% VAT)
So I enter the Products Price (Gross) of 25.
After saving the product, I go back into the product and now the price is 25.0001

Currency EUR has decimals 2.

In previous versions 1.38 I did not have this issue. It is giving me problems when customers try to redeem the gift certificate and enter 25.
They can only redeem 24.99.

Basically with this post I try to find a solution that when I enter a new product and enter the price including vat, that this price is NOT changing.
I do not care if the price excluding vat is somewhat rounded.

5 Sep 2017, 7:05 PM
#2
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: 155e rounding issue after adding new product

With that particular entry of calculating the net price from the gross price, using four significant digits as is standard for ecommerce, the tax would have to be modified to be at least 20.99% or could be even entered as 20.9999% and in order to calculate back to the original 25 with rounding.

Otherwise if the price storage and associated rounding was changed to maintaining five decimal places instead of just 4, the 21% with a final (gross) price of 25 would work.