vue2-client 1.15.4 → 1.15.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (469) hide show
  1. package/.cursorrules +19 -19
  2. package/.env.apply +19 -0
  3. package/.env.gaslink +19 -19
  4. package/.env.his +19 -19
  5. package/.env.liuli +19 -19
  6. package/.env.scada +19 -19
  7. package/.eslintrc.js +90 -90
  8. package/CHANGELOG.md +824 -824
  9. package/Components.md +60 -60
  10. package/docs/Logic/345/207/275/346/225/260/344/275/277/347/224/250/347/233/270/345/205/263.md +45 -46
  11. package/docs/LowCode/lowcode.md +155 -155
  12. package/docs/LowCode/lowcodeForDeveloper.md +230 -230
  13. package/docs/index.md +30 -30
  14. package/docs//345/207/275/346/225/260/344/275/277/347/224/250/347/233/270/345/205/263.md +2 -4
  15. package/index.js +31 -31
  16. package/jest-transform-stub.js +8 -8
  17. package/jest.setup.js +7 -7
  18. package/jsconfig.json +19 -19
  19. package/package.json +2 -1
  20. package/public/his/editor/editor.html +51 -51
  21. package/public/his/editor/mock/bind_data.html +779 -779
  22. package/public/his/editor/mock/data_table.html +40 -40
  23. package/public/his/editor/mock/sign.html +75 -75
  24. package/public/his/editor/vender/JsBarcode.all.js +3669 -3669
  25. package/public/his/editor/vender/date97/My97DatePicker.htm +65 -65
  26. package/public/his/editor/vender/date97/WdatePicker.js +677 -677
  27. package/public/his/editor/vender/date97/calendar.js +4 -4
  28. package/public/his/editor/vender/date97/lang/en.js +13 -13
  29. package/public/his/editor/vender/date97/lang/zh-cn.js +13 -13
  30. package/public/his/editor/vender/date97/lang/zh-tw.js +13 -13
  31. package/public/his/editor/vender/date97/skin/WdatePicker.css +10 -10
  32. package/public/his/editor/vender/date97/skin/default/datepicker.css +328 -328
  33. package/public/his/editor/vender/date97/skin/ext/datepicker.css +308 -308
  34. package/public/his/editor/vender/date97/skin/whyGreen/datepicker.css +255 -255
  35. package/public/his/editor/vender/diff.js +1627 -1627
  36. package/public/his/editor/vender/editor.js +1 -1
  37. package/public/his/editor/vender/fabric.js +31187 -31187
  38. package/public/his/editor/vender/jquery/jquery.base64.js +190 -190
  39. package/public/his/editor/vender/jquery/jquery.js +10872 -10872
  40. package/public/his/editor/vender/jquery/jquery.print.js +255 -255
  41. package/public/his/editor/vender/jquery/zTreeStyle/zTreeStyle.css +96 -96
  42. package/public/his/editor/vender/mui/mui.min.css +4 -4
  43. package/public/his/editor/vender/mui/mui.min.js +5 -5
  44. package/public/his/editor/vender/mui/mui.picker.min.css +6 -6
  45. package/public/his/editor/vender/mui/mui.picker.min.js +6 -6
  46. package/public/his/editor/vender/qrcode.js +7 -7
  47. package/public/his/editor/vender/requirejs/require.js +2145 -2145
  48. package/public/his/editor/vender/signature/jSignature.CompressorSVG.js +518 -518
  49. package/public/his/editor/vender/signature/jSignature.UndoButton.js +164 -164
  50. package/public/his/editor/vender/signature/jSignature.js +1486 -1486
  51. package/public/his/editor/vender/validator.js +5094 -5094
  52. package/public/his/editor/vender/weui/weui.css +5659 -5659
  53. package/public/his/editor/vender/weui/weui.min.css +4 -4
  54. package/public/his/editor/vender/weui/weui.min.js +11 -11
  55. package/public/index.html +27 -27
  56. package/src/ReportView.js +19 -19
  57. package/src/assets/img/querySlotDemo.svg +15 -15
  58. package/src/assets/svg/badtwo.svg +1 -1
  59. package/src/assets/svg/goodtwo.svg +1 -1
  60. package/src/base-client/components/AI/AskAiBtn.vue +136 -136
  61. package/src/base-client/components/AI/demo.vue +31 -31
  62. package/src/base-client/components/common/AMisRender/index.js +3 -3
  63. package/src/base-client/components/common/AMisRender/index.vue +263 -263
  64. package/src/base-client/components/common/AddressSearchCombobox/IcMapIcon.vue +16 -16
  65. package/src/base-client/components/common/AddressSearchCombobox/demo.vue +36 -36
  66. package/src/base-client/components/common/AddressSearchCombobox/ic_map.svg +6 -6
  67. package/src/base-client/components/common/AmapMarker/AmapPointRendering.vue +120 -120
  68. package/src/base-client/components/common/CitySelect/index.js +3 -3
  69. package/src/base-client/components/common/CitySelect/index.md +109 -109
  70. package/src/base-client/components/common/CreateQuery/CreateQuery.vue +669 -669
  71. package/src/base-client/components/common/CreateQuery/CreateQueryItem.vue +1014 -1014
  72. package/src/base-client/components/common/CreateQuery/index.js +3 -3
  73. package/src/base-client/components/common/CreateQuery/index.md +42 -42
  74. package/src/base-client/components/common/CreateSimpleFormQuery/CreateSimpleFormQuery.vue +452 -452
  75. package/src/base-client/components/common/CreateSimpleFormQuery/CreateSimpleFormQueryItem.vue +511 -511
  76. package/src/base-client/components/common/CreateSimpleFormQuery/index.js +3 -3
  77. package/src/base-client/components/common/CreateSimpleFormQuery/index.md +42 -42
  78. package/src/base-client/components/common/FormGroupEdit/index.js +3 -3
  79. package/src/base-client/components/common/FormGroupEdit/index.md +43 -43
  80. package/src/base-client/components/common/FormGroupQuery/FormGroupQuery.vue +166 -166
  81. package/src/base-client/components/common/FormGroupQuery/index.js +3 -3
  82. package/src/base-client/components/common/FormGroupQuery/index.md +43 -43
  83. package/src/base-client/components/common/JSONToTree/jsontotree.vue +271 -271
  84. package/src/base-client/components/common/LowCodeComponent/LowCodeEditorModal.vue +108 -108
  85. package/src/base-client/components/common/LowCodeComponent/LowCodeEditorPanel.vue +413 -413
  86. package/src/base-client/components/common/LowCodeComponent/LowCodePageOrganization.vue +502 -502
  87. package/src/base-client/components/common/LowCodeComponent/LowCodeRender.vue +728 -728
  88. package/src/base-client/components/common/LowCodeComponent/LowCodeRenderEnter.vue +29 -29
  89. package/src/base-client/components/common/LowCodeComponent/LowCodeUIStore.vue +219 -219
  90. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeAddPageModal.vue +117 -117
  91. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeCustomJSModal.vue +80 -80
  92. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeEventEditorModal.vue +398 -398
  93. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeLifeCycleModal.vue +65 -65
  94. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeLogicCallbackModal.vue +64 -64
  95. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeLogicParamModal.vue +73 -73
  96. package/src/base-client/components/common/LowCodeComponent/modal/lowCodeRunFunctionParamModal.vue +76 -76
  97. package/src/base-client/components/common/PersonSetting/PersonSetting.vue +208 -208
  98. package/src/base-client/components/common/PersonSetting/index.js +3 -3
  99. package/src/base-client/components/common/Recording/Recording.vue +243 -243
  100. package/src/base-client/components/common/Recording/index.js +3 -3
  101. package/src/base-client/components/common/Tree/Tree.vue +149 -149
  102. package/src/base-client/components/common/Tree/index.js +2 -2
  103. package/src/base-client/components/common/Upload/index.js +3 -3
  104. package/src/base-client/components/common/XAddForm/XAddForm.vue +113 -113
  105. package/src/base-client/components/common/XAddNativeForm/XAddNativeForm.vue +13 -0
  106. package/src/base-client/components/common/XAddNativeForm/index.md +146 -146
  107. package/src/base-client/components/common/XAddNativeFormOA/XAddNativeFormOA.vue +303 -303
  108. package/src/base-client/components/common/XAddNativeFormOA/index.js +3 -3
  109. package/src/base-client/components/common/XAddNativeFormOA/index.md +146 -146
  110. package/src/base-client/components/common/XAddReport/index.js +3 -3
  111. package/src/base-client/components/common/XAddReport/index.md +56 -56
  112. package/src/base-client/components/common/XBadge/XBadge.vue +94 -94
  113. package/src/base-client/components/common/XButtons/XButtonDemo.vue +28 -28
  114. package/src/base-client/components/common/XButtons/XButtons.vue +71 -71
  115. package/src/base-client/components/common/XButtons/index.js +3 -3
  116. package/src/base-client/components/common/XButtons/index.md +61 -61
  117. package/src/base-client/components/common/XCard/XCard.vue +64 -64
  118. package/src/base-client/components/common/XCheckList/XCheckList.vue +106 -106
  119. package/src/base-client/components/common/XCheckList/XCheckListDemo.vue +41 -41
  120. package/src/base-client/components/common/XDataCard/index.js +3 -3
  121. package/src/base-client/components/common/XDataCard/index.md +1 -1
  122. package/src/base-client/components/common/XDataDrawer/XDataDrawer.vue +180 -180
  123. package/src/base-client/components/common/XDataDrawer/index.js +3 -3
  124. package/src/base-client/components/common/XDataDrawer/index.md +41 -41
  125. package/src/base-client/components/common/XDatePicker/demo.vue +153 -153
  126. package/src/base-client/components/common/XDescriptions/index.js +3 -3
  127. package/src/base-client/components/common/XDescriptions/index.md +83 -83
  128. package/src/base-client/components/common/XDetailsView/XDetailsView.vue +238 -238
  129. package/src/base-client/components/common/XDetailsView/index.js +3 -3
  130. package/src/base-client/components/common/XForm/XStatusButton.vue +54 -54
  131. package/src/base-client/components/common/XForm/index.md +178 -178
  132. package/src/base-client/components/common/XForm/itemComponent/XClickChangeBtn/index.vue +49 -49
  133. package/src/base-client/components/common/XFormGroup/index.js +3 -3
  134. package/src/base-client/components/common/XFormGroup/index.md +38 -38
  135. package/src/base-client/components/common/XFormGroupDetails/XFormGroupDetails.vue +72 -72
  136. package/src/base-client/components/common/XFormGroupDetails/index.js +3 -3
  137. package/src/base-client/components/common/XFormTable/XFormTable.vue +12 -0
  138. package/src/base-client/components/common/XFormTable/index.md +92 -92
  139. package/src/base-client/components/common/XImportExcel/XImportExcel.vue +167 -167
  140. package/src/base-client/components/common/XLabelSelect/XLabelSelect.vue +110 -110
  141. package/src/base-client/components/common/XLabelSelect/XLabelSelectDemo.vue +35 -35
  142. package/src/base-client/components/common/XLicensePlate/XLicensePlate.vue +193 -193
  143. package/src/base-client/components/common/XLicensePlate/XLicensePlateDemo.vue +48 -48
  144. package/src/base-client/components/common/XPrint/OpenInvoice.vue +21 -21
  145. package/src/base-client/components/common/XPrint/PrintBill.vue +302 -302
  146. package/src/base-client/components/common/XPrint/PrintHtml.js +98 -98
  147. package/src/base-client/components/common/XPrint/css/hiPrintCss.js +359 -359
  148. package/src/base-client/components/common/XPrint/css/lodopCss.js +26 -26
  149. package/src/base-client/components/common/XPrint/css/print-lock.css +351 -351
  150. package/src/base-client/components/common/XPrint/index.vue +97 -97
  151. package/src/base-client/components/common/XReport/XReportDesign.vue +463 -463
  152. package/src/base-client/components/common/XReport/XReportJsonRender.vue +381 -381
  153. package/src/base-client/components/common/XReport/index.js +3 -3
  154. package/src/base-client/components/common/XReport/print.js +186 -186
  155. package/src/base-client/components/common/XReportDrawer/index.js +3 -3
  156. package/src/base-client/components/common/XReportGrid/index.js +3 -3
  157. package/src/base-client/components/common/XReportGrid/index.md +44 -44
  158. package/src/base-client/components/common/XReportSlot/XReportSlot.vue +110 -110
  159. package/src/base-client/components/common/XReportSlot/index.js +3 -3
  160. package/src/base-client/components/common/XReportSlot/index.md +48 -48
  161. package/src/base-client/components/common/XSimpleDescriptions/XSimpleDescriptions.vue +166 -166
  162. package/src/base-client/components/common/XSimpleDescriptions/index.js +3 -3
  163. package/src/base-client/components/common/XSimpleDescriptions/index.md +7 -7
  164. package/src/base-client/components/common/XStepView/XStepView.vue +252 -252
  165. package/src/base-client/components/common/XStepView/index.js +3 -3
  166. package/src/base-client/components/common/XStepView/index.md +31 -31
  167. package/src/base-client/components/common/XTab/XTab.vue +2 -1
  168. package/src/base-client/components/common/XTab/XTabDemo.vue +22 -22
  169. package/src/base-client/components/common/XTab/index.js +3 -3
  170. package/src/base-client/components/common/XTable/CustomFuncCel.vue +51 -51
  171. package/src/base-client/components/common/XTable/TableCellRenderer.vue +161 -161
  172. package/src/base-client/components/common/XTable/index.md +255 -255
  173. package/src/base-client/components/common/XTagGroup/index.vue +52 -52
  174. package/src/base-client/components/common/XTree/XTree.vue +424 -424
  175. package/src/base-client/components/common/XTree/index.js +3 -3
  176. package/src/base-client/components/common/XTree/index.md +36 -36
  177. package/src/base-client/components/common/XTreeOne/XTreeOne.vue +113 -113
  178. package/src/base-client/components/common/XTreeOne/XTreeOnePro.vue +128 -128
  179. package/src/base-client/components/common/richTextModal/index.vue +56 -56
  180. package/src/base-client/components/common/richTextModal/richDemo.vue +48 -48
  181. package/src/base-client/components/his/XHisEditor/index.js +3 -3
  182. package/src/base-client/components/his/XTextCard/XTextCard.vue +207 -207
  183. package/src/base-client/components/his/XTreeRows/TreeNode.vue +100 -100
  184. package/src/base-client/components/his/XTreeRows/XTreeRows.vue +197 -197
  185. package/src/base-client/components/his/threeTestOrders/editor.vue +111 -111
  186. package/src/base-client/components/index.js +51 -51
  187. package/src/base-client/components/layout/XTreeView/XTreeView.vue +130 -130
  188. package/src/base-client/components/layout/XTreeView/index.js +3 -3
  189. package/src/base-client/components/layout/XTreeView/index.md +46 -46
  190. package/src/base-client/components/system/DictionaryDetailsView/DictionaryDetailsView.vue +232 -232
  191. package/src/base-client/components/system/QueryParamsDetailsView/QueryParamsDetailsView.vue +281 -281
  192. package/src/base-client/plugins/Config.js +19 -19
  193. package/src/base-client/plugins/GetLoginInfoService.js +183 -183
  194. package/src/base-client/plugins/Recording.js +258 -258
  195. package/src/base-client/plugins/index.js +23 -23
  196. package/src/base-client/plugins/tabs-page-plugin.js +39 -39
  197. package/src/components/Charts/Bar.vue +62 -62
  198. package/src/components/Charts/ChartCard.vue +134 -134
  199. package/src/components/Charts/Liquid.vue +67 -67
  200. package/src/components/Charts/MiniArea.vue +39 -39
  201. package/src/components/Charts/MiniBar.vue +39 -39
  202. package/src/components/Charts/MiniProgress.vue +75 -75
  203. package/src/components/Charts/MiniSmoothArea.vue +40 -40
  204. package/src/components/Charts/Radar.vue +68 -68
  205. package/src/components/Charts/RankList.vue +77 -77
  206. package/src/components/Charts/TagCloud.vue +113 -113
  207. package/src/components/Charts/TransferBar.vue +64 -64
  208. package/src/components/Charts/Trend.vue +82 -82
  209. package/src/components/Charts/chart.less +12 -12
  210. package/src/components/Charts/smooth.area.less +13 -13
  211. package/src/components/CodeMirror/inedx.vue +118 -118
  212. package/src/components/CodeMirror/setting.js +40 -40
  213. package/src/components/HeightScanner/index.vue +571 -571
  214. package/src/components/NumberInfo/NumberInfo.vue +54 -54
  215. package/src/components/NumberInfo/index.js +3 -3
  216. package/src/components/NumberInfo/index.less +54 -54
  217. package/src/components/NumberInfo/index.md +43 -43
  218. package/src/components/card/ChartCard.vue +79 -79
  219. package/src/components/chart/Bar.vue +60 -60
  220. package/src/components/chart/MiniArea.vue +67 -67
  221. package/src/components/chart/MiniBar.vue +59 -59
  222. package/src/components/chart/MiniProgress.vue +57 -57
  223. package/src/components/chart/Radar.vue +80 -80
  224. package/src/components/chart/RankingList.vue +60 -60
  225. package/src/components/chart/Trend.vue +79 -79
  226. package/src/components/chart/index.less +9 -9
  227. package/src/components/checkbox/ColorCheckbox.vue +157 -157
  228. package/src/components/checkbox/ImgCheckbox.vue +117 -117
  229. package/src/components/checkbox/ImgCheckboxGroup.vue +76 -76
  230. package/src/components/checkbox/index.js +9 -9
  231. package/src/components/exception/ExceptionPage.vue +70 -70
  232. package/src/components/g2Charts/constants.js +202 -202
  233. package/src/components/g2Charts/demo.vue +808 -808
  234. package/src/components/g2Charts/designer.vue +228 -228
  235. package/src/components/g2Charts/designerBaseConfig.vue +61 -61
  236. package/src/components/g2Charts/designerDataConfig.vue +259 -259
  237. package/src/components/g2Charts/designerStyleConfig.vue +16 -16
  238. package/src/components/g2Charts/index.vue +397 -397
  239. package/src/components/index.js +36 -36
  240. package/src/components/input/IInput.vue +66 -66
  241. package/src/components/menu/SideMenu.vue +75 -75
  242. package/src/components/menu/menu.js +273 -273
  243. package/src/components/setting/Setting.vue +234 -234
  244. package/src/components/tool/AStepItem.vue +60 -60
  245. package/src/config/CreateQueryConfig.js +325 -325
  246. package/src/config/default/antd.config.js +89 -89
  247. package/src/config/default/setting.config.js +55 -55
  248. package/src/font-style/font.css +4 -4
  249. package/src/layouts/CommonLayout.vue +56 -56
  250. package/src/layouts/PageLayout.vue +151 -151
  251. package/src/layouts/SinglePageView.vue +136 -136
  252. package/src/layouts/header/AdminHeader.vue +132 -132
  253. package/src/layouts/header/HeaderNotice.vue +177 -177
  254. package/src/layouts/header/InstitutionDetail.vue +181 -181
  255. package/src/layouts/tabs/TabsHead.vue +189 -189
  256. package/src/layouts/tabs/TabsView.vue +389 -389
  257. package/src/lib.js +1 -1
  258. package/src/mock/extend/index.js +84 -84
  259. package/src/mock/goods/index.js +108 -108
  260. package/src/pages/AMisDemo/AMisDemo.vue +325 -325
  261. package/src/pages/AMisDemo/AMisDemo2.vue +74 -74
  262. package/src/pages/DefaultExample/index.vue +77 -77
  263. package/src/pages/DynamicStatistics/ChartSelector.vue +331 -331
  264. package/src/pages/DynamicStatistics/DataTabs.vue +83 -83
  265. package/src/pages/DynamicStatistics/DynamicTable.vue +128 -128
  266. package/src/pages/DynamicStatistics/EvaluationArea.vue +69 -69
  267. package/src/pages/DynamicStatistics/FavoriteList.vue +50 -50
  268. package/src/pages/DynamicStatistics/QuestionHistoryAndFavorites.vue +591 -591
  269. package/src/pages/DynamicStatistics/SearchBar.vue +192 -192
  270. package/src/pages/DynamicStatistics/index.vue +282 -282
  271. package/src/pages/Example/childIndex.vue +15 -15
  272. package/src/pages/Example/index.vue +30 -30
  273. package/src/pages/NewDynamicStatistics/ChartSelector.vue +331 -331
  274. package/src/pages/NewDynamicStatistics/DataTabs.vue +122 -122
  275. package/src/pages/NewDynamicStatistics/DynamicTable.vue +128 -128
  276. package/src/pages/NewDynamicStatistics/EvaluationArea.vue +69 -69
  277. package/src/pages/NewDynamicStatistics/FavoriteList.vue +50 -50
  278. package/src/pages/NewDynamicStatistics/QuestionHistoryAndFavorites.vue +289 -289
  279. package/src/pages/NewDynamicStatistics/SearchBar.vue +193 -193
  280. package/src/pages/NewDynamicStatistics/index.vue +258 -258
  281. package/src/pages/Recording/index.vue +77 -77
  282. package/src/pages/ServiceReview/index.vue +284 -284
  283. package/src/pages/SubExample/index.vue +26 -26
  284. package/src/pages/WorkflowDetail/WorkFlowDemo2.vue +1 -1
  285. package/src/pages/WorkflowDetail/WorkflowDetail.vue +41 -36
  286. package/src/pages/WorkflowDetail/WorkflowPageDetail/TrimTextTail.vue +23 -23
  287. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowBaseInformationDetails.vue +276 -276
  288. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowHandle.vue +641 -386
  289. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowHandleReso.vue +6 -6
  290. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowPreview.vue +2 -3
  291. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowTimeline.vue +240 -8
  292. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkOrderParentDetails.vue +1 -12
  293. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkflowDetailResso.vue +1 -19
  294. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkflowListResolution.vue +248 -248
  295. package/src/pages/WorkflowDetail/WorkflowPageDetail/components/WorkflowPersonSelector.vue +69 -0
  296. package/src/pages/XReportView/index.vue +64 -64
  297. package/src/pages/XTreeOneProExample/index.vue +67 -67
  298. package/src/pages/dashboard/workplace/WorkPlace.vue +141 -141
  299. package/src/pages/login/Login.vue +378 -378
  300. package/src/pages/login/LoginV3.vue +389 -389
  301. package/src/pages/lowCode/lowCodeEditor.vue +1219 -1219
  302. package/src/pages/lowCode/lowCodeRenderPage.vue +43 -43
  303. package/src/pages/report/ReportTable.js +124 -124
  304. package/src/pages/resourceManage/orgListManage.vue +98 -98
  305. package/src/pages/system/dictionary/index.vue +44 -44
  306. package/src/pages/system/monitor/loginInfor/index.vue +37 -37
  307. package/src/pages/system/monitor/operLog/index.vue +37 -37
  308. package/src/pages/system/settings/modifyPassword.vue +117 -117
  309. package/src/pages/system/ticket/index.vue +480 -480
  310. package/src/pages/system/ticket/submitTicketSuccess.vue +484 -484
  311. package/src/pages/userInfoDetailManage/ChangeMeterRecordQuery/index.vue +64 -64
  312. package/src/pages/userInfoDetailManage/InfoChangeRecordQuery/index.vue +64 -64
  313. package/src/pages/userInfoDetailManage/InstructRecordQuery/index.vue +64 -64
  314. package/src/pages/userInfoDetailManage/MeterParamRecordQuery/index.vue +64 -64
  315. package/src/pages/userInfoDetailManage/TransferRecordQuery/index.vue +66 -66
  316. package/src/pages/userInfoDetailManage/WatchCollectionRecordQuery/index.vue +64 -64
  317. package/src/plugins/EventLogPlugin.js +33 -33
  318. package/src/plugins/FindParentsData.js +17 -17
  319. package/src/router/async/config.async.js +35 -35
  320. package/src/router/index.js +27 -27
  321. package/src/router.js +19 -19
  322. package/src/services/DataModel.js +30 -30
  323. package/src/services/LodopFuncs.js +137 -137
  324. package/src/services/api/TicketDetailsViewApi.js +46 -46
  325. package/src/services/api/cas.js +79 -79
  326. package/src/services/api/common.js +346 -346
  327. package/src/services/api/entity.js +18 -18
  328. package/src/services/api/index.js +17 -17
  329. package/src/services/api/workFlow.js +0 -2
  330. package/src/store/modules/account.js +115 -115
  331. package/src/store/modules/index.js +5 -5
  332. package/src/store/modules/lowCode.js +33 -33
  333. package/src/store/modules/setting.js +119 -119
  334. package/src/theme/default/style.less +58 -58
  335. package/src/theme/global.less +159 -159
  336. package/src/utils/authority-utils.js +85 -85
  337. package/src/utils/errorCode.js +6 -6
  338. package/src/utils/formatter.js +74 -74
  339. package/src/utils/htmlToPDF.js +108 -108
  340. package/src/utils/htmlToPDFApi.js +5 -5
  341. package/src/utils/login.js +188 -188
  342. package/src/utils/lowcode/lowcodeComponentMixin.js +120 -120
  343. package/src/utils/lowcode/lowcodeLog.js +29 -29
  344. package/src/utils/lowcode/lowcodeUtils.js +373 -373
  345. package/src/utils/lowcode/registerComponentForEditor.js +1 -1
  346. package/src/utils/lowcode/registerComponentForRender.js +11 -11
  347. package/src/utils/map-utils.js +47 -47
  348. package/src/utils/reg.js +95 -95
  349. package/src/utils/runEvalFunction.js +14 -14
  350. package/src/utils/theme-color-replacer-extend.js +92 -92
  351. package/src/utils/util.js +329 -329
  352. package/src/utils/waterMark.js +31 -31
  353. package/vue.config.js +5 -0
  354. package//350/277/201/347/247/273/346/227/245/345/277/227.md +15 -15
  355. package/.history/public/his/editor/editor_20250606134713.html +0 -51
  356. package/.history/src/base-client/components/common/AddressSearchCombobox/AddressSearchCombobox_20250527173925.vue +0 -509
  357. package/.history/src/base-client/components/common/AddressSearchCombobox/AddressSearchCombobox_20250527174316.vue +0 -524
  358. package/.history/src/base-client/components/common/AddressSearchCombobox/AddressSearchCombobox_20250527174419.vue +0 -524
  359. package/.history/src/base-client/components/common/AddressSearchCombobox/AddressSearchCombobox_20250527174422.vue +0 -524
  360. package/.history/src/base-client/components/common/XAddReport/XAddReport_20250611172825.vue +0 -207
  361. package/.history/src/base-client/components/common/XAddReport/XAddReport_20250611172945.vue +0 -211
  362. package/.history/src/base-client/components/common/XAddReport/XAddReport_20250611172949.vue +0 -212
  363. package/.history/src/base-client/components/common/XAddReport/XAddReport_20250611173010.vue +0 -212
  364. package/.history/src/base-client/components/common/XForm/XFormItem_20250508134122.vue +0 -1320
  365. package/.history/src/base-client/components/common/XForm/XFormItem_20250527171604.vue +0 -1332
  366. package/.history/src/base-client/components/common/XForm/XFormItem_20250527171613.vue +0 -1331
  367. package/.history/src/base-client/components/common/XForm/XFormItem_20250527171703.vue +0 -1331
  368. package/.history/src/base-client/components/common/XForm/XFormItem_20250527171720.vue +0 -1331
  369. package/.history/src/base-client/components/common/XForm/XFormItem_20250527174327.vue +0 -1339
  370. package/.history/src/base-client/components/common/XReportGrid/XReportTrGroup_20250612092804.vue +0 -731
  371. package/.history/src/base-client/components/common/XReportGrid/XReportTrGroup_20250612112546.vue +0 -748
  372. package/.history/src/base-client/components/common/XReportGrid/XReportTrGroup_20250612113808.vue +0 -748
  373. package/.history/src/base-client/components/common/XReportGrid/XReport_20250612115237.vue +0 -1071
  374. package/.history/src/base-client/components/common/XReportGrid/XReport_20250612115346.vue +0 -1078
  375. package/.history/src/base-client/components/common/XReportGrid/XReport_20250612115350.vue +0 -1077
  376. package/.history/src/base-client/components/common/XReportGrid/XReport_20250612115415.vue +0 -1077
  377. package/.history/src/base-client/components/common/XReportGrid/XReport_20250612115429.vue +0 -1077
  378. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611091619.vue +0 -442
  379. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611092547.vue +0 -442
  380. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611092552.vue +0 -442
  381. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611092744.vue +0 -475
  382. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611092955.vue +0 -475
  383. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611092957.vue +0 -475
  384. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611095652.vue +0 -477
  385. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611095701.vue +0 -477
  386. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611095704.vue +0 -477
  387. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611100005.vue +0 -473
  388. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611100011.vue +0 -473
  389. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611100014.vue +0 -473
  390. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611100833.vue +0 -473
  391. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611100853.vue +0 -473
  392. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611100940.vue +0 -473
  393. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101011.vue +0 -473
  394. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101013.vue +0 -473
  395. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101014.vue +0 -473
  396. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101159.vue +0 -473
  397. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101238.vue +0 -474
  398. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101240.vue +0 -474
  399. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101242.vue +0 -474
  400. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101404.vue +0 -472
  401. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101410.vue +0 -472
  402. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101459.vue +0 -472
  403. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101500.vue +0 -472
  404. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101502.vue +0 -472
  405. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101504.vue +0 -472
  406. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101610.vue +0 -501
  407. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101700.vue +0 -501
  408. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101702.vue +0 -501
  409. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101741.vue +0 -504
  410. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101749.vue +0 -504
  411. package/.history/src/base-client/components/his/XHisEditor/XHisEditor_20250611101759.vue +0 -504
  412. package/.history/src/base-client/components/his/XHisEditor/dome_20250611091349.vue +0 -131
  413. package/.history/src/base-client/components/his/XHisEditor/dome_20250611105854.vue +0 -160
  414. package/.history/src/base-client/components/his/XHisEditor/dome_20250611105902.vue +0 -160
  415. package/.history/src/base-client/components/his/XHisEditor/dome_20250611105924.vue +0 -160
  416. package/.history/src/base-client/components/his/XHisEditor/dome_20250611105932.vue +0 -158
  417. package/.history/src/base-client/components/his/XList/XList_20250609135848.vue +0 -173
  418. package/.history/src/base-client/components/his/XList/XList_20250609141026.vue +0 -222
  419. package/.history/src/base-client/components/his/XList/XList_20250609141035.vue +0 -229
  420. package/.history/src/base-client/components/his/XList/XList_20250609141103.vue +0 -229
  421. package/.history/src/base-client/components/his/XList/XList_20250609141105.vue +0 -229
  422. package/.history/src/base-client/components/his/XList/XList_20250609141334.vue +0 -241
  423. package/.history/src/base-client/components/his/XList/XList_20250609141404.vue +0 -241
  424. package/.history/src/base-client/components/his/XList/XList_20250609141406.vue +0 -241
  425. package/.history/src/base-client/components/his/XList/XList_20250609141801.vue +0 -245
  426. package/.history/src/base-client/components/his/XList/XList_20250609142033.vue +0 -245
  427. package/.history/src/base-client/components/his/XList/XList_20250609142038.vue +0 -245
  428. package/.history/src/base-client/components/his/XList/XList_20250609142435.vue +0 -255
  429. package/.history/src/base-client/components/his/XList/XList_20250609142503.vue +0 -255
  430. package/.history/src/base-client/components/his/XList/XList_20250609142504.vue +0 -255
  431. package/.history/src/base-client/components/his/XList/XList_20250609143012.vue +0 -270
  432. package/.history/src/base-client/components/his/XList/XList_20250609143044.vue +0 -270
  433. package/.history/src/base-client/components/his/XList/XList_20250609143046.vue +0 -270
  434. package/.history/src/base-client/components/his/XList/XList_20250609143210.vue +0 -270
  435. package/.history/src/base-client/components/his/XList/XList_20250609144339.vue +0 -294
  436. package/.history/src/base-client/components/his/XList/XList_20250609144410.vue +0 -294
  437. package/.history/src/base-client/components/his/XList/XList_20250609144412.vue +0 -294
  438. package/.history/src/base-client/components/his/XList/XList_20250609144647.vue +0 -303
  439. package/.history/src/base-client/components/his/XList/XList_20250609144716.vue +0 -303
  440. package/.history/src/base-client/components/his/XList/XList_20250609144729.vue +0 -303
  441. package/.history/src/base-client/components/his/XList/XList_20250609151232.vue +0 -288
  442. package/.history/src/base-client/components/his/XList/XList_20250609151247.vue +0 -288
  443. package/.history/src/base-client/components/his/XList/XList_20250609151252.vue +0 -288
  444. package/.history/src/base-client/components/his/XList/XList_20250609161220.vue +0 -317
  445. package/.history/src/base-client/components/his/XList/XList_20250609161258.vue +0 -306
  446. package/.history/src/base-client/components/his/XList/XList_20250609161319.vue +0 -306
  447. package/.history/src/base-client/components/his/XList/XList_20250609161320.vue +0 -306
  448. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250609151519.vue +0 -222
  449. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250612155514.vue +0 -183
  450. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250612155556.vue +0 -183
  451. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250612155600.vue +0 -183
  452. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250612181609.vue +0 -206
  453. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250612181629.vue +0 -209
  454. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613095553.vue +0 -242
  455. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613095610.vue +0 -242
  456. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613095612.vue +0 -242
  457. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613100041.vue +0 -251
  458. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613100047.vue +0 -251
  459. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613100054.vue +0 -250
  460. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613100105.vue +0 -250
  461. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613100107.vue +0 -250
  462. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613100114.vue +0 -250
  463. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613140844.vue +0 -238
  464. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613140910.vue +0 -238
  465. package/.history/src/base-client/components/his/XShiftSchedule/XShiftSchedule_20250613140912.vue +0 -238
  466. package/Users/objecrt/af-vue2-client/src/base-client/components/his/XShiftSchedule/XShiftSchedule.vue +0 -36
  467. package/src/base-client/components/TreeList/TreeList.vue +0 -91
  468. package/src/base-client/components/TreeList/TreeNode.vue +0 -81
  469. package/src/base-client/components/common/XCardSet/XTiltle.vue +0 -191
@@ -13,182 +13,171 @@
13
13
  @activeStep="activeStep"/>
14
14
  </a-card>
15
15
  <!-- 无权访问的提示 -->
16
- <template v-if="!canSubmit">
17
- <a-result status="403" title="无权操作" sub-title="您没有访问该步骤的权限.">
18
- </a-result>
19
- </template>
20
- <template v-else>
16
+ <a-result v-show="!canSubmit" status="403" title="无权操作" sub-title="您没有访问该步骤的权限.">
17
+ </a-result>
18
+ <div v-show="canSubmit">
21
19
  <!-- 流程被退回的提示 -->
22
- <template v-if="currentStep && currentStep.back && !(beforeStepActive || workflowState)">
23
- <a-alert type="info" show-icon style="margin-bottom: 14px">
24
- <div slot="message">
25
- <span style="font-weight: bold">流程被退回</span>
26
- <span style="margin-left: 14px; font-size: 14px; color: rgba(0, 0, 0, 0.65)">请重新填写信息发起提交</span>
20
+ <a-alert v-if="currentStep && currentStep.back && !(beforeStepActive || workflowState)" type="info" show-icon style="margin-bottom: 14px">
21
+ <div slot="message">
22
+ <span style="font-weight: bold">流程被退回</span>
23
+ <span style="margin-left: 14px; font-size: 14px; color: rgba(0, 0, 0, 0.65)">请重新填写信息发起提交</span>
24
+ </div>
25
+ <div slot="description">
26
+ <div>操作人:{{
27
+ currentStep.back.f_operator
28
+ }}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;操作时间:{{ currentStep.back.f_date }}
27
29
  </div>
28
- <div slot="description">
29
- <div>操作人:{{ currentStep.back.f_operator }}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;操作时间:{{ currentStep.back.f_date }}</div>
30
- <div>原因:{{ currentStep.back.f_notes }}</div>
31
- </div>
32
- </a-alert>
33
- </template>
30
+ <div>原因:{{ currentStep.back.f_notes }}</div>
31
+ </div>
32
+ </a-alert>
34
33
  <!-- 步骤内容主体 -->
35
34
  <a-tabs default-active-key="1" @change="note = ''" type="card">
36
- <template v-if="beforeStepActive || workflowState">
37
- <a-tab-pane key="0" tab="步骤详情">
38
- <a-card :bordered="false" :loading="loadingHistory" :body-style="{ paddingTop: 0 }">
39
- <!-- 当前步骤历史记录 -->
40
- <template v-if="showTab">
41
- <x-tab
42
- :compProp="{ buttonState: { add: false, edit: false, delete: false, import: false }, disableAction: true }"
43
- :local-config="tabDesigner"
44
- :body-style="{ padding: 0 }"
45
- :tabBarGutter="24"
46
- :extra-data="{ workflowId: workflowId }"
47
- default-active-key="workFlowTab">
48
- <a-tab-pane
49
- :forceRender="true"
50
- v-if="formCompletedDataPreview"
51
- slot="extraBeforeTabs"
52
- key="workFlowTab"
53
- tab="表单"
54
- >
55
- <work-flow-preview :form-completed-data-preview="formCompletedDataPreview" />
56
- </a-tab-pane>
57
- </x-tab>
58
- </template>
59
- <template v-else-if="formCompletedDataPreview">
60
- <work-flow-preview :form-completed-data-preview="formCompletedDataPreview" />
61
- </template>
62
- <template v-else>
63
- <a-result status="404" title="暂无数据" sub-title="该步骤暂无数据。">
64
- </a-result>
65
- </template>
66
- </a-card>
67
- </a-tab-pane>
68
- </template>
69
- <template v-else>
70
- <a-tab-pane key="1" tab="业务操作">
71
- <a-card :bordered="false" :loading="loadingHistory" :body-style="{ paddingTop: 0 }">
72
- <template v-if="showTab">
73
- <x-tab :local-config="tabDesigner" :extra-data="{ workflowId:workflowId }" :body-style="{ padding: 0 }" :tabBarGutter="24" default-active-key="workFlowTab">
74
- <a-tab-pane
75
- :forceRender="true"
76
- v-if="showForm"
77
- slot="extraBeforeTabs"
78
- key="workFlowTab"
79
- tab="表单"
80
- >
81
- <x-add-native-form
82
- ref="xAddForm"
83
- @onSubmit="submitForm"/>
84
- </a-tab-pane>
85
- </x-tab>
86
- </template>
87
- <template v-else>
88
- <template v-if="showForm">
89
- <x-add-native-form
90
- ref="xAddForm"
91
- @x-form-item-emit-func="formItemEmitFunc"
92
- @onSubmit="submitForm"/>
93
- </template>
94
- </template>
95
- <a-divider />
96
- <a-form v-if="!lastStep" label-align="left" :label-col="{ span: 3 }" :wrapper-col="{ span: 13 }">
97
- <a-form-item v-if="showStepNextBtn" label="操作类型" required>
98
- <a-radio-group v-model="operationType" @change="handleOperationTypeChange">
99
- <a-radio value="submit">到下一步</a-radio>
100
- <a-radio value="skip">{{ stepNextBtnTitle }}</a-radio>
101
- </a-radio-group>
102
- </a-form-item>
103
- <a-form-item label="下一环节处理人" required v-if="needSelectPerson">
104
- <a-select
105
- v-model="checkedChargePerson"
106
- placeholder="请选择或搜索"
107
- :options="chargePersonOptions"
108
- show-search
109
- style="width: 195px"
110
- />
111
- </a-form-item>
112
- <a-form-item
113
- label="下一环节截止时间"
114
- :validate-status="deadlineValidateStatus"
115
- :help="deadlineHelp"
116
- required>
117
- <a-date-picker
118
- v-model="deadline"
119
- value-format="YYYY-MM-DD HH:mm"
120
- format="YYYY-MM-DD HH:mm"
121
- :allow-clear="false"
122
- :show-today="false"
123
- show-time
124
- placeholder="请选择"/>
125
- </a-form-item>
126
- </a-form>
127
- <a-divider />
128
- <!-- 备注信息 -->
129
- <a-textarea
130
- v-model="note"
131
- :auto-size="{ minRows: 3, maxRows: 5 }"
132
- placeholder="填写本环节备注事项"
133
- />
134
- <!-- 当前步骤完成后,控制流程按钮 -->
135
- <div style="text-align: center">
136
- <a-radio-group style="margin-top: 20px">
137
- <a-space>
138
- <!-- 动态按钮渲染 -->
139
- <template v-if="buttonGroup && buttonGroup.actionArr">
35
+ <a-tab-pane key="0" tab="步骤详情" v-if="beforeStepActive || workflowState">
36
+ <a-card :bordered="false" :loading="loadingHistory" :body-style="{ paddingTop: 0 }">
37
+ <!-- 当前步骤历史记录 -->
38
+ <template v-if="showTab">
39
+ <x-tab
40
+ :compProp="{ buttonState: { add: false, edit: false, delete: false, import: false }, disableAction: true }"
41
+ :local-config="tabDesigner"
42
+ :body-style="{ padding: 0 }"
43
+ :tabBarGutter="24"
44
+ :extra-data="{ workflowId: workflowId }"
45
+ default-active-key="workFlowTab">
46
+ <a-tab-pane
47
+ :forceRender="true"
48
+ v-if="formCompletedDataPreview"
49
+ slot="extraBeforeTabs"
50
+ key="workFlowTab"
51
+ tab="表单"
52
+ >
53
+ <work-flow-preview :form-completed-data-preview="formCompletedDataPreview"/>
54
+ </a-tab-pane>
55
+ </x-tab>
56
+ </template>
57
+ <template v-else-if="formCompletedDataPreview">
58
+ <work-flow-preview :form-completed-data-preview="formCompletedDataPreview"/>
59
+ </template>
60
+ <template v-else>
61
+ <a-result status="404" title="暂无数据" sub-title="该步骤暂无数据。">
62
+ </a-result>
63
+ </template>
64
+ </a-card>
65
+ </a-tab-pane>
66
+ <a-tab-pane key="1" tab="业务操作" v-else>
67
+ <a-card :bordered="false" :loading="loadingHistory" :body-style="{ paddingTop: 0 }">
68
+ <x-tab
69
+ v-if="showTab"
70
+ :local-config="tabDesigner"
71
+ :extra-data="{ workflowId:workflowId }"
72
+ :body-style="{ padding: 0 }"
73
+ :tabBarGutter="24"
74
+ default-active-key="workFlowTab">
75
+ <a-tab-pane
76
+ :forceRender="true"
77
+ v-if="showForm"
78
+ slot="extraBeforeTabs"
79
+ key="workFlowTab"
80
+ tab="表单"
81
+ >
82
+ <x-add-native-form
83
+ ref="xAddForm"
84
+ @onSubmit="submitForm"/>
85
+ </a-tab-pane>
86
+ </x-tab>
87
+ <x-add-native-form
88
+ v-else
89
+ ref="xAddForm"
90
+ @x-form-item-emit-func="formItemEmitFunc"
91
+ @onSubmit="submitForm"/>
92
+ <a-divider/>
93
+ <a-form v-show="!lastStep" label-align="left" :label-col="{ span: 3 }" :wrapper-col="{ span: 13 }">
94
+ <a-form-item v-if="showStepNextBtn" label="操作类型" required>
95
+ <a-radio-group v-model="operationType" @change="handleOperationTypeChange">
96
+ <a-radio value="submit">到下一步</a-radio>
97
+ <a-radio value="skip">{{ stepNextBtnTitle }}</a-radio>
98
+ </a-radio-group>
99
+ </a-form-item>
100
+ <!-- 智能分支人员选择组件 -->
101
+ <WorkflowPersonSelector ref="personSelector"/>
102
+ <a-form-item
103
+ label="下一环节截止时间"
104
+ :validate-status="deadlineValidateStatus"
105
+ :help="deadlineHelp"
106
+ required>
107
+ <a-date-picker
108
+ v-model="deadline"
109
+ value-format="YYYY-MM-DD HH:mm"
110
+ format="YYYY-MM-DD HH:mm"
111
+ :allow-clear="false"
112
+ :show-today="false"
113
+ show-time
114
+ placeholder="请选择"/>
115
+ </a-form-item>
116
+ </a-form>
117
+ <a-divider/>
118
+ <!-- 备注信息 -->
119
+ <a-textarea
120
+ v-model="note"
121
+ :auto-size="{ minRows: 3, maxRows: 5 }"
122
+ placeholder="填写本环节备注事项"
123
+ />
124
+ <!-- 当前步骤完成后,控制流程按钮 -->
125
+ <div style="text-align: center">
126
+ <a-radio-group style="margin-top: 20px">
127
+ <a-space>
128
+ <!-- 动态按钮渲染 -->
129
+ <template v-if="buttonGroup && buttonGroup.actionArr">
130
+ <a-button
131
+ v-for="(button, index) in buttonGroup.actionArr"
132
+ :key="index"
133
+ v-show="checkButtonVisible(button)"
134
+ :type="button.type ? button.type : 'default'"
135
+ @click="handleCustomButtonClick(button)"
136
+ >
137
+ {{ button.text }}
138
+ </a-button>
139
+ </template>
140
+ <!-- 原有的按钮逻辑 -->
141
+ <template>
142
+ <a-popover v-if="operationType === 'submit'">
143
+ <template slot="content">
144
+ <p>{{ nextBtnTitle }}</p>
145
+ </template>
140
146
  <a-button
141
- v-for="(button, index) in buttonGroup.actionArr"
142
- :key="index"
143
- v-show="checkButtonVisible(button)"
144
- :type="button.type ? button.type : 'default'"
145
- @click="handleCustomButtonClick(button)"
147
+ v-show="!lastStep"
148
+ :disabled="!showNextBtn && !stepDone"
149
+ type="primary"
150
+ @click="nextClick"
146
151
  >
147
- {{ button.text }}
152
+ 完成提交
153
+ <a-icon type="right"/>
148
154
  </a-button>
149
- </template>
150
- <!-- 原有的按钮逻辑 -->
151
- <template>
152
- <a-popover v-if="operationType === 'submit'">
153
- <template slot="content">
154
- <p>{{ nextBtnTitle }}</p>
155
- </template>
156
- <a-button
157
- v-show="!lastStep"
158
- :disabled="!showNextBtn && !stepDone"
159
- type="primary"
160
- @click="nextClick"
161
- >
162
- 完成提交
163
- <a-icon type="right"/>
164
- </a-button>
165
- </a-popover>
166
- <a-popover v-else :title="stepNextBtnTitle">
167
- <template slot="content">
168
- <p v-for="(item,index) in stepNextBtnText" :key="index">{{ item }}</p>
169
- </template>
170
- <a-button
171
- v-if="showStepNextBtn && !lastStep"
172
- type="primary"
173
- @click="stepNextClick"
174
- >
175
- 跳过
176
- </a-button>
177
- </a-popover>
155
+ </a-popover>
156
+ <a-popover v-else :title="stepNextBtnTitle">
157
+ <template slot="content">
158
+ <p v-for="(item,index) in stepNextBtnText" :key="index">{{ item }}</p>
159
+ </template>
178
160
  <a-button
179
- v-if="lastStep"
161
+ v-if="showStepNextBtn && !lastStep"
180
162
  type="primary"
181
- @click="lastStepNextClick"
163
+ @click="stepNextClick"
182
164
  >
183
- 确认完成
165
+ 跳过
184
166
  </a-button>
185
- </template>
186
- </a-space>
187
- </a-radio-group>
188
- </div>
189
- </a-card>
190
- </a-tab-pane>
191
- </template>
167
+ </a-popover>
168
+ <a-button
169
+ v-if="lastStep"
170
+ type="primary"
171
+ @click="lastStepNextClick"
172
+ >
173
+ 确认完成
174
+ </a-button>
175
+ </template>
176
+ </a-space>
177
+ </a-radio-group>
178
+ </div>
179
+ </a-card>
180
+ </a-tab-pane>
192
181
  <!-- 退回 -->
193
182
  <a-tab-pane v-if="canSubmit && !beforeStepActive && showPrevBtn && !workflowState" key="2" tab="退回">
194
183
  <a-form layout="vertical">
@@ -220,7 +209,7 @@
220
209
  <workflow-list-resolution :workflow-project-id="workflowId" :details="details"></workflow-list-resolution>
221
210
  </a-tab-pane>-->
222
211
  </a-tabs>
223
- </template>
212
+ </div>
224
213
  </div>
225
214
  </template>
226
215
 
@@ -230,23 +219,30 @@ import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XF
230
219
  import XAddForm from '@vue2-client/base-client/components/common/XAddForm/XAddForm'
231
220
  import { postByServiceName } from '@vue2-client/services/api/restTools'
232
221
  import { workFlowViewApi } from '@vue2-client/services/api/workFlow'
222
+ import { commonApi } from '@vue2-client/services/api'
233
223
  import { formatDate } from '@vue2-client/utils/util'
234
- // import { commonApi } from '@vue2-client/services/api/common'
235
224
  import { mapState } from 'vuex'
236
225
  import moment from 'moment'
237
226
  import FilePreview from '@vue2-client/components/FilePreview'
238
227
  import WorkFlowTimeline from './WorkFlowTimeline.vue'
239
228
  import { FileItem, ImageItem } from '@vue2-client/components/FileImageItem'
240
229
  import WorkflowListResolution from './WorkflowListResolution'
241
- import { commonApi } from '@vue2-client/services/api'
242
230
  import { executeStrFunctionByContext } from '@vue2-client/utils/runEvalFunction'
243
231
  import * as util from '@vue2-client/utils/util'
244
232
  import { getConfigByNameAsync, runLogic } from '@vue2-client/services/api/common'
233
+ import LogicRunner from '@vue2-client/logic/LogicRunner'
245
234
  import XTab from '@vue2-client/base-client/components/common/XTab/XTab.vue'
246
235
  import WorkFlowPreview from './WorkFlowPreview'
236
+ import WorkflowPersonSelector from './components/WorkflowPersonSelector.vue'
247
237
 
248
238
  export default {
249
239
  name: 'WorkFlowHandle',
240
+ provide () {
241
+ return {
242
+ formDataChange: this.handleFormDataChange,
243
+ workflowHandleWrap: this.workflowHandleWrap
244
+ }
245
+ },
250
246
  components: {
251
247
  XTab,
252
248
  WorkflowListResolution,
@@ -257,9 +253,13 @@ export default {
257
253
  FilePreview,
258
254
  FileItem,
259
255
  ImageItem,
260
- WorkFlowPreview
256
+ WorkFlowPreview,
257
+ WorkflowPersonSelector
261
258
  },
262
259
  computed: {
260
+ workflowHandleWrap () {
261
+ return this
262
+ },
263
263
  ...mapState('account', { currUser: 'user' }),
264
264
  canSubmit () {
265
265
  // 对于超级管理员直接认为可以提交
@@ -272,7 +272,7 @@ export default {
272
272
  }
273
273
  // 如果当前选中节点不是正在进行的节点,则判断viewers权限
274
274
  if (this.activeStepId !== this.currentStepId) {
275
- const activeStep = this.stepsForChild[this.activeStepId - 1]
275
+ const activeStep = this.stepsForChild.find(item => item.id === this.activeStepId)
276
276
  const viewers = activeStep?.properties?.otherProperty?.viewers ?? []
277
277
  if (viewers.length > 0) {
278
278
  // 使用some方法判断当前人员是否满足任一条件
@@ -291,7 +291,7 @@ export default {
291
291
  return true
292
292
  }
293
293
  } else {
294
- const step = this.stepsForChild[this.currentStepId - 1]
294
+ const step = this.stepsForChild.find(item => item.id === this.currentStepId)
295
295
  // 检查角色和部门权限
296
296
  if (step && step.properties && step.properties.chargePerson) {
297
297
  if (step.properties.chargePerson.personList && step.properties.chargePerson.personList.length > 0) {
@@ -410,11 +410,16 @@ export default {
410
410
  // 下一环节人员信息
411
411
  chargePerson: {},
412
412
  // 动态按钮配置
413
- buttonGroup: null
413
+ buttonGroup: null,
414
+ // 分支节点相关数据
415
+ branchNodes: [], // 需要选择人员的分支节点列表
416
+ branchChargePersons: {}, // 分支节点人员选择 格式:{stepId: personId}
417
+ isWfResultBranch: false, // 是否包含WF_RESULT的分支
418
+ calculatedTargetNode: null // 前台计算出的目标节点
414
419
  }
415
420
  },
416
421
  async mounted () {
417
- this.init()
422
+ await this.init()
418
423
  // this.checkDeadline()
419
424
  },
420
425
  props: {
@@ -469,6 +474,12 @@ export default {
469
474
  this.formCompletedData = {}
470
475
  this.formCompletedDataPreview = null
471
476
  this.operationType = 'submit'
477
+
478
+ // 清理分支节点相关数据
479
+ this.branchNodes = []
480
+ this.branchChargePersons = {}
481
+ this.isWfResultBranch = false
482
+ this.calculatedTargetNode = null
472
483
  },
473
484
  async showQueryFormItemFunc () {
474
485
  if (this.attr.showQueryFormItemFunc) {
@@ -503,42 +514,39 @@ export default {
503
514
  workflowId: this.workflowId
504
515
  })
505
516
  .then(res => {
506
- res.state = this.stepsForChild[res.id - 1].name
507
517
  this.currentStepId = res.id
518
+ const currentStep = this.stepsForChild.find(item => item.id === res.id)
519
+ res.state = currentStep.name
508
520
  // 获取到当前步骤后复制下一步时间
509
- this.deadline = this.getDefaultDeadline(this.stepsForChild[this.currentStepId - 1].properties?.otherProperty?.nextNodeInterval)
521
+ this.deadline = this.getDefaultDeadline(currentStep.properties?.otherProperty?.nextNodeInterval)
510
522
  this.currentStep = res
511
523
  this.getDirection()
512
524
  }, err => {
513
525
  console.log(err)
514
526
  })
515
527
  },
516
- // 判断id是否为流程中最后一个
517
- isLastStep (stepId) {
518
- const lastStepId = this.stepsDefine[this.stepsDefine.length - 1].id
519
- this.lastStep = stepId === lastStepId
520
- },
521
528
  // 完工按钮
522
529
  async lastStepNextClick () {
523
530
  this.$refs.xAddForm.asyncSubmit().then((res) => {
524
- this.submitForm(res)
525
- postByServiceName(workFlowViewApi.afterWorkFlowFinalStepSubmit, {
526
- workflowId: this.workflowId,
527
- stepId: this.currentStepId,
528
- submitUser: this.currUser.name,
529
- submitUserId: this.currUser.id
530
- }).then(_res => {
531
- this.saveWorkflowLog('确认完工', '最后一步: ' + this.getStepNameByStepId(this.currentStepId), { notes: this.note.trim() })
532
- this.$message.success('已完工!')
533
- this.loading = true
534
- this.loadingHistory = true
535
- this.onClose()
536
- this.$emit('success', { note: this.note.trim(), form: res.realForm, workflowId: this.workflowId })
537
- },
538
- () => {
539
- this.$message.error('提交失败!')
540
- }
541
- )
531
+ this.submitForm(res).then(_ => {
532
+ postByServiceName(workFlowViewApi.afterWorkFlowFinalStepSubmit, {
533
+ workflowId: this.workflowId,
534
+ stepId: this.currentStepId,
535
+ submitUser: this.currUser.name,
536
+ submitUserId: this.currUser.id
537
+ }).then(_res => {
538
+ this.saveWorkflowLog('确认完工', '最后一步: ' + this.getStepNameByStepId(this.currentStepId), { notes: this.note.trim() })
539
+ this.$message.success('已完工!')
540
+ this.loading = true
541
+ this.loadingHistory = true
542
+ this.onClose()
543
+ this.$emit('success', { note: this.note.trim(), form: res.realForm, workflowId: this.workflowId })
544
+ },
545
+ () => {
546
+ this.$message.error('提交失败!')
547
+ }
548
+ )
549
+ })
542
550
  })
543
551
  },
544
552
  // 三个按钮点击后逻辑
@@ -558,29 +566,35 @@ export default {
558
566
  })
559
567
  })
560
568
  this.$refs.xAddForm.asyncSubmit().then(res => {
561
- this.submitForm(res)
562
- postByServiceName(workFlowViewApi.submitToNextStep, extraData)
563
- .then(
564
- () => {
565
- const extra = {
566
- setHandler: this.getStepHandler(),
567
- setDeadline: this.deadline,
568
- notes: this.note.trim()
569
+ this.submitForm(res).then(_ => {
570
+ postByServiceName(workFlowViewApi.submitToNextStep, extraData)
571
+ .then(
572
+ () => {
573
+ const extra = {
574
+ setHandler: this.getStepHandler(),
575
+ setDeadline: this.deadline,
576
+ notes: this.note.trim()
577
+ }
578
+ this.saveWorkflowLog('提交', this.generateStepChangeText(this.currentStepId, this.nextBtnTo), extra)
579
+ this.$message.success('提交成功')
580
+ this.loading = true
581
+ this.loadingHistory = true
582
+ this.$emit('nextClick', {
583
+ note: this.note.trim(),
584
+ form: res.realForm,
585
+ workflowId: this.workflowId,
586
+ ...this.generateStepChange(this.currentStepId, this.nextBtnTo)
587
+ })
588
+ this.$emit('refresh')
589
+ this.onClose()
590
+ this.init()
591
+ },
592
+ err => {
593
+ this.$message.error('提交失败!')
594
+ console.log(err)
569
595
  }
570
- this.saveWorkflowLog('提交', this.generateStepChangeText(this.currentStepId, this.nextBtnTo), extra)
571
- this.$message.success('提交成功')
572
- this.loading = true
573
- this.loadingHistory = true
574
- this.$emit('nextClick', { note: this.note.trim(), form: res.realForm, workflowId: this.workflowId, ...this.generateStepChange(this.currentStepId, this.nextBtnTo) })
575
- this.$emit('refresh')
576
- this.onClose()
577
- this.init()
578
- },
579
- err => {
580
- this.$message.error('提交失败!')
581
- console.log(err)
582
- }
583
- )
596
+ )
597
+ })
584
598
  })
585
599
  },
586
600
  async preClick () {
@@ -591,7 +605,8 @@ export default {
591
605
  }
592
606
  return postByServiceName(workFlowViewApi.updateWorkFlowState, {
593
607
  stepId: this.preBtnTo,
594
- workflowId: this.workflowId
608
+ workflowId: this.workflowId,
609
+ type: 'back'
595
610
  })
596
611
  .then(
597
612
  res => {
@@ -615,72 +630,75 @@ export default {
615
630
  return
616
631
  }
617
632
  this.$refs.xAddForm.asyncSubmit().then(res => {
618
- this.submitForm(res)
619
- postByServiceName(workFlowViewApi.submitToNextStep, extraData)
620
- .then(
621
- () => {
622
- const extra = {
623
- setHandler: this.getStepHandler(),
624
- setDeadline: this.deadline,
625
- notes: this.note.trim()
633
+ this.submitForm(res).then(_ => {
634
+ postByServiceName(workFlowViewApi.submitToNextStep, extraData)
635
+ .then(
636
+ () => {
637
+ const extra = {
638
+ setHandler: this.getStepHandler(),
639
+ setDeadline: this.deadline,
640
+ notes: this.note.trim()
641
+ }
642
+ this.saveWorkflowLog('跳过', this.generateStepChangeText(this.currentStepId, this.stepNextBtnTo), extra)
643
+ this.$message.success('提交成功')
644
+ this.$emit('nextClick', {
645
+ note: this.note.trim(),
646
+ form: res.realForm,
647
+ workflowId: this.workflowId,
648
+ ...this.generateStepChange(this.currentStepId, this.stepNextBtnTo)
649
+ })
650
+ this.loading = true
651
+ this.loadingHistory = true
652
+ this.$emit('refresh')
653
+ this.onClose()
654
+ this.init()
655
+ },
656
+ err => {
657
+ this.$message.error('提交失败!')
658
+ console.log(err)
626
659
  }
627
- this.saveWorkflowLog('跳过', this.generateStepChangeText(this.currentStepId, this.stepNextBtnTo), extra)
628
- this.$message.success('提交成功')
629
- this.$emit('nextClick', { note: this.note.trim(), form: res.realForm, workflowId: this.workflowId, ...this.generateStepChange(this.currentStepId, this.stepNextBtnTo) })
630
- this.loading = true
631
- this.loadingHistory = true
632
- this.$emit('refresh')
633
- this.onClose()
634
- this.init()
635
- },
636
- err => {
637
- this.$message.error('提交失败!')
638
- console.log(err)
639
- }
640
- )
660
+ )
661
+ })
641
662
  })
642
663
  },
643
664
  // 获取当前步骤节点,连通的节点
644
- getDirection () {
665
+ async getDirection () {
645
666
  // 获取流程定义
646
667
  return postByServiceName(workFlowViewApi.getWorkFlowDefine, {
647
668
  id: this.workflowId
648
669
  })
649
- .then(res => {
670
+ .then(async res => {
650
671
  res = JSON.parse(res.value)
651
672
  this.directions = []
652
673
  this.stepsDefine = res.steps
653
- this.resolveDirections()
674
+ await this.resolveDirections()
654
675
  this.resolveStep()
655
676
  }, err => {
656
677
  console.log(err)
657
678
  })
658
679
  },
659
680
  // 分析当前节点,能通向的节点
660
- resolveDirections () {
661
- let hasBack = false
662
- if (this.stepsDefine[this.currentStepId - 1]?.properties?.actions) {
663
- this.currentDirections = this.stepsDefine[this.currentStepId - 1].properties.actions.filter((item) => {
664
- if (item.type === 'back') {
665
- hasBack = true
666
- }
667
- return true
668
- })
669
- }
670
- // 默认可退回到上一步
671
- if (!hasBack && this.currentStepId !== 1) {
672
- this.currentDirections.push({ head: this.currentStepId, tail: this.currentStepId - 1, type: 'back' })
681
+ async resolveDirections () {
682
+ const currentStep = this.stepsForChild.find(item => item.id === this.currentStepId)
683
+ if (currentStep?.properties?.actions) {
684
+ this.currentDirections = currentStep.properties.actions
673
685
  }
674
- this.isLastStep(this.currentStepId)
686
+ // 判断是否是最后ige节点
687
+ this.lastStep = (currentStep?.properties?.actions || []).filter(item => {
688
+ return item.type !== 'back'
689
+ }).length === 0
690
+
691
+ // 处理跳转按钮
692
+ this.workflowControl()
693
+
675
694
  if (!this.lastStep) {
676
- // 设置下一步的操作人
677
- this.setChargePersonOptions(this.currentStepId + 1)
695
+ // 分析分支节点并设置智能人员选择
696
+ await this.analyzeBranchNodes()
678
697
  }
679
- this.workflowControl()
680
698
  },
681
699
  // 根据步骤id获取步骤名称
682
700
  getStepNameByStepId (stepId) {
683
- return this.stepsDefine[stepId - 1].name
701
+ return this.stepsDefine.find(item => item.id === stepId)?.name
684
702
  },
685
703
  // 表单提交的回调
686
704
  submitForm (obj) {
@@ -710,7 +728,7 @@ export default {
710
728
  },
711
729
  // 获取当前步骤定义内容,构建组件
712
730
  buildComp () {
713
- const properties = this.stepsDefine[this.currentStep.id - 1].properties
731
+ const properties = this.stepsDefine.find(item => item.id === this.currentStep.id).properties
714
732
  // 表单的渲染
715
733
  if (properties.form && properties.form.formJson) {
716
734
  this.stepDefine = properties.form.formJson
@@ -737,34 +755,66 @@ export default {
737
755
  },
738
756
  // 根据当前节点,判断之后流程,以及按钮的显示
739
757
  workflowControl () {
740
- for (const direction of this.currentDirections) {
741
- if (direction.type === 'submit') {
742
- this.showNextBtn = true
743
- this.nextBtnTo = direction.to
744
- this.nextBtnTitle = '进行下一环节:' + this.getStepNameByStepId(direction.to)
745
- } else if (direction.type === 'skip') {
746
- this.showStepNextBtn = true
747
- this.stepNextBtnTo = direction.to
748
- this.stepNextBtnTitle = '跳至:' + this.getStepNameByStepId(direction.to) + '环节'
758
+ // 分类收集不同类型的actions
759
+ const submitActions = this.currentDirections.filter(item => item.type === 'submit')
760
+ const conditionalActions = this.currentDirections.filter(item => item.type === 'conditionalBranch')
761
+ const parallelActions = this.currentDirections.filter(item => item.type === 'parallelBranch')
762
+ const skipActions = this.currentDirections.filter(item => item.type === 'skip')
763
+ const backActions = this.currentDirections.filter(item => item.type === 'back')
764
+
765
+ // 处理提交按钮 - 优先级:submit > conditionalBranch > parallelBranch
766
+ if (submitActions.length > 0) {
767
+ this.showNextBtn = true
768
+ this.nextBtnTo = submitActions[0].to // 如果有多个submit,取第一个作为主要跳转目标
769
+ if (submitActions.length === 1) {
770
+ this.nextBtnTitle = '进行下一环节:' + this.getStepNameByStepId(submitActions[0].to)
771
+ } else {
772
+ this.nextBtnTitle = '将进入以下环节:' + submitActions.map(item => this.getStepNameByStepId(item.to)).join(' , ')
773
+ }
774
+ } else if (conditionalActions.length > 0) {
775
+ this.showNextBtn = true
776
+ this.nextBtnTo = conditionalActions[0].to // 条件分支的第一个作为主要跳转目标
777
+ const targetSteps = conditionalActions.map(item => this.getStepNameByStepId(item.to)).join(' , ')
778
+ this.nextBtnTitle = '后台判断后跳转到:' + targetSteps
779
+ } else if (parallelActions.length > 0) {
780
+ this.showNextBtn = true
781
+ this.nextBtnTo = parallelActions[0].to // 并行分支的第一个作为主要跳转目标
782
+ const targetSteps = parallelActions.map(item => this.getStepNameByStepId(item.to)).join(' , ')
783
+ this.nextBtnTitle = '将并行进入以下分支:' + targetSteps
784
+ }
785
+
786
+ // 处理跳过按钮
787
+ if (skipActions.length > 0) {
788
+ this.showStepNextBtn = true
789
+ this.stepNextBtnTo = skipActions[0].to
790
+ if (skipActions.length === 1) {
791
+ this.stepNextBtnTitle = '跳至:' + this.getStepNameByStepId(skipActions[0].to) + '环节'
749
792
  this.stepNextBtnText.push('将跳过以下环节:')
750
- for (let i = this.currentStepId; i < direction.to - 1; i++) {
793
+ for (let i = this.currentStepId; i < skipActions[0].to - 1; i++) {
751
794
  this.stepNextBtnText.push(this.stepsDefine[i].name)
752
795
  }
753
- } else if (direction.type === 'back') {
754
- for (let i = this.currentStepId - 1; i > 0; i--) {
755
- if (direction.to >= i && this.stepsForChild[i - 1].handler) {
756
- this.preBtnTo = i
757
- this.preBtnTitle = '回退至:' + this.getStepNameByStepId(i) + '环节'
758
- this.showPrevBtn = true
759
- break
760
- } else {
761
- this.preBtnText.push(this.getStepNameByStepId(i))
762
- }
763
- }
764
- if (this.preBtnText.length) {
765
- this.preBtnText.unshift('将跳过以下环节:')
796
+ } else {
797
+ const targetSteps = skipActions.map(item => this.getStepNameByStepId(item.to)).join(' , ')
798
+ this.stepNextBtnTitle = '跳至:' + targetSteps
799
+ }
800
+ }
801
+
802
+ // 处理退回按钮
803
+ if (backActions.length > 0) {
804
+ const backAction = backActions[0] // 通常只有一个back action
805
+ for (let i = this.currentStepId - 1; i > 0; i--) {
806
+ if (backAction.to >= i && this.stepsForChild.find(item => item.id === i)?.handler) {
807
+ this.preBtnTo = i
808
+ this.preBtnTitle = '回退至:' + this.getStepNameByStepId(i) + '环节'
809
+ this.showPrevBtn = true
810
+ break
811
+ } else {
812
+ this.preBtnText.push(this.getStepNameByStepId(i))
766
813
  }
767
814
  }
815
+ if (this.preBtnText.length) {
816
+ this.preBtnText.unshift('将跳过以下环节:')
817
+ }
768
818
  }
769
819
  },
770
820
  // 获取表单字段实际值
@@ -779,7 +829,7 @@ export default {
779
829
  // 加载完成
780
830
  resolveStep () {
781
831
  // 获取当前步骤的按钮组配置
782
- const currentStep = this.stepsDefine[this.currentStepId - 1]
832
+ const currentStep = this.stepsDefine.find(item => item.id === this.currentStepId)
783
833
  if (currentStep && currentStep.properties && currentStep.properties.buttonGroup) {
784
834
  this.buttonGroup = currentStep.properties.buttonGroup
785
835
  } else {
@@ -789,6 +839,7 @@ export default {
789
839
  },
790
840
  // 流程图组件给当前组件传值用,stepNo为用户点击的非当前步骤
791
841
  async activeStep (stepId) {
842
+ console.log('activeStep', stepId)
792
843
  // 开启加载
793
844
  this.loadingHistory = true
794
845
  this.activeStepId = stepId
@@ -806,7 +857,8 @@ export default {
806
857
  formCompletedDataPreview = JSON.parse(JSON.stringify(this.formCompletedData))
807
858
  // 使用字段定义中内容,将回显数据的列名,替换为定义的中文名
808
859
  const formData = formCompletedDataPreview.data
809
- const isKeyHandle = this.stepsDefine[stepId - 1]?.properties?.form?.isKeyHandle || false
860
+ const currentStepDefine = this.stepsDefine.find(item => item.id === stepId)
861
+ const isKeyHandle = currentStepDefine?.properties?.form?.isKeyHandle || false
810
862
  for (const key in formData) {
811
863
  for (let i = 0; i < this.targetStepDefine.length; i++) {
812
864
  const stepDefine = this.targetStepDefine[i]
@@ -837,19 +889,15 @@ export default {
837
889
  formCompletedDataPreview.data = null
838
890
  }
839
891
  // 备注
840
- formCompletedDataPreview.note = this.stepsForChild[stepId - 1].note
892
+ formCompletedDataPreview.note = this.stepsForChild.find(item => item.id === stepId)?.note
841
893
  if (!formCompletedDataPreview.data && !formCompletedDataPreview.files.length && !formCompletedDataPreview.images.length && !formCompletedDataPreview.note) {
842
894
  formCompletedDataPreview = null
843
895
  }
844
896
  this.formCompletedDataPreview = formCompletedDataPreview
845
897
  // 渲染已完成步骤的Tab
846
- const properties = this.stepsDefine[stepId - 1].properties
898
+ const properties = this.stepsDefine.find(item => item.id === stepId).properties
847
899
  this.tabDesigner = properties.tabDesigner
848
- if (this.tabDesigner) {
849
- this.showTab = true
850
- } else {
851
- this.showTab = false
852
- }
900
+ this.showTab = !!this.tabDesigner
853
901
  // 完成
854
902
  this.loadingHistory = false
855
903
  this.beforeStepActive = this.activeStepName !== this.currentStep.state
@@ -884,11 +932,28 @@ export default {
884
932
  // if (!this.checkDeadline(true)) {
885
933
  // return false
886
934
  // }
887
- const stepHandler = this.getStepHandler()
888
- if (this.needSelectPerson && !this.checkedChargePerson) {
889
- this.$message.error('请设置下一环节处理人')
890
- return false
935
+
936
+ // 验证人员选择
937
+ if (this.needSelectPerson) {
938
+ if (this.isWfResultBranch) {
939
+ // 多分支情况:检查是否所有需要的分支都选择了人员
940
+ const missingSelections = this.branchNodes.filter(node => !this.branchChargePersons[node.stepId])
941
+ if (missingSelections.length > 0) {
942
+ const missingNames = missingSelections.map(node => node.stepName).join('、')
943
+ this.$message.error(`请设置以下节点的处理人:${missingNames}`)
944
+ return false
945
+ }
946
+ } else {
947
+ // 单分支情况:检查是否选择了处理人
948
+ if (!this.checkedChargePerson) {
949
+ this.$message.error('请设置下一环节处理人')
950
+ return false
951
+ }
952
+ }
891
953
  }
954
+
955
+ const stepHandler = this.getStepHandler()
956
+
892
957
  return {
893
958
  workflowId: this.workflowId,
894
959
  stepId,
@@ -899,20 +964,62 @@ export default {
899
964
  personList: this.chargePerson.personList,
900
965
  deadline: this.deadline,
901
966
  submitUser: this.currUser.name,
902
- submitUserId: this.currUser.id
967
+ submitUserId: this.currUser.id,
968
+ // 新增:分支节点信息
969
+ branchInfo: this.isWfResultBranch ? {
970
+ isWfResultBranch: true,
971
+ branchChargePersons: this.branchChargePersons,
972
+ branchNodes: this.branchNodes.map(node => ({
973
+ stepId: node.stepId,
974
+ stepName: node.stepName,
975
+ selectedPersonId: this.branchChargePersons[node.stepId],
976
+ selectedPersonName: this.getBranchPersonName(node.stepId)
977
+ }))
978
+ } : {
979
+ isWfResultBranch: false,
980
+ calculatedTargetNode: this.calculatedTargetNode
981
+ }
903
982
  }
904
983
  },
905
984
  // 获取当前选择的负责人
906
985
  getStepHandler () {
907
986
  let stepHandler
908
- if (this.checkedChargePerson) {
909
- // 使用 value 找到对应的 label
910
- stepHandler = this.chargePersonOptions.find(item => item.value === this.checkedChargePerson).label
911
- } else if (this.chargePerson.personList && this.chargePerson.personList.length > 0) {
912
- stepHandler = this.chargePerson.personList.map(item => item.name).join(',')
987
+
988
+ if (this.isWfResultBranch) {
989
+ // 多分支情况:返回所有已选择的人员信息
990
+ const selectedHandlers = []
991
+ for (const node of this.branchNodes) {
992
+ const personId = this.branchChargePersons[node.stepId]
993
+ if (personId) {
994
+ const personName = this.getBranchPersonName(node.stepId)
995
+ selectedHandlers.push(`${node.stepName}:${personName}`)
996
+ }
997
+ }
998
+ stepHandler = selectedHandlers.join(';')
999
+ } else {
1000
+ // 单分支情况:原有逻辑
1001
+ if (this.checkedChargePerson) {
1002
+ // 使用 value 找到对应的 label
1003
+ stepHandler = this.chargePersonOptions.find(item => item.value === this.checkedChargePerson)?.label
1004
+ } else if (this.chargePerson.personList && this.chargePerson.personList.length > 0) {
1005
+ stepHandler = this.chargePerson.personList.map(item => item.name).join(',')
1006
+ }
913
1007
  }
1008
+
914
1009
  return stepHandler
915
1010
  },
1011
+
1012
+ // 获取分支节点选择的人员姓名
1013
+ getBranchPersonName (stepId) {
1014
+ const personId = this.branchChargePersons[stepId]
1015
+ if (!personId) return ''
1016
+
1017
+ const node = this.branchNodes.find(n => n.stepId === stepId)
1018
+ if (!node) return ''
1019
+
1020
+ const person = node.chargePersonOptions.find(p => p.value === personId)
1021
+ return person ? person.label : ''
1022
+ },
916
1023
  // 生成工作流日志步骤变化描述
917
1024
  generateStepChangeText (fromStepId, toStepId) {
918
1025
  return `第${fromStepId}步: ${this.getStepNameByStepId(fromStepId)} --> 第${toStepId}步: ${this.getStepNameByStepId(toStepId)}`
@@ -970,86 +1077,13 @@ export default {
970
1077
  return true
971
1078
  },
972
1079
  // 操作类型单选按钮改变时重新设置负责人选择框
973
- handleOperationTypeChange (event) {
1080
+ async handleOperationTypeChange (event) {
974
1081
  this.checkedChargePerson = undefined
975
- if (event.target.value === 'submit') {
976
- this.setChargePersonOptions(this.nextBtnTo)
977
- } else {
978
- this.setChargePersonOptions(this.stepNextBtnTo)
979
- }
1082
+ this.branchChargePersons = {}
1083
+ // 重新分析分支节点
1084
+ await this.analyzeBranchNodes()
980
1085
  },
981
- // 从指定步骤设置负责人下拉选择框
982
- async setChargePersonOptions (stepId) {
983
- this.checkedChargePerson = undefined
984
- const define = this.stepsDefine[stepId - 1]
985
- const defineProperties = define.properties
986
- // chargePerson 改造 旧数据类型是 {chrgePerson: {role: '1', department: '1'}}
987
- // 新数据类型是
988
- // "chargePerson": {
989
- // "personList": [
990
- // {
991
- // "type": "department",
992
- // "name": "营业厅"
993
- // },
994
- // {
995
- // "type": "role",
996
- // "name": "管理员"
997
- // }
998
- // ],
999
- // "needSelectPerson": true
1000
- // }
1001
- const chargePerson = defineProperties.chargePerson
1002
- if (!chargePerson) {
1003
- this.needSelectPerson = false
1004
- this.chargePersonOptions = []
1005
- return
1006
- }
1007
- // 如果是旧的格式 转换成新的格式后再作处理
1008
- if (chargePerson.role || chargePerson.department) {
1009
- chargePerson.needSelectPerson = true
1010
- chargePerson.personList = [{ type: chargePerson.role ? 'role' : 'department', name: chargePerson.role || chargePerson.department }]
1011
- }
1012
- this.needSelectPerson = chargePerson.needSelectPerson
1013
- this.chargePerson = chargePerson
1014
- const chargePersonOptions = []
1015
- // 如果需要选择人员 则在这里选择人员 否则 后台选择人员 这里不处理
1016
- if (chargePerson.needSelectPerson) {
1017
- // 获取所有用户信息
1018
- const allUser = await postByServiceName(commonApi.getAllUserOptionList, {})
1019
-
1020
- // 使用reduce累积结果
1021
- const options = chargePerson.personList.reduce((acc, personItem) => {
1022
- let filteredUsers = []
1023
1086
 
1024
- if (personItem.type === 'role') {
1025
- // 根据角色获取人员
1026
- filteredUsers = allUser.filter(user =>
1027
- user.rolestr && user.rolestr.split(',').includes(personItem.name)
1028
- ).map(user => {
1029
- return { label: user.label, value: user.value }
1030
- })
1031
- } else if (personItem.type === 'department') {
1032
- // 根据部门获取人员
1033
- filteredUsers = allUser.filter(user =>
1034
- user.depname === personItem.name
1035
- ).map(user => {
1036
- return { label: user.label, value: user.value }
1037
- })
1038
- }
1039
-
1040
- return [...acc, ...filteredUsers]
1041
- }, [])
1042
-
1043
- // 去重处理
1044
- const uniqueOptions = Array.from(new Map(options.map(item => [item.value, item])).values())
1045
- chargePersonOptions.push(...uniqueOptions)
1046
- }
1047
- this.chargePersonOptions = chargePersonOptions
1048
- // 默认选中下一环节负责人
1049
- if (this.chargePersonOptions.length === 1) {
1050
- this.checkedChargePerson = this.chargePersonOptions[0].value
1051
- }
1052
- },
1053
1087
  // 处理动态按钮点击
1054
1088
  handleCustomButtonClick (button) {
1055
1089
  try {
@@ -1084,7 +1118,222 @@ export default {
1084
1118
  },
1085
1119
  formItemEmitFunc (func, data, value) {
1086
1120
  this.$emit('x-form-item-emit-func', func, data, value)
1087
- }
1121
+ },
1122
+ // 检查条件表达式是否包含WF_RESULT
1123
+ checkIfContainsWfResult () {
1124
+ const conditionalActions = this.currentDirections.filter(action => action.type === 'conditionalBranch')
1125
+ if (conditionalActions.length === 0) return false
1126
+
1127
+ return conditionalActions.some(action => {
1128
+ return action.expression && action.expression.includes('WF_RESULT')
1129
+ })
1130
+ },
1131
+
1132
+ // 分析分支节点并设置选择框
1133
+ async analyzeBranchNodes () {
1134
+ const conditionalActions = this.currentDirections.filter(action => action.type === 'conditionalBranch')
1135
+ // 如果没有分支节点,处理普通单线流程
1136
+ if (conditionalActions.length === 0) {
1137
+ this.branchNodes = []
1138
+ this.isWfResultBranch = false
1139
+
1140
+ await this.handleNormalFlow()
1141
+ return
1142
+ }
1143
+
1144
+ this.isWfResultBranch = this.checkIfContainsWfResult()
1145
+
1146
+ if (this.isWfResultBranch) {
1147
+ // 包含WF_RESULT,需要显示所有可能分支的人员选择
1148
+ await this.setupMultipleBranchSelection(conditionalActions)
1149
+ } else {
1150
+ this.branchNodes = []
1151
+ // 不包含WF_RESULT,可以前台实时计算
1152
+ await this.calculateTargetNodeFromForm(conditionalActions)
1153
+ }
1154
+ },
1155
+
1156
+ // 根据表单数据计算目标节点
1157
+ async calculateTargetNodeFromForm (conditionalActions = null) {
1158
+ if (!conditionalActions) {
1159
+ conditionalActions = this.currentDirections.filter(action => action.type === 'conditionalBranch')
1160
+ }
1161
+
1162
+ if (conditionalActions.length === 0) return
1163
+
1164
+ try {
1165
+ const formData = this.$refs.xAddForm?.form || {}
1166
+
1167
+ // 遍历条件找到匹配的
1168
+ for (const action of conditionalActions) {
1169
+ if (action.expression) {
1170
+ const result = await this.evaluateExpression(action.expression, formData)
1171
+ if (result) {
1172
+ this.calculatedTargetNode = action.to
1173
+
1174
+ // 设置对应节点的人员选择
1175
+ const stepDefine = this.stepsDefine.find(step => step.id === action.to)
1176
+ if (stepDefine?.properties?.chargePerson?.needSelectPerson) {
1177
+ this.chargePerson = stepDefine?.properties?.chargePerson
1178
+ this.checkedChargePerson = undefined
1179
+ this.chargePersonOptions = await this.getChargePersonOptionsForStep(action.to)
1180
+ // 如果只有一个选项,自动选中
1181
+ if (this.chargePersonOptions.length === 1) {
1182
+ this.checkedChargePerson = this.chargePersonOptions[0].value
1183
+ }
1184
+ this.needSelectPerson = true
1185
+ } else {
1186
+ this.needSelectPerson = false
1187
+ this.chargePersonOptions = []
1188
+ }
1189
+ return
1190
+ }
1191
+ }
1192
+ }
1193
+ // 如果没有匹配的条件,清空选择
1194
+ this.calculatedTargetNode = null
1195
+ this.needSelectPerson = false
1196
+ this.chargePersonOptions = []
1197
+ } catch (error) {
1198
+ console.warn('计算目标节点失败:', error)
1199
+ this.calculatedTargetNode = null
1200
+ }
1201
+ },
1202
+
1203
+ // 表达式评估 - 使用 LogicRunner
1204
+ async evaluateExpression (expression, formData) {
1205
+ try {
1206
+ // 构建参数对象,传递当前表单数据
1207
+ const params = {
1208
+ WF_FORM: { ...formData }
1209
+ }
1210
+
1211
+ // 使用 LogicRunner 执行表达式
1212
+ const result = await LogicRunner.runExpression(expression, params)
1213
+ return result
1214
+ } catch (error) {
1215
+ console.warn('表达式评估失败:', expression, error)
1216
+ return false
1217
+ }
1218
+ },
1219
+
1220
+ // 获取指定步骤的人员选项
1221
+ async getChargePersonOptionsForStep (stepId) {
1222
+ const define = this.stepsDefine.find(item => item.id === stepId)
1223
+ if (!define?.properties?.chargePerson) return []
1224
+
1225
+ const chargePerson = define.properties.chargePerson
1226
+ this.chargePerson = chargePerson
1227
+ // 如果是旧的格式 转换成新的格式
1228
+ if (chargePerson.role || chargePerson.department) {
1229
+ chargePerson.needSelectPerson = true
1230
+ chargePerson.personList = [{
1231
+ type: chargePerson.role ? 'role' : 'department',
1232
+ name: chargePerson.role || chargePerson.department
1233
+ }]
1234
+ }
1235
+
1236
+ if (!chargePerson.needSelectPerson || !chargePerson.personList) return []
1237
+
1238
+ // 获取所有用户信息
1239
+ const allUser = await postByServiceName(commonApi.getAllUserOptionList, {})
1240
+
1241
+ // 使用reduce累积结果
1242
+ const options = chargePerson.personList.reduce((acc, personItem) => {
1243
+ let filteredUsers = []
1244
+
1245
+ if (personItem.type === 'role') {
1246
+ filteredUsers = allUser.filter(user =>
1247
+ user.rolestr && user.rolestr.split(',').includes(personItem.name)
1248
+ ).map(user => ({
1249
+ label: user.label,
1250
+ value: user.value
1251
+ }))
1252
+ } else if (personItem.type === 'department') {
1253
+ filteredUsers = allUser.filter(user =>
1254
+ user.depname === personItem.name
1255
+ ).map(user => ({
1256
+ label: user.label,
1257
+ value: user.value
1258
+ }))
1259
+ }
1260
+
1261
+ return [...acc, ...filteredUsers]
1262
+ }, [])
1263
+
1264
+ // 去重处理
1265
+ return Array.from(new Map(options.map(item => [item.value, item])).values())
1266
+ },
1267
+
1268
+ // 设置多分支人员选择(包含WF_RESULT的情况)
1269
+ async setupMultipleBranchSelection (conditionalActions) {
1270
+ this.branchNodes = []
1271
+ this.branchChargePersons = {}
1272
+
1273
+ for (const action of conditionalActions) {
1274
+ const stepDefine = this.stepsDefine.find(step => step.id === action.to)
1275
+ if (stepDefine?.properties?.chargePerson?.needSelectPerson) {
1276
+ this.chargePerson = stepDefine?.properties?.chargePerson
1277
+ // 获取这个节点的人员选项
1278
+ const chargePersonOptions = await this.getChargePersonOptionsForStep(action.to)
1279
+
1280
+ this.branchNodes.push({
1281
+ stepId: action.to,
1282
+ stepName: this.getStepNameByStepId(action.to),
1283
+ chargePerson: stepDefine.properties.chargePerson,
1284
+ chargePersonOptions: chargePersonOptions
1285
+ })
1286
+
1287
+ // 初始化选择值
1288
+ this.branchChargePersons[action.to] = undefined
1289
+ }
1290
+ }
1291
+
1292
+ // 如果没有需要选择人员的分支,隐藏选择区域
1293
+ this.needSelectPerson = this.branchNodes.length > 0
1294
+ },
1295
+
1296
+ // 处理普通单线流程(没有分支的情况)
1297
+ async handleNormalFlow () {
1298
+ let targetStepId = this.nextBtnTo
1299
+ if (this.operationType === 'skip') {
1300
+ targetStepId = this.stepNextBtnTo
1301
+ }
1302
+
1303
+ const stepDefine = this.stepsDefine.find(step => step.id === targetStepId)
1304
+ const defineProperties = stepDefine.properties
1305
+ this.chargePerson = defineProperties?.chargePerson
1306
+ if (defineProperties.chargePerson?.role || defineProperties.chargePerson?.department) {
1307
+ defineProperties.chargePerson.needSelectPerson = true
1308
+ defineProperties.chargePerson.personList = [{
1309
+ type: defineProperties.chargePerson.role ? 'role' : 'department',
1310
+ name: defineProperties.chargePerson.role || defineProperties.chargePerson.department
1311
+ }]
1312
+ }
1313
+ console.warn('defineProperties', defineProperties)
1314
+
1315
+ if (defineProperties?.chargePerson?.needSelectPerson) {
1316
+ // 获取人员选项并设置
1317
+ this.checkedChargePerson = undefined
1318
+ this.chargePersonOptions = await this.getChargePersonOptionsForStep(targetStepId)
1319
+ // 如果只有一个选项,自动选中
1320
+ if (this.chargePersonOptions.length === 1) {
1321
+ this.checkedChargePerson = this.chargePersonOptions[0].value
1322
+ }
1323
+ this.needSelectPerson = true
1324
+ console.warn('设置人员选择,选项数量:', this.chargePersonOptions.length)
1325
+ } else {
1326
+ this.needSelectPerson = false
1327
+ this.chargePersonOptions = []
1328
+ console.warn('无需选择人员')
1329
+ }
1330
+ },
1331
+ // 表单数据变化处理函数(将通过provide传递给表单组件)
1332
+ async handleFormDataChange (formData) {
1333
+ if (!this.isWfResultBranch) {
1334
+ await this.calculateTargetNodeFromForm()
1335
+ }
1336
+ },
1088
1337
  },
1089
1338
  watch: {}
1090
1339
  }
@@ -1094,23 +1343,29 @@ export default {
1094
1343
  margin-top: 8px;
1095
1344
  margin-bottom: 8px;
1096
1345
  }
1097
- :deep(.ant-result){
1346
+
1347
+ :deep(.ant-result) {
1098
1348
  padding: 0;
1099
1349
  }
1350
+
1100
1351
  .descriptionPreviewItem {
1101
1352
  margin-bottom: 22px;
1353
+
1102
1354
  :deep(.ant-descriptions-view) {
1103
1355
  overflow: visible;
1104
1356
  }
1105
1357
  }
1358
+
1106
1359
  .allWidth {
1107
1360
  :deep(.ant-descriptions-item-content) {
1108
1361
  width: 100%;
1109
1362
  }
1110
1363
  }
1364
+
1111
1365
  .descriptionTitle {
1112
1366
  position: relative;
1113
1367
  padding-left: 12px;
1368
+
1114
1369
  &::before {
1115
1370
  content: '';
1116
1371
  position: absolute;