Add a feature to enable tax on shipping boolean inside the TaxZone model #1353
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context
I implemented an e-commerce website for a client that has mainly customers in the USA. They wanted to have the option to have tax on the shipping amount or not. So I decided to first extend the SystemTaxDriver of Lunar and add the code inside of it (and all the features).
Now, that the site is in production and the feature is working well, I wanted to share this option as I think it could be interesting for other people.
I tested the implementation with the Lunar's demo and inside my project too, to be sure everything is working well.
If you need more information, don't hesitate to ask! Please note that as it's a new feature I targeted the main branch.
Documentation updates
I added the
tax_on_shipping
field inside the TaxZone part of the documentation.Automated tests
I wrote new tests relative to the feature inside the
SystemTaxDriverTest
class.