keli-ui 0.3.0 → 0.3.1
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/dist/ApprovalRecord-4ohFAtSZ.js +111 -0
- package/dist/ApprovalRecord-4ohFAtSZ.js.map +1 -0
- package/dist/api-Gtg77a-p.js +4507 -0
- package/dist/api-Gtg77a-p.js.map +1 -0
- package/dist/components/AppComponent/AppFormRender.vue.d.ts +74 -0
- package/dist/components/AppComponent/AppTableRender.vue.d.ts +16 -0
- package/dist/components/AppComponent/components/ApprovalRecord.vue.d.ts +20 -0
- package/dist/components/AppComponent/components/DialogForm.vue.d.ts +22 -0
- package/dist/components/AppComponent/components/DrawerForm.vue.d.ts +22 -0
- package/dist/components/AppComponent/components/FileIsland.vue.d.ts +21 -0
- package/dist/components/AppComponent/components/FlowUserDialog.vue.d.ts +13 -0
- package/dist/components/AppComponent/components/chartList/ChartRender.vue.d.ts +17 -0
- package/dist/components/AppComponent/components/chartList/index.d.ts +1 -0
- package/dist/components/AppComponent/components/chartList/index.vue.d.ts +4 -0
- package/dist/components/AppComponent/components/embedded/EmbeddedDialogForm.vue.d.ts +46 -0
- package/dist/components/AppComponent/components/embedded/EmbeddedTable.vue.d.ts +16 -0
- package/dist/components/AppComponent/hooks/useAutoForm.hook.d.ts +9 -0
- package/dist/components/AppComponent/hooks/useSplitApiButton.d.ts +13 -0
- package/dist/components/AppComponent/hooks/useTable.hook.d.ts +134 -0
- package/dist/components/AppComponent/index.d.ts +4 -0
- package/dist/components/ElPlusComponent/ElColPlus/ElColPlus.vue.d.ts +1 -1
- package/dist/components/FormComponent/DynamicMapTable/DynamicMapTable.vue.d.ts +21 -0
- package/dist/components/FormComponent/DynamicMapTable/index.d.ts +3 -0
- package/dist/components/FormComponent/FormCascaderAsync/FormCascaderAsync.vue.d.ts +34 -0
- package/dist/components/FormComponent/FormCascaderAsync/index.d.ts +3 -0
- package/dist/components/FormComponent/FormCheckBox/FormCheckBox.vue.d.ts +37 -0
- package/dist/components/FormComponent/FormCheckBox/index.d.ts +3 -0
- package/dist/components/FormComponent/FormCheckBoxAsync/FormCheckBoxAsync.vue.d.ts +37 -0
- package/dist/components/FormComponent/FormCheckBoxAsync/index.d.ts +3 -0
- package/dist/components/FormComponent/FormCodeEditor/FormCodeEditor.vue.d.ts +35 -0
- package/dist/components/FormComponent/FormCodeEditor/index.d.ts +3 -0
- package/dist/components/FormComponent/FormCodeEditor/language/java.d.ts +72 -0
- package/dist/components/FormComponent/FormCodeEditor/language/mysql.d.ts +80 -0
- package/dist/components/FormComponent/FormCodeEditor/language/postgresql.d.ts +6 -0
- package/dist/components/FormComponent/FormCodeEditor/volar/setup.d.ts +2 -0
- package/dist/components/FormComponent/FormDatePicker/FormDatePicker.vue.d.ts +32 -0
- package/dist/components/FormComponent/FormDatePicker/index.d.ts +3 -0
- package/dist/components/FormComponent/FormDateTimePicker/FormDateTimePicker.vue.d.ts +36 -0
- package/dist/components/FormComponent/FormDateTimePicker/index.d.ts +3 -0
- package/dist/components/FormComponent/FormDictSelector/FormDictSelector.vue.d.ts +32 -0
- package/dist/components/FormComponent/FormDictSelector/index.d.ts +3 -0
- package/dist/components/FormComponent/FormDivider/FormDivider.vue.d.ts +35 -0
- package/dist/components/FormComponent/FormDivider/index.d.ts +3 -0
- package/dist/components/FormComponent/FormDynamicTable/FormDynamicTable.vue.d.ts +26 -0
- package/dist/components/FormComponent/FormDynamicTable/index.d.ts +3 -0
- package/dist/components/FormComponent/FormFieldset/FormFieldset.vue.d.ts +75 -0
- package/dist/components/FormComponent/FormFieldset/index.d.ts +3 -0
- package/dist/components/FormComponent/FormIconPicker/FormIconPicker.vue.d.ts +16 -0
- package/dist/components/FormComponent/FormIconPicker/index.d.ts +3 -0
- package/dist/components/FormComponent/FormInput/FormInput.vue.d.ts +36 -0
- package/dist/components/FormComponent/FormInput/index.d.ts +3 -0
- package/dist/components/FormComponent/FormInputNumber/FormInputNumber.vue.d.ts +26 -0
- package/dist/components/FormComponent/FormInputNumber/index.d.ts +3 -0
- package/dist/components/FormComponent/FormRadio/FormRadio.vue.d.ts +32 -0
- package/dist/components/FormComponent/FormRadio/index.d.ts +3 -0
- package/dist/components/FormComponent/FormRender/FormRender.vue.d.ts +81 -0
- package/dist/components/FormComponent/FormRender/components/FormAreaRender.vue.d.ts +67 -0
- package/dist/components/FormComponent/FormRender/hooks/formRender.hook.d.ts +35 -0
- package/dist/components/FormComponent/FormRender/index.d.ts +3 -0
- package/dist/components/FormComponent/FormSelect/FormSelect.vue.d.ts +34 -0
- package/dist/components/FormComponent/FormSelect/index.d.ts +3 -0
- package/dist/components/FormComponent/FormSelectAsync/FormSelectAsync.vue.d.ts +44 -0
- package/dist/components/FormComponent/FormSelectAsync/index.d.ts +3 -0
- package/dist/components/FormComponent/FormSelectRemote/FormSelectRemote.vue.d.ts +44 -0
- package/dist/components/FormComponent/FormSelectRemote/index.d.ts +3 -0
- package/dist/components/FormComponent/FormSwitch/FormSwitch.vue.d.ts +34 -0
- package/dist/components/FormComponent/FormSwitch/index.d.ts +3 -0
- package/dist/components/FormComponent/FormTableSelect/FormTableSelect.vue.d.ts +32 -0
- package/dist/components/FormComponent/FormTableSelect/index.d.ts +3 -0
- package/dist/components/FormComponent/FormTableSelectAsync/FormTableSelectAsync.vue.d.ts +44 -0
- package/dist/components/FormComponent/FormTableSelectAsync/index.d.ts +3 -0
- package/dist/components/FormComponent/FormText/FormText.vue.d.ts +26 -0
- package/dist/components/FormComponent/FormText/index.d.ts +3 -0
- package/dist/components/FormComponent/FormTextArea/FormTextArea.vue.d.ts +34 -0
- package/dist/components/FormComponent/FormTextArea/index.d.ts +3 -0
- package/dist/components/FormComponent/hooks/selectAsync.hook.d.ts +30 -0
- package/dist/components/FormComponent/hooks/useColumnRender.hook.d.ts +26 -0
- package/dist/components/FormComponent/hooks/useMitt.hook.d.ts +4 -0
- package/dist/components/FormComponent/index.d.ts +24 -0
- package/dist/components/QueryComponent/QueryBar/hooks/index.d.ts +6 -0
- package/dist/components/QueryComponent/QueryTreeFilter/QueryTreeFilter.d.ts +14 -0
- package/dist/components/QueryComponent/QueryTreeFilter/QueryTreeFilter.vue.d.ts +22 -0
- package/dist/components/QueryComponent/QueryTreeFilter/index.d.ts +3 -0
- package/dist/components/QueryComponent/index.d.ts +1 -0
- package/dist/components/TableComponent/TableCardRender/TableCardRender.vue.d.ts +99 -0
- package/dist/components/TableComponent/TableCardRender/index.d.ts +3 -0
- package/dist/components/TableComponent/TableCheckBoxAsync/TableCheckBoxAsync.vue.d.ts +11 -10
- package/dist/components/TableComponent/TableCheckBoxAsync/type.d.ts +5 -0
- package/dist/components/TableComponent/TableInputNumber/TableInputNumber.vue.d.ts +2 -2
- package/dist/components/TableComponent/TableRender/TableRender.vue.d.ts +103 -0
- package/dist/components/TableComponent/TableRender/hooks/useVxeGrid.hook.d.ts +29 -0
- package/dist/components/TableComponent/TableRender/index.d.ts +3 -0
- package/dist/components/TableComponent/TableRender/plugin/vxe-table-clipboard.d.ts +73 -0
- package/dist/components/TableComponent/index.d.ts +2 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/config/appRouter.config.d.ts +6 -0
- package/dist/config/index.d.ts +170 -0
- package/dist/config/moduleCache.d.ts +14 -0
- package/dist/config/pageTableConfig.d.ts +8 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/useButtonExec.hook.d.ts +7 -1
- package/dist/hooks/useRemoteComponentManager.hook.d.ts +23 -0
- package/dist/hooks/useTableFormats.hook.d.ts +4 -0
- package/dist/index.d.ts +11 -5
- package/dist/java-BrZSNBDG.js +2603 -0
- package/dist/java-BrZSNBDG.js.map +1 -0
- package/dist/keli-ui.css +2 -1
- package/dist/keli-ui.js +68159 -679
- package/dist/keli-ui.js.map +1 -1
- package/dist/keli-ui.umd.cjs +2577 -2
- package/dist/keli-ui.umd.cjs.map +1 -1
- package/dist/mysql-BJR6iO89.js +923 -0
- package/dist/mysql-BJR6iO89.js.map +1 -0
- package/dist/postgresql-CLVUxiA0.js +2375 -0
- package/dist/postgresql-CLVUxiA0.js.map +1 -0
- package/dist/types/api/app.req.d.ts +23 -0
- package/dist/types/api/app.res.d.ts +79 -0
- package/dist/types/api/appTable.api.res.d.ts +22 -0
- package/dist/types/api/index.d.ts +34 -0
- package/dist/types/app.d.ts +5 -0
- package/dist/types/assets.d.ts +4 -0
- package/dist/types/button.d.ts +43 -0
- package/dist/types/cacheValue.d.ts +32 -0
- package/dist/types/chart.d.ts +31 -0
- package/dist/types/common.d.ts +5 -0
- package/dist/types/componentFrame.d.ts +24 -0
- package/dist/types/flowButton.d.ts +7 -0
- package/dist/types/formFrame.d.ts +299 -0
- package/dist/types/global-components.d.ts +61 -0
- package/dist/types/index.d.ts +12 -96
- package/dist/types/queryFrame.d.ts +36 -0
- package/dist/types/tableFrame.d.ts +196 -0
- package/dist/types/translate.d.ts +20 -0
- package/dist/types/vue3-sfc-loader.d.ts +19 -0
- package/dist/utils/arrayUtils.d.ts +73 -0
- package/dist/utils/baseFunction.d.ts +10 -0
- package/dist/utils/dataFormatter.d.ts +69 -0
- package/dist/utils/dateTime.d.ts +22 -0
- package/dist/utils/emitter.d.ts +7 -0
- package/dist/utils/formValidates.d.ts +28 -0
- package/dist/utils/index.d.ts +9 -24
- package/dist/utils/msgTips.d.ts +26 -0
- package/dist/utils/sleep.d.ts +6 -0
- package/dist/utils/validate.d.ts +5 -0
- package/package.json +39 -8
|
@@ -0,0 +1,299 @@
|
|
|
1
|
+
import { ComponentFrame, HttpMethod, OptionInterface, Size } from './componentFrame';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
type LabelPosition = 'left' | 'right';
|
|
5
|
+
|
|
6
|
+
type FormLayout = 'horizontal' | 'inline' | 'vertical';
|
|
7
|
+
|
|
8
|
+
export interface FormFrame extends ComponentFrame {
|
|
9
|
+
/** 表单编辑器 */
|
|
10
|
+
formEditor: string;
|
|
11
|
+
/** 是否禁止编辑 */
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
/** 组件大小 */
|
|
14
|
+
size?: Size;
|
|
15
|
+
/** 当值发生变化时 通知这些字段的组件 */
|
|
16
|
+
noticeField?: string[];
|
|
17
|
+
/** 接收到字段值发生变化是触发的js函数 */
|
|
18
|
+
noticeReceive?: Function;
|
|
19
|
+
/** 组件其他参数 */
|
|
20
|
+
componentParams?: any;
|
|
21
|
+
/** 格栅占据数 */
|
|
22
|
+
formSpan?: number;
|
|
23
|
+
/**
|
|
24
|
+
* label-width 标签宽度,例如 '50px'。 可以使用 auto。
|
|
25
|
+
* string / number
|
|
26
|
+
*/
|
|
27
|
+
labelWidth?: number | string;
|
|
28
|
+
/** 默认值 */
|
|
29
|
+
defaultValue?: null | string | undefined;
|
|
30
|
+
/**
|
|
31
|
+
* 域子组件
|
|
32
|
+
*/
|
|
33
|
+
children?: FormFrame[];
|
|
34
|
+
/**
|
|
35
|
+
* 强制换行
|
|
36
|
+
*/
|
|
37
|
+
formBreak?: boolean;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* 下拉表组件的options
|
|
42
|
+
*/
|
|
43
|
+
interface KeFormTableSelectOption {
|
|
44
|
+
field: string;
|
|
45
|
+
label: string;
|
|
46
|
+
/**
|
|
47
|
+
* 最大24
|
|
48
|
+
*/
|
|
49
|
+
span: number;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* 下拉表组件
|
|
54
|
+
*/
|
|
55
|
+
export interface FormTableSelectProp extends FormFrame {
|
|
56
|
+
/** 是否多选 */
|
|
57
|
+
multiple?: boolean;
|
|
58
|
+
/** 下拉框选项 */
|
|
59
|
+
options: any[];
|
|
60
|
+
componentParams: {
|
|
61
|
+
/**
|
|
62
|
+
* key字段
|
|
63
|
+
*/
|
|
64
|
+
keyField: string;
|
|
65
|
+
/**
|
|
66
|
+
* label字段
|
|
67
|
+
*/
|
|
68
|
+
labelField: string;
|
|
69
|
+
mode?: string;
|
|
70
|
+
optionSlots: KeFormTableSelectOption[];
|
|
71
|
+
/**
|
|
72
|
+
* option宽度
|
|
73
|
+
*/
|
|
74
|
+
optionWidth: number;
|
|
75
|
+
/**
|
|
76
|
+
* value字段
|
|
77
|
+
*/
|
|
78
|
+
valueField: string;
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
export interface FormTableSelectAsyncProp extends FormSelectAsyncProp {
|
|
82
|
+
componentParams: {
|
|
83
|
+
/**
|
|
84
|
+
* key字段
|
|
85
|
+
*/
|
|
86
|
+
keyField: string;
|
|
87
|
+
/**
|
|
88
|
+
* label字段
|
|
89
|
+
*/
|
|
90
|
+
labelField: string;
|
|
91
|
+
mode?: string;
|
|
92
|
+
optionSlots: KeFormTableSelectOption[];
|
|
93
|
+
/**
|
|
94
|
+
* option宽度
|
|
95
|
+
*/
|
|
96
|
+
optionWidth?: number;
|
|
97
|
+
/**
|
|
98
|
+
* value字段
|
|
99
|
+
*/
|
|
100
|
+
valueField: string;
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/** 动态表格 */
|
|
105
|
+
export interface FormDynamicTableProps extends FormFrame {
|
|
106
|
+
column: DynamicTableColumn[];
|
|
107
|
+
componentParams?: {
|
|
108
|
+
column: any[];
|
|
109
|
+
width?: number;
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
interface DynamicTableColumn {
|
|
113
|
+
field: string;
|
|
114
|
+
title: string;
|
|
115
|
+
width: number;
|
|
116
|
+
editor: DynamicComponent;
|
|
117
|
+
[key: string]: any;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
export interface FormRadioProp extends FormFrame {
|
|
121
|
+
options: OptionInterface[];
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/** 表单基本配置 */
|
|
125
|
+
export interface KeFormBasicInterface {
|
|
126
|
+
/** 主键的key */
|
|
127
|
+
rowKey: string;
|
|
128
|
+
labelWidth: number;
|
|
129
|
+
span?: number;
|
|
130
|
+
// label对齐方式
|
|
131
|
+
labelPosition?: LabelPosition;
|
|
132
|
+
// 表单布局方式
|
|
133
|
+
layout?: FormLayout;
|
|
134
|
+
formWindowType?: 'default' | 'EmbeddedDialogForm' | 'DrawerForm';
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export type SupportedLanguage =
|
|
138
|
+
| 'java'
|
|
139
|
+
| 'javascript'
|
|
140
|
+
| 'json'
|
|
141
|
+
| 'mysql'
|
|
142
|
+
| 'postgresql'
|
|
143
|
+
| 'vue';
|
|
144
|
+
|
|
145
|
+
export interface FormCodeEditorProp extends FormFrame {
|
|
146
|
+
componentParams: {
|
|
147
|
+
lang?: SupportedLanguage;
|
|
148
|
+
maxLine?: number;
|
|
149
|
+
prefix?: string;
|
|
150
|
+
suffix?: string;
|
|
151
|
+
theme?: 'dark' | 'default' | 'light';
|
|
152
|
+
width?: number;
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
/** 表单基本配置 */
|
|
157
|
+
export interface FormBasicInterface {
|
|
158
|
+
/** 主键的key */
|
|
159
|
+
rowKey: string;
|
|
160
|
+
labelWidth: number;
|
|
161
|
+
span?: number;
|
|
162
|
+
/**
|
|
163
|
+
* 启用流程
|
|
164
|
+
*/
|
|
165
|
+
startOA?: boolean;
|
|
166
|
+
// label对齐方式
|
|
167
|
+
labelPosition?: 'left' | 'right' | 'top';
|
|
168
|
+
// 表单布局方式
|
|
169
|
+
layout?: FormLayout;
|
|
170
|
+
formWindowType?: 'default' | 'EmbeddedDialogForm' | 'DrawerForm';
|
|
171
|
+
/**
|
|
172
|
+
* 响应式布局 默认打开
|
|
173
|
+
*/
|
|
174
|
+
responsive?: boolean;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export interface FormRenderProp {
|
|
178
|
+
formConfig: FormBasicInterface;
|
|
179
|
+
formFrame: formFrameType;
|
|
180
|
+
formRules: {
|
|
181
|
+
// [propName: string]: Rule[];
|
|
182
|
+
[propName: string]: any[];
|
|
183
|
+
};
|
|
184
|
+
formButtons?: FormButton[];
|
|
185
|
+
embeddedTableList?: FormEmbeddedTable[];
|
|
186
|
+
/**
|
|
187
|
+
* 组件显示规则
|
|
188
|
+
*/
|
|
189
|
+
componentShowRule?: {
|
|
190
|
+
[key: string]: Function;
|
|
191
|
+
};
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
/** 嵌入表 */
|
|
195
|
+
export interface FormEmbeddedTableProp {
|
|
196
|
+
/** pageEn */
|
|
197
|
+
embeddedId: number;
|
|
198
|
+
/** tab标题 */
|
|
199
|
+
tabTitle: string;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
// frame类型
|
|
203
|
+
type formFrameType = (
|
|
204
|
+
| FormCodeEditor
|
|
205
|
+
| FormDynamicTable
|
|
206
|
+
| FormFilePicker
|
|
207
|
+
| FormFrame
|
|
208
|
+
| FormNumberInput
|
|
209
|
+
| FormSelect
|
|
210
|
+
| FormSelectAsync
|
|
211
|
+
)[];
|
|
212
|
+
|
|
213
|
+
/** 表单验证规则 */
|
|
214
|
+
export interface FormRuleProp {
|
|
215
|
+
required?: boolean;
|
|
216
|
+
min?: number;
|
|
217
|
+
max?: number;
|
|
218
|
+
message?: string;
|
|
219
|
+
trigger: ruleTriggerType;
|
|
220
|
+
validator?: Function | string;
|
|
221
|
+
[key: string]: any;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
/** 下拉框 */
|
|
225
|
+
export interface FormSelectProp extends FormFrame {
|
|
226
|
+
/** 是否多选 */
|
|
227
|
+
multiple?: boolean;
|
|
228
|
+
/** 下拉框选项 */
|
|
229
|
+
options: OptionInterface[];
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
/** 异步下拉框 */
|
|
233
|
+
export interface FormSelectAsyncProp extends FormFrame {
|
|
234
|
+
/** 是否多选 */
|
|
235
|
+
multiple: boolean;
|
|
236
|
+
/** Http URL */
|
|
237
|
+
optionHttpUrl: string;
|
|
238
|
+
/** http方法 */
|
|
239
|
+
optionHttpMethod: HttpMethod;
|
|
240
|
+
/** http默认参数 */
|
|
241
|
+
optionHttpParams: any;
|
|
242
|
+
/** http其他字段 */
|
|
243
|
+
optionHttpComponentValue: string[];
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
/** 动态表格 */
|
|
247
|
+
export interface FormDynamicTableProp extends FormFrame {
|
|
248
|
+
componentParams: {
|
|
249
|
+
column: DynamicTableColumn[];
|
|
250
|
+
width: number;
|
|
251
|
+
};
|
|
252
|
+
}
|
|
253
|
+
interface DynamicTableColumn {
|
|
254
|
+
field: string;
|
|
255
|
+
title: string;
|
|
256
|
+
width: number;
|
|
257
|
+
editor: DynamicComponent;
|
|
258
|
+
[key: string]: any;
|
|
259
|
+
}
|
|
260
|
+
type DynamicComponent =
|
|
261
|
+
| 'FormCodeEditor'
|
|
262
|
+
| 'FormInput'
|
|
263
|
+
| 'FormInputNumber'
|
|
264
|
+
| 'FormSelect'
|
|
265
|
+
| 'FormSwitch'
|
|
266
|
+
| 'FormText'
|
|
267
|
+
| 'FormTextArea';
|
|
268
|
+
|
|
269
|
+
export type FormSwitch = FormFrame;
|
|
270
|
+
|
|
271
|
+
/** 文件选择器(单选) */
|
|
272
|
+
export interface FormFilePickerProp extends FormFrame {
|
|
273
|
+
fileType: FileType[];
|
|
274
|
+
maxNumber: number;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
/** 当值发生变化时通知 */
|
|
278
|
+
export interface NoticeData {
|
|
279
|
+
/** 需要通知的字段 */
|
|
280
|
+
field: string;
|
|
281
|
+
/** 当前 */
|
|
282
|
+
value: any;
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
/** 附件图片 */
|
|
286
|
+
export interface FileUpload {
|
|
287
|
+
id: string;
|
|
288
|
+
fileOriginalName: string;
|
|
289
|
+
type: string;
|
|
290
|
+
fileType: string;
|
|
291
|
+
disabled: boolean;
|
|
292
|
+
createBy: string;
|
|
293
|
+
createTime: string;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
export type FileUploadField = {
|
|
297
|
+
fieldName: string;
|
|
298
|
+
fieldTitle: string;
|
|
299
|
+
};
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { ElButtonPlus, ElColPlus, ElRowPlus, ToolBar, QueryBar, QueryDateTime, QueryInput, QueryInputLike, QuerySelect, QueryTreeFilter, TableInput, TableInputNumber, TableSelect, TableSelectAsync, TableSwitch, TableListSelect, TableCheckBoxAsync, TableRender, TableCardRender, FormInput, FormInputNumber, FormTextArea, FormText, FormSelect, FormSelectAsync, FormSelectRemote, FormRadio, FormCheckBox, FormCheckBoxAsync, FormSwitch, FormDatePicker, FormDateTimePicker, FormCascaderAsync, FormTableSelect, FormTableSelectAsync, FormDictSelector, FormIconPicker, FormCodeEditor, FormDivider, FormFieldset, FormDynamicTable, DynamicMapTable, FormRender, AppFormRender, DialogForm, DrawerForm, FileIsland, ApprovalRecord, FlowUserDialog, EmbeddedTable, EmbeddedDialogForm, ChartRender } from './index';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
declare module 'vue' {
|
|
5
|
+
export interface GlobalComponents {
|
|
6
|
+
ElButtonPlus: typeof ElButtonPlus;
|
|
7
|
+
ElColPlus: typeof ElColPlus;
|
|
8
|
+
ElRowPlus: typeof ElRowPlus;
|
|
9
|
+
ToolBar: typeof ToolBar;
|
|
10
|
+
QueryBar: typeof QueryBar;
|
|
11
|
+
QueryDateTime: typeof QueryDateTime;
|
|
12
|
+
QueryInput: typeof QueryInput;
|
|
13
|
+
QueryInputLike: typeof QueryInputLike;
|
|
14
|
+
QuerySelect: typeof QuerySelect;
|
|
15
|
+
QueryTreeFilter: typeof QueryTreeFilter;
|
|
16
|
+
TableInput: typeof TableInput;
|
|
17
|
+
TableInputNumber: typeof TableInputNumber;
|
|
18
|
+
TableSelect: typeof TableSelect;
|
|
19
|
+
TableSelectAsync: typeof TableSelectAsync;
|
|
20
|
+
TableSwitch: typeof TableSwitch;
|
|
21
|
+
TableListSelect: typeof TableListSelect;
|
|
22
|
+
TableCheckBoxAsync: typeof TableCheckBoxAsync;
|
|
23
|
+
TableRender: typeof TableRender;
|
|
24
|
+
TableCardRender: typeof TableCardRender;
|
|
25
|
+
FormInput: typeof FormInput;
|
|
26
|
+
FormInputNumber: typeof FormInputNumber;
|
|
27
|
+
FormTextArea: typeof FormTextArea;
|
|
28
|
+
FormText: typeof FormText;
|
|
29
|
+
FormSelect: typeof FormSelect;
|
|
30
|
+
FormSelectAsync: typeof FormSelectAsync;
|
|
31
|
+
FormSelectRemote: typeof FormSelectRemote;
|
|
32
|
+
FormRadio: typeof FormRadio;
|
|
33
|
+
FormCheckBox: typeof FormCheckBox;
|
|
34
|
+
FormCheckBoxAsync: typeof FormCheckBoxAsync;
|
|
35
|
+
FormSwitch: typeof FormSwitch;
|
|
36
|
+
FormDatePicker: typeof FormDatePicker;
|
|
37
|
+
FormDateTimePicker: typeof FormDateTimePicker;
|
|
38
|
+
FormCascaderAsync: typeof FormCascaderAsync;
|
|
39
|
+
FormTableSelect: typeof FormTableSelect;
|
|
40
|
+
FormTableSelectAsync: typeof FormTableSelectAsync;
|
|
41
|
+
FormDictSelector: typeof FormDictSelector;
|
|
42
|
+
FormIconPicker: typeof FormIconPicker;
|
|
43
|
+
FormCodeEditor: typeof FormCodeEditor;
|
|
44
|
+
FormDivider: typeof FormDivider;
|
|
45
|
+
FormFieldset: typeof FormFieldset;
|
|
46
|
+
FormDynamicTable: typeof FormDynamicTable;
|
|
47
|
+
DynamicMapTable: typeof DynamicMapTable;
|
|
48
|
+
FormRender: typeof FormRender;
|
|
49
|
+
AppFormRender: typeof AppFormRender;
|
|
50
|
+
DialogForm: typeof DialogForm;
|
|
51
|
+
DrawerForm: typeof DrawerForm;
|
|
52
|
+
FileIsland: typeof FileIsland;
|
|
53
|
+
ApprovalRecord: typeof ApprovalRecord;
|
|
54
|
+
FlowUserDialog: typeof FlowUserDialog;
|
|
55
|
+
EmbeddedTable: typeof EmbeddedTable;
|
|
56
|
+
EmbeddedDialogForm: typeof EmbeddedDialogForm;
|
|
57
|
+
ChartRender: typeof ChartRender;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export {};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,96 +1,12 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
placeholder?: string;
|
|
14
|
-
disabled?: boolean;
|
|
15
|
-
editRender?: {
|
|
16
|
-
name: string;
|
|
17
|
-
enabled?: boolean;
|
|
18
|
-
props?: Record<string, any>;
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
export interface TableSelectorProp extends TableComponentFrame {
|
|
22
|
-
editRender?: {
|
|
23
|
-
name: string;
|
|
24
|
-
enabled?: boolean;
|
|
25
|
-
props?: {
|
|
26
|
-
multiple?: boolean;
|
|
27
|
-
options?: Array<{
|
|
28
|
-
label: string;
|
|
29
|
-
value: any;
|
|
30
|
-
disabled?: boolean;
|
|
31
|
-
}>;
|
|
32
|
-
componentParams?: Record<string, any>;
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
export interface TableListSelectorProp extends TableComponentFrame {
|
|
37
|
-
editRender?: {
|
|
38
|
-
name: string;
|
|
39
|
-
props?: {
|
|
40
|
-
multiple?: boolean;
|
|
41
|
-
options?: Array<Record<string, any>>;
|
|
42
|
-
componentParams?: {
|
|
43
|
-
keyField?: string;
|
|
44
|
-
labelField?: string;
|
|
45
|
-
optionWidth?: number;
|
|
46
|
-
optionSlots?: Array<{
|
|
47
|
-
field: string;
|
|
48
|
-
label: string;
|
|
49
|
-
span: number;
|
|
50
|
-
}>;
|
|
51
|
-
} & Record<string, any>;
|
|
52
|
-
};
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
export interface TableQueryFrame {
|
|
56
|
-
fieldName: string;
|
|
57
|
-
fieldTitle: string;
|
|
58
|
-
queryEditor: string;
|
|
59
|
-
options?: Array<{
|
|
60
|
-
label: string;
|
|
61
|
-
value: any;
|
|
62
|
-
disabled?: boolean;
|
|
63
|
-
}>;
|
|
64
|
-
}
|
|
65
|
-
export interface TableConfigInterface {
|
|
66
|
-
rowKey: string;
|
|
67
|
-
titleField?: string;
|
|
68
|
-
coverField?: string;
|
|
69
|
-
tree?: boolean;
|
|
70
|
-
}
|
|
71
|
-
export interface Pagination {
|
|
72
|
-
currentPage: number;
|
|
73
|
-
pageSize: number;
|
|
74
|
-
total: number;
|
|
75
|
-
}
|
|
76
|
-
export interface QuerySelector {
|
|
77
|
-
options?: Array<{
|
|
78
|
-
label: string;
|
|
79
|
-
value: any;
|
|
80
|
-
disabled?: boolean;
|
|
81
|
-
}>;
|
|
82
|
-
}
|
|
83
|
-
export interface translateObj {
|
|
84
|
-
[key: string]: (value: any) => any;
|
|
85
|
-
}
|
|
86
|
-
export interface translateJSON {
|
|
87
|
-
[key: string]: {
|
|
88
|
-
label: string;
|
|
89
|
-
value: any;
|
|
90
|
-
}[];
|
|
91
|
-
}
|
|
92
|
-
export interface TableCheckBoxAsyncI18n {
|
|
93
|
-
save: string;
|
|
94
|
-
cancel: string;
|
|
95
|
-
close: string;
|
|
96
|
-
}
|
|
1
|
+
export type * from './api';
|
|
2
|
+
export type * from './app';
|
|
3
|
+
export type * from './button';
|
|
4
|
+
export type * from './cacheValue';
|
|
5
|
+
export type * from './chart';
|
|
6
|
+
export type * from './common';
|
|
7
|
+
export type * from './componentFrame';
|
|
8
|
+
export type * from './flowButton';
|
|
9
|
+
export type * from './formFrame';
|
|
10
|
+
export type * from './queryFrame';
|
|
11
|
+
export type * from './tableFrame';
|
|
12
|
+
export type * from './translate';
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { HttpMethod, OptionInterface } from './componentFrame';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
export interface QueryDataInterface {
|
|
5
|
+
[key: string]: QueryComponent;
|
|
6
|
+
}
|
|
7
|
+
export interface QueryComponent {
|
|
8
|
+
val: any;
|
|
9
|
+
queryType: QueryType;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
// 等于 包含 范围
|
|
13
|
+
type QueryType = 'equal' | 'hasAny' | 'like' | 'range';
|
|
14
|
+
|
|
15
|
+
/** 查询配置 */
|
|
16
|
+
export interface TableQueryFrame {
|
|
17
|
+
fieldName: string;
|
|
18
|
+
fieldTitle: string;
|
|
19
|
+
queryEditor: string;
|
|
20
|
+
options?: any[];
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export interface QuerySelector extends TableQueryFrame {
|
|
24
|
+
/** 是否多选 */
|
|
25
|
+
multiple?: boolean;
|
|
26
|
+
/** Http URL */
|
|
27
|
+
optionHttpUrl: string;
|
|
28
|
+
/** http方法 */
|
|
29
|
+
optionHttpMethod: HttpMethod;
|
|
30
|
+
/** http默认参数 */
|
|
31
|
+
optionHttpParams: any;
|
|
32
|
+
/** http其他字段 */
|
|
33
|
+
optionHttpParamsValue: string[];
|
|
34
|
+
/** 选项默认是空的 需要在render里面进行数据异步获取 不在组件内部进行数据获取 */
|
|
35
|
+
options: OptionInterface[];
|
|
36
|
+
}
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
import { ComponentFrame, HttpMethod, OptionInterface, Slots } from './componentFrame';
|
|
2
|
+
import { translateJSON, translateObj } from './translate';
|
|
3
|
+
import { KeFormTableSelectOption } from './index';
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
/** 表格基础配置 */
|
|
7
|
+
export interface TableConfigInterface {
|
|
8
|
+
/**
|
|
9
|
+
* 页面ID
|
|
10
|
+
*/
|
|
11
|
+
pageId?: number;
|
|
12
|
+
/** 主键 */
|
|
13
|
+
rowKey: string;
|
|
14
|
+
/** 是否tree table */
|
|
15
|
+
tree: boolean;
|
|
16
|
+
/** tree的父字段id */
|
|
17
|
+
parentField?: null | string;
|
|
18
|
+
/** tree默认值 */
|
|
19
|
+
treeDefault?: null | string;
|
|
20
|
+
/** 是否懒加载 */
|
|
21
|
+
treeLazyLoad?: boolean;
|
|
22
|
+
/** 某些特定参数,用于类似于异步下拉框取component的值时 */
|
|
23
|
+
params?: any;
|
|
24
|
+
/** 显示类型 */
|
|
25
|
+
showType: 'SidebarTable' | 'TableRender' | 'TableRenderCard';
|
|
26
|
+
/** 封面字段 showType为Card时生效(展示图片) */
|
|
27
|
+
coverField?: string;
|
|
28
|
+
/**
|
|
29
|
+
* 标题字段
|
|
30
|
+
*/
|
|
31
|
+
titleField?: string;
|
|
32
|
+
/**
|
|
33
|
+
* 是否有tree过滤器
|
|
34
|
+
*/
|
|
35
|
+
hasQueryTreeFilter: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* 允许拖拽排序
|
|
38
|
+
*/
|
|
39
|
+
dragSort?: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* 允许粘贴
|
|
42
|
+
*/
|
|
43
|
+
paste?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* 删除按钮
|
|
46
|
+
*/
|
|
47
|
+
deleteBtn?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* 弹出的窗口方式
|
|
50
|
+
*/
|
|
51
|
+
formWindow?: 'DialogForm' | 'DrawerForm';
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
type Fixed = 'left' | 'right';
|
|
55
|
+
|
|
56
|
+
export interface TableComponentFrame extends ComponentFrame {
|
|
57
|
+
/**
|
|
58
|
+
* 最小宽度
|
|
59
|
+
*/
|
|
60
|
+
minWidth: number;
|
|
61
|
+
/**
|
|
62
|
+
* 固定列位置
|
|
63
|
+
*/
|
|
64
|
+
fixed?: Fixed;
|
|
65
|
+
/**
|
|
66
|
+
* 允许拖拽
|
|
67
|
+
*/
|
|
68
|
+
sortable?: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* 是否禁用
|
|
71
|
+
*/
|
|
72
|
+
disabled?: boolean;
|
|
73
|
+
slots?: {
|
|
74
|
+
default: Slots;
|
|
75
|
+
};
|
|
76
|
+
editRender?: {
|
|
77
|
+
/**
|
|
78
|
+
* 组件名称
|
|
79
|
+
*/
|
|
80
|
+
name: string;
|
|
81
|
+
props: {
|
|
82
|
+
/** 组件其他参数 可参考element-plus或者vant的组件参数 */
|
|
83
|
+
componentParams?: {
|
|
84
|
+
[propName: string]: any;
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* 是否禁止编辑
|
|
88
|
+
*/
|
|
89
|
+
disabled: boolean;
|
|
90
|
+
};
|
|
91
|
+
};
|
|
92
|
+
/** 翻译类型 */
|
|
93
|
+
tabObj?: translateObj;
|
|
94
|
+
translate?: translateJSON;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
export interface TableSelectorProp extends TableComponentFrame {
|
|
98
|
+
editRender?: {
|
|
99
|
+
/**
|
|
100
|
+
* 组件名称
|
|
101
|
+
*/
|
|
102
|
+
name: string;
|
|
103
|
+
props: {
|
|
104
|
+
/** 组件其他参数 可参考element-plus或者vant的组件参数 */
|
|
105
|
+
componentParams?: {
|
|
106
|
+
[propName: string]: any;
|
|
107
|
+
};
|
|
108
|
+
/**
|
|
109
|
+
* 是否禁止编辑
|
|
110
|
+
*/
|
|
111
|
+
disabled: boolean;
|
|
112
|
+
/** 是否多选 */
|
|
113
|
+
multiple?: boolean;
|
|
114
|
+
/** http方法 */
|
|
115
|
+
optionHttpMethod: HttpMethod;
|
|
116
|
+
/** http默认参数 */
|
|
117
|
+
optionHttpParams: any;
|
|
118
|
+
/** http其他字段 */
|
|
119
|
+
optionHttpParamsValue: string[];
|
|
120
|
+
/** Http URL */
|
|
121
|
+
optionHttpUrl: string;
|
|
122
|
+
/** 选项默认是空的 需要在render里面进行数据异步获取 不在组件内部进行数据获取 */
|
|
123
|
+
options: OptionInterface[];
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
export interface TableListSelectorProp extends TableComponentFrame {
|
|
128
|
+
editRender: {
|
|
129
|
+
/**
|
|
130
|
+
* 组件名称
|
|
131
|
+
*/
|
|
132
|
+
name: string;
|
|
133
|
+
|
|
134
|
+
props: {
|
|
135
|
+
/** 组件其他参数 可参考element-plus或者vant的组件参数 */
|
|
136
|
+
componentParams: {
|
|
137
|
+
[propName: string]: any;
|
|
138
|
+
/**
|
|
139
|
+
* key字段
|
|
140
|
+
*/
|
|
141
|
+
keyField: string;
|
|
142
|
+
/**
|
|
143
|
+
* label字段
|
|
144
|
+
*/
|
|
145
|
+
labelField: string;
|
|
146
|
+
mode?: string;
|
|
147
|
+
optionSlots: KeFormTableSelectOption[];
|
|
148
|
+
/**
|
|
149
|
+
* option宽度
|
|
150
|
+
*/
|
|
151
|
+
optionWidth: number;
|
|
152
|
+
/**
|
|
153
|
+
* value字段
|
|
154
|
+
*/
|
|
155
|
+
valueField: string;
|
|
156
|
+
};
|
|
157
|
+
/**
|
|
158
|
+
* 是否禁止编辑
|
|
159
|
+
*/
|
|
160
|
+
disabled: boolean;
|
|
161
|
+
/** 是否多选 */
|
|
162
|
+
multiple?: boolean;
|
|
163
|
+
/** 下拉框选项 */
|
|
164
|
+
options: any[];
|
|
165
|
+
};
|
|
166
|
+
};
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
/**
|
|
170
|
+
* 分页
|
|
171
|
+
*/
|
|
172
|
+
export type Pagination = {
|
|
173
|
+
/**
|
|
174
|
+
* 当前页
|
|
175
|
+
*/
|
|
176
|
+
currentPage: number;
|
|
177
|
+
/**
|
|
178
|
+
* 页面大小
|
|
179
|
+
*/
|
|
180
|
+
pageSize: number;
|
|
181
|
+
/**
|
|
182
|
+
* 总数
|
|
183
|
+
*/
|
|
184
|
+
total: number;
|
|
185
|
+
};
|
|
186
|
+
|
|
187
|
+
export interface QueryFilterDTO {
|
|
188
|
+
/**
|
|
189
|
+
* 页面ID
|
|
190
|
+
*/
|
|
191
|
+
pageId: number;
|
|
192
|
+
/**
|
|
193
|
+
* 父id值
|
|
194
|
+
*/
|
|
195
|
+
pid: any;
|
|
196
|
+
}
|