base_vat: faulty vat number check

Bug #578888 reported by Xavier Fernandez http://www.smile.fr
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Low
OpenERP R&D Addons Team 3

Bug Description

There seems to be quite a lot of bug reports concerning base_vat with checks not working for (at least) Slovakia, Romania, Bulgaria, Portugal, Spain and Sweden.

I'd like to add a new of for Italy. IT 00118439991 is validated ok by http://ec.europa.eu/taxation_customs/vies/viesquer.do

but is not by OpenERP base_vat addon.

Given the poor added value of theses (invalid) checks and their hindrance of not being able to fill the (correct) VAT of a partner, I think we should stick to the official checks guidelines available here: http://ec.europa.eu/taxation_customs/vies/faqvies.do#item11

Related branches

Revision history for this message
Borja López Soilán (NeoPolus) (borjals) wrote :

Currently the VAT validation is working for Spain. It's true that we had some problems back then, but they where caused by a change on our VAT numbering system (the VAT validation was based on the older validation, so the numbers that changed on the new one weren't considered valid).

Just using the guidelines you propose wouldn't be enough for most people (you can type a digit incorrectly and it would still validate that VAT).

So I think it is a problem of the each localization community: if some Italian VAT numbers are not being detected properly, somebody from the Italian community should take care to propose a patch for base_vat that corrects the problem for Italy, and ask the OpenERP guys to merge it.

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Hello Guys,

The Europa link does not provide a sheer validation formulaes. The link you attached is mentioning pretty basic things,not all the validation.

We are following http://sima-pc.com/nif.php.

Although its not accurate and it has conflicts with Europa validated vat numbers, we are requesting you share more validation-related information of more trustworthy links.

Thanks in advance.

Changed in openobject-addons:
importance: Undecided → Wishlist
Revision history for this message
Nicola Riolini - Micronaet (nicolariolini) wrote :

Hi, Does Anyone has news about VAT check for Italy, I still have problems with more VAT code (I can write some false positive if needed).
Thanks

Revision history for this message
Nicola Riolini - Micronaet (nicolariolini) wrote :

I find the problem in my version (5.0.8)
the 8-9-10 numbers are VAT registration office, the problem is that there is a new number: 999 for extra Italy company, in wiki it is not indicated so maybe the programmer did not include in validation test.

I'm downloading 5.0.14 for a verify if the bug is corrected in my version 999 is not in case list...
bye

Revision history for this message
Nicola Riolini - Micronaet (nicolariolini) wrote :

sorry ... i forgot to indicate that my post if for Italy VAT check problem :)

Revision history for this message
Nicola Riolini - Micronaet (nicolariolini) wrote :

and the special code 888 ...
Validating VAT testing registration office, unfortunately, need modification of python check funtion every new office/province for incrementing case range...
I've update this special code: 999 and 888 for italy VAT in wiki, this for programmers who take wiki as a trace for writing code...
bye

Revision history for this message
Fabien (Open ERP) (fp-tinyerp) wrote :

this is not a wishlist but a real bug, I reassign for v6.0

Changed in openobject-addons:
status: New → Confirmed
importance: Wishlist → Low
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
qdp (OpenERP) (qdp)
Changed in openobject-addons:
milestone: none → 6.0-rc2
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
vth(openerp) (vth-tinyerp) wrote :

Hello Xavier,

yes you are right. I have tested vat number IT00118439991 (Italy) and its seems its not valid for openerp.
I am attaching patch here. Can you please test it and tell us if its ok for all italy vat numbers.

Thank you,
vth

Revision history for this message
vth(openerp) (vth-tinyerp) wrote :

Hello All,

We have fixed problem branch: lp:~openerp-commiter/openobject-addons/trunk-dev-addons3-vth2
revision-id: <email address hidden>

Thank you,
vth

Changed in openobject-addons:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.