There are two methods that can be used to calculate cart and order totals. The method used depends on the
calculation_method setting. The default is currently the simple method and this continues to be the case for all stores currently using this method. In future, new stores use the line method by default.
Simple calculation method
Taxes are calculated for each line and are rounded to the nearest penny for the unit.
The cart totals are calculated by summing each of the lines and then subtracting any discounts.
|Item 1||Item 2||Discount||Total|
In summary, discounts are applied after tax and rounding occurs at the individual unit level.
Line calculation method
Any cart-level discount is distributed among the cart items such that the amount each line gets is in proportion to its value before tax).
Discounts are calculated for each line by subtracting from the pre-tax value and the discount is rounded to the nearest penny for the line.
Taxes are calculated for each line based on the line value after discounts have been applied and are rounded to the nearest penny for the line.
The cart totals are calculated by summing each of the lines.
|Item 1||Item 2||Total|
In summary, discounts are applied before tax and rounding occurs for whole lines.