@cloud-app-dev/vidc 2.2.0-alpha.7 → 3.0.0

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 (339) hide show
  1. package/.eslintignore +1 -3
  2. package/.eslintrc +3 -0
  3. package/.prettierignore +1 -0
  4. package/.umirc.ts +74 -74
  5. package/es/AppContext/Sync.d.ts +3 -2
  6. package/es/AppContext/Sync.js +11 -2
  7. package/es/AppContext/index.js +63 -9
  8. package/es/AppContext/interface.d.ts +10 -1
  9. package/es/AppContext/static.d.ts +2 -0
  10. package/es/AppContext/static.js +5 -1
  11. package/es/Box/InfoBox/index.css +5 -6
  12. package/es/Box/TwoColumnBox/index.css +17 -24
  13. package/es/Box/TwoColumnBox/index.js +1 -4
  14. package/es/Box/index.css +1 -1
  15. package/es/Config/interface.d.ts +2 -1
  16. package/es/ConfigContext/index.d.ts +1 -1
  17. package/es/DomMove/demo.d.ts +2 -0
  18. package/es/DomMove/demo.js +16 -0
  19. package/es/DomMove/index.d.ts +16 -0
  20. package/es/DomMove/index.js +145 -0
  21. package/es/DomMove/utils.d.ts +8 -0
  22. package/es/{Picture/component/MoveContent → DomMove}/utils.js +19 -0
  23. package/es/Drawer/index.d.ts +2 -2
  24. package/es/Drawer/interface.d.ts +4 -174
  25. package/es/ErrorBoundary/index.d.ts +18 -0
  26. package/es/ErrorBoundary/index.js +84 -0
  27. package/es/List/DynamicGridList/Demo.js +40 -27
  28. package/es/List/DynamicGridList/index.d.ts +19 -18
  29. package/es/List/DynamicGridList/index.js +36 -36
  30. package/es/List/DynamicList/index.css +15 -0
  31. package/es/List/DynamicList/index.d.ts +14 -0
  32. package/es/List/DynamicList/index.js +105 -0
  33. package/es/List/DynamicList/interface.d.ts +19 -0
  34. package/es/List/DynamicList/utils.d.ts +4 -0
  35. package/es/List/DynamicList/utils.js +6 -0
  36. package/es/List/GridList/Demo.js +27 -4
  37. package/es/List/GridList/index.css +1 -0
  38. package/es/List/GridList/index.d.ts +2 -2
  39. package/es/List/GridList/index.js +8 -12
  40. package/es/List/GridList/interface.d.ts +1 -1
  41. package/es/List/VList/index.js +2 -3
  42. package/es/List/index.css +3 -55
  43. package/es/List/index.d.ts +5 -6
  44. package/es/List/index.js +15 -154
  45. package/es/List/interface.d.ts +3 -61
  46. package/es/LoaderApp/index.d.ts +1 -1
  47. package/es/LoaderApp/index.js +27 -46
  48. package/es/LoaderApp/interface.d.ts +3 -0
  49. package/es/LoaderApp/loader.d.ts +6 -7
  50. package/es/LoaderApp/loader.js +20 -30
  51. package/es/LoaderApp/sandbox.back.d.ts +18 -0
  52. package/es/LoaderApp/sandbox.back.js +356 -0
  53. package/es/LoaderApp/sandbox.d.ts +12 -0
  54. package/es/LoaderApp/sandbox.js +110 -0
  55. package/es/LoaderApp/utils.d.ts +5 -1
  56. package/es/LoaderApp/utils.js +98 -2
  57. package/es/Map/AMap.d.ts +1572 -0
  58. package/es/Map/BasicMap/AMapInstance.d.ts +15 -0
  59. package/es/Map/BasicMap/AMapInstance.js +66 -0
  60. package/es/Map/BasicMap/LeafletInstance.d.ts +15 -0
  61. package/es/Map/BasicMap/LeafletInstance.js +98 -0
  62. package/es/Map/BasicMap/index.css +24 -0
  63. package/es/Map/BasicMap/index.d.ts +9 -0
  64. package/es/Map/BasicMap/index.js +108 -0
  65. package/es/Map/ClusterLayer/hook.d.ts +5 -0
  66. package/es/Map/ClusterLayer/hook.js +144 -0
  67. package/es/Map/ClusterLayer/index.css +26 -0
  68. package/es/Map/ClusterLayer/index.d.ts +5 -0
  69. package/es/Map/ClusterLayer/index.js +31 -0
  70. package/es/Map/ClusterLayer/props.d.ts +8 -0
  71. package/es/Map/Config/index.d.ts +7 -0
  72. package/es/{InitialConfig → Map/Config}/index.js +35 -36
  73. package/es/Map/Config/utils.d.ts +2 -0
  74. package/es/{List/DynamicDeviceList → Map/Config}/utils.js +48 -45
  75. package/es/Map/Context/index.d.ts +11 -0
  76. package/es/Map/Context/index.js +66 -0
  77. package/es/Map/FindPio/index.css +7 -0
  78. package/es/Map/FindPio/index.d.ts +4 -0
  79. package/es/Map/FindPio/index.js +16 -0
  80. package/es/{WorkerFlow/Demo.d.ts → Map/InfoWindow/demo.d.ts} +0 -0
  81. package/es/{List/DynamicDeviceList/Demo.js → Map/InfoWindow/demo.js} +27 -25
  82. package/es/Map/InfoWindow/index.d.ts +8 -0
  83. package/es/Map/InfoWindow/index.js +74 -0
  84. package/es/Map/LevelCenter/DragMarker/index.d.ts +12 -0
  85. package/es/Map/LevelCenter/DragMarker/index.js +48 -0
  86. package/es/{List/DeviceList → Map/LevelCenter}/index.css +0 -0
  87. package/es/Map/LevelCenter/index.d.ts +13 -0
  88. package/es/Map/LevelCenter/index.js +42 -0
  89. package/es/Map/LoaderMap/index.d.ts +12 -0
  90. package/es/Map/LoaderMap/index.js +58 -0
  91. package/es/Map/ResetTools/index.css +32 -0
  92. package/es/Map/ResetTools/index.d.ts +9 -0
  93. package/es/Map/ResetTools/index.js +61 -0
  94. package/es/Map/SinglePoint/Marker/index.d.ts +7 -0
  95. package/es/Map/SinglePoint/Marker/index.js +29 -0
  96. package/es/Map/SinglePoint/icon/Place_icon_OnLine_Hover.svg +15 -0
  97. package/es/Map/SinglePoint/icon/Place_icon_OnLine_Normal.svg +15 -0
  98. package/es/Map/SinglePoint/icon/Place_icon_OutLine_Hover.svg +15 -0
  99. package/es/Map/SinglePoint/icon/Place_icon_OutLine_Normal.svg +15 -0
  100. package/es/Map/SinglePoint/index.css +29 -0
  101. package/es/Map/SinglePoint/index.d.ts +7 -0
  102. package/es/Map/SinglePoint/index.js +32 -0
  103. package/es/Map/hook/useMapType.d.ts +4 -0
  104. package/es/Map/hook/useMapType.js +13 -0
  105. package/es/Map/icon.d.ts +2 -0
  106. package/es/Map/icon.js +10 -0
  107. package/es/Map/index.d.ts +23 -0
  108. package/es/Map/index.js +25 -0
  109. package/es/Map/interface.d.ts +55 -0
  110. package/es/Map/points.json +61247 -0
  111. package/es/{Picture/component/MoveContent → Map/useMarker}/index.css +0 -0
  112. package/es/Map/useMarker/index.d.ts +11 -0
  113. package/es/{WorkerFlow/Form/FormAuth.js → Map/useMarker/index.js} +57 -80
  114. package/es/Map/withMap/index.d.ts +2 -0
  115. package/es/Map/withMap/index.js +12 -0
  116. package/es/Modal/index.css +1 -1
  117. package/es/Modal/index.d.ts +7 -7
  118. package/es/Picture/index.d.ts +1 -1
  119. package/es/Picture/index.js +2 -2
  120. package/es/Player/api/index.d.ts +1 -0
  121. package/es/Player/api/index.js +7 -1
  122. package/es/Player/demo.js +13 -21
  123. package/es/Player/event/index.js +5 -1
  124. package/es/Player/frontend_player.d.ts +1 -1
  125. package/es/Player/frontend_player.js +20 -13
  126. package/es/Player/frontend_timeline.d.ts +1 -1
  127. package/es/Player/live_heart.js +45 -12
  128. package/es/Player/message.js +23 -12
  129. package/es/Player/player.d.ts +31 -7
  130. package/es/Player/segment_player.d.ts +1 -1
  131. package/es/Player/segment_player.js +30 -18
  132. package/es/Player/segment_timeline.js +6 -6
  133. package/es/Player/single_player.js +50 -9
  134. package/es/Player/timeline.js +8 -6
  135. package/es/Player/util.d.ts +2 -1
  136. package/es/Player/util.js +4 -1
  137. package/es/PlayerExt/index.css +2 -2
  138. package/es/PlayerExt/index.d.ts +3 -1
  139. package/es/PlayerExt/index.js +19 -5
  140. package/es/ScreenPlayer/Live.d.ts +5 -0
  141. package/es/ScreenPlayer/Live.js +109 -0
  142. package/es/ScreenPlayer/LiveTools.d.ts +15 -0
  143. package/es/ScreenPlayer/LiveTools.js +95 -0
  144. package/es/ScreenPlayer/PlayerWithExt.d.ts +22 -0
  145. package/es/ScreenPlayer/PlayerWithExt.js +169 -0
  146. package/es/ScreenPlayer/Record.d.ts +5 -0
  147. package/es/{WorkerFlow/index.js → ScreenPlayer/Record.js} +290 -273
  148. package/es/ScreenPlayer/RecordTools.d.ts +17 -0
  149. package/es/ScreenPlayer/RecordTools.js +102 -0
  150. package/es/ScreenPlayer/SegmentTimeLine.d.ts +10 -0
  151. package/es/ScreenPlayer/SegmentTimeLine.js +40 -0
  152. package/es/ScreenPlayer/TimeSlider.d.ts +127 -0
  153. package/es/ScreenPlayer/TimeSlider.js +528 -0
  154. package/es/ScreenPlayer/demo.d.ts +2 -0
  155. package/es/ScreenPlayer/demo.js +25 -0
  156. package/es/ScreenPlayer/demo2.d.ts +2 -0
  157. package/es/ScreenPlayer/demo2.js +153 -0
  158. package/es/ScreenPlayer/index.css +50 -0
  159. package/es/ScreenPlayer/index.d.ts +6 -0
  160. package/es/ScreenPlayer/index.js +7 -0
  161. package/es/ScreenPlayer/interface.d.ts +81 -0
  162. package/es/ScreenPlayer/useRecordList.d.ts +3 -0
  163. package/es/{WorkerFlow/Form/UserAndGroupSelect.js → ScreenPlayer/useRecordList.js} +173 -176
  164. package/es/ScreenPlayer/useVideoFit.d.ts +5 -0
  165. package/es/{Tree/BaseTree/demo.js → ScreenPlayer/useVideoFit.js} +30 -55
  166. package/es/ScreenPlayer/utils.d.ts +25 -0
  167. package/es/ScreenPlayer/utils.js +84 -0
  168. package/es/ThemeAntd/index.css +58 -58
  169. package/es/ThemeAntd/style/button.css +1 -1
  170. package/es/ThemeAntd/style/checkbox.css +8 -8
  171. package/es/ThemeAntd/style/input.css +13 -13
  172. package/es/ThemeAntd/style/pagination.css +5 -5
  173. package/es/ThemeAntd/style/picker.css +11 -11
  174. package/es/ThemeAntd/style/popover.css +1 -1
  175. package/es/ThemeAntd/style/radio.css +4 -4
  176. package/es/ThemeAntd/style/scrollbar.css +3 -3
  177. package/es/ThemeAntd/style/select.css +11 -11
  178. package/es/ThemeAntd/style/table.css +1 -1
  179. package/es/Tree/demo.js +9 -12
  180. package/es/Tree/index.css +55 -29
  181. package/es/Tree/index.d.ts +20 -19
  182. package/es/Tree/index.js +70 -185
  183. package/es/index.d.ts +7 -9
  184. package/es/index.js +7 -9
  185. package/es/useInfiniteScroll/index.d.ts +16 -0
  186. package/es/{useHttp → useInfiniteScroll}/index.js +79 -43
  187. package/es/useVirtualList/index.d.ts +13 -0
  188. package/es/useVirtualList/index.js +175 -0
  189. package/es/withErrorBoundary/index.d.ts +8 -0
  190. package/es/withErrorBoundary/index.js +43 -0
  191. package/package.json +19 -21
  192. package/test.js +48 -0
  193. package/es/DeviceIcon/icon.d.ts +0 -9
  194. package/es/DeviceIcon/icon.js +0 -138
  195. package/es/DeviceIcon/index.css +0 -8
  196. package/es/DeviceIcon/index.d.ts +0 -14
  197. package/es/DeviceIcon/index.js +0 -37
  198. package/es/DeviceSelect/TreeType.d.ts +0 -7
  199. package/es/DeviceSelect/TreeType.js +0 -36
  200. package/es/DeviceSelect/demo.d.ts +0 -3
  201. package/es/DeviceSelect/demo.js +0 -22
  202. package/es/DeviceSelect/index.css +0 -11
  203. package/es/DeviceSelect/index.d.ts +0 -13
  204. package/es/DeviceSelect/index.js +0 -191
  205. package/es/Dict/cache.d.ts +0 -3
  206. package/es/Dict/cache.js +0 -21
  207. package/es/Dict/device.d.ts +0 -28
  208. package/es/Dict/device.js +0 -117
  209. package/es/Dict/hook.d.ts +0 -3
  210. package/es/Dict/hook.js +0 -98
  211. package/es/Dict/index.d.ts +0 -9
  212. package/es/Dict/index.js +0 -10
  213. package/es/Dict/interface.d.ts +0 -16
  214. package/es/Dict/utils.d.ts +0 -10
  215. package/es/Dict/utils.js +0 -44
  216. package/es/InitialConfig/index.d.ts +0 -8
  217. package/es/InitialConfig/utils.d.ts +0 -20
  218. package/es/InitialConfig/utils.js +0 -110
  219. package/es/InitialRequest/index.d.ts +0 -9
  220. package/es/InitialRequest/index.js +0 -97
  221. package/es/InitialRequest/utils.d.ts +0 -10
  222. package/es/InitialRequest/utils.js +0 -116
  223. package/es/List/CheckExt.d.ts +0 -9
  224. package/es/List/CheckExt.js +0 -36
  225. package/es/List/DeviceList/index.d.ts +0 -11
  226. package/es/List/DeviceList/index.js +0 -50
  227. package/es/List/DynamicDeviceList/Demo.d.ts +0 -3
  228. package/es/List/DynamicDeviceList/index.css +0 -39
  229. package/es/List/DynamicDeviceList/index.d.ts +0 -12
  230. package/es/List/DynamicDeviceList/index.js +0 -205
  231. package/es/List/DynamicDeviceList/interface.d.ts +0 -37
  232. package/es/List/DynamicDeviceList/utils.d.ts +0 -16
  233. package/es/List/ListExt/index.css +0 -3
  234. package/es/List/ListExt/index.d.ts +0 -19
  235. package/es/List/ListExt/index.js +0 -44
  236. package/es/Picture/component/MoveContent/index.d.ts +0 -39
  237. package/es/Picture/component/MoveContent/index.js +0 -244
  238. package/es/Picture/component/MoveContent/utils.d.ts +0 -4
  239. package/es/Title/index.css +0 -25
  240. package/es/Title/index.d.ts +0 -12
  241. package/es/Title/index.js +0 -30
  242. package/es/Tree/BaseTree/demo.d.ts +0 -3
  243. package/es/Tree/BaseTree/index.css +0 -64
  244. package/es/Tree/BaseTree/index.d.ts +0 -24
  245. package/es/Tree/BaseTree/index.js +0 -83
  246. package/es/UserSelect/demo.d.ts +0 -3
  247. package/es/UserSelect/demo.js +0 -21
  248. package/es/UserSelect/index.css +0 -16
  249. package/es/UserSelect/index.d.ts +0 -18
  250. package/es/UserSelect/index.js +0 -194
  251. package/es/WorkerFlow/Demo.js +0 -57
  252. package/es/WorkerFlow/Form/Approver.d.ts +0 -10
  253. package/es/WorkerFlow/Form/Approver.js +0 -33
  254. package/es/WorkerFlow/Form/Condition.d.ts +0 -11
  255. package/es/WorkerFlow/Form/Condition.js +0 -235
  256. package/es/WorkerFlow/Form/EmptyUserSet.d.ts +0 -8
  257. package/es/WorkerFlow/Form/EmptyUserSet.js +0 -137
  258. package/es/WorkerFlow/Form/FormAuth.d.ts +0 -8
  259. package/es/WorkerFlow/Form/GroupList.d.ts +0 -12
  260. package/es/WorkerFlow/Form/GroupList.js +0 -44
  261. package/es/WorkerFlow/Form/GroupSelect.d.ts +0 -8
  262. package/es/WorkerFlow/Form/GroupSelect.js +0 -167
  263. package/es/WorkerFlow/Form/GroupSelectModalContent.d.ts +0 -6
  264. package/es/WorkerFlow/Form/GroupSelectModalContent.js +0 -177
  265. package/es/WorkerFlow/Form/Handle.d.ts +0 -10
  266. package/es/WorkerFlow/Form/Handle.js +0 -33
  267. package/es/WorkerFlow/Form/LevelGroupSelect.d.ts +0 -12
  268. package/es/WorkerFlow/Form/LevelGroupSelect.js +0 -208
  269. package/es/WorkerFlow/Form/Notifier.d.ts +0 -8
  270. package/es/WorkerFlow/Form/Notifier.js +0 -16
  271. package/es/WorkerFlow/Form/UserAndGroupSelect.d.ts +0 -8
  272. package/es/WorkerFlow/Form/UserSelect.d.ts +0 -8
  273. package/es/WorkerFlow/Form/UserSelect.js +0 -150
  274. package/es/WorkerFlow/Form/UserSelectModalContent.d.ts +0 -6
  275. package/es/WorkerFlow/Form/UserSelectModalContent.js +0 -166
  276. package/es/WorkerFlow/Form/UserSet.d.ts +0 -14
  277. package/es/WorkerFlow/Form/UserSet.js +0 -308
  278. package/es/WorkerFlow/Form/UsersHandleType.d.ts +0 -7
  279. package/es/WorkerFlow/Form/UsersHandleType.js +0 -32
  280. package/es/WorkerFlow/Form/utils.d.ts +0 -3
  281. package/es/WorkerFlow/Form/utils.js +0 -47
  282. package/es/WorkerFlow/Nodes/Add.d.ts +0 -7
  283. package/es/WorkerFlow/Nodes/Add.js +0 -97
  284. package/es/WorkerFlow/Nodes/AddOption.d.ts +0 -10
  285. package/es/WorkerFlow/Nodes/AddOption.js +0 -23
  286. package/es/WorkerFlow/Nodes/AddOptionList.d.ts +0 -8
  287. package/es/WorkerFlow/Nodes/AddOptionList.js +0 -46
  288. package/es/WorkerFlow/Nodes/Approver.d.ts +0 -11
  289. package/es/WorkerFlow/Nodes/Approver.js +0 -53
  290. package/es/WorkerFlow/Nodes/Condition.d.ts +0 -10
  291. package/es/WorkerFlow/Nodes/Condition.js +0 -140
  292. package/es/WorkerFlow/Nodes/Constants.d.ts +0 -35
  293. package/es/WorkerFlow/Nodes/Constants.js +0 -150
  294. package/es/WorkerFlow/Nodes/End.d.ts +0 -7
  295. package/es/WorkerFlow/Nodes/End.js +0 -16
  296. package/es/WorkerFlow/Nodes/Handle.d.ts +0 -11
  297. package/es/WorkerFlow/Nodes/Handle.js +0 -52
  298. package/es/WorkerFlow/Nodes/Node.d.ts +0 -8
  299. package/es/WorkerFlow/Nodes/Node.js +0 -26
  300. package/es/WorkerFlow/Nodes/Notifier.d.ts +0 -11
  301. package/es/WorkerFlow/Nodes/Notifier.js +0 -52
  302. package/es/WorkerFlow/Nodes/Render.d.ts +0 -8
  303. package/es/WorkerFlow/Nodes/Render.js +0 -16
  304. package/es/WorkerFlow/Nodes/Start.d.ts +0 -12
  305. package/es/WorkerFlow/Nodes/Start.js +0 -26
  306. package/es/WorkerFlow/Nodes/TitleElement.d.ts +0 -10
  307. package/es/WorkerFlow/Nodes/TitleElement.js +0 -127
  308. package/es/WorkerFlow/Nodes/Wrap.d.ts +0 -13
  309. package/es/WorkerFlow/Nodes/Wrap.js +0 -35
  310. package/es/WorkerFlow/OperatorContext.d.ts +0 -4
  311. package/es/WorkerFlow/OperatorContext.js +0 -3
  312. package/es/WorkerFlow/Tools.d.ts +0 -8
  313. package/es/WorkerFlow/Tools.js +0 -78
  314. package/es/WorkerFlow/XML/CanvasTag.d.ts +0 -3
  315. package/es/WorkerFlow/XML/CanvasTag.js +0 -142
  316. package/es/WorkerFlow/XML/EndEvent.d.ts +0 -1
  317. package/es/WorkerFlow/XML/EndEvent.js +0 -14
  318. package/es/WorkerFlow/XML/ExclusiveGateway.d.ts +0 -9
  319. package/es/WorkerFlow/XML/ExclusiveGateway.js +0 -101
  320. package/es/WorkerFlow/XML/Root.d.ts +0 -1
  321. package/es/WorkerFlow/XML/Root.js +0 -5
  322. package/es/WorkerFlow/XML/StartEvent.d.ts +0 -5
  323. package/es/WorkerFlow/XML/StartEvent.js +0 -28
  324. package/es/WorkerFlow/XML/UserTask.d.ts +0 -5
  325. package/es/WorkerFlow/XML/UserTask.js +0 -93
  326. package/es/WorkerFlow/XML/index.d.ts +0 -4
  327. package/es/WorkerFlow/XML/index.js +0 -100
  328. package/es/WorkerFlow/XML/utils.d.ts +0 -6
  329. package/es/WorkerFlow/XML/utils.js +0 -97
  330. package/es/WorkerFlow/data.json +0 -83
  331. package/es/WorkerFlow/index.css +0 -779
  332. package/es/WorkerFlow/index.d.ts +0 -13
  333. package/es/WorkerFlow/interface.d.ts +0 -93
  334. package/es/WorkerFlow/template.d.ts +0 -2
  335. package/es/WorkerFlow/template.js +0 -17
  336. package/es/WorkerFlow/utils.d.ts +0 -7
  337. package/es/WorkerFlow/utils.js +0 -197
  338. package/es/useHttp/index.d.ts +0 -8
  339. package/pnpm-lock.yaml +0 -13650
@@ -1,13 +0,0 @@
1
- import React from 'react';
2
- import { WorkerFlowRequest, WorkerFlowFormType, SubmitData } from './interface';
3
- import './index.less';
4
- interface IWorkFlowProps {
5
- data?: WorkerFlowRequest;
6
- form?: WorkerFlowFormType[];
7
- errorIds?: string[];
8
- onChange?: (data: SubmitData) => void;
9
- readOnly?: boolean;
10
- hasTools?: boolean;
11
- }
12
- declare const _default: React.ForwardRefExoticComponent<IWorkFlowProps & React.RefAttributes<any>>;
13
- export default _default;
@@ -1,93 +0,0 @@
1
- export type NodeType = 0 | 1 | 2 | 3 | 4 | 5 | 9; //0开始,1审核,2抄送,3条件判断,4路由,5办理人,9结束
2
- export type UserSetType = 1 | 2 | 3 | 4 | 5; //1,指定人员;2,自选人员;3,岗位;4,直属主管;5,连续多级主管;
3
- export type MutipleUserHandleType = 1 | 2; //1,会签,2,或签
4
- export type NodeTypeKey = 'APPROVER' | 'NOTIFIER' | 'BRANCH' | 'CONDITION' | 'HANDLE';
5
- export type BpmnTypeKey = 'startEvent' | 'endEvent' | 'exclusiveGateway' | 'userTask' | 'sequenceFlow';
6
- export type FormAuthType = 0 | 1 | 2; //0隐藏;1,可以编辑;2,可阅读
7
-
8
- export type NodeUserType = {
9
- name: string; //用户名或者岗位名称
10
- key: 'userId' | 'groupId'; //用户id 或者 岗位id
11
- value: string; //id
12
- groupName?: string;
13
- };
14
-
15
- export type WorkerFlowFormType = {
16
- name: string;
17
- label: string;
18
- widgetType: 'SINGLE_TEXT' | 'MULTIPLE_TEXT' | 'SINGLE_SELECTION' | 'MULTIPLE_SELECTION' | 'IMAGE';
19
- type: string;
20
- value: string;
21
- auth?: FormAuthType;
22
- required: boolean;
23
- options?: { value: string | number | boolean; label: string }[];
24
- };
25
-
26
- export type ConditionItemType = { field: string; value: any };
27
-
28
- export type NodeItem = {
29
- id: string; // ID按规则生成;
30
- nodeName: string; //节点名称
31
- nodeUserList?: NodeUserType[]; //审核用户,userTask类型存在切必选
32
- emptyUserList?: NodeUserType[]; //节点 审核人员为空时
33
- copyUserIds?: string[]; //下一个节点需要抄送的用户id
34
- childNode?: NodeItem; //下一个链接元素
35
- chargeLevel?: 1 | 2 | 3; //连线多级主管上溯级别
36
- conditionNodes?: NodeItem[]; //条件判断集合,路由节点存在
37
- type: NodeType; // 自定义类型
38
- userType?: UserSetType; //人员设置类型
39
- usersHandType?: MutipleUserHandleType; //多人时处理类型,会签 or 或签
40
- conditionList?: ConditionItemType[]; //条件对象
41
- vNode?: NodeItem; //虚拟条件对象,自动生成,用于同意和进入下一个节点,取消结束流程
42
- expression?: string; //条件判断模板
43
- priorityLevel?: number; // 条件优先级
44
- owner?: string; // 显示审核人员文本
45
- error?: boolean; // 节点是否出错
46
- bpmnType: BpmnTypeKey; // 对于bpmn类型
47
- form?: WorkerFlowFormType[];
48
- };
49
-
50
- export interface WorkerFlowContext {
51
- config: NodeItem;
52
- errorIds?: string[];
53
- form: WorkerFlowFormType[];
54
- onInsertNode: (type: NodeType, node: NodeItem) => void;
55
- onDeleteNode: (parentNode: NodeItem, node: NodeItem, type?: NodeType, index?: number) => void;
56
- onSelectNode: (node: NodeItem, parentNode: NodeItem, index?: number) => void;
57
- updateNode: () => void;
58
- readOnly?: boolean;
59
- }
60
-
61
- export interface WorkerFlowRequest {
62
- id: string;
63
- name: string;
64
- nodeConfig: NodeItem;
65
- }
66
-
67
- export type SubmitFlowItemType = {
68
- processId: string;
69
- actNodeId: string;
70
- taskType: 0 | 1; //任务类型,0,办理人;1,审批人;
71
- jointlySignBlank?: 1; //会签标识
72
- multiVariableName?: string; //会签选定人员的变量名称(同一部署文件,id要求唯一)
73
- actNodeName: string; //用户任务节点名称
74
- assignType: number; // 任务执行人选定方式,1,直接执行人;2,自选;3,岗位;4.直属主管;5.连续多级主管
75
- assignVariableName: string; //任务执行人的变量名称(同一部署文件,id要求唯一)
76
- chargeLevel: 1 | 2 | 3; //连续多级主管上溯级别
77
- stationIds?: string[]; //直接选择的/自选的岗位Id
78
- nextTaskId?: string; //下一个任务节点Id,条件不算
79
- formAuthority?: string; //表单权限等扩展信息
80
- copyUserIds?: string[]; //下个节点存在抄送人饿
81
- emptyPersonIds?: string[]; //没有审批人时,任务交给指定人员处理
82
- assignPersonIds?: string[]; //直接执行/自选的人员Ids
83
- taskFirstBlank?: 1; //首用户任务标志,1,首任务;
84
- };
85
-
86
- export type SubmitData = {
87
- config: WorkerFlowRequest;
88
- bpmnBlob: Blob;
89
- useFormKeys: ConditionItemType[];
90
- taskList: SubmitFlowItemType[];
91
- };
92
-
93
- export type AddNodeType = 1 | 2 | 3 | 4; //1审核人,2抄送人,3办理人,4条件分支
@@ -1,2 +0,0 @@
1
- import { NodeItem } from './interface';
2
- export declare const TemplateConfig1: NodeItem;
@@ -1,17 +0,0 @@
1
- import { createId } from './XML/utils';
2
- var startId = createId('StartEvent');
3
- var endId = createId('EndEvent');
4
- export var TemplateConfig1 = {
5
- id: startId,
6
- nodeName: '发起人',
7
- type: 0,
8
- bpmnType: 'startEvent',
9
- owner: '系统发起',
10
- nodeUserList: [],
11
- childNode: {
12
- id: endId,
13
- nodeName: '流程结束',
14
- bpmnType: 'endEvent',
15
- type: 9
16
- }
17
- };
@@ -1,7 +0,0 @@
1
- import { ConditionItemType, NodeItem, SubmitFlowItemType } from './interface';
2
- export declare function getJAVATaskData(data: NodeItem): SubmitFlowItemType[];
3
- export declare function getNextTaskId(node: NodeItem): string | undefined;
4
- export declare function getNextNode(node: NodeItem): NodeItem | undefined;
5
- export declare function filterNoticeNode(data: NodeItem): NodeItem;
6
- export declare function getUserFormKeys(data: NodeItem): ConditionItemType[];
7
- export declare function getFirstUserTask(data: NodeItem): NodeItem | undefined;
@@ -1,197 +0,0 @@
1
- function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
2
-
3
- function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
4
-
5
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
6
-
7
- function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
8
-
9
- function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
10
-
11
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
12
-
13
- import { cloneDeep } from 'lodash-es';
14
- import { getNodeById } from './XML/utils';
15
- export function getJAVATaskData(data) {
16
- var _a;
17
-
18
- var arr = [];
19
-
20
- var fn = function fn(node, _nextNode) {
21
- var _a, _b, _c, _d;
22
-
23
- if (node.bpmnType === 'userTask') {
24
- var item = {
25
- actNodeId: node.id,
26
- actNodeName: node.nodeName,
27
- assignType: node.userType,
28
- assignVariableName: "users_".concat(node.id),
29
- emptyPersonIds: ((_a = node.emptyUserList) === null || _a === void 0 ? void 0 : _a.map(function (v) {
30
- return v.value;
31
- })) || [],
32
- taskType: node.type === 5 ? 0 : 1
33
- };
34
-
35
- if (node.userType === 1 || node.userType === 2 || node.userType === 3 || node.userType === 5) {
36
- item.assignPersonIds = node.nodeUserList.filter(function (v) {
37
- return v.key === 'userId';
38
- }).map(function (v) {
39
- return v.value;
40
- });
41
- item.stationIds = node.nodeUserList.filter(function (v) {
42
- return v.key === 'groupId';
43
- }).map(function (v) {
44
- return v.value;
45
- });
46
- }
47
-
48
- if (node.userType === 5) {
49
- item.chargeLevel = node.chargeLevel;
50
- }
51
-
52
- if (node.usersHandType === 1) {
53
- item.jointlySignBlank = 1;
54
- item.multiVariableName = "assigneeList_".concat(node.id);
55
- }
56
-
57
- if (((_b = node.childNode) === null || _b === void 0 ? void 0 : _b.bpmnType) === 'userTask') {
58
- item.nextTaskId = getNextTaskId(node.childNode);
59
- } // 连接条件nextTaskId
60
-
61
-
62
- if (!node.childNode) {
63
- item.nextTaskId = _nextNode === null || _nextNode === void 0 ? void 0 : _nextNode.id;
64
- }
65
-
66
- if (node.form) {
67
- item.formAuthority = JSON.stringify((_c = node.form) === null || _c === void 0 ? void 0 : _c.map(function (v) {
68
- return {
69
- formAuth: v.auth,
70
- formVariableName: v.name
71
- };
72
- }));
73
- }
74
-
75
- if (((_d = node.childNode) === null || _d === void 0 ? void 0 : _d.type) === 2) {
76
- item.copyUserIds = node.childNode.nodeUserList.map(function (v) {
77
- return v.value;
78
- });
79
- }
80
-
81
- arr.push(item);
82
- } // 检查最后一个nextTaskId
83
-
84
-
85
- var nextNode = getNextNode(node.childNode);
86
-
87
- if (node.conditionNodes) {
88
- node.conditionNodes.forEach(function (item) {
89
- fn(item, nextNode);
90
- });
91
- }
92
-
93
- if (nextNode) {
94
- fn(nextNode, _nextNode);
95
- }
96
- };
97
-
98
- fn(data);
99
-
100
- if (arr[0]) {
101
- arr[0].taskFirstBlank = 1;
102
- } // 修正最后一个节点的nextid
103
-
104
-
105
- var lastNextId = (_a = arr[arr.length - 1]) === null || _a === void 0 ? void 0 : _a.nextTaskId;
106
-
107
- if (lastNextId) {
108
- var lastNode = getNodeById(data, lastNextId);
109
-
110
- if (lastNode.type === 2 || lastNode.bpmnType === 'endEvent') {
111
- arr[arr.length - 1].nextTaskId = undefined;
112
- }
113
- }
114
-
115
- return arr;
116
- }
117
- export function getNextTaskId(node) {
118
- if (!node) {
119
- return undefined;
120
- }
121
-
122
- if (node.type !== 2) {
123
- return node.id;
124
- } else {
125
- return getNextTaskId(node.childNode);
126
- }
127
- }
128
- export function getNextNode(node) {
129
- if (!node) {
130
- return undefined;
131
- }
132
-
133
- if (node.type !== 2) {
134
- return node;
135
- } else {
136
- return getNextNode(node.childNode);
137
- }
138
- }
139
- export function filterNoticeNode(data) {
140
- var newData = cloneDeep(data);
141
-
142
- var fn = function fn(node) {
143
- var _a; // 过滤抄送节点
144
-
145
-
146
- if (((_a = node.childNode) === null || _a === void 0 ? void 0 : _a.type) === 2) {
147
- node.copyUserIds = node.childNode.nodeUserList.map(function (v) {
148
- return v.value;
149
- });
150
- node.childNode = node.childNode.childNode;
151
- }
152
-
153
- if (node.conditionNodes) {
154
- node.conditionNodes.forEach(function (item) {
155
- fn(item);
156
- });
157
- }
158
-
159
- if (node.childNode) {
160
- fn(node.childNode);
161
- }
162
- };
163
-
164
- fn(newData);
165
- return newData;
166
- }
167
- export function getUserFormKeys(data) {
168
- var arr = [];
169
-
170
- var fn = function fn(node) {
171
- if (node.bpmnType == 'sequenceFlow' && node.conditionList) {
172
- arr.push.apply(arr, _toConsumableArray(node.conditionList));
173
- }
174
-
175
- if (node.conditionNodes) {
176
- node.conditionNodes.forEach(function (item) {
177
- fn(item);
178
- });
179
- }
180
-
181
- if (node.childNode) {
182
- fn(node.childNode);
183
- }
184
- };
185
-
186
- fn(data);
187
- return arr.filter(function (v) {
188
- return !!v;
189
- });
190
- }
191
- export function getFirstUserTask(data) {
192
- if (data.bpmnType === 'startEvent') {
193
- return data.childNode;
194
- }
195
-
196
- return undefined;
197
- }
@@ -1,8 +0,0 @@
1
- export interface IHttpHookPromiseResult<T> {
2
- update: () => void;
3
- data: T;
4
- error: any;
5
- loadding: boolean;
6
- }
7
- declare function useHttp<T, K>(key: T, fetcher: (key: T) => Promise<any>): IHttpHookPromiseResult<K>;
8
- export default useHttp;