Shipping: 180,00
Shipping Tax: 21,00%
Tax: 378,00 (it should be 37,8)
The products taxes are perfectly calculated.
I have not modified anything myself, only added the new percentage to the dropdown. It works wrongly for all the percentages in the dropdown, even the default ones included by default.
Formula for calculating shipping tax and all other line item actions reside at modules/AOS_Products_Quotes/line_items.js which is a core file. you have to point to a custom file in order to add your custom changes. See quotes vardefs value for line_items
Thank you cherub-chum for pointing me to the calculation scripts.
I have found a solution, but it seems to me as workaround, because i cannot explain full the 1000 instead of 100. But when I change the next calculation:
var shippingtax_amt = shipping * (shippingtax/100);
to
var shippingtax_amt = shipping * (shippingtax/1000);
The error in calculation happens when you use comma as a decimal separator.
I am working on it. I. think that we need to unformat the value because if for exmaple you have in the dropdown 7.0 value with the decimal separator the value will be 70 because in this case the “.” is consider as a thousand separator.
ASAP as I resolved the issue I will posted my solution.
If you use /1000 and someone in your organization likes the displays in “.” the tax calculation is not good again.