[DMS]fixed bug

bzr revid: hmo@tinyerp.com-20090408095726-5tz2qt202r2a1oiu
This commit is contained in:
Harry (Open ERP)
2009-04-08 15:27:26 +05:30
parent a200350524
commit fd73be83e3
+2 -2
View File
@@ -317,10 +317,10 @@ class abstracted_fs:
raise OSError(1, 'Operation not permited.')
val = {
'name': basename,
'ressource_type_id': object and object.ressource_type_id.id or False,
'ressource_parent_type_id': object and object.ressource_type_id.id or False,
'ressource_id': object2 and object2.id or False
}
if (object and (object.type in ('directory'))) or not object2:
if (object and (object.type in ('directory'))) or not object2:
val['parent_id'] = object and object.id or False
# Check if it alreayd exists !
pool.get('document.directory').create(cr, uid, val)