CF (Cod de înregistrare în scopuri de TVA, Romanian VAT number).
The Romanian CF is used for VAT purposes and can be from 2 to 10 digits long.
>>> validate('RO 185 472 90')
'18547290'
>>> validate('185 472 91')
Traceback (most recent call last):
...
InvalidChecksum: ...
>>> validate('1630615123457') # personal code
'1630615123457'
Traceback (most recent call last):
...
InvalidChecksum: ...
Calculate the check digit for organisations. The number passed should not have the check digit included.
Convert the number to the minimal representation. This strips the number of any valid separators and removes surrounding whitespace.
Checks to see if the number provided is a valid VAT number. This checks the length, formatting and check digit.
Checks to see if the number provided is a valid VAT number. This checks the length, formatting and check digit.