Export to GitHub

vatnumber - issue #15

Sweden vat validation fail


Posted on Jul 4, 2011 by Quick Horse

What steps will reproduce the problem? >>> import vatnumber >>> vatnumber.check_vat('SE556728341001') False

This is a valid IT VAT number according to: http://ec.europa.eu/taxation_customs/vies/viesquer.do

What is the expected output? What do you see instead? It should be True

What version of the product are you using? On what operating system? 0.9

Please provide any additional information below. according to this link: http://sima-pc.com/nif.php?pais=IT&nif=SE556728341001 N(1-9)+C(1)+N(10-11) N(10-11)>0 e.g: 123456789701 that means N(1-9) = 123456789 C(1) = 7 N(10-11) = 01

Line no : 1017 is if int(vat[9:11]) <= 0: return False it should be if int(vat[9:11]) < 0: return False

as the check can be 0, in my example int(vat[9:11]) = 0

Thanks, Purnendu Singh(openERP)

Comment #1

Posted on Jul 11, 2011 by Quick Horse

Hello,

Any updates on this issue!!

Thanks in advance, Purnendu Singh(OpenERP)

Comment #2

Posted on Jul 15, 2011 by Helpful Kangaroo

Fixed with rev f8e25cd17789

PS: next time if you want to have fix faster submit a correct patch (as attachment).

Comment #3

Posted on Jul 15, 2011 by Helpful Kangaroo

rf8e25cd17789

Comment #4

Posted on Jul 18, 2011 by Quick Horse

Thanks for the fixes.

Purnendu Singh(OpenERP)

Status: Fixed

Labels:
Type-Defect Priority-Medium