[FIX] project: solve traceback on clicking 'Documents' button

bzr revid: cha@tinyerp.com-20121109083903-d8fk1yw5823u8q8k
This commit is contained in:
Ajay Chauhan (OpenERP) 2012-11-09 14:09:03 +05:30
parent 1a8ef8657b
commit e5b6b3f7e0
1 changed files with 2 additions and 2 deletions

View File

@ -204,8 +204,8 @@ class project(osv.osv):
def attachment_tree_view(self, cr, uid, ids, context):
task_ids = self.pool.get('project.task').search(cr, uid, [('project_id', 'in', ids)])
domain = [
('|',
'&', 'res_model', '=', 'project.project'), ('res_id', 'in', ids),
'|',
'&', ('res_model', '=', 'project.project'), ('res_id', 'in', ids),
'&', ('res_model', '=', 'project.task'), ('res_id', 'in', task_ids)
]
res_id = ids and ids[0] or False