[FIX] mail: display messages in chatter of inactive records
The method search inside _find_allowed_model_wise must consider records with active field=True. opw:630295
This commit is contained in:
parent
49e7e67a27
commit
3bd29a3483
|
@ -572,7 +572,8 @@ class mail_message(osv.Model):
|
|||
|
||||
def _find_allowed_model_wise(self, cr, uid, doc_model, doc_dict, context=None):
|
||||
doc_ids = doc_dict.keys()
|
||||
allowed_doc_ids = self.pool.get(doc_model).search(cr, uid, [('id', 'in', doc_ids)], context=context)
|
||||
ctx = dict(context or {}, active_test=False)
|
||||
allowed_doc_ids = self.pool.get(doc_model).search(cr, uid, [('id', 'in', doc_ids)], context=ctx)
|
||||
return set([message_id for allowed_doc_id in allowed_doc_ids for message_id in doc_dict[allowed_doc_id]])
|
||||
|
||||
def _find_allowed_doc_ids(self, cr, uid, model_ids, context=None):
|
||||
|
|
Loading…
Reference in New Issue