Hello, I have a question about OpenCart rounding as per the example below:- Firstly, I should point out that I use an Excel spreadsheet to manage my products and pricing, I would therefore assume OpenCart uses the same mathematical formula:-
My tax (VAT) rate is set at 20% so for Product A:
Sell Price Ex Tax = £8.33
Sell Price Inc Tax = £9.99
The problem is that OpenCart rounds the Tax inc figure to £10 and I need it rounding down as per my Excel spreadsheet and that is also what is legally required in the UK. (I know we're only talking pennies but it is important from an advertising standards perspective).
I realise that the actual price inc tax is actually 8.33 x 1.2 = 9.996 but we can only charge to 2 decimal places so OpenCart changing the price to £10. Alternatively the price less tax is 9.99 / 1.2 = 8.325 hence £8.33
I would be very grateful if someone could explain how this problem could be solved.
Many thanks in advance.
My tax (VAT) rate is set at 20% so for Product A:
Sell Price Ex Tax = £8.33
Sell Price Inc Tax = £9.99
The problem is that OpenCart rounds the Tax inc figure to £10 and I need it rounding down as per my Excel spreadsheet and that is also what is legally required in the UK. (I know we're only talking pennies but it is important from an advertising standards perspective).
I realise that the actual price inc tax is actually 8.33 x 1.2 = 9.996 but we can only charge to 2 decimal places so OpenCart changing the price to £10. Alternatively the price less tax is 9.99 / 1.2 = 8.325 hence £8.33
I would be very grateful if someone could explain how this problem could be solved.
Many thanks in advance.
Attachments
excel.JPG (48.23 KiB) Viewed 1066 times
tech1x10 wrote:
I realise that the actual price inc tax is actually 8.33 x 1.2 = 9.996 but we can only charge to 2 decimal places so OpenCart changing the price to £10. Alternatively the price less tax is 9.99 / 1.2 = 8.325 hence £8.33
Thanks for the reply. So I understand this will work as per above, it's just that this won't make sense to the customer if they see a price of £8.325 on an invoice, they can only pay .33 or .32 it seems to be fundamentally down to the way OpenCart is rounding it's prices
Displays and invoices that customers see will ordinarily be to two digits. I would just tell them, in effect, that OC and money processor may differ by an entire halfpenny, even less or more, measurable in four farthings rounded down or up, and if money processor arithmetic yields rounding down or up relative to a halfpenny, then enjoy the two or suffer the four farthings. I understand that the approach may run amok of powers that be in at least some places in Europe, but somewhere in the mix must be a modicum of common sense about machines. Customers should understand that there was a time when pennies as well as halfpennies and farthings went along with crowns in the pockets, and nowadays rounding such as was suffered and learnt in school must be reckoned with, at once both without the lesser coins and with mere machines.
oops yes thanks. It never actually occurred to me to check the customer side display of a 4 place rounded number i.e. 3.3252 is displayed correctly to the customer as 3.33 Once again apologies for this elementary mistake. I feel rather foolish now.
Who is online
Users browsing this forum: Baidu [Spider] and 8 guests