From 48555cd2eda08ec6b7d3b6b961cbc397d54a217f Mon Sep 17 00:00:00 2001 From: Bertrand Chenal Date: Wed, 27 May 2009 18:28:26 +0200 Subject: [PATCH] handle inactive records in get_parent --- work.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/work.py b/work.py index d523f4a881..14ac151e57 100644 --- a/work.py +++ b/work.py @@ -113,9 +113,11 @@ class Work(ModelSQL, ModelView): for project_work in project_works: ptw2pw[project_work.work.parent.id] = project_work.id + ctx = context and context.copy() or {} + ctx['active_test'] = False parent_project_ids = self.search(cursor, user, [ ('work', 'in', ptw2pw.keys()), - ], context=context) + ], context=ctx) parent_projects = self.browse(cursor, user, parent_project_ids, context=context) for parent_project in parent_projects: