summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjbm-odoo <jbm@odoo.com>2019-12-16 15:47:57 +0000
committerjbm-odoo <jbm@odoo.com>2019-12-19 17:24:31 +0000
commit3b40a324d60e3f427c5e7663eab2ec6a7fa513ae (patch)
treec7eac639f8673f3e48be8b30642f24291dd4c920
parent4f0b6d6ce51bf7e2bf403e80425a8b2afe439573 (diff)
[FIX] hr_org_chart: Avoid write on employee just by loading the view
Before this commit: When loading a employee form, a write is done due to hr_org_chart After this commit: No write should be performed closes odoo/odoo#42214 Taskid: 2150314 X-original-commit: 6e150ee19bb1f42c14d13218114ae9afbb84ebf4 Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
-rw-r--r--addons/hr_org_chart/models/hr_org_chart_mixin.py1
1 files changed, 0 insertions, 1 deletions
diff --git a/addons/hr_org_chart/models/hr_org_chart_mixin.py b/addons/hr_org_chart/models/hr_org_chart_mixin.py
index e687c51feb0..473fc4294eb 100644
--- a/addons/hr_org_chart/models/hr_org_chart_mixin.py
+++ b/addons/hr_org_chart/models/hr_org_chart_mixin.py
@@ -28,7 +28,6 @@ class HrEmployeeBase(models.AbstractModel):
direct_subordinates = self.child_ids - parents
for child in direct_subordinates:
child_subordinate = child._get_subordinates(parents=parents)
- child.subordinate_ids = child_subordinate
indirect_subordinates |= child_subordinate
return indirect_subordinates | direct_subordinates