wfeditor-commons.xml 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197
  1. <mxEditor defaultGroup="group" defaultEdge="edge" urlPost="/api/admin/sqleditor/show/ShowMultiBranchEditor/saveGraph.do?"
  2. defaultDecinodeConfigUrl="/conditionNode/init.do"
  3. defaultShowResultConfigUrl="/resultNode/init.do"
  4. defaultResultConfigUrl="/ShowMultiBranchEditor/queryResultDic.do"
  5. helpWindowImage="/pubMng/graph/images/help.gif"
  6. tasksWindowImage="/pubMng/graph/images/tasks.gif"
  7. forcedInserting="0"
  8. swimlaneRequired="0"
  9. >
  10. <include name="/pubMng/graph/config2/editor-commons.xml"/>
  11. <add as="onInit">
  12. function ()
  13. {
  14. //this.showTasks();
  15. this.showOutline();
  16. }
  17. </add>
  18. <Array as="cycleAttributeValues">
  19. <add value="#83027F"/>
  20. <add value="#66B922"/>
  21. <add value="#808913"/>
  22. <add value="#CF0056"/>
  23. <add value="#4679B6"/>
  24. </Array>
  25. <Array as="templates">
  26. <add as="group">
  27. <Group label="" description="" href="">
  28. <mxCell vertex="1" style="group" connectable="0"/>
  29. </Group>
  30. </add>
  31. <add as="edge">
  32. <Edge label="" description="" lineCondition="">
  33. <mxCell edge="2">
  34. <mxGeometry as="geometry" relative="1" height="2"/>
  35. </mxCell>
  36. </Edge>
  37. </add>
  38. <add as="swimlane">
  39. <Swimlane label="Swimlane" description="" href="">
  40. <mxCell vertex="1" style="swimlane" connectable="0">
  41. <mxGeometry as="geometry" width="35" height="35"/>
  42. </mxCell>
  43. </Swimlane>
  44. </add>
  45. <add as="task">
  46. <Task label="结果" taskname="" nodemethod="" nodemethodname="" businessLogic="" logicArgs="">
  47. <mxCell vertex="1">
  48. <mxGeometry as="geometry" width="35" height="35"/>
  49. </mxCell>
  50. </Task>
  51. </add>
  52. <add as="shape">
  53. <Shape label="自定义结果" taskname="" actor-id="" actor-idname="" advancebutton="" businessLogic="" logicArgs="">
  54. <mxCell vertex="1" >
  55. <mxGeometry as="geometry" width="35" height="35"/>
  56. </mxCell>
  57. </Shape>
  58. </add>
  59. <add as="decinode">
  60. <Decinode label="连接" leftcond="" compare="" rightcond="">
  61. <mxCell vertex="1" >
  62. <mxGeometry as="geometry" width="35" height="35"/>
  63. </mxCell>
  64. </Decinode>
  65. </add>
  66. <add as="start">
  67. <start label="开始" description="" businessLogic="" logicArgs="">
  68. <mxCell vertex="1">
  69. <mxGeometry as="geometry" width="35" height="35"/>
  70. </mxCell>
  71. </start>
  72. </add>
  73. <add as="end">
  74. <end label="结束" description="" businessLogic="" logicArgs="">
  75. <mxCell vertex="1">
  76. <mxGeometry as="geometry" width="35" height="35"/>
  77. </mxCell>
  78. </end>
  79. </add>
  80. </Array>
  81. <add as="createTasks"><![CDATA[
  82. function (div)
  83. {
  84. var off = 30;
  85. if (this.graph != null)
  86. {
  87. var layer = this.graph.model.root.getChildAt(0);
  88. mxUtils.para(div, mxResources.get('examples'));
  89. mxUtils.linkInvoke(div, mxResources.get('newDiagram'), this,
  90. 'open', 'diagrams/empty.xml', off);
  91. mxUtils.br(div);
  92. mxUtils.linkInvoke(div, mxResources.get('swimlanes'), this,
  93. 'open', 'diagrams/swimlanes.xml', off);
  94. mxUtils.br(div);
  95. mxUtils.linkInvoke(div, mxResources.get('travelBooking'), this,
  96. 'open', 'diagrams/travel-booking.xml', off);
  97. mxUtils.br(div);
  98. if (!this.graph.isSelectionEmpty())
  99. {
  100. var cell = this.graph.getSelectionCell();
  101. if (this.graph.getSelectionCount() == 1 &&
  102. (this.graph.model.isVertex(cell) &&
  103. cell.getEdgeCount() > 0) || this.graph.isSwimlane(cell))
  104. {
  105. mxUtils.para(div, 'Layout');
  106. mxUtils.linkAction(div, mxResources.get('verticalTree'),
  107. this, 'verticalTree', off);
  108. mxUtils.br(div);
  109. mxUtils.linkAction(div, mxResources.get('horizontalTree'),
  110. this, 'horizontalTree', off);
  111. mxUtils.br(div);
  112. }
  113. mxUtils.para(div, 'Format');
  114. if (mxUtils.isNode(cell.value, 'Symbol'))
  115. {
  116. mxUtils.linkAction(div, mxResources.get('image'),
  117. this, 'image', off);
  118. mxUtils.br(div);
  119. }
  120. else
  121. {
  122. mxUtils.linkAction(div, mxResources.get('opacity'),
  123. this, 'opacity', off);
  124. mxUtils.br(div);
  125. if (this.graph.model.isVertex(cell) ||
  126. (cell.style != null &&
  127. cell.style.indexOf("arrowEdge") >= 0))
  128. {
  129. mxUtils.linkAction(div, mxResources.get('gradientColor'),
  130. this, 'gradientColor', off);
  131. mxUtils.br(div);
  132. }
  133. if (this.graph.model.isEdge(cell))
  134. {
  135. mxUtils.linkAction(div, 'Straight Connector', this, 'straightConnector', off);
  136. mxUtils.br(div);
  137. mxUtils.linkAction(div, 'Elbow Connector', this, 'elbowConnector', off);
  138. mxUtils.br(div);
  139. mxUtils.linkAction(div, 'Arrow Connector', this, 'arrowConnector', off);
  140. mxUtils.br(div);
  141. }
  142. }
  143. mxUtils.linkAction(div, 'Rounded', this, 'toggleRounded', off);
  144. mxUtils.br(div);
  145. if (this.graph.isSwimlane(cell) || this.graph.model.isEdge(cell))
  146. {
  147. mxUtils.linkAction(div, 'Orientation', this, 'toggleOrientation', off);
  148. mxUtils.br(div);
  149. }
  150. if (this.graph.getSelectionCount() > 1)
  151. {
  152. mxUtils.para(div, mxResources.get('align'));
  153. mxUtils.linkAction(div, mxResources.get('left'),
  154. this, 'alignCellsLeft', off);
  155. mxUtils.br(div);
  156. mxUtils.linkAction(div, mxResources.get('center'),
  157. this, 'alignCellsCenter', off);
  158. mxUtils.br(div);
  159. mxUtils.linkAction(div, mxResources.get('right'),
  160. this, 'alignCellsRight', off);
  161. mxUtils.br(div);
  162. mxUtils.linkAction(div, mxResources.get('top'),
  163. this, 'alignCellsTop', off);
  164. mxUtils.br(div);
  165. mxUtils.linkAction(div, mxResources.get('middle'),
  166. this, 'alignCellsMiddle', off);
  167. mxUtils.br(div);
  168. mxUtils.linkAction(div, mxResources.get('bottom'),
  169. this, 'alignCellsBottom', off);
  170. mxUtils.br(div);
  171. }
  172. mxUtils.para(div, mxResources.get('selection'));
  173. mxUtils.linkAction(div, mxResources.get('clearSelection'),
  174. this, 'selectNone', off);
  175. mxUtils.br(div);
  176. }
  177. else if (layer.getChildCount() > 0)
  178. {
  179. mxUtils.para(div, mxResources.get('selection'));
  180. mxUtils.linkAction(div, mxResources.get('selectAll'),
  181. this, 'selectAll', off);
  182. mxUtils.br(div);
  183. }
  184. mxUtils.br(div);
  185. }
  186. }
  187. ]]></add>
  188. </mxEditor>