odoo/odoo#123708

Created by fw-bot
Merged at b27705c901d3c228ace8dd3b86f1070c7edd9d24

Statuses:

label
odoo-dev:master-2023_05_10_RR_REFACTORING_CHECK_VAT-M-aJ-fw
head
d2e1eaaa16b380aa4513051d0b34e107551b34ae
merged
2 years ago by Accounting, Josse Colpaert (jco)
odoo/odoo
16.0 #121099
saas-16.1 #122637
saas-16.2 #122650
saas-16.3 #123584
17.0
18.0
saas-18.1
saas-18.2
saas-18.3
master #123708

[FW][REF] l10n_ec: Message validation for VAT

  • We refactored the VAT validation from a validation error to a warning that is stored in l10n_ec_vat_error
  • Remove the "-" and "EC" from the base_vat in the EC validation/example
  • Only validate the length in the base_vat
  • Add compute field with the warning message in the l10n_ec

Description of the issue/feature this PR addresses:

  1. In EC there are some RUCs (VAT number) and Cedulas (ID for physical individuals) that were given by the government, and they don't follow the math rule for the validation.
  2. This brings a problem as the RUC / Cedula is blocked from being added and the contact creation is blocked in Odoo to be created.
  3. But these RUCs and Cedulas are actually OK and valid, it is just that they don't follow the validation rule, as the government is the one that didn't follow the validation rule.
  4. We need to solve this for these types of contacts that have these types of Identification that don't follow the rule, as they are blocked to create the contact.

Current behavior before PR:
The current validation blocks the creation of contacts in Odoo when the vat do not follow the rule

Desired behavior after PR is merged:
We will warn the user that the given RUC / Cedula ay be wrong, with a yellow banner at the top with the warning message


I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

Forward-Port-Of: #123584
Forward-Port-Of: #121099