Need to output taxes or a figure equal to subtotal minus discounts on the cart page

New Member
7 0 0

I'm currently using the ULTIMATE Cart Drawer app. The cart includes a subtotal line "{{original_total_price_formatted}}", a discount line "{{{total_discount_formatted}}}" and a total line "{{total_price_formatted}}".


The problem, however, is that the total line includes the taxes, which are not listed in the cart. So inevitably the total number is wrong. For example, if the subtotal is $100 and the discount is $10, the total is appearing as $96.30 (presuming a 7% tax rate). But since the taxes are not shown in the app, it simply looks like the math is wrong, which is very confusing to the customer.

To resolve this, I believe I need to either output the taxes in the cart (to show the customer where the missing money is coming from) or output the difference between the subtotal and the discount that excludes the taxes. However, I cannot figure out how to do either of these things. I tried to code an equation {{original_total_formatted | minus: total_discount_formatted}} but this does not work. I am not sure if I have written the equation incorrectly or if this is simply inappropriate for the app, which I believe is coded in handlebar.js


Any help would be greatly appreciated



19 0 0

It's common to get issues like this when the amounts are controlled by different pieces of code. A similar situation occurs when you have a free shipping tier based on cart price, and use one app to apply coupons in the cart, and another to display the free shipping tier incentive.

All these scenarios work well if you use an app that displays the entire cart summary like This way the app is what calculates the whole thing and the amounts are always consistent.