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

Revert "patches/DCWorkflow.py: when generate xml file, verfie the existence of...

Revert "patches/DCWorkflow.py: when generate xml file, verfie the existence of the object, if an object id is bad defined, don't put it in XML."

This reverts commit aac83e25.
parent 4c43bf4a
......@@ -871,13 +871,7 @@ def DCWorkflowDefinition_showAsXML(self, root=None):
sdef = self.states[sid]
state = SubElement(states, 'state', attrib=dict(reference=sid,portal_type='State'))
for property_id in sorted(state_prop_id_to_show):
# do not put non-exist transition id in xml:
if property_id == 'transitions':
property_value = ()
for transition_id in getattr(sdef, property_id, ''):
if transition_id in self.transitions.keys():
property_value = property_value + (transition_id, )
else: property_value = getattr(sdef, property_id, '')
property_value = getattr(sdef, property_id, '')
if property_value is None or property_value == [] or property_value ==():
property_value = ''
property_type = state_prop_id_to_show[property_id]
......
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