You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The tax total on an order object is incorrect when gift cards are applied. The system provider for tax calculation calculates the tax from the amount after the gift card is subtracted and not before.
It looks like that I have to manually summarize tax_total and gift_card_tax_total but in the cart the tax_total includes the actual total tax.
I realize this is correct behavior given a "single purpose" gift card. At least according to danish rules.
The VAT of a single purpose gift card is due at time of selling a gift card and when the gift card is redeemed, the VAT is already paid. That is why the total tax of a completed order is lower when a gift card is applied.
Bug report
Describe the bug
The tax total on an order object is incorrect when gift cards are applied. The system provider for tax calculation calculates the tax from the amount after the gift card is subtracted and not before.
It looks like that I have to manually summarize
tax_total
andgift_card_tax_total
but in the cart thetax_total
includes the actual total tax.Maybe related to #5005
Another question, will it be possible to allow discount codes to apply to shipping as well in 2.0?
Looking massively forward to check out the release candidate when it is ready. Awesome work on this project - kudos!
System information
Medusa version (including plugins): Latest
Node.js version: 18.19
Database: latest
Operating system: macOS
Browser (if relevant):
Steps to reproduce the behavior
Expected behavior
Expect tax_total to equal
item_tax_total + shipping_tax_total + gift_card_tax_total
on the order objectScreenshots
In cart:
![image](https://private-user-images.githubusercontent.com/32750681/333822112-43eedbac-a511-4844-9271-4ce89b838c22.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk2ODMxMDEsIm5iZiI6MTczOTY4MjgwMSwicGF0aCI6Ii8zMjc1MDY4MS8zMzM4MjIxMTItNDNlZWRiYWMtYTUxMS00ODQ0LTkyNzEtNGNlODliODM4YzIyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTYlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjE2VDA1MTMyMVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWQ0NzBiYTE2NGVjZWYzNGUzMzVkOTBmNjBmNTFmOGU4MWY4Y2UyNTk1NTk1ZGUxMWNlOTg2NmJmMDk5OWFhMWYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.gfOjdcAiYAgI-LmNfaelENaX6N8ebMmS4V2PGmrhIGk)
In order confirmation:
![image](https://private-user-images.githubusercontent.com/32750681/333822185-91e4eabd-71c8-4203-b718-a0b2d967ac2b.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk2ODMxMDEsIm5iZiI6MTczOTY4MjgwMSwicGF0aCI6Ii8zMjc1MDY4MS8zMzM4MjIxODUtOTFlNGVhYmQtNzFjOC00MjAzLWI3MTgtYTBiMmQ5NjdhYzJiLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTYlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjE2VDA1MTMyMVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWU2NWMxODNhNGQyYTI1OTk2ZDBmZWY5NDc3MzFjYjU1ZmU5NGI0ZDA0OWE0ZjJkMzlkMjdiMTEyNDI2ZjkwMWMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.AM-MHp28UsGeeQEHHA8ZsoSRlOcJwA_0rApwQi1OUw8)
Code snippets
Cart Object
Order Object
Additional context
Add any other context about the problem here
The text was updated successfully, but these errors were encountered: