Comments (5)
I wanted to pose this as a discussion to get your thoughts. There is a likely hood that we'll be able to help facilitate a PR for this.
Before any of that though, having some dialog with you all first would help.
from craft-avatax.
@curtismorte - tax calculation should only happen once there is a shipping address and at least one line item in the cart, and the response is cached until something else changes again (quantity, address, shipping method, etc) so there shouldn't be too many roundtrip requests to the Avatax API already hopefully.
That said for your use case would something like a hidden form attribute that overrides the plugin's tax calculation setting for just the current cart update form help?
Maybe something like:
<input type="hidden" name="avatax_disable_tax_calclution" value="1">
or
<input type="hidden" name="avatax_force_tax_calculation" value="1">
from craft-avatax.
@imagehat that solution would be ideal because it allow us to specify when to submit for calculation.
You have outlined how tax calculation is completed. The e-commerce setup I am working on right now has hundreds of SKUs where purchasing a single SKU is a rare use case and purchasing multiple SKUs that are related is more common. We have a "Catalog" page that groups SKUs together and the user can very quickly select how many quantities of each SKU they need. Think of this as a page that allows you to purchase individual Lego pieces where you need to purchase 10+ pieces for your order to be "meaningful" to you.
We're using Sprig, so each SKU specification causes the cart to be updated which ultimately causes Tax validation to be run frequently for any returning customer (since they have a saved address).
This is not a common use case, but is one that is critical to the way we are operating.
from craft-avatax.
@curtismorte - That makes sense, and I think it will be pretty easy to add the check for those params. I'll take a look and let you know.
from craft-avatax.
Correct me if I'm wrong, but it seems like it may be a good idea to require this parameter to be passed through with a security hash to avoid bypassing taxes.
from craft-avatax.
Related Issues (20)
- Use Craft Autosuggest fields to support env-based config HOT 1
- 400 Error when validating address with AJAX HOT 3
- Craft Commerce 3.0 Support HOT 4
- Provide setting to select when order is committed HOT 4
- TypeError - Arg 1 passed to validateAddress() must be an instance of craft\commerce\models\Address? HOT 3
- Cannot edit plugin settings HOT 3
- Is this plugin a custom integration? HOT 2
- Invalid address error results in uncaught exception HOT 2
- License Key Value Stored in config/project/project.yaml HOT 5
- Request to avatax.com failed HOT 7
- Cart passing all items as non-taxable HOT 2
- SalesTaxService.php - Request could not be completed HOT 5
- $model is undefined - SalesTaxService.php HOT 1
- After install event breaking automated testing HOT 9
- Error if the order is saved through console command in 2.1.7 version HOT 1
- Guzzle Error HOT 2
- Does this plugin support international fees? (Customs / VAT / etc). HOT 1
- Craftcms 4 compatibility HOT 1
- Commerce V4, Address Validation Fails - Calling Unknown Method SalesTaxService:getState() HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from craft-avatax.