Commit 200d0be1 authored by Sebastien Robin's avatar Sebastien Robin

when there was no activity tool, 2 uids where assigned to a new object !


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@6079 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4c9868ae
...@@ -320,7 +320,9 @@ class DocumentConstructor(Method): ...@@ -320,7 +320,9 @@ class DocumentConstructor(Method):
if is_indexable is not None: if is_indexable is not None:
o.isIndexable=is_indexable o.isIndexable=is_indexable
folder._setObject(id, o) folder._setObject(id, o)
o.uid = folder.portal_catalog.newUid() # if no activity tool, the object has already an uid
if getattr(aq_base(o),'uid',None) is None:
o.uid = folder.portal_catalog.newUid()
#LOG('DocumentConstructor', 0, 'o = %r, kw = %r' % (o, kw)) #LOG('DocumentConstructor', 0, 'o = %r, kw = %r' % (o, kw))
if kw: o.__of__(folder)._edit(force_update=1, **kw) if kw: o.__of__(folder)._edit(force_update=1, **kw)
if REQUEST is not None: if REQUEST is not None:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment