From 938990f6984d7432842bddaac878f731cf2decf9 Mon Sep 17 00:00:00 2001 From: jem-odoo Date: Fri, 24 May 2019 13:03:09 +0000 Subject: [IMP] project: company required on task As task can be billed, it became a important business model. To avoid mistakes in a multi company environment, we need to make the company_id field required. Indeed shared task can be problematic with access rights when a employee will log timesheet from another company in a task that is not in the same company as its project. To populate this field, we recommend to take the company of task's project, or to fallback on the company of the user that created one. Task-1999686 --- addons/project/security/project_security.xml | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'addons/project/security/project_security.xml') diff --git a/addons/project/security/project_security.xml b/addons/project/security/project_security.xml index c50386bb6ec..eecc68d1ccb 100644 --- a/addons/project/security/project_security.xml +++ b/addons/project/security/project_security.xml @@ -38,10 +38,7 @@ Project: multi-company - ['|', - ('company_id', '=', False), - ('company_id', 'in', company_ids), - ] + [('company_id', 'in', company_ids)] @@ -67,10 +64,7 @@ Project/Task: multi-company - ['|', - ('company_id', '=', False), - ('company_id', 'in', company_ids), - ] + [('company_id', 'in', company_ids)] @@ -100,7 +94,7 @@ Task Analysis multi-company - ['|',('company_id','=',False),('company_id', 'in', company_ids)] + [('company_id', 'in', company_ids)] -- cgit v1.2.3