[FIX] Attachment creation does not set datas_fname in ir_attachments

lp bug: https://launchpad.net/bugs/909069 fixed

bzr revid: fme@openerp.com-20120112134856-um5lw4b42x0vbmiw
This commit is contained in:
Fabien Meghazi 2012-01-12 14:48:56 +01:00
commit 378c20491b
1 changed files with 1 additions and 0 deletions

View File

@ -1257,6 +1257,7 @@ class Binary(openerpweb.Controller):
attachment_id = Model.create({
'name': ufile.filename,
'datas': base64.encodestring(ufile.read()),
'datas_fname': ufile.filename,
'res_model': model,
'res_id': int(id)
}, context)