NKoonen / vatchecker

[Prestashop]Checks if customer has a valid VAT number, and then puts the customer a specific group.
https://customs-documents.com
BSD 3-Clause "New" or "Revised" License
34 stars 14 forks source link

v2.0 - Store validation in database and stop using groups #13

Closed JoryHogeveen closed 2 years ago

JoryHogeveen commented 2 years ago

This PR will update this plugin to store all validations into the database. If a VIES call was successful it will store a new record into the database based on the address id, country id and vat number. These records will contain whether the VAT number is valid, when it was checked and if it is invalid, when it was last checked as valid. Whether the customer can buy without TAX is after this PR not depending on the user group but on the VAT validation stored in the database based on the address.

At the point of writing this I still kept the user groups active for administration purposes.

TODO: