fixed Bug #296100
bzr revid: hmo@tinyerp.com-20081111052750-zqzvr6oaihvt103t
This commit is contained in:
parent
ad280f3462
commit
83d2edd8c0
|
@ -96,6 +96,7 @@ class node_class(object):
|
|||
where.append( ('res_id','=',False) )
|
||||
if nodename:
|
||||
where.append( (fobj._rec_name,'=',nodename) )
|
||||
print where+[ ('parent_id','=',self.object and self.object.id or False) ]
|
||||
ids = fobj.search(self.cr, self.uid, where+[ ('parent_id','=',self.object and self.object.id or False) ], context=self.context)
|
||||
if self.object and self.root and (self.object.type=='ressource'):
|
||||
ids += fobj.search(self.cr, self.uid, where+[ ('parent_id','=',False) ], context=self.context)
|
||||
|
@ -560,6 +561,7 @@ class document_file(osv.osv):
|
|||
if not self._check_duplication(cr,uid,vals):
|
||||
raise except_orm('ValidateError', 'File name must be unique!')
|
||||
result = super(document_file,self).write(cr,uid,ids,vals,context=context)
|
||||
cr.commit()
|
||||
try:
|
||||
for f in self.browse(cr, uid, ids, context=context):
|
||||
if 'datas' not in vals:
|
||||
|
@ -568,6 +570,7 @@ class document_file(osv.osv):
|
|||
super(document_file,self).write(cr, uid, ids, {
|
||||
'index_content': res
|
||||
})
|
||||
cr.commit()
|
||||
except:
|
||||
pass
|
||||
return result
|
||||
|
|
Loading…
Reference in New Issue