Commit 7ac1baf3 authored by Sebastien Robin's avatar Sebastien Robin

call unindexObject with an activity

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@11327 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 42f3035a
No related merge requests found
...@@ -26,6 +26,7 @@ from Products.CMFCore.utils import getToolByName ...@@ -26,6 +26,7 @@ from Products.CMFCore.utils import getToolByName
from Globals import PersistentMapping, MessageDialog from Globals import PersistentMapping, MessageDialog
from Products.ERP5Type.Utils import get_request from Products.ERP5Type.Utils import get_request
from Products.CMFCore.WorkflowCore import WorkflowException from Products.CMFCore.WorkflowCore import WorkflowException
from Products.CMFCore.CatalogTool import CatalogTool as CMFCoreCatalogTool
from zLOG import LOG from zLOG import LOG
...@@ -298,9 +299,10 @@ class CopyContainer: ...@@ -298,9 +299,10 @@ class CopyContainer:
catalog = getToolByName(self, 'portal_catalog', None) catalog = getToolByName(self, 'portal_catalog', None)
if catalog is not None: if catalog is not None:
self.flushActivity(invoke=0) self.flushActivity(invoke=0)
#LOG("after flush",0, str(self.id)) uid = getattr(self,'uid',None)
catalog.unindexObject(self, path=path) if uid is None and path is None:
#LOG("unindexObject",0, str(self.id)) path = catalog.getUrl(self)
catalog.activate(activity='SQLQueue').unindexObject(None, path=path,uid=uid)
security.declareProtected(Permissions.ModifyPortalContent, 'moveObject') security.declareProtected(Permissions.ModifyPortalContent, 'moveObject')
def moveObject(self, idxs=None): def moveObject(self, idxs=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