Commit e6aac13f authored by Jérome Perrin's avatar Jérome Perrin

reindex in notifyWorkflowMethod, so that only standard workflow method reindex,

and not interactions.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16220 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 00e368b5
No related merge requests found
...@@ -205,9 +205,6 @@ class WorkflowMethod(Method): ...@@ -205,9 +205,6 @@ class WorkflowMethod(Method):
except ObjectMoved, ex: except ObjectMoved, ex:
# Re-raise with a different result. # Re-raise with a different result.
raise ObjectMoved(ex.getNewObject(), result) raise ObjectMoved(ex.getNewObject(), result)
else:
if getattr(aq_base(instance), 'reindexObject', None) is not None:
instance.reindexObject()
# Call whatever must be called after changing states # Call whatever must be called after changing states
for wf_id, transition_list in valid_transition_item_list: for wf_id, transition_list in valid_transition_item_list:
......
...@@ -46,6 +46,8 @@ def DCWorkflowDefinition_notifyWorkflowMethod(self, ob, method_id, args=None, kw ...@@ -46,6 +46,8 @@ def DCWorkflowDefinition_notifyWorkflowMethod(self, ob, method_id, args=None, kw
if not self._checkTransitionGuard(tdef, ob): if not self._checkTransitionGuard(tdef, ob):
raise Unauthorized(method_id) raise Unauthorized(method_id)
self._changeStateOf(ob, tdef) self._changeStateOf(ob, tdef)
if getattr(ob, 'reindexObject', None) is not None:
ob.reindexObject()
def DCWorkflowDefinition_notifyBefore(self, ob, action, args=None, kw=None, transition_list=None): def DCWorkflowDefinition_notifyBefore(self, ob, action, args=None, kw=None, transition_list=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