cnhis-design-vue 3.1.53-beta.2 → 3.1.53-hotfix.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.
- package/README.md +87 -87
- package/es/components/annotation-edit/src/AnnotationEdit.js +1 -1
- package/es/components/big-table/src/components/edit-form/edit-separate.vue.d.ts +4 -4
- package/es/components/big-table/src/hooks/useEdit.d.ts +4 -4
- package/es/components/big-table/src/hooks/useSeparateRow.d.ts +4 -4
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
- package/es/components/button-print/src/ButtonPrint.vue.d.ts +1 -3
- package/es/components/button-print/src/utils/dialog.d.ts +2 -2
- package/es/components/button-print/src/utils/print.d.ts +13 -14
- package/es/components/button-print/src/utils/print.js +1 -1
- package/es/components/callback/src/components/render/popupMaps.d.ts +5 -44
- package/es/components/card-reader-sdk/src/cardReaderSDK.js +1 -1
- package/es/components/card-reader-sdk/src/types/index.d.ts +3 -3
- package/es/components/date-picker/src/DatePicker.vue2.js +1 -1
- package/es/components/expand-field/src/components/form.vue2.js +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useLeft.js +1 -1
- package/es/components/form-config/index.d.ts +24 -24
- package/es/components/form-config/src/FormConfig.vue.d.ts +25 -25
- package/es/components/form-config/src/FormConfig.vue2.js +1 -1
- package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +5 -5
- package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +11 -11
- package/es/components/form-config/src/components/FormConfigEventSetting.vue2.js +1 -1
- package/es/components/form-render/index.d.ts +5 -5
- package/es/components/form-render/index.js +1 -1
- package/es/components/form-render/src/FormRender.vue.d.ts +6 -6
- package/es/components/form-render/src/FormRender.vue2.js +1 -1
- package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +6 -6
- package/es/components/form-render/src/components/renderer/index.js +1 -1
- package/es/components/form-render/src/components/renderer/inputNumber.d.ts +5 -5
- package/es/components/form-render/src/components/renderer/{levelSearchCascader/index.d.ts → levelSearchCascader.d.ts} +5 -3
- package/es/components/form-render/src/components/renderer/levelSearchCascader.js +1 -0
- package/es/components/form-render/src/components/renderer/searchCascade.d.ts +3 -3
- package/es/components/form-render/src/components/renderer/select.d.ts +3 -3
- package/es/components/form-render/src/components/renderer/select.js +1 -1
- package/es/components/form-render/src/constants/index.d.ts +2 -3
- package/es/components/form-render/src/hooks/index.d.ts +2 -0
- package/es/components/form-render/src/hooks/index.js +1 -1
- package/es/components/form-render/src/hooks/useAnchor.d.ts +3 -3
- package/es/components/form-render/src/hooks/useCommonInjection.d.ts +2 -2
- package/es/components/form-render/src/hooks/useFieldNormalize.d.ts +2 -2
- package/es/components/form-render/src/hooks/useFormAsyncQueue.d.ts +16 -0
- package/es/components/form-render/src/hooks/useFormAsyncQueue.js +1 -0
- package/es/components/form-render/src/hooks/useFormContext.d.ts +3 -3
- package/es/components/form-render/src/hooks/useFormContext.js +1 -1
- package/es/components/form-render/src/hooks/useFormItemDeps.d.ts +3 -3
- package/es/components/form-render/src/hooks/useFormRenderOptions.d.ts +4 -5
- package/es/components/form-render/src/hooks/useFormRenderOptions.js +1 -1
- package/es/components/form-render/src/hooks/useFormRequest.d.ts +26 -0
- package/es/components/form-render/src/hooks/useFormRequest.js +1 -0
- package/es/components/form-render/src/types/fieldItem.d.ts +26 -4
- package/es/components/form-render/src/types/index.d.ts +13 -2
- package/es/components/form-render/src/utils/index.d.ts +2 -1
- package/es/components/form-render/src/utils/index.js +1 -1
- package/es/components/form-render/src/utils/schema.d.ts +2 -2
- package/es/components/guide/src/renderer.js +1 -1
- package/es/components/iho-table/index.d.ts +0 -39
- package/es/components/iho-table/src/IhoTable.vue.d.ts +0 -40
- package/es/components/iho-table/src/IhoTable.vue2.js +1 -1
- package/es/components/iho-table/src/constants/index.d.ts +1 -4
- package/es/components/iho-table/src/constants/index.js +1 -1
- package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.d.ts +2 -2
- package/es/components/iho-table/src/hooks/tapHooks/useExposeHooks.d.ts +2 -2
- package/es/components/iho-table/src/plugins/defaultValuePlugin.js +1 -1
- package/es/components/iho-table/src/plugins/index.js +1 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.d.ts +2 -2
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/hooks/useAutoFocus.js +1 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/index.js +1 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue.d.ts +2 -2
- package/es/components/iho-table/src/types/index.d.ts +2 -7
- package/es/components/iho-table/src/types/pluginType.d.ts +3 -3
- package/es/components/iho-table/style/index.css +1 -1
- package/es/components/index.css +1 -1
- package/es/components/index.d.ts +0 -1
- package/es/components/index.js +1 -1
- package/es/components/info-header/index.d.ts +27 -27
- package/es/components/info-header/src/InfoHeader.vue.d.ts +28 -28
- package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue.d.ts +5 -5
- package/es/components/info-header/src/components/infoDescription/DescriptionList.vue.d.ts +6 -6
- package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +12 -12
- package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +5 -5
- package/es/components/keyboard/src/Keyboard.vue2.js +1 -1
- package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
- package/es/components/search-cascader/index.d.ts +3 -23
- package/es/components/search-cascader/src/SearchCascader.vue.d.ts +4 -24
- package/es/components/search-cascader/src/SearchCascader.vue2.js +1 -1
- package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
- package/es/components/select-person/src/SearchMultiple.vue.d.ts +0 -6
- package/es/components/shortcut-setter/index.d.ts +8 -8
- package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +9 -9
- package/es/components/steps-wheel/src/StepsWheel.vue2.js +1 -1
- package/es/components/table-export-field/src/components/ExportModal.vue.d.ts +3 -0
- package/es/components/time-picker/src/TimePicker.vue2.js +1 -1
- package/es/env.d.ts +25 -25
- package/es/shared/assets/img/failure.png.js +1 -1
- package/es/shared/assets/img/no-permission.png.js +1 -1
- package/es/shared/assets/img/nodata.png.js +1 -1
- package/es/shared/assets/img/notfound.png.js +1 -1
- package/es/shared/assets/img/qr.png.js +1 -1
- package/es/shared/assets/img/success.png.js +1 -1
- package/es/shared/assets/img/video.png.js +1 -1
- package/es/shared/assets/img/video_default_cover.png.js +1 -1
- package/es/shared/assets/img/xb_big.png.js +1 -1
- package/es/shared/assets/img/xb_small.png.js +1 -1
- package/es/shared/components/InputNumberSlash/InputNumberSlash.d.ts +4 -4
- package/es/shared/components/SlotRender/SlotRender.d.ts +5 -5
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
- package/es/shared/hooks/index.d.ts +0 -2
- package/es/shared/hooks/index.js +1 -1
- package/es/shared/hooks/{useAsyncQueue/index.d.ts → useAsyncQueue.d.ts} +15 -7
- package/es/shared/hooks/useAsyncQueue.js +1 -0
- package/es/shared/hooks/useDateTime.d.ts +2 -2
- package/es/shared/package.json.js +1 -1
- package/es/shared/types/business.d.ts +0 -24
- package/es/shared/types/index.d.ts +1 -1
- package/es/shared/utils/fabricjs/index.d.ts +6823 -0
- package/es/shared/utils/tapable/index.d.ts +139 -0
- package/package.json +2 -2
- package/es/components/form-render/src/components/renderer/levelSearchCascader/index.js +0 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.d.ts +0 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.js +0 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/levelSearchCascadePlugin/levelSearchCascade.vue.d.ts +0 -552
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/levelSearchCascadePlugin/levelSearchCascade.vue.js +0 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/levelSearchCascadePlugin/levelSearchCascade.vue2.js +0 -1
- package/es/components/iho-table/src/plugins/wordbookSettingPlugin.d.ts +0 -1
- package/es/components/iho-table/src/plugins/wordbookSettingPlugin.js +0 -1
- package/es/components/search-cascader/src/components/ClearIcon.vue.js +0 -1
- package/es/shared/hooks/useAsyncQueue/index.js +0 -1
- package/es/shared/hooks/useAsyncQueue/types.d.ts +0 -20
- package/es/shared/hooks/useAsyncQueue/types.js +0 -1
- package/es/shared/hooks/useFormRequest/index.d.ts +0 -24
- package/es/shared/hooks/useFormRequest/index.js +0 -1
- package/es/shared/hooks/useFormRequest/types.d.ts +0 -39
- package/es/shared/hooks/useFormRequest/types.js +0 -1
- package/es/shared/hooks/useLevelSearchCascader.d.ts +0 -31
- package/es/shared/hooks/useLevelSearchCascader.js +0 -1
|
@@ -1,552 +0,0 @@
|
|
|
1
|
-
import { AnyObject } from '../../../../../../../../es/shared/types';
|
|
2
|
-
import { PropType } from 'vue';
|
|
3
|
-
declare const _default: import("vue").DefineComponent<{
|
|
4
|
-
options: {
|
|
5
|
-
type: PropType<AnyObject[]>;
|
|
6
|
-
default: () => never[];
|
|
7
|
-
};
|
|
8
|
-
labelField: {
|
|
9
|
-
type: StringConstructor;
|
|
10
|
-
default: string;
|
|
11
|
-
};
|
|
12
|
-
valueField: {
|
|
13
|
-
type: StringConstructor;
|
|
14
|
-
default: string;
|
|
15
|
-
};
|
|
16
|
-
autograph: {
|
|
17
|
-
type: StringConstructor;
|
|
18
|
-
required: true;
|
|
19
|
-
};
|
|
20
|
-
lazyRequest: {
|
|
21
|
-
type: BooleanConstructor;
|
|
22
|
-
default: boolean;
|
|
23
|
-
};
|
|
24
|
-
requestCache: {
|
|
25
|
-
type: BooleanConstructor;
|
|
26
|
-
default: boolean;
|
|
27
|
-
};
|
|
28
|
-
wordbook: {
|
|
29
|
-
type: PropType<Partial<{
|
|
30
|
-
level_num: number;
|
|
31
|
-
id: string;
|
|
32
|
-
name: string;
|
|
33
|
-
render_key: string[];
|
|
34
|
-
search_key: string[];
|
|
35
|
-
value_key: string;
|
|
36
|
-
queryParams: string[];
|
|
37
|
-
primary_key: string;
|
|
38
|
-
type: string;
|
|
39
|
-
level_key: string;
|
|
40
|
-
link_key: string;
|
|
41
|
-
link_key_split: string;
|
|
42
|
-
show_key: string | string[];
|
|
43
|
-
conObj: AnyObject[];
|
|
44
|
-
conObjFirstLevel: AnyObject[];
|
|
45
|
-
setting: Partial<{
|
|
46
|
-
cascading: {
|
|
47
|
-
'form.name': string;
|
|
48
|
-
value: string;
|
|
49
|
-
}[];
|
|
50
|
-
}>;
|
|
51
|
-
}>>;
|
|
52
|
-
required: true;
|
|
53
|
-
};
|
|
54
|
-
value: {
|
|
55
|
-
type: PropType<string | AnyObject[]>;
|
|
56
|
-
};
|
|
57
|
-
fieldKey: {
|
|
58
|
-
type: StringConstructor;
|
|
59
|
-
required: true;
|
|
60
|
-
};
|
|
61
|
-
payload: {
|
|
62
|
-
type: PropType<AnyObject>;
|
|
63
|
-
required: true;
|
|
64
|
-
};
|
|
65
|
-
}, {
|
|
66
|
-
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
67
|
-
options: {
|
|
68
|
-
type: PropType<AnyObject[]>;
|
|
69
|
-
default: () => never[];
|
|
70
|
-
};
|
|
71
|
-
labelField: {
|
|
72
|
-
type: StringConstructor;
|
|
73
|
-
default: string;
|
|
74
|
-
};
|
|
75
|
-
valueField: {
|
|
76
|
-
type: StringConstructor;
|
|
77
|
-
default: string;
|
|
78
|
-
};
|
|
79
|
-
autograph: {
|
|
80
|
-
type: StringConstructor;
|
|
81
|
-
required: true;
|
|
82
|
-
};
|
|
83
|
-
lazyRequest: {
|
|
84
|
-
type: BooleanConstructor;
|
|
85
|
-
default: boolean;
|
|
86
|
-
};
|
|
87
|
-
requestCache: {
|
|
88
|
-
type: BooleanConstructor;
|
|
89
|
-
default: boolean;
|
|
90
|
-
};
|
|
91
|
-
wordbook: {
|
|
92
|
-
type: PropType<Partial<{
|
|
93
|
-
level_num: number;
|
|
94
|
-
id: string;
|
|
95
|
-
name: string;
|
|
96
|
-
render_key: string[];
|
|
97
|
-
search_key: string[];
|
|
98
|
-
value_key: string;
|
|
99
|
-
queryParams: string[];
|
|
100
|
-
primary_key: string;
|
|
101
|
-
type: string;
|
|
102
|
-
level_key: string;
|
|
103
|
-
link_key: string;
|
|
104
|
-
link_key_split: string;
|
|
105
|
-
show_key: string | string[];
|
|
106
|
-
conObj: AnyObject[];
|
|
107
|
-
conObjFirstLevel: AnyObject[];
|
|
108
|
-
setting: Partial<{
|
|
109
|
-
cascading: {
|
|
110
|
-
'form.name': string;
|
|
111
|
-
value: string;
|
|
112
|
-
}[];
|
|
113
|
-
}>;
|
|
114
|
-
}>>;
|
|
115
|
-
required: true;
|
|
116
|
-
};
|
|
117
|
-
value: {
|
|
118
|
-
type: PropType<string | AnyObject[]>;
|
|
119
|
-
};
|
|
120
|
-
fieldKey: {
|
|
121
|
-
type: StringConstructor;
|
|
122
|
-
required: true;
|
|
123
|
-
};
|
|
124
|
-
payload: {
|
|
125
|
-
type: PropType<AnyObject>;
|
|
126
|
-
required: true;
|
|
127
|
-
};
|
|
128
|
-
}>> & {
|
|
129
|
-
onClick?: ((...args: any[]) => any) | undefined;
|
|
130
|
-
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
131
|
-
}>>;
|
|
132
|
-
emit: (event: "click" | "update:value", ...args: any[]) => void;
|
|
133
|
-
asyncQueue: import("../../../../../../../../es/shared/hooks").FormRequestDefine.FormAsyncQueue;
|
|
134
|
-
valueKey: import("vue").ComputedRef<string>;
|
|
135
|
-
valueRef: import("vue").WritableComputedRef<string | AnyObject[] | undefined>;
|
|
136
|
-
labelKey: import("vue").ComputedRef<string>;
|
|
137
|
-
optionsRef: import("vue").Ref<AnyObject[]>;
|
|
138
|
-
showRef: import("vue").Ref<boolean>;
|
|
139
|
-
fetchData: (node?: AnyObject | undefined, keyword?: string | undefined, updateValueWhenNoChild?: boolean) => Promise<void | AnyObject>;
|
|
140
|
-
menuWidth: import("vue").Ref<number>;
|
|
141
|
-
searchCascaderRef: import("vue").Ref<{
|
|
142
|
-
getWidth: () => number;
|
|
143
|
-
setCursor: (option?: AnyObject | undefined) => void;
|
|
144
|
-
} | undefined>;
|
|
145
|
-
onFocus: () => void;
|
|
146
|
-
onClick: (event: MouseEvent) => void;
|
|
147
|
-
NoData: import("vue").DefineComponent<{
|
|
148
|
-
noDataTip: {
|
|
149
|
-
type: StringConstructor;
|
|
150
|
-
default: string;
|
|
151
|
-
};
|
|
152
|
-
noDataImg: {
|
|
153
|
-
type: StringConstructor;
|
|
154
|
-
default: string;
|
|
155
|
-
};
|
|
156
|
-
showImg: {
|
|
157
|
-
type: BooleanConstructor;
|
|
158
|
-
default: boolean;
|
|
159
|
-
};
|
|
160
|
-
}, {
|
|
161
|
-
wrapperStyle: import("vue").CSSProperties;
|
|
162
|
-
imgStyle: import("vue").CSSProperties;
|
|
163
|
-
paragraphStyle: import("vue").CSSProperties;
|
|
164
|
-
textStyle: import("vue").CSSProperties;
|
|
165
|
-
imgStr: import("vue").ComputedRef<null>;
|
|
166
|
-
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
167
|
-
noDataTip: {
|
|
168
|
-
type: StringConstructor;
|
|
169
|
-
default: string;
|
|
170
|
-
};
|
|
171
|
-
noDataImg: {
|
|
172
|
-
type: StringConstructor;
|
|
173
|
-
default: string;
|
|
174
|
-
};
|
|
175
|
-
showImg: {
|
|
176
|
-
type: BooleanConstructor;
|
|
177
|
-
default: boolean;
|
|
178
|
-
};
|
|
179
|
-
}>> & {}>>;
|
|
180
|
-
handleDesc: import("vue").ComputedRef<string>;
|
|
181
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
182
|
-
noDataTip: {
|
|
183
|
-
type: StringConstructor;
|
|
184
|
-
default: string;
|
|
185
|
-
};
|
|
186
|
-
noDataImg: {
|
|
187
|
-
type: StringConstructor;
|
|
188
|
-
default: string;
|
|
189
|
-
};
|
|
190
|
-
showImg: {
|
|
191
|
-
type: BooleanConstructor;
|
|
192
|
-
default: boolean;
|
|
193
|
-
};
|
|
194
|
-
}>>, {
|
|
195
|
-
noDataTip: string;
|
|
196
|
-
noDataImg: string;
|
|
197
|
-
showImg: boolean;
|
|
198
|
-
}>;
|
|
199
|
-
CSearchCascader: import("../../../../../../../../es/shared/types").SFCWithInstall<import("vue").DefineComponent<{
|
|
200
|
-
value: {
|
|
201
|
-
type: PropType<string | AnyObject[]>;
|
|
202
|
-
};
|
|
203
|
-
show: {
|
|
204
|
-
type: BooleanConstructor;
|
|
205
|
-
default: boolean;
|
|
206
|
-
};
|
|
207
|
-
clearable: {
|
|
208
|
-
type: BooleanConstructor;
|
|
209
|
-
default: boolean;
|
|
210
|
-
};
|
|
211
|
-
childKey: {
|
|
212
|
-
type: StringConstructor;
|
|
213
|
-
default: string;
|
|
214
|
-
};
|
|
215
|
-
placeholder: {
|
|
216
|
-
type: StringConstructor;
|
|
217
|
-
default: string;
|
|
218
|
-
};
|
|
219
|
-
editPlaceholder: {
|
|
220
|
-
type: StringConstructor;
|
|
221
|
-
default: string;
|
|
222
|
-
};
|
|
223
|
-
options: {
|
|
224
|
-
type: PropType<AnyObject[]>;
|
|
225
|
-
default: () => never[];
|
|
226
|
-
};
|
|
227
|
-
search: {
|
|
228
|
-
type: PropType<import("../../../../../../../../es/shared/types").AnyFn<any[], any>>;
|
|
229
|
-
};
|
|
230
|
-
labelKey: {
|
|
231
|
-
type: StringConstructor;
|
|
232
|
-
default: string;
|
|
233
|
-
};
|
|
234
|
-
valueKey: {
|
|
235
|
-
type: StringConstructor;
|
|
236
|
-
default: string;
|
|
237
|
-
};
|
|
238
|
-
checkAbleLevel: {
|
|
239
|
-
type: PropType<number | "last">;
|
|
240
|
-
default: string;
|
|
241
|
-
};
|
|
242
|
-
beforeSetValue: {
|
|
243
|
-
type: PropType<(value: string | AnyObject[]) => void | (string | AnyObject[]) | Promise<string | AnyObject[]>>;
|
|
244
|
-
};
|
|
245
|
-
menuWidth: {
|
|
246
|
-
type: (NumberConstructor | StringConstructor)[];
|
|
247
|
-
default: number;
|
|
248
|
-
};
|
|
249
|
-
disabled: BooleanConstructor;
|
|
250
|
-
inputProps: {
|
|
251
|
-
type: PropType<AnyObject>;
|
|
252
|
-
};
|
|
253
|
-
popperProps: {
|
|
254
|
-
type: PropType<AnyObject>;
|
|
255
|
-
};
|
|
256
|
-
}, {
|
|
257
|
-
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
258
|
-
value: {
|
|
259
|
-
type: PropType<string | AnyObject[]>;
|
|
260
|
-
};
|
|
261
|
-
show: {
|
|
262
|
-
type: BooleanConstructor;
|
|
263
|
-
default: boolean;
|
|
264
|
-
};
|
|
265
|
-
clearable: {
|
|
266
|
-
type: BooleanConstructor;
|
|
267
|
-
default: boolean;
|
|
268
|
-
};
|
|
269
|
-
childKey: {
|
|
270
|
-
type: StringConstructor;
|
|
271
|
-
default: string;
|
|
272
|
-
};
|
|
273
|
-
placeholder: {
|
|
274
|
-
type: StringConstructor;
|
|
275
|
-
default: string;
|
|
276
|
-
};
|
|
277
|
-
editPlaceholder: {
|
|
278
|
-
type: StringConstructor;
|
|
279
|
-
default: string;
|
|
280
|
-
};
|
|
281
|
-
options: {
|
|
282
|
-
type: PropType<AnyObject[]>;
|
|
283
|
-
default: () => never[];
|
|
284
|
-
};
|
|
285
|
-
search: {
|
|
286
|
-
type: PropType<import("../../../../../../../../es/shared/types").AnyFn<any[], any>>;
|
|
287
|
-
};
|
|
288
|
-
labelKey: {
|
|
289
|
-
type: StringConstructor;
|
|
290
|
-
default: string;
|
|
291
|
-
};
|
|
292
|
-
valueKey: {
|
|
293
|
-
type: StringConstructor;
|
|
294
|
-
default: string;
|
|
295
|
-
};
|
|
296
|
-
checkAbleLevel: {
|
|
297
|
-
type: PropType<number | "last">;
|
|
298
|
-
default: string;
|
|
299
|
-
};
|
|
300
|
-
beforeSetValue: {
|
|
301
|
-
type: PropType<(value: string | AnyObject[]) => void | (string | AnyObject[]) | Promise<string | AnyObject[]>>;
|
|
302
|
-
};
|
|
303
|
-
menuWidth: {
|
|
304
|
-
type: (NumberConstructor | StringConstructor)[];
|
|
305
|
-
default: number;
|
|
306
|
-
};
|
|
307
|
-
disabled: BooleanConstructor;
|
|
308
|
-
inputProps: {
|
|
309
|
-
type: PropType<AnyObject>;
|
|
310
|
-
};
|
|
311
|
-
popperProps: {
|
|
312
|
-
type: PropType<AnyObject>;
|
|
313
|
-
};
|
|
314
|
-
}>> & {
|
|
315
|
-
onFocus?: ((...args: any[]) => any) | undefined;
|
|
316
|
-
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
317
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
318
|
-
}>>;
|
|
319
|
-
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
|
320
|
-
emit: (event: "update:show" | "update:value" | "focus", ...args: any[]) => void;
|
|
321
|
-
emitValue: (value: string | AnyObject[]) => void;
|
|
322
|
-
clearableRef: import("vue").ComputedRef<number | boolean>;
|
|
323
|
-
onClear: () => void;
|
|
324
|
-
onClick: (evt: Event) => void;
|
|
325
|
-
onKeydown: (evt: KeyboardEvent) => void;
|
|
326
|
-
cssVariable: import("vue").ComputedRef<{
|
|
327
|
-
'--menu-width': string | number;
|
|
328
|
-
}>;
|
|
329
|
-
eventBus: AnyObject;
|
|
330
|
-
uuid: string;
|
|
331
|
-
show: import("vue").Ref<boolean> | import("vue").WritableComputedRef<boolean>;
|
|
332
|
-
patternContent: import("vue").Ref<string>;
|
|
333
|
-
editPlaceholderRef: import("vue").ComputedRef<string>;
|
|
334
|
-
displayValue: import("vue").WritableComputedRef<string>;
|
|
335
|
-
onFocus: (focusEvt: Event) => void;
|
|
336
|
-
openMenu: () => void;
|
|
337
|
-
closeMenu: () => Promise<void>;
|
|
338
|
-
inputRef: import("vue").Ref<any>;
|
|
339
|
-
popoverRef: import("vue").Ref<any>;
|
|
340
|
-
currentNode: import("vue").Ref<AnyObject | undefined>;
|
|
341
|
-
cursorNode: import("vue").Ref<AnyObject | undefined>;
|
|
342
|
-
loadingNode: import("vue").Ref<import("../../../../../../../../es/shared/types").Nullable<AnyObject>>;
|
|
343
|
-
search: (payload?: {
|
|
344
|
-
type: "search" | "update";
|
|
345
|
-
node: AnyObject;
|
|
346
|
-
} | undefined, keyword?: string | undefined) => Promise<void>;
|
|
347
|
-
changeCursorNode: (node: AnyObject) => void;
|
|
348
|
-
NInput: any;
|
|
349
|
-
NPopover: any;
|
|
350
|
-
ClearIcon: any;
|
|
351
|
-
SearchMenu: import("vue").DefineComponent<{
|
|
352
|
-
childKey: {
|
|
353
|
-
type: StringConstructor;
|
|
354
|
-
default: string;
|
|
355
|
-
};
|
|
356
|
-
options: {
|
|
357
|
-
type: PropType<AnyObject[]>;
|
|
358
|
-
default: () => never[];
|
|
359
|
-
};
|
|
360
|
-
labelKey: {
|
|
361
|
-
type: StringConstructor;
|
|
362
|
-
default: string;
|
|
363
|
-
};
|
|
364
|
-
valueKey: {
|
|
365
|
-
type: StringConstructor;
|
|
366
|
-
default: string;
|
|
367
|
-
};
|
|
368
|
-
currentNode: {
|
|
369
|
-
type: PropType<AnyObject>;
|
|
370
|
-
};
|
|
371
|
-
cursorNode: {
|
|
372
|
-
type: PropType<AnyObject>;
|
|
373
|
-
};
|
|
374
|
-
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("nodeClick" | "changeCursor")[], "nodeClick" | "changeCursor", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
375
|
-
childKey: {
|
|
376
|
-
type: StringConstructor;
|
|
377
|
-
default: string;
|
|
378
|
-
};
|
|
379
|
-
options: {
|
|
380
|
-
type: PropType<AnyObject[]>;
|
|
381
|
-
default: () => never[];
|
|
382
|
-
};
|
|
383
|
-
labelKey: {
|
|
384
|
-
type: StringConstructor;
|
|
385
|
-
default: string;
|
|
386
|
-
};
|
|
387
|
-
valueKey: {
|
|
388
|
-
type: StringConstructor;
|
|
389
|
-
default: string;
|
|
390
|
-
};
|
|
391
|
-
currentNode: {
|
|
392
|
-
type: PropType<AnyObject>;
|
|
393
|
-
};
|
|
394
|
-
cursorNode: {
|
|
395
|
-
type: PropType<AnyObject>;
|
|
396
|
-
};
|
|
397
|
-
}>> & {
|
|
398
|
-
onNodeClick?: ((...args: any[]) => any) | undefined;
|
|
399
|
-
onChangeCursor?: ((...args: any[]) => any) | undefined;
|
|
400
|
-
}, {
|
|
401
|
-
options: AnyObject[];
|
|
402
|
-
valueKey: string;
|
|
403
|
-
childKey: string;
|
|
404
|
-
labelKey: string;
|
|
405
|
-
}>;
|
|
406
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:show" | "update:value" | "focus")[], "focus" | "update:show" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
407
|
-
value: {
|
|
408
|
-
type: PropType<string | AnyObject[]>;
|
|
409
|
-
};
|
|
410
|
-
show: {
|
|
411
|
-
type: BooleanConstructor;
|
|
412
|
-
default: boolean;
|
|
413
|
-
};
|
|
414
|
-
clearable: {
|
|
415
|
-
type: BooleanConstructor;
|
|
416
|
-
default: boolean;
|
|
417
|
-
};
|
|
418
|
-
childKey: {
|
|
419
|
-
type: StringConstructor;
|
|
420
|
-
default: string;
|
|
421
|
-
};
|
|
422
|
-
placeholder: {
|
|
423
|
-
type: StringConstructor;
|
|
424
|
-
default: string;
|
|
425
|
-
};
|
|
426
|
-
editPlaceholder: {
|
|
427
|
-
type: StringConstructor;
|
|
428
|
-
default: string;
|
|
429
|
-
};
|
|
430
|
-
options: {
|
|
431
|
-
type: PropType<AnyObject[]>;
|
|
432
|
-
default: () => never[];
|
|
433
|
-
};
|
|
434
|
-
search: {
|
|
435
|
-
type: PropType<import("../../../../../../../../es/shared/types").AnyFn<any[], any>>;
|
|
436
|
-
};
|
|
437
|
-
labelKey: {
|
|
438
|
-
type: StringConstructor;
|
|
439
|
-
default: string;
|
|
440
|
-
};
|
|
441
|
-
valueKey: {
|
|
442
|
-
type: StringConstructor;
|
|
443
|
-
default: string;
|
|
444
|
-
};
|
|
445
|
-
checkAbleLevel: {
|
|
446
|
-
type: PropType<number | "last">;
|
|
447
|
-
default: string;
|
|
448
|
-
};
|
|
449
|
-
beforeSetValue: {
|
|
450
|
-
type: PropType<(value: string | AnyObject[]) => void | (string | AnyObject[]) | Promise<string | AnyObject[]>>;
|
|
451
|
-
};
|
|
452
|
-
menuWidth: {
|
|
453
|
-
type: (NumberConstructor | StringConstructor)[];
|
|
454
|
-
default: number;
|
|
455
|
-
};
|
|
456
|
-
disabled: BooleanConstructor;
|
|
457
|
-
inputProps: {
|
|
458
|
-
type: PropType<AnyObject>;
|
|
459
|
-
};
|
|
460
|
-
popperProps: {
|
|
461
|
-
type: PropType<AnyObject>;
|
|
462
|
-
};
|
|
463
|
-
}>> & {
|
|
464
|
-
onFocus?: ((...args: any[]) => any) | undefined;
|
|
465
|
-
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
466
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
|
467
|
-
}, {
|
|
468
|
-
disabled: boolean;
|
|
469
|
-
show: boolean;
|
|
470
|
-
options: AnyObject[];
|
|
471
|
-
placeholder: string;
|
|
472
|
-
valueKey: string;
|
|
473
|
-
clearable: boolean;
|
|
474
|
-
childKey: string;
|
|
475
|
-
editPlaceholder: string;
|
|
476
|
-
labelKey: string;
|
|
477
|
-
checkAbleLevel: number | "last";
|
|
478
|
-
menuWidth: string | number;
|
|
479
|
-
}>>;
|
|
480
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("click" | "update:value")[], "click" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
481
|
-
options: {
|
|
482
|
-
type: PropType<AnyObject[]>;
|
|
483
|
-
default: () => never[];
|
|
484
|
-
};
|
|
485
|
-
labelField: {
|
|
486
|
-
type: StringConstructor;
|
|
487
|
-
default: string;
|
|
488
|
-
};
|
|
489
|
-
valueField: {
|
|
490
|
-
type: StringConstructor;
|
|
491
|
-
default: string;
|
|
492
|
-
};
|
|
493
|
-
autograph: {
|
|
494
|
-
type: StringConstructor;
|
|
495
|
-
required: true;
|
|
496
|
-
};
|
|
497
|
-
lazyRequest: {
|
|
498
|
-
type: BooleanConstructor;
|
|
499
|
-
default: boolean;
|
|
500
|
-
};
|
|
501
|
-
requestCache: {
|
|
502
|
-
type: BooleanConstructor;
|
|
503
|
-
default: boolean;
|
|
504
|
-
};
|
|
505
|
-
wordbook: {
|
|
506
|
-
type: PropType<Partial<{
|
|
507
|
-
level_num: number;
|
|
508
|
-
id: string;
|
|
509
|
-
name: string;
|
|
510
|
-
render_key: string[];
|
|
511
|
-
search_key: string[];
|
|
512
|
-
value_key: string;
|
|
513
|
-
queryParams: string[];
|
|
514
|
-
primary_key: string;
|
|
515
|
-
type: string;
|
|
516
|
-
level_key: string;
|
|
517
|
-
link_key: string;
|
|
518
|
-
link_key_split: string;
|
|
519
|
-
show_key: string | string[];
|
|
520
|
-
conObj: AnyObject[];
|
|
521
|
-
conObjFirstLevel: AnyObject[];
|
|
522
|
-
setting: Partial<{
|
|
523
|
-
cascading: {
|
|
524
|
-
'form.name': string;
|
|
525
|
-
value: string;
|
|
526
|
-
}[];
|
|
527
|
-
}>;
|
|
528
|
-
}>>;
|
|
529
|
-
required: true;
|
|
530
|
-
};
|
|
531
|
-
value: {
|
|
532
|
-
type: PropType<string | AnyObject[]>;
|
|
533
|
-
};
|
|
534
|
-
fieldKey: {
|
|
535
|
-
type: StringConstructor;
|
|
536
|
-
required: true;
|
|
537
|
-
};
|
|
538
|
-
payload: {
|
|
539
|
-
type: PropType<AnyObject>;
|
|
540
|
-
required: true;
|
|
541
|
-
};
|
|
542
|
-
}>> & {
|
|
543
|
-
onClick?: ((...args: any[]) => any) | undefined;
|
|
544
|
-
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
545
|
-
}, {
|
|
546
|
-
options: AnyObject[];
|
|
547
|
-
labelField: string;
|
|
548
|
-
valueField: string;
|
|
549
|
-
lazyRequest: boolean;
|
|
550
|
-
requestCache: boolean;
|
|
551
|
-
}>;
|
|
552
|
-
export default _default;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import e from"./levelSearchCascade.vue2.js";import r from"../../../../../../../_virtual/_plugin-vue_export-helper.js";var a=r(e,[["__file","levelSearchCascade.vue"]]);export{a as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{defineComponent as e,inject as a,openBlock as t,createBlock as r,unref as o,isRef as l,withCtx as u,createVNode as s}from"vue";import i from"../../../../../../../shared/components/no-data/NoData.vue.js";import"../../../../../../../shared/utils/index.js";import"lodash-es";import"naive-ui";import"@vueuse/core";import"date-fns";import"@vue/shared";import{useLevelSearchCascader as p}from"../../../../../../../shared/hooks/useLevelSearchCascader.js";import{InjectionTableAsyncQueue as d}from"../../../../constants/index.js";import n from"../../../../../../search-cascader/index.js";var c=e({__name:"levelSearchCascade",props:{options:{type:Array,default:()=>[]},labelField:{type:String,default:"text"},valueField:{type:String,default:"value"},autograph:{type:String,required:!0},lazyRequest:{type:Boolean,default:!0},requestCache:{type:Boolean,default:!0},wordbook:{type:Object,required:!0},value:{type:[String,Array]},fieldKey:{type:String,required:!0},payload:{type:Object,required:!0}},emits:["update:value","click"],setup(e,{emit:c}){const y=e,f=a(d),{valueKey:m,valueRef:h,labelKey:v,optionsRef:k,showRef:b,fetchData:g,menuWidth:j,searchCascaderRef:q}=p(y,c,{fieldKey:y.fieldKey,asyncQueue:f,getRequestPayload:()=>y.payload});function w(){j.value=150}function R(e){c("click",e)}return(e,a)=>(t(),r(o(n),{ref_key:"searchCascaderRef",ref:q,value:o(h),"onUpdate:value":a[0]||(a[0]=e=>l(h)?h.value=e:null),show:o(b),"onUpdate:show":a[1]||(a[1]=e=>l(b)?b.value=e:null),options:o(k),"label-key":o(v),"value-key":o(m),search:o(g),"menu-width":o(j),"input-props":{onClick:R},onFocus:w},{empty:u((()=>[s(o(i))])),_:1},8,["value","show","options","label-key","value-key","search","menu-width","input-props"]))}});export{c as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function wordbookSettingPlugin(): import("../../../../../es/components/iho-table").TablePlugin;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"../../index.js";import{isFunction as o}from"lodash-es";import{getLowCodeFieldFromField as n}from"../utils/index.js";import{defineTablePlugin as t}from"../hooks/useTablePlugin.js";function i(){const i="wordbookSettingPlugin";return t({name:i,apply(t){t.configHooks.config.tap(i,(t=>{const i=t.onFormChange;return t.onFormChange=function(t){var r,e,l;o(i)&&i(t);const{column:s,row:u,$table:a,option:c}=t,d=n(s);c&&(null==(l=null==(e=null==(r=null==d?void 0:d.wordbook)?void 0:r.setting)?void 0:e.cascading)?void 0:l.length)&&d.wordbook.setting.cascading.forEach((o=>{const n=function(o,n){return o.getColumns().find((o=>o.title===n))}(a,o["form.name"]);n&&(u[n.field]=c[o.value])}))},t}))}})}export{i as wordbookSettingPlugin};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{openBlock as r,createElementBlock as e,createElementVNode as o}from"vue";import L from"../../../../_virtual/_plugin-vue_export-helper.js";const l={},n={viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg",style:{width:"15px",color:"var(--n-clear-color)",cursor:"pointer"}},t=[o("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},[o("g",{fill:"currentColor","fill-rule":"nonzero"},[o("path",{d:"M8,2 C11.3137085,2 14,4.6862915 14,8 C14,11.3137085 11.3137085,14 8,14 C4.6862915,14 2,11.3137085 2,8 C2,4.6862915 4.6862915,2 8,2 Z M6.5343055,5.83859116 C6.33943736,5.70359511 6.07001296,5.72288026 5.89644661,5.89644661 L5.89644661,5.89644661 L5.83859116,5.9656945 C5.70359511,6.16056264 5.72288026,6.42998704 5.89644661,6.60355339 L5.89644661,6.60355339 L7.293,8 L5.89644661,9.39644661 L5.83859116,9.4656945 C5.70359511,9.66056264 5.72288026,9.92998704 5.89644661,10.1035534 L5.89644661,10.1035534 L5.9656945,10.1614088 C6.16056264,10.2964049 6.42998704,10.2771197 6.60355339,10.1035534 L6.60355339,10.1035534 L8,8.707 L9.39644661,10.1035534 L9.4656945,10.1614088 C9.66056264,10.2964049 9.92998704,10.2771197 10.1035534,10.1035534 L10.1035534,10.1035534 L10.1614088,10.0343055 C10.2964049,9.83943736 10.2771197,9.57001296 10.1035534,9.39644661 L10.1035534,9.39644661 L8.707,8 L10.1035534,6.60355339 L10.1614088,6.5343055 C10.2964049,6.33943736 10.2771197,6.07001296 10.1035534,5.89644661 L10.1035534,5.89644661 L10.0343055,5.83859116 C9.83943736,5.70359511 9.57001296,5.72288026 9.39644661,5.89644661 L9.39644661,5.89644661 L8,7.293 L6.60355339,5.89644661 Z"})])],-1)];var i=L(l,[["render",function(o,L){return r(),e("svg",n,t)}],["__file","ClearIcon.vue"]]);export{i as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{cloneDeep as s}from"lodash-es";var e=(s=>(s[s.PENDING=0]="PENDING",s[s.DONE=1]="DONE",s))(e||{});class t{constructor(s,e,t){this.item=s,this.key=e,this.state=0,this.callback=t}}class i{constructor(s){this._list=s?Array.from(s):[]}enqueue(s){this._list.push(s)}dequeue(){return this._list.shift()}}class r{constructor({name:s,processor:e,getKey:t,parallelism:r,uniqueData:a}){this._queued=new i,this._entries=new Map,this._activeTasks=0,this._processingLock=!1,this._stopped=!1,this.uniqueData=!0,this.name=s,this.processor=e,this.getKey=t,this.parallelism=r||100,this.uniqueData=!!a}add(e,i){if(this._stopped)return i(new Error("Queue was stopped"));const r=this.getKey(e);if(this._entries.has(r)){const e=this._entries.get(r);return void(1===e.state?setTimeout((()=>{i&&i(this.uniqueData?s(e.error):e.error,this.uniqueData?s(e.result):e.result)})):e.callbacks?e.callbacks.push(i):e.callbacks=[i])}const a=new t(e,r,i);this._entries.set(r,a),this._queued.enqueue(a),this._processingLock||(this._processingLock=!0,Promise.resolve().then(this._ensureProcessing.bind(this)))}addAsync(s){return new Promise(((e,t)=>{this.add(s,((s,i)=>{s&&t(s),e(i)}))}))}_ensureProcessing(){for(;this._activeTasks<this.parallelism;){const s=this._queued.dequeue();if(!s)break;this._activeTasks++,s.state=0,this._startProcess(s)}this._processingLock=!1}_startProcess(s){this.processor(s.item,((e,t)=>{e?this._handlerResult(s,e):this._handlerResult(s,e,t)}),(()=>this._entries.delete(s.key)))}_handlerResult(e,t,i){const r=e.callback;e.state=1,e.callback=void 0,e.result=this.uniqueData?s(i):i,e.error=this.uniqueData?s(t):t,this._activeTasks--,r&&r(t,i),e.callbacks&&e.callbacks.forEach((s=>s(t,i))),this._processingLock||(this._processingLock=!0,Promise.resolve().then(this._ensureProcessing.bind(this)))}}export{r as AsyncQueue,e as ENTRY_STATE};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { AnyObject, UndefinedAble } from '../../../../es/shared/types';
|
|
2
|
-
export declare namespace AsyncQueueDefine {
|
|
3
|
-
interface EntryCallback {
|
|
4
|
-
(err?: any, result?: any): void;
|
|
5
|
-
}
|
|
6
|
-
interface Processor<T, R = any> {
|
|
7
|
-
(item: T, cb: (err?: any, result?: R) => void, removeCache: () => void): void;
|
|
8
|
-
}
|
|
9
|
-
interface CreatorOptions<T = any, K = any> {
|
|
10
|
-
name: string;
|
|
11
|
-
processor: Processor<T>;
|
|
12
|
-
parallelism: number;
|
|
13
|
-
getKey: (item: T) => K;
|
|
14
|
-
uniqueData?: boolean;
|
|
15
|
-
}
|
|
16
|
-
type ProcessorOption = Partial<{
|
|
17
|
-
afterRequest(key: string, res?: unknown, payload?: AnyObject): AnyObject[];
|
|
18
|
-
beforeRequest(key: string, params?: unknown, payload?: AnyObject): UndefinedAble<AnyObject> | void;
|
|
19
|
-
}>;
|
|
20
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { FormRequestDefine } from './types';
|
|
2
|
-
import { ComputedRef } from 'vue';
|
|
3
|
-
import { AsyncQueue, AsyncQueueDefine } from '../../../../es/shared/hooks';
|
|
4
|
-
import { AnyObject, Nullable, UndefinedAble } from '../../../../es/shared/types';
|
|
5
|
-
export * from './types';
|
|
6
|
-
export declare function useFormRequest(): {
|
|
7
|
-
getHttpInstance: () => Nullable<FormRequestDefine.RequestInstance>;
|
|
8
|
-
registGlobHttpInstance: (instance: FormRequestDefine.RequestInstance) => void;
|
|
9
|
-
registGlobRecommendInfo: (info: Partial<FormRequestDefine.RecommendInfo>) => void;
|
|
10
|
-
registGlobSearchInfo: (info: FormRequestDefine.SearchInfo) => void;
|
|
11
|
-
getSearchRequestInfo: () => {
|
|
12
|
-
method: FormRequestDefine.RequestType;
|
|
13
|
-
url: string;
|
|
14
|
-
primaryKeyUrl?: string | undefined;
|
|
15
|
-
};
|
|
16
|
-
getRecommendRequestInfo: () => FormRequestDefine.RecommendInfo;
|
|
17
|
-
};
|
|
18
|
-
export declare function useFormAsyncQueue(requestInstance: ComputedRef<UndefinedAble<FormRequestDefine.RequestInstance>>, uniqueData: ComputedRef<boolean>): {
|
|
19
|
-
create: (parallelism?: number, option?: AsyncQueueDefine.ProcessorOption) => AsyncQueue<FormRequestDefine.AsyncQueueItem, any, {
|
|
20
|
-
label: string;
|
|
21
|
-
value: unknown;
|
|
22
|
-
}[]>;
|
|
23
|
-
};
|
|
24
|
-
export declare function presetRequestHandler(res: unknown): AnyObject[];
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{isObject as e}from"@vue/shared";import{uuidGenerator as t}from"../../utils/index.js";import{unref as r}from"vue";import{cloneDeep as n,isFunction as o}from"lodash-es";import"naive-ui";import"@vueuse/core";import"date-fns";import{AsyncQueue as s}from"../useAsyncQueue/index.js";let u=null;const a={method:"post",url:"",primaryKeyUrl:""},c={url:{get:"/fdp-api/fdp/aiRec/search",post:"/fdp-api/fdp/aiRec/sendBehaviorData",delete:"/fdp-api/fdp/aiRec/delete"},getRecommendIds:()=>({})};function i(){return{getHttpInstance:function(){return u},registGlobHttpInstance:function(e){u=e},registGlobRecommendInfo:function(e){Object.assign(c,e)},registGlobSearchInfo:function(e){Object.assign(a,e)},getSearchRequestInfo:function(){return{...a}},getRecommendRequestInfo:function(){return n(c)}}}function f(e,n){const{getHttpInstance:u}=i();return{create:function(a=3,c){return new s({name:"FormRenderAsyncQueue",uniqueData:n.value,parallelism:a,async processor({key:t,method:n="post",cache:s,params:a,url:i,payload:f},l,p){var m,d;const h=null!=(m=r(e))?m:u();if(!h)return console.log("before use http feature, you should regist http instance by useFormRequest.registGlobHttpInstance()"),l(),void p();try{c&&o(c.beforeRequest)&&(a=null!=(d=c.beforeRequest(t,a,f))?d:{});let e=await h[n](i,a);c&&o(c.afterRequest)&&(e=c.afterRequest(t,e,f)),l(void 0,Array.isArray(e)?e:[]),!s&&p()}catch(e){l(new Error(`Request error => ${e}`)),p()}},getKey:({url:e,method:r="post",cache:n,params:o})=>n?e+r+JSON.stringify(o||{}):t()})}}}function l(t){if(!e(t))throw t;return r=t,Reflect.has(r,"map")&&Reflect.has(r,"result")?function(e){const{result:t,map:r}=e;if("SUCCESS"!==t)throw e;return r.rows}(t):function(e){return Reflect.has(e,"result")&&Reflect.has(e,"obj")}(t)?function(t){const{obj:r,result:n}=t;if("SUCCESS"!==n||!e(r))throw t;return Object.entries(r).reduce(((e,[t,r])=>(r.forEach((r=>e.push({...r,type:t}))),e)),[])}(t):function(e){return Reflect.has(e,"data")&&Reflect.has(e,"success")}(t)?function(e){const{data:t,success:r}=e;if(!r)throw e;return t}(t):[];var r}export{l as presetRequestHandler,f as useFormAsyncQueue,i as useFormRequest};
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { AsyncQueue } from '../../../../es/shared/hooks';
|
|
2
|
-
import { AnyObject, AnyFn } from '../../../../es/shared/types';
|
|
3
|
-
export declare namespace FormRequestDefine {
|
|
4
|
-
type RequestType = 'post' | 'get' | 'patch' | 'delete' | 'put';
|
|
5
|
-
interface AsyncQueueItem {
|
|
6
|
-
key: any;
|
|
7
|
-
cache?: boolean;
|
|
8
|
-
url: string;
|
|
9
|
-
method?: RequestType;
|
|
10
|
-
params?: AnyObject;
|
|
11
|
-
payload?: AnyObject;
|
|
12
|
-
}
|
|
13
|
-
type FormAsyncQueue = AsyncQueue<AsyncQueueItem, any, AnyObject[]>;
|
|
14
|
-
type RequestInstance = Record<string, AnyFn>;
|
|
15
|
-
type SearchInfo = {
|
|
16
|
-
method: RequestType;
|
|
17
|
-
url: string;
|
|
18
|
-
primaryKeyUrl?: string;
|
|
19
|
-
};
|
|
20
|
-
type RecommendIds = Partial<Record<'businessId' | 'componentId' | 'deptId' | 'userId', string>>;
|
|
21
|
-
type RecommendInfo = {
|
|
22
|
-
getRecommendIds(): RecommendIds;
|
|
23
|
-
url: Record<'get' | 'post' | 'delete', string>;
|
|
24
|
-
};
|
|
25
|
-
type SearchResult = {
|
|
26
|
-
result: 'SUCCESS' | 'ERROR';
|
|
27
|
-
map: {
|
|
28
|
-
rows: AnyObject[];
|
|
29
|
-
};
|
|
30
|
-
};
|
|
31
|
-
type SelectResult = {
|
|
32
|
-
success: boolean;
|
|
33
|
-
data: AnyObject[];
|
|
34
|
-
};
|
|
35
|
-
type RecommendResult = {
|
|
36
|
-
result: 'SUCCESS' | 'ERROR';
|
|
37
|
-
obj: Partial<Record<'commonly' | 'recently', AnyObject[]>>;
|
|
38
|
-
};
|
|
39
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|