Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Time-aware tax rates #1857

Closed
mamhoff opened this issue Apr 22, 2017 · 3 comments
Closed

Time-aware tax rates #1857

mamhoff opened this issue Apr 22, 2017 · 3 comments

Comments

@mamhoff
Copy link
Contributor

mamhoff commented Apr 22, 2017

Tax rates are currently valid "forever". If a tax rate changes in a jurisdiction a store sells to, the tax rate records have to be updated exactly when the new tax rates comes into effect. This is not very user-friendly.

It would instead be nice if we could set a valid_from and valid_until date on tax rates, and have them apply when the current datetime is within these two dates. If both are nil, tax rates can still be indefinitely valid.

@vladstoick
Copy link
Contributor

I will start working on this

@mtylty
Copy link
Contributor

mtylty commented May 22, 2017

@vladstoick I'm working on this as well, would you mind splitting the work? We could work on solidus_core and solidus_backend separately.

@vladstoick
Copy link
Contributor

@mtylty I think this one might be easier if just one person works on it so I can let you work on it if you already started working

mtylty added a commit to nebulab/solidus that referenced this issue May 31, 2017
This code adds a starts_at and expires_at datetime field to
Spree::TaxRate so that tax rates can be scoped in time.

Null values will be treated as valid so that a tax rate is valid by
default and you can just ignore this feature if you don't need it.

The Spree::Calculator::DefaultTax will always return 0 in case the tax
rate is not valid (either not started or expired).

Ref. solidusio#1857
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants