Commit 332c674b authored by Yusei Tahara's avatar Yusei Tahara

When cannot acquire workflow tool from instance, just to call original method and return.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16101 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent c8f63457
......@@ -131,12 +131,17 @@ class WorkflowMethod(Method):
# critical sections in this part of the code and a
# thread variable which tells in which semantic context the code
# should ne executed. - XXX
return apply(self._m, (instance,) + args, kw)
return self._m(instance, *args, **kw)
# New implementation does not use any longer wrapWorkflowMethod
# but directly calls the workflow methods
wf = getToolByName(instance, 'portal_workflow', None)
if wf is None:
# XXX instance is unwrapped(no acquisition)
# XXX I must think that what is a correct behavior.(Yusei)
return self._m(instance, *args, **kw)
# Build a list of transitions which may need to be invoked
instance_path = instance.getPhysicalPath()
portal_type = instance.portal_type
......
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