summaryrefslogtreecommitdiff
path: root/addons/document/document.py
diff options
context:
space:
mode:
authordle@openerp.com <>2012-12-19 18:00:05 +0100
committerdle@openerp.com <>2012-12-19 18:00:05 +0100
commit7a627b581062ea55178448480d7ed9f7ee36a6e0 (patch)
treecdebfcefc5412eb2bd84e57aa53d0b9fb3c43391 /addons/document/document.py
parent6d49547fb6aafa5c9b5417177dd518b21d7b3f46 (diff)
[FIX]Update request missing one argument
bzr revid: dle@openerp.com-20121219170005-swdzzhvm2nifye5f
Diffstat (limited to 'addons/document/document.py')
-rw-r--r--addons/document/document.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/addons/document/document.py b/addons/document/document.py
index 52c4984a299..6cb2cabbf38 100644
--- a/addons/document/document.py
+++ b/addons/document/document.py
@@ -551,7 +551,7 @@ class document_storage(osv.osv):
# a hack: /assume/ that the calling write operation will not try
# to write the fname and size, and update them in the db concurrently.
# We cannot use a write() here, because we are already in one.
- cr.execute('UPDATE ir_attachment SET index_content = %s, file_type = %s WHERE id = %s', (filesize, icont_u, mime, file_node.file_id))
+ cr.execute('UPDATE ir_attachment SET file_size = %s, index_content = %s, file_type = %s WHERE id = %s', (filesize, icont_u, mime, file_node.file_id))
file_node.content_length = filesize
file_node.content_type = mime
return True
@@ -1620,7 +1620,6 @@ class node_res_obj(node_class):
}
if not self.res_find_all:
val['parent_id'] = self.dir_id
-
fil_id = fil_obj.create(cr, uid, val, context=ctx)
fil = fil_obj.browse(cr, uid, fil_id, context=ctx)
klass = self.context.node_file_class