Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: VAT Number Validation

Entity: res.partner

Compute Method: _compute_perform_vies_validation

Inputs Method Outputs
""" Determine whether to show VIES validity on the current VAT number """
for partner in self:
            to_check = partner.vies_vat_to_check
            company_code = self.env.company.account_fiscal_country_id.code
            partner.perform_vies_validation = (
                to_check
                and to_check[:2].upper() != _eu_country_vat_inverse.get(company_code, company_code)
                and self.env.company.vat_check_vies
            )

Back to entity