[IMP] email.message: fix context problem for attachment in schedule_with_attach()

bzr revid: rha@tinyerp.com-20110401132159-h4mdo4k8zxrgagkz
This commit is contained in:
Rifakat Haradwala (Open ERP)
2011-04-01 18:51:59 +05:30
parent 8cce4b4bb6
commit faa13b7332
+2
View File
@@ -243,6 +243,8 @@ class email_message(osv.osv):
'res_model':'email.message',
'res_id': email_msg_id,
}
if context.has_key('default_type'):
del context['default_type']
attachment_ids.append(attachment_obj.create(cr, uid, attachment_data, context))
self.write(cr, uid, email_msg_id,
{ 'attachment_ids': [[6, 0, attachment_ids]] }, context)