Commit 55c50c73 authored by wenjie.zheng's avatar wenjie.zheng

erp5_graph_editor: Workflow_getGraph, priorly use title to generate graph.

parent d2684255
...@@ -69,7 +69,7 @@ def getWorkflowGraph(workflow):\n ...@@ -69,7 +69,7 @@ def getWorkflowGraph(workflow):\n
is_initial_state = state.getId() == workflow.getSourceId()\n is_initial_state = state.getId() == workflow.getSourceId()\n
graph[\'node\'][state.getId()] = dict(\n graph[\'node\'][state.getId()] = dict(\n
_class=\'workflow.state\',\n _class=\'workflow.state\',\n
name=state.getId(),\n name=state.getTitleOrId(),\n
is_initial_state="Yes" if is_initial_state else "No")\n is_initial_state="Yes" if is_initial_state else "No")\n
if is_initial_state:\n if is_initial_state:\n
graph[\'node\'][state.getId()][\'css\'] = { "color": "red" } # TODO: use different CSS for initial state\n graph[\'node\'][state.getId()][\'css\'] = { "color": "red" } # TODO: use different CSS for initial state\n
...@@ -82,7 +82,7 @@ def getWorkflowGraph(workflow):\n ...@@ -82,7 +82,7 @@ def getWorkflowGraph(workflow):\n
dict(_class=\'workflow.transition\',\n dict(_class=\'workflow.transition\',\n
source=state.getId(),\n source=state.getId(),\n
destination=transition.getDestinationId(),\n destination=transition.getDestinationId(),\n
name=transition.getActboxName() or transition.getId(),\n name=transition.getActboxName() or transition.getTitleOrId(),\n
description=transition.getDescription(),\n description=transition.getDescription(),\n
actbox_url=transition.getActboxUrl(),\n actbox_url=transition.getActboxUrl(),\n
transition_id=transition.getId() # used for edition.\n transition_id=transition.getId() # used for edition.\n
......
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