[FIX] base_setup: correct VAT label for all countries

To reproduce the issue:

1. Install [Accounting] on Apps
2. On [Settings],
- [Users & Companies]>[Companies]: add a company with country Belgium
- Set the company to the Belgian one
- add French, set the language to it
- [General Settings] - check the [Companies] section

Desired behavior: Correction of VAT label

Impacted versions: 14.0 up to master

opw-3104416

closes odoo/odoo#111243

X-original-commit: f740cbeed106b5e04538128c861151039751ac1d
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Lee, Hansun (hale) <hale@odoo.com>
This commit is contained in:
Hansun (hale)
2023-01-27 21:10:16 +01:00
parent 27c275568f
commit b2bceb42d3
@@ -114,7 +114,9 @@ class ResConfigSettings(models.TransientModel):
informations += '%s\n' % self.company_id.city if self.company_id.city else ''
informations += '%s\n' % self.company_id.state_id.display_name if self.company_id.state_id else ''
informations += '%s' % self.company_id.country_id.display_name if self.company_id.country_id else ''
informations += '\nVAT: %s' % self.company_id.vat if self.company_id.vat else ''
vat_display = self.company_id.country_id.vat_label or _('VAT')
vat_display = '\n' + vat_display + ': '
informations += '%s %s' % (vat_display, self.company_id.vat) if self.company_id.vat else ''
for record in self:
record.company_informations = informations