summaryrefslogtreecommitdiff
path: root/addons/account/__init__.py
diff options
context:
space:
mode:
authorYannick Tivisse <yti@odoo.com>2019-05-22 09:03:55 +0000
committerYannick Tivisse <yti@odoo.com>2019-05-29 08:09:15 +0000
commitf5dfe4727c086c7577da2aef12c2d3548ba938a3 (patch)
tree8af04c84c18ded0c1ed48c7c61640021dd9d24cb /addons/account/__init__.py
parent11cab26fb0f2167bfccfc3f11db10ff308f067b4 (diff)
[IMP] api.py: Rename company_id/company_ids into company/companies
The goal is to be coherent with the user property. Actually, company_id and company_ids on the environment are no fields. Calling env.company_id returns a browse record, not an id.
Diffstat (limited to 'addons/account/__init__.py')
-rw-r--r--addons/account/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/account/__init__.py b/addons/account/__init__.py
index b68cc24e7db..8a862f5d090 100644
--- a/addons/account/__init__.py
+++ b/addons/account/__init__.py
@@ -13,7 +13,7 @@ SYSCOHADA_LIST = ['BJ', 'BF', 'CM', 'CF', 'KM', 'CG', 'CI', 'GA', 'GN', 'GW', 'G
def _auto_install_l10n(cr, registry):
#check the country of the main company (only) and eventually load some module needed in that country
env = api.Environment(cr, SUPERUSER_ID, {})
- country_code = env.company_id.country_id.code
+ country_code = env.company.country_id.code
if country_code:
#auto install localization module(s) if available
module_list = []