Commit c0878727 authored by wenjie.zheng's avatar wenjie.zheng

Workflow.py: fix addTransition errors and add a new combatibility-related...

Workflow.py: fix addTransition errors and add a new combatibility-related function deleteTransitions.
parent fe3a2438
......@@ -760,8 +760,12 @@ class Workflow(IdAsReferenceMixin("", "prefix"), XMLObject):
return res
def addTransition(self, name):
self.newContent(portal_type='Transition')
self.setReference('dummy_workflow_method')
tr = self.newContent(portal_type='Transition')
tr.setReference(name)
def deleteTransitions(self, name_list):
for name in name_list:
self._delObject('transition_'+name)
def showAsXML(self, root=None):
if root is 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