@cloud-app-dev/vidc 2.3.0 → 3.0.2
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.
- package/.umirc.ts +2 -2
- package/es/Config/interface.d.ts +2 -1
- package/es/DomMove/demo.d.ts +2 -0
- package/es/DomMove/demo.js +16 -0
- package/es/DomMove/index.d.ts +16 -0
- package/es/DomMove/index.js +145 -0
- package/es/DomMove/utils.d.ts +8 -0
- package/es/{Picture/component/MoveContent → DomMove}/utils.js +19 -0
- package/es/Drawer/index.d.ts +2 -2
- package/es/Drawer/interface.d.ts +4 -174
- package/es/ErrorBoundary/index.d.ts +18 -0
- package/es/ErrorBoundary/index.js +79 -0
- package/es/List/DynamicGridList/Demo.js +40 -27
- package/es/List/DynamicGridList/index.d.ts +20 -29
- package/es/List/DynamicGridList/index.js +40 -63
- package/es/List/DynamicList/index.css +15 -0
- package/es/List/DynamicList/index.d.ts +14 -0
- package/es/List/DynamicList/index.js +105 -0
- package/es/List/DynamicList/interface.d.ts +19 -0
- package/es/List/DynamicList/utils.d.ts +4 -0
- package/es/List/DynamicList/utils.js +6 -0
- package/es/List/GridList/Demo.js +27 -4
- package/es/List/GridList/index.css +1 -0
- package/es/List/GridList/index.d.ts +2 -2
- package/es/List/GridList/index.js +8 -12
- package/es/List/GridList/interface.d.ts +1 -1
- package/es/List/VList/index.js +2 -3
- package/es/List/index.css +2 -54
- package/es/List/index.d.ts +6 -7
- package/es/List/index.js +14 -153
- package/es/List/interface.d.ts +3 -61
- package/es/LoaderApp/index.d.ts +1 -1
- package/es/LoaderApp/index.js +27 -46
- package/es/LoaderApp/interface.d.ts +3 -0
- package/es/LoaderApp/loader.d.ts +6 -7
- package/es/LoaderApp/loader.js +20 -30
- package/es/LoaderApp/sandbox.back.d.ts +18 -0
- package/es/LoaderApp/sandbox.back.js +356 -0
- package/es/LoaderApp/sandbox.d.ts +12 -0
- package/es/LoaderApp/sandbox.js +110 -0
- package/es/LoaderApp/utils.d.ts +5 -1
- package/es/LoaderApp/utils.js +98 -2
- package/es/Map/AMap.d.ts +1572 -0
- package/es/Map/BasicMap/AMapInstance.d.ts +15 -0
- package/es/Map/BasicMap/AMapInstance.js +66 -0
- package/es/Map/BasicMap/LeafletInstance.d.ts +15 -0
- package/es/Map/BasicMap/LeafletInstance.js +98 -0
- package/es/Map/BasicMap/index.css +24 -0
- package/es/Map/BasicMap/index.d.ts +9 -0
- package/es/Map/BasicMap/index.js +103 -0
- package/es/Map/ClusterLayer/hook.d.ts +5 -0
- package/es/Map/ClusterLayer/hook.js +144 -0
- package/es/Map/ClusterLayer/index.css +26 -0
- package/es/Map/ClusterLayer/index.d.ts +5 -0
- package/es/Map/ClusterLayer/index.js +31 -0
- package/es/Map/ClusterLayer/props.d.ts +8 -0
- package/es/Map/Config/index.d.ts +7 -0
- package/es/{InitialConfig → Map/Config}/index.js +35 -36
- package/es/Map/Config/utils.d.ts +2 -0
- package/es/{List/DynamicDeviceList → Map/Config}/utils.js +48 -45
- package/es/Map/Context/index.d.ts +11 -0
- package/es/Map/Context/index.js +66 -0
- package/es/Map/FindPio/index.css +7 -0
- package/es/Map/FindPio/index.d.ts +4 -0
- package/es/Map/FindPio/index.js +16 -0
- package/es/{WorkerFlow/Demo.d.ts → Map/InfoWindow/demo.d.ts} +0 -0
- package/es/{List/DynamicDeviceList/Demo.js → Map/InfoWindow/demo.js} +27 -25
- package/es/Map/InfoWindow/index.d.ts +8 -0
- package/es/Map/InfoWindow/index.js +74 -0
- package/es/Map/LevelCenter/DragMarker/index.d.ts +12 -0
- package/es/Map/LevelCenter/DragMarker/index.js +48 -0
- package/es/{List/DeviceList → Map/LevelCenter}/index.css +0 -0
- package/es/Map/LevelCenter/index.d.ts +13 -0
- package/es/Map/LevelCenter/index.js +42 -0
- package/es/Map/LoaderMap/index.d.ts +12 -0
- package/es/Map/LoaderMap/index.js +58 -0
- package/es/Map/ResetTools/index.css +32 -0
- package/es/Map/ResetTools/index.d.ts +9 -0
- package/es/Map/ResetTools/index.js +61 -0
- package/es/Map/SinglePoint/Marker/index.d.ts +7 -0
- package/es/Map/SinglePoint/Marker/index.js +29 -0
- package/es/Map/SinglePoint/icon/Place_icon_OnLine_Hover.svg +15 -0
- package/es/Map/SinglePoint/icon/Place_icon_OnLine_Normal.svg +15 -0
- package/es/Map/SinglePoint/icon/Place_icon_OutLine_Hover.svg +15 -0
- package/es/Map/SinglePoint/icon/Place_icon_OutLine_Normal.svg +15 -0
- package/es/Map/SinglePoint/index.css +29 -0
- package/es/Map/SinglePoint/index.d.ts +7 -0
- package/es/Map/SinglePoint/index.js +32 -0
- package/es/Map/hook/useMapType.d.ts +4 -0
- package/es/Map/hook/useMapType.js +13 -0
- package/es/Map/icon.d.ts +2 -0
- package/es/Map/icon.js +10 -0
- package/es/Map/index.d.ts +23 -0
- package/es/Map/index.js +25 -0
- package/es/Map/interface.d.ts +55 -0
- package/es/Map/points.json +61247 -0
- package/es/{Picture/component/MoveContent → Map/useMarker}/index.css +0 -0
- package/es/Map/useMarker/index.d.ts +11 -0
- package/es/{WorkerFlow/Form/FormAuth.js → Map/useMarker/index.js} +57 -80
- package/es/Map/withMap/index.d.ts +2 -0
- package/es/Map/withMap/index.js +12 -0
- package/es/Modal/index.js +7 -5
- package/es/Picture/component/RectMenu/index.d.ts +1 -1
- package/es/Picture/index.d.ts +1 -1
- package/es/Picture/index.js +2 -2
- package/es/Player/api/index.d.ts +2 -8
- package/es/Player/api/index.js +29 -35
- package/es/Player/contraller_bar/left_bar.js +2 -2
- package/es/Player/contraller_bar/right_bar.d.ts +1 -1
- package/es/Player/contraller_bar/right_bar.js +13 -27
- package/es/Player/demo.js +21 -24
- package/es/Player/event/index.js +5 -1
- package/es/Player/frontend_player.d.ts +2 -3
- package/es/Player/frontend_player.js +35 -52
- package/es/Player/frontend_timeline.d.ts +3 -2
- package/es/Player/frontend_timeline.js +20 -9
- package/es/Player/live_heart.js +45 -12
- package/es/Player/message.js +23 -12
- package/es/Player/player.d.ts +29 -7
- package/es/Player/segment_player.d.ts +1 -1
- package/es/Player/segment_player.js +50 -39
- package/es/Player/segment_timeline.js +14 -13
- package/es/Player/single_player.js +59 -14
- package/es/Player/timeline.js +8 -6
- package/es/Player/util.d.ts +4 -25
- package/es/Player/util.js +47 -55
- package/es/PlayerExt/index.css +2 -2
- package/es/PlayerExt/index.d.ts +3 -1
- package/es/PlayerExt/index.js +19 -5
- package/es/ScreenPlayer/Live.d.ts +5 -0
- package/es/ScreenPlayer/Live.js +109 -0
- package/es/ScreenPlayer/LiveTools.d.ts +15 -0
- package/es/ScreenPlayer/LiveTools.js +95 -0
- package/es/ScreenPlayer/PlayerWithExt.d.ts +22 -0
- package/es/ScreenPlayer/PlayerWithExt.js +156 -0
- package/es/ScreenPlayer/Record.d.ts +5 -0
- package/es/{WorkerFlow/index.js → ScreenPlayer/Record.js} +286 -273
- package/es/ScreenPlayer/RecordTools.d.ts +17 -0
- package/es/ScreenPlayer/RecordTools.js +102 -0
- package/es/ScreenPlayer/SegmentTimeLine.d.ts +10 -0
- package/es/ScreenPlayer/SegmentTimeLine.js +40 -0
- package/es/ScreenPlayer/TimeSlider.d.ts +127 -0
- package/es/ScreenPlayer/TimeSlider.js +530 -0
- package/es/ScreenPlayer/demo.d.ts +2 -0
- package/es/ScreenPlayer/demo.js +25 -0
- package/es/ScreenPlayer/demo2.d.ts +2 -0
- package/es/ScreenPlayer/demo2.js +153 -0
- package/es/ScreenPlayer/index.css +49 -0
- package/es/ScreenPlayer/index.d.ts +5 -0
- package/es/ScreenPlayer/index.js +8 -0
- package/es/ScreenPlayer/interface.d.ts +81 -0
- package/es/ScreenPlayer/useRecordList.d.ts +3 -0
- package/es/{WorkerFlow/Form/UserAndGroupSelect.js → ScreenPlayer/useRecordList.js} +173 -176
- package/es/ScreenPlayer/useVideoFit.d.ts +5 -0
- package/es/ScreenPlayer/useVideoFit.js +46 -0
- package/es/ScreenPlayer/utils.d.ts +25 -0
- package/es/ScreenPlayer/utils.js +84 -0
- package/es/Timeout/index.d.ts +33 -0
- package/es/Timeout/index.js +83 -0
- package/es/Tree/demo.js +9 -12
- package/es/Tree/index.css +55 -29
- package/es/Tree/index.d.ts +20 -19
- package/es/Tree/index.js +70 -185
- package/es/index.d.ts +8 -9
- package/es/index.js +8 -9
- package/es/useInfiniteScroll/index.d.ts +16 -0
- package/es/{useHttp → useInfiniteScroll}/index.js +79 -43
- package/es/useVirtualList/index.d.ts +13 -0
- package/es/useVirtualList/index.js +175 -0
- package/es/withErrorBoundary/index.d.ts +9 -0
- package/es/withErrorBoundary/index.js +45 -0
- package/package.json +18 -21
- package/release-build.sh +44 -0
- package/test.js +48 -0
- package/es/DeviceIcon/icon.d.ts +0 -9
- package/es/DeviceIcon/icon.js +0 -138
- package/es/DeviceIcon/index.css +0 -8
- package/es/DeviceIcon/index.d.ts +0 -14
- package/es/DeviceIcon/index.js +0 -37
- package/es/DeviceSelect/TreeType.d.ts +0 -7
- package/es/DeviceSelect/TreeType.js +0 -36
- package/es/DeviceSelect/demo.d.ts +0 -3
- package/es/DeviceSelect/demo.js +0 -22
- package/es/DeviceSelect/index.css +0 -11
- package/es/DeviceSelect/index.d.ts +0 -13
- package/es/DeviceSelect/index.js +0 -191
- package/es/Dict/cache.d.ts +0 -3
- package/es/Dict/cache.js +0 -21
- package/es/Dict/device.d.ts +0 -28
- package/es/Dict/device.js +0 -117
- package/es/Dict/hook.d.ts +0 -3
- package/es/Dict/hook.js +0 -98
- package/es/Dict/index.d.ts +0 -9
- package/es/Dict/index.js +0 -10
- package/es/Dict/interface.d.ts +0 -16
- package/es/Dict/utils.d.ts +0 -10
- package/es/Dict/utils.js +0 -44
- package/es/InitialConfig/index.d.ts +0 -8
- package/es/InitialConfig/utils.d.ts +0 -20
- package/es/InitialConfig/utils.js +0 -110
- package/es/InitialRequest/index.d.ts +0 -9
- package/es/InitialRequest/index.js +0 -97
- package/es/InitialRequest/utils.d.ts +0 -10
- package/es/InitialRequest/utils.js +0 -116
- package/es/List/CheckExt.d.ts +0 -9
- package/es/List/CheckExt.js +0 -36
- package/es/List/DeviceList/index.d.ts +0 -11
- package/es/List/DeviceList/index.js +0 -50
- package/es/List/DynamicDeviceList/Demo.d.ts +0 -3
- package/es/List/DynamicDeviceList/index.css +0 -39
- package/es/List/DynamicDeviceList/index.d.ts +0 -12
- package/es/List/DynamicDeviceList/index.js +0 -205
- package/es/List/DynamicDeviceList/interface.d.ts +0 -37
- package/es/List/DynamicDeviceList/utils.d.ts +0 -16
- package/es/List/ListExt/index.css +0 -3
- package/es/List/ListExt/index.d.ts +0 -19
- package/es/List/ListExt/index.js +0 -44
- package/es/Picture/component/MoveContent/index.d.ts +0 -39
- package/es/Picture/component/MoveContent/index.js +0 -244
- package/es/Picture/component/MoveContent/utils.d.ts +0 -4
- package/es/Title/index.css +0 -25
- package/es/Title/index.d.ts +0 -12
- package/es/Title/index.js +0 -30
- package/es/Tree/BaseTree/index.css +0 -64
- package/es/Tree/BaseTree/index.d.ts +0 -24
- package/es/Tree/BaseTree/index.js +0 -83
- package/es/UserSelect/demo.d.ts +0 -3
- package/es/UserSelect/demo.js +0 -21
- package/es/UserSelect/index.css +0 -16
- package/es/UserSelect/index.d.ts +0 -18
- package/es/UserSelect/index.js +0 -194
- package/es/WorkerFlow/Demo.js +0 -57
- package/es/WorkerFlow/Form/Approver.d.ts +0 -10
- package/es/WorkerFlow/Form/Approver.js +0 -33
- package/es/WorkerFlow/Form/Condition.d.ts +0 -11
- package/es/WorkerFlow/Form/Condition.js +0 -235
- package/es/WorkerFlow/Form/EmptyUserSet.d.ts +0 -8
- package/es/WorkerFlow/Form/EmptyUserSet.js +0 -137
- package/es/WorkerFlow/Form/FormAuth.d.ts +0 -8
- package/es/WorkerFlow/Form/GroupList.d.ts +0 -12
- package/es/WorkerFlow/Form/GroupList.js +0 -44
- package/es/WorkerFlow/Form/GroupSelect.d.ts +0 -8
- package/es/WorkerFlow/Form/GroupSelect.js +0 -167
- package/es/WorkerFlow/Form/GroupSelectModalContent.d.ts +0 -6
- package/es/WorkerFlow/Form/GroupSelectModalContent.js +0 -177
- package/es/WorkerFlow/Form/Handle.d.ts +0 -10
- package/es/WorkerFlow/Form/Handle.js +0 -33
- package/es/WorkerFlow/Form/LevelGroupSelect.d.ts +0 -12
- package/es/WorkerFlow/Form/LevelGroupSelect.js +0 -208
- package/es/WorkerFlow/Form/Notifier.d.ts +0 -8
- package/es/WorkerFlow/Form/Notifier.js +0 -16
- package/es/WorkerFlow/Form/UserAndGroupSelect.d.ts +0 -8
- package/es/WorkerFlow/Form/UserSelect.d.ts +0 -8
- package/es/WorkerFlow/Form/UserSelect.js +0 -150
- package/es/WorkerFlow/Form/UserSelectModalContent.d.ts +0 -6
- package/es/WorkerFlow/Form/UserSelectModalContent.js +0 -166
- package/es/WorkerFlow/Form/UserSet.d.ts +0 -14
- package/es/WorkerFlow/Form/UserSet.js +0 -308
- package/es/WorkerFlow/Form/UsersHandleType.d.ts +0 -7
- package/es/WorkerFlow/Form/UsersHandleType.js +0 -32
- package/es/WorkerFlow/Form/utils.d.ts +0 -3
- package/es/WorkerFlow/Form/utils.js +0 -47
- package/es/WorkerFlow/Nodes/Add.d.ts +0 -7
- package/es/WorkerFlow/Nodes/Add.js +0 -98
- package/es/WorkerFlow/Nodes/AddOption.d.ts +0 -10
- package/es/WorkerFlow/Nodes/AddOption.js +0 -23
- package/es/WorkerFlow/Nodes/AddOptionList.d.ts +0 -8
- package/es/WorkerFlow/Nodes/AddOptionList.js +0 -46
- package/es/WorkerFlow/Nodes/Approver.d.ts +0 -11
- package/es/WorkerFlow/Nodes/Approver.js +0 -53
- package/es/WorkerFlow/Nodes/Condition.d.ts +0 -10
- package/es/WorkerFlow/Nodes/Condition.js +0 -140
- package/es/WorkerFlow/Nodes/Constants.d.ts +0 -35
- package/es/WorkerFlow/Nodes/Constants.js +0 -150
- package/es/WorkerFlow/Nodes/End.d.ts +0 -7
- package/es/WorkerFlow/Nodes/End.js +0 -16
- package/es/WorkerFlow/Nodes/Handle.d.ts +0 -11
- package/es/WorkerFlow/Nodes/Handle.js +0 -52
- package/es/WorkerFlow/Nodes/Node.d.ts +0 -8
- package/es/WorkerFlow/Nodes/Node.js +0 -26
- package/es/WorkerFlow/Nodes/Notifier.d.ts +0 -11
- package/es/WorkerFlow/Nodes/Notifier.js +0 -52
- package/es/WorkerFlow/Nodes/Render.d.ts +0 -8
- package/es/WorkerFlow/Nodes/Render.js +0 -16
- package/es/WorkerFlow/Nodes/Start.d.ts +0 -12
- package/es/WorkerFlow/Nodes/Start.js +0 -26
- package/es/WorkerFlow/Nodes/TitleElement.d.ts +0 -10
- package/es/WorkerFlow/Nodes/TitleElement.js +0 -127
- package/es/WorkerFlow/Nodes/Wrap.d.ts +0 -13
- package/es/WorkerFlow/Nodes/Wrap.js +0 -35
- package/es/WorkerFlow/OperatorContext.d.ts +0 -4
- package/es/WorkerFlow/OperatorContext.js +0 -3
- package/es/WorkerFlow/Tools.d.ts +0 -8
- package/es/WorkerFlow/Tools.js +0 -78
- package/es/WorkerFlow/XML/CanvasTag.d.ts +0 -3
- package/es/WorkerFlow/XML/CanvasTag.js +0 -142
- package/es/WorkerFlow/XML/EndEvent.d.ts +0 -1
- package/es/WorkerFlow/XML/EndEvent.js +0 -14
- package/es/WorkerFlow/XML/ExclusiveGateway.d.ts +0 -9
- package/es/WorkerFlow/XML/ExclusiveGateway.js +0 -101
- package/es/WorkerFlow/XML/Root.d.ts +0 -1
- package/es/WorkerFlow/XML/Root.js +0 -5
- package/es/WorkerFlow/XML/StartEvent.d.ts +0 -5
- package/es/WorkerFlow/XML/StartEvent.js +0 -28
- package/es/WorkerFlow/XML/UserTask.d.ts +0 -5
- package/es/WorkerFlow/XML/UserTask.js +0 -93
- package/es/WorkerFlow/XML/index.d.ts +0 -4
- package/es/WorkerFlow/XML/index.js +0 -100
- package/es/WorkerFlow/XML/utils.d.ts +0 -6
- package/es/WorkerFlow/XML/utils.js +0 -97
- package/es/WorkerFlow/data.json +0 -83
- package/es/WorkerFlow/index.css +0 -779
- package/es/WorkerFlow/index.d.ts +0 -13
- package/es/WorkerFlow/interface.d.ts +0 -93
- package/es/WorkerFlow/template.d.ts +0 -2
- package/es/WorkerFlow/template.js +0 -17
- package/es/WorkerFlow/utils.d.ts +0 -14
- package/es/WorkerFlow/utils.js +0 -212
- package/es/useHttp/index.d.ts +0 -8
package/es/WorkerFlow/index.d.ts
DELETED
|
@@ -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,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
|
-
};
|
package/es/WorkerFlow/utils.d.ts
DELETED
|
@@ -1,14 +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;
|
|
8
|
-
/**
|
|
9
|
-
* @desc html event once
|
|
10
|
-
* @param dom
|
|
11
|
-
* @param eventName
|
|
12
|
-
* @param fn
|
|
13
|
-
*/
|
|
14
|
-
export declare function once(dom: HTMLElement, eventName: keyof HTMLElementEventMap, fn: (e: Event) => void): void;
|
package/es/WorkerFlow/utils.js
DELETED
|
@@ -1,212 +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
|
-
}
|
|
198
|
-
/**
|
|
199
|
-
* @desc html event once
|
|
200
|
-
* @param dom
|
|
201
|
-
* @param eventName
|
|
202
|
-
* @param fn
|
|
203
|
-
*/
|
|
204
|
-
|
|
205
|
-
export function once(dom, eventName, fn) {
|
|
206
|
-
var cfn = function cfn(e) {
|
|
207
|
-
dom.removeEventListener(eventName, cfn, false);
|
|
208
|
-
fn(e);
|
|
209
|
-
};
|
|
210
|
-
|
|
211
|
-
dom.addEventListener(eventName, cfn, false);
|
|
212
|
-
}
|
package/es/useHttp/index.d.ts
DELETED