Commit 3998e922 authored by wenjie.zheng's avatar wenjie.zheng

WorkflowTool.py: improve a type getter.

parent 03f24b4a
......@@ -587,9 +587,9 @@ class WorkflowTool(BaseTool, OriginalWorkflowTool):
# in the action list. Reassignment happens in the background. Nothing need to
# be done, just go back to whatever you are doing.
type_workflow_dict = self.getChainsByType()
type_tool = self.getPortalObject().portal_types
for ptype_id in type_workflow_dict:
ptype = getattr(context.getPortalObject().portal_types, ptype_id, None)
ptype = type_tool._getOb(ptype_id, None)
if ptype is not None:
for workflow_id in type_workflow_dict[ptype_id]:
workflow = getattr(self, workflow_id, 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