[MERGE] [CHERRYPICK] Backport of revision 4879 of saas-1 branch.
[FIX] ir_attachment: in check, values could coutain a False res_model; no need to check self.pool[False], obviously. We consider void attachments as being accessible, because no related document exists. lp bug: https://launchpad.net/bugs/1171457 fixed bzr revid: tde@openerp.com-20130530142608-jgu1y7175q8hjkt5
This commit is contained in:
parent
aaa0cc0b82
commit
ac791818e0
|
@ -198,7 +198,7 @@ class ir_attachment(osv.osv):
|
|||
continue
|
||||
res_ids.setdefault(rmod,set()).add(rid)
|
||||
if values:
|
||||
if 'res_model' in values and 'res_id' in values:
|
||||
if values.get('res_model') and 'res_id' in values:
|
||||
res_ids.setdefault(values['res_model'],set()).add(values['res_id'])
|
||||
|
||||
ima = self.pool.get('ir.model.access')
|
||||
|
|
Loading…
Reference in New Issue