summaryrefslogtreecommitdiff
path: root/addons/document/document.py
diff options
context:
space:
mode:
authorhusen daudi <hda@hda>2009-04-13 18:13:13 +0530
committerhusen daudi <hda@hda>2009-04-13 18:13:13 +0530
commitea2efc15067b3b5f6448a5bce7baae8880c7bfbb (patch)
tree921b362d733c0e601792aa59955a81cd70722f3a /addons/document/document.py
parent7767525f1edc8c5e7dd32678ffce9ed2d19310a7 (diff)
parent4b180641bdc3356ec778a98bc10d936042a8fc12 (diff)
Ported all bugs from trunk to stable
bzr revid: hda@hda-20090413124313-x9gdobzpxf1lkfxl
Diffstat (limited to 'addons/document/document.py')
-rw-r--r--addons/document/document.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/addons/document/document.py b/addons/document/document.py
index 8c69a428100..039778915d3 100644
--- a/addons/document/document.py
+++ b/addons/document/document.py
@@ -588,6 +588,7 @@ class document_file(osv.osv):
res=self.search(cr,uid,[('id','<>',file.id),('name','=',name),('parent_id','=',parent_id),('res_model','=',res_model),('res_id','=',res_id)])
if len(res):
return False
+
if op=='create':
res=self.search(cr,uid,[('name','=',name),('parent_id','=',parent_id),('res_id','=',res_id),('res_model','=',res_model)])
if len(res):