mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-06 01:28:19 +01:00
FIX VAT number for Monaco (it uses FR)
This commit is contained in:
@@ -576,6 +576,7 @@ function isValidVATID($company)
|
||||
{
|
||||
$vatprefix = $company->country_code;
|
||||
if ($vatprefix == 'GR') $vatprefix = '(EL|GR)';
|
||||
elseif ($vatprefix == 'MC') $vatprefix = 'FR'; // Monaco is using french VAT numbers
|
||||
else $vatprefix = preg_quote($vatprefix, '/');
|
||||
if (! preg_match('/^'.$vatprefix.'[a-zA-Z0-9\-\.]{5,14}$/i', str_replace(' ', '', $company->tva_intra)))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user