@kengic/vue 0.26.6-beta.99 → 0.26.6
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/card-text-outline.6e053122.mjs +8 -0
- package/dist/index.css +1 -1
- package/dist/kengic-vue.js +52454 -51386
- package/dist/project/build/vite/plugin/index.ts +0 -1
- package/dist/src/component/KgAppSelect/index.event.d.ts +17 -0
- package/dist/src/component/KgAppSelect/index.hooks.d.ts +13 -11
- package/dist/src/component/KgAppSelect/index.store.d.ts +6 -21
- package/dist/src/component/KgButton/index.event.d.ts +27 -0
- package/dist/src/component/KgButton/index.hooks.d.ts +8 -6
- package/dist/src/component/KgButton/index.store.d.ts +8 -32
- package/dist/src/component/KgCanvas/KgCanvas.ContextMenu.d.ts +0 -3
- package/dist/src/component/KgCanvas/KgCanvas.d.ts +15 -0
- package/dist/src/component/KgCanvas/KgCanvas.service.d.ts +2 -2
- package/dist/src/component/KgCanvas/index.event.d.ts +213 -0
- package/dist/src/component/KgCanvas/index.hooks.d.ts +18 -13
- package/dist/src/component/KgCanvas/index.store.d.ts +0 -229
- package/dist/src/component/KgCanvas/index.vm.d.ts +4 -0
- package/dist/src/component/KgForm/index.event.d.ts +191 -0
- package/dist/src/component/KgForm/index.hooks.d.ts +17 -9
- package/dist/src/component/KgForm/index.store.d.ts +11 -177
- package/dist/src/component/KgForm.Item/KgForm.Item.service.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Checkbox.d.ts +3 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.CheckboxGroup.d.ts +3 -3
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Date.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.DateRange.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Input.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.InputNumber.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.InputPassword.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.RadioGroup.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Select.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.Switch.d.ts +1 -1
- package/dist/src/component/KgForm.Item/components/KgForm.Item.TextArea.d.ts +1 -1
- package/dist/src/component/KgSearch/KgSearch.service.d.ts +1 -1
- package/dist/src/component/KgSearch/index.event.d.ts +17 -0
- package/dist/src/component/KgSearch/index.hooks.d.ts +6 -5
- package/dist/src/component/KgSearch/index.store.d.ts +14 -29
- package/dist/src/component/KgSubmit/KgSubmit.service.d.ts +1 -1
- package/dist/src/component/KgSubmit/index.event.d.ts +105 -0
- package/dist/src/component/KgSubmit/index.hooks.d.ts +15 -13
- package/dist/src/component/KgSubmit/index.store.d.ts +13 -115
- package/dist/src/component/KgTable/KgTable.service.d.ts +2 -2
- package/dist/src/component/KgTable/index.event.d.ts +57 -0
- package/dist/src/component/KgTable/index.hooks.d.ts +13 -12
- package/dist/src/component/KgTable/index.store.d.ts +10 -63
- package/dist/src/component/KgVar/index.event.d.ts +60 -0
- package/dist/src/component/KgVar/index.hooks.d.ts +31 -3
- package/dist/src/component/KgVar/index.store.d.ts +1 -38
- package/dist/src/component/KgVar/index.vm.d.ts +16 -2
- package/dist/src/component/KgWarehouse/index.hooks.d.ts +3 -3
- package/dist/src/component/KgWarehouse/index.store.d.ts +6 -6
- package/dist/src/config/setup/setup.d.ts +1 -1
- package/dist/src/const/i18n/en.d.ts +1 -1
- package/dist/src/const/i18n/es_ES.d.ts +1 -1
- package/dist/src/const/i18n/fr_FR.d.ts +1 -1
- package/dist/src/const/i18n/km_KH.d.ts +1 -1
- package/dist/src/const/i18n/ko_KR.d.ts +1 -1
- package/dist/src/const/i18n/vi_VN.d.ts +1 -1
- package/dist/src/const/i18n/zh_CN.d.ts +1 -1
- package/dist/src/const/index.vm.d.ts +22 -24
- package/dist/src/const/injection-keys.const.d.ts +2 -0
- package/dist/src/index.d.ts +2 -2
- package/dist/src/util/index.d.ts +14 -0
- package/dist/src/util/kg-var.util.d.ts +14 -0
- package/dist/src/util/kg.util.d.ts +7 -5
- package/package.json +5 -4
- package/dist/src/component/KgSearch/components/KgSearch.ConfigModal.d.ts +0 -16
- package/dist/src/component/KgTable/components/setting/config/KgTable.Setting.ConfigModal.d.ts +0 -16
- package/dist/src/component/util.d.ts +0 -14
- /package/dist/{close-outlined-DMcSQWxQ.67071609.mjs → close-outlined-DMcSQWxQ.ecd794e3.mjs} +0 -0
- /package/dist/{fullscreen-exit-outlined-X1iYkFc4.3aba678f.mjs → fullscreen-exit-outlined-X1iYkFc4.81ef5f5d.mjs} +0 -0
- /package/dist/{fullscreen-outlined-DDBrsRcy.c4fdcf26.mjs → fullscreen-outlined-DDBrsRcy.678cfca5.mjs} +0 -0
@@ -1,238 +1,9 @@
|
|
1
|
-
import { Q } from '@thymine/xunee';
|
2
1
|
import { StoreDefinition } from 'pinia';
|
3
|
-
import { Ref } from 'vue';
|
4
|
-
import { IKgEventListener } from '../../const';
|
5
|
-
import { type IKgCanvasContextMenu } from './KgCanvas.ContextMenu';
|
6
|
-
/**
|
7
|
-
* 事件类型.
|
8
|
-
* 'onInit': 图形组件初始完成
|
9
|
-
* 'onReload': 重新加载
|
10
|
-
* 'onResize': 尺寸变化
|
11
|
-
* 'onMouseMove': 鼠标移动
|
12
|
-
* 'onMouseEnter': 鼠标进入
|
13
|
-
* 'onMouseLeave': 鼠标离开
|
14
|
-
* 'onClick': 单击鼠标左键
|
15
|
-
* 'onRightClick': 单击鼠标右键
|
16
|
-
* 'onContextMenuOpen': 右键菜单打开
|
17
|
-
* 'onContextMenuClose': 右键菜单关闭
|
18
|
-
*/
|
19
|
-
export declare type IKgCanvasEvent = 'onInit' | 'onReload' | 'onResize' | 'onMouseMove' | 'onMouseEnter' | 'onMouseLeave' | 'onClick' | 'onRightClick' | 'onContextMenuOpen' | 'onContextMenuClose';
|
20
|
-
export declare type IKgCanvasOnInitEventListenerParameter = {
|
21
|
-
/**
|
22
|
-
* Q.
|
23
|
-
*/
|
24
|
-
Q: typeof Q;
|
25
|
-
/**
|
26
|
-
* 图形组件对象.
|
27
|
-
*/
|
28
|
-
graph: Q.Graph;
|
29
|
-
eid: string;
|
30
|
-
};
|
31
|
-
export declare type IKgCanvasOnInitEventListener = ((param: IKgCanvasOnInitEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
32
|
-
export declare type IKgCanvasOnReloadEventListenerParameter = {
|
33
|
-
/**
|
34
|
-
* Q.
|
35
|
-
*/
|
36
|
-
Q: typeof Q;
|
37
|
-
eid: string;
|
38
|
-
/**
|
39
|
-
* 图形组件对象.
|
40
|
-
*/
|
41
|
-
graph: Q.Graph;
|
42
|
-
};
|
43
|
-
export declare type IKgCanvasOnReloadEventListener = ((param: IKgCanvasOnReloadEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
44
|
-
export declare type IKgCanvasOnResizeEventListenerParameter = {
|
45
|
-
/**
|
46
|
-
* Q.
|
47
|
-
*/
|
48
|
-
Q: typeof Q;
|
49
|
-
eid: string;
|
50
|
-
/**
|
51
|
-
* 图形组件对象.
|
52
|
-
*/
|
53
|
-
graph: Q.Graph;
|
54
|
-
/**
|
55
|
-
* 当前高度.
|
56
|
-
*/
|
57
|
-
height: number;
|
58
|
-
/**
|
59
|
-
* 当前宽度.
|
60
|
-
*/
|
61
|
-
width: number;
|
62
|
-
};
|
63
|
-
export declare type IKgCanvasOnResizeEventListener = ((param: IKgCanvasOnResizeEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
64
|
-
export declare type IKgCanvasOnRightClickEventListenerParameter = {
|
65
|
-
/**
|
66
|
-
* Q.
|
67
|
-
*/
|
68
|
-
Q: typeof Q;
|
69
|
-
/**
|
70
|
-
* <p>右键菜单列表.</p>
|
71
|
-
* <p>用户可以直接修改该参数的值, 从而修改此次单击右键事件弹出的右键菜单.</p>
|
72
|
-
*/
|
73
|
-
contextMenus: Ref<Array<IKgCanvasContextMenu>>;
|
74
|
-
eid: string;
|
75
|
-
/**
|
76
|
-
* 图元.
|
77
|
-
*/
|
78
|
-
element?: Q.Element;
|
79
|
-
/**
|
80
|
-
* 图元组件.
|
81
|
-
*/
|
82
|
-
elementUI?: Q.ElementUI;
|
83
|
-
/**
|
84
|
-
* 鼠标事件.
|
85
|
-
*/
|
86
|
-
event: MouseEvent;
|
87
|
-
/**
|
88
|
-
* 图形组件对象.
|
89
|
-
*/
|
90
|
-
graph: Q.Graph;
|
91
|
-
/**
|
92
|
-
* 图元组件.
|
93
|
-
*/
|
94
|
-
ui?: Q.BaseUI;
|
95
|
-
};
|
96
|
-
export declare type IKgCanvasOnRightClickEventListener = ((param: IKgCanvasOnRightClickEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
97
|
-
export declare type IKgCanvasOnMouseMoveEventListenerParameter = {
|
98
|
-
/**
|
99
|
-
* Q.
|
100
|
-
*/
|
101
|
-
Q: typeof Q;
|
102
|
-
eid: string;
|
103
|
-
/**
|
104
|
-
* 图元.
|
105
|
-
*/
|
106
|
-
element?: Q.Element;
|
107
|
-
/**
|
108
|
-
* 图元组件.
|
109
|
-
*/
|
110
|
-
elementUI?: Q.ElementUI;
|
111
|
-
/**
|
112
|
-
* 图形组件对象.
|
113
|
-
*/
|
114
|
-
graph: Q.Graph;
|
115
|
-
/**
|
116
|
-
* 图元组件.
|
117
|
-
*/
|
118
|
-
ui?: Q.BaseUI;
|
119
|
-
};
|
120
|
-
export declare type IKgCanvasOnMouseMoveEventListener = ((param: IKgCanvasOnMouseMoveEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
121
|
-
export declare type IKgCanvasOnMouseLeaveEventListenerParameter = {
|
122
|
-
/**
|
123
|
-
* Q.
|
124
|
-
*/
|
125
|
-
Q: typeof Q;
|
126
|
-
eid: string;
|
127
|
-
/**
|
128
|
-
* 图元.
|
129
|
-
*/
|
130
|
-
element?: Q.Element;
|
131
|
-
/**
|
132
|
-
* 图元组件.
|
133
|
-
*/
|
134
|
-
elementUI?: Q.ElementUI;
|
135
|
-
/**
|
136
|
-
* 图形组件对象.
|
137
|
-
*/
|
138
|
-
graph: Q.Graph;
|
139
|
-
/**
|
140
|
-
* 图元组件.
|
141
|
-
*/
|
142
|
-
ui?: Q.BaseUI;
|
143
|
-
};
|
144
|
-
export declare type IKgCanvasOnMouseLeaveEventListener = ((param: IKgCanvasOnMouseLeaveEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
145
|
-
export declare type IKgCanvasOnMouseEnterEventListenerParameter = {
|
146
|
-
/**
|
147
|
-
* Q.
|
148
|
-
*/
|
149
|
-
Q: typeof Q;
|
150
|
-
eid: string;
|
151
|
-
/**
|
152
|
-
* 图元.
|
153
|
-
*/
|
154
|
-
element?: Q.Element;
|
155
|
-
/**
|
156
|
-
* 图元组件.
|
157
|
-
*/
|
158
|
-
elementUI?: Q.ElementUI;
|
159
|
-
/**
|
160
|
-
* 图形组件对象.
|
161
|
-
*/
|
162
|
-
graph: Q.Graph;
|
163
|
-
/**
|
164
|
-
* 图元组件.
|
165
|
-
*/
|
166
|
-
ui?: Q.BaseUI;
|
167
|
-
};
|
168
|
-
export declare type IKgCanvasOnMouseEnterEventListener = ((param: IKgCanvasOnMouseEnterEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
169
|
-
export declare type IKgCanvasOnClickEventListenerParameter = {
|
170
|
-
/**
|
171
|
-
* Q.
|
172
|
-
*/
|
173
|
-
Q: typeof Q;
|
174
|
-
eid: string;
|
175
|
-
/**
|
176
|
-
* 图元.
|
177
|
-
*/
|
178
|
-
element?: Q.Element;
|
179
|
-
/**
|
180
|
-
* 图元组件.
|
181
|
-
*/
|
182
|
-
elementUI?: Q.ElementUI;
|
183
|
-
/**
|
184
|
-
* 图形组件对象.
|
185
|
-
*/
|
186
|
-
graph: Q.Graph;
|
187
|
-
/**
|
188
|
-
* 图元组件.
|
189
|
-
*/
|
190
|
-
ui?: Q.BaseUI;
|
191
|
-
};
|
192
|
-
export declare type IKgCanvasOnClickEventListener = ((param: IKgCanvasOnClickEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
193
|
-
export declare type IKgCanvasOnContextMenuOpenEventListenerParameter = {
|
194
|
-
eid: string;
|
195
|
-
};
|
196
|
-
export declare type IKgCanvasOnContextMenuOpenEventListener = ((param: IKgCanvasOnContextMenuOpenEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
197
|
-
export declare type IKgCanvasOnContextMenuCloseEventListenerParameter = {
|
198
|
-
eid: string;
|
199
|
-
};
|
200
|
-
export declare type IKgCanvasOnContextMenuCloseEventListener = ((param: IKgCanvasOnContextMenuCloseEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
201
|
-
export declare type IKgCanvasEventListenerParameter = IKgCanvasOnInitEventListenerParameter | IKgCanvasOnReloadEventListenerParameter | IKgCanvasOnResizeEventListenerParameter | IKgCanvasOnRightClickEventListenerParameter | IKgCanvasOnMouseMoveEventListenerParameter | IKgCanvasOnMouseEnterEventListenerParameter | IKgCanvasOnMouseLeaveEventListenerParameter | IKgCanvasOnClickEventListenerParameter | IKgCanvasOnContextMenuOpenEventListenerParameter | IKgCanvasOnContextMenuCloseEventListenerParameter;
|
202
|
-
export declare type IKgCanvasEventListener = IKgCanvasOnInitEventListener | IKgCanvasOnReloadEventListener | IKgCanvasOnResizeEventListener | IKgCanvasOnRightClickEventListener | IKgCanvasOnMouseMoveEventListener | IKgCanvasOnMouseEnterEventListener | IKgCanvasOnMouseLeaveEventListener | IKgCanvasOnClickEventListener | IKgCanvasOnContextMenuOpenEventListener | IKgCanvasOnContextMenuCloseEventListener;
|
203
2
|
export interface IUseKgCanvasStoreState {
|
204
|
-
onClickEventListenerMap: Map<string, Array<IKgCanvasOnClickEventListener>>;
|
205
|
-
onContextMenuCloseEventListenerMap: Map<string, Array<IKgCanvasOnContextMenuCloseEventListener>>;
|
206
|
-
onContextMenuOpenEventListenerMap: Map<string, Array<IKgCanvasOnContextMenuOpenEventListener>>;
|
207
|
-
onInitEventListenerMap: Map<string, Array<IKgCanvasOnInitEventListener>>;
|
208
|
-
onMouseEnterEventListenerMap: Map<string, Array<IKgCanvasOnMouseEnterEventListener>>;
|
209
|
-
onMouseLeaveEventListenerMap: Map<string, Array<IKgCanvasOnMouseLeaveEventListener>>;
|
210
|
-
onMouseMoveEventListenerMap: Map<string, Array<IKgCanvasOnMouseMoveEventListener>>;
|
211
|
-
onReloadEventListenerMap: Map<string, Array<IKgCanvasOnReloadEventListener>>;
|
212
|
-
onResizeEventListenerMap: Map<string, Array<IKgCanvasOnResizeEventListener>>;
|
213
|
-
onRightClickEventListenerMap: Map<string, Array<IKgCanvasOnRightClickEventListener>>;
|
214
3
|
}
|
215
4
|
export interface IUseKgCanvasStoreGetters {
|
216
5
|
}
|
217
6
|
export interface IUseKgCanvasStoreActions {
|
218
|
-
/**
|
219
|
-
* 注册事件监听.
|
220
|
-
* @param event 事件名称.
|
221
|
-
* @param listener 事件监听函数.
|
222
|
-
*/
|
223
|
-
addEventListener(event: IKgCanvasEvent, listener: any): void;
|
224
|
-
/**
|
225
|
-
* 触发事件.
|
226
|
-
* @param event 事件名称.
|
227
|
-
* @param param 参数.
|
228
|
-
*/
|
229
|
-
emit<T = IKgCanvasEventListenerParameter>(event: IKgCanvasEvent, param?: T | null): Promise<boolean>;
|
230
|
-
/**
|
231
|
-
* 退订事件监听.
|
232
|
-
* @param event 事件名称.
|
233
|
-
* @param listener 事件监听函数.
|
234
|
-
*/
|
235
|
-
removeEventListener(event: IKgCanvasEvent, listener?: any): void;
|
236
7
|
}
|
237
8
|
export declare type IUseKgCanvasStore = StoreDefinition<'KgCanvas', IUseKgCanvasStoreState, IUseKgCanvasStoreGetters, IUseKgCanvasStoreActions>;
|
238
9
|
export declare type IKgCanvasStore = ReturnType<IUseKgCanvasStore>;
|
@@ -1,6 +1,10 @@
|
|
1
1
|
import { Q } from '@thymine/xunee';
|
2
2
|
import { InjectionKey } from 'vue';
|
3
3
|
export declare const KG__DI__KG_CANVAS_PROPS: InjectionKey<Partial<import("vue").ExtractPropTypes<{
|
4
|
+
id: {
|
5
|
+
type: import("vue").PropType<string>;
|
6
|
+
required: boolean;
|
7
|
+
};
|
4
8
|
kgCanvasToolbarFullscreen: {
|
5
9
|
type: import("vue").PropType<Partial<import("vue").ExtractPropTypes<{
|
6
10
|
kgIsShowText: {
|
@@ -0,0 +1,191 @@
|
|
1
|
+
import { IKgEventListener } from '@kengic/core.core';
|
2
|
+
import { ComputedRef, Ref } from 'vue';
|
3
|
+
import { KG_FORM_CONTEXT } from '../../const';
|
4
|
+
import { IKgTableRow } from '../KgTable';
|
5
|
+
/**
|
6
|
+
* 事件类型.
|
7
|
+
* 'onChange': 表单控件的值发生变更
|
8
|
+
* 'onBlur': 失去焦点
|
9
|
+
* 'onSelectBeforeRequest': 即将发起查询请求, 如果返回 true 表示不会发起请求,
|
10
|
+
* 'onSelectBeforeSetDatas': 下拉列表查询请求成功, 列表数据尚未赋值. 此处可以对查询接口返回的列表数据作处理
|
11
|
+
* 'onSelectChange': 下拉列表选中某个(可能多个)数据
|
12
|
+
* 'onLookupBeforeOpen': 查找弹窗打开之前
|
13
|
+
* 'onLookupBeforeOk': 查找弹窗点击确定之前. 如果返回 true 则查找弹窗不会触发 kgOk 事件
|
14
|
+
* 'onLookupOk': 查找弹窗点击确定
|
15
|
+
*/
|
16
|
+
export declare type IKgFormEvent = 'onChange' | 'onBlur' | 'onSelectBeforeRequest' | 'onSelectBeforeSetDatas' | 'onSelectChange' | 'onLookupBeforeOpen' | 'onLookupBeforeOk' | 'onLookupOk';
|
17
|
+
export declare type IKgFormOnChangeEventListenerParameter = {
|
18
|
+
/**
|
19
|
+
* 表单控件所处环境.
|
20
|
+
*/
|
21
|
+
context: KG_FORM_CONTEXT;
|
22
|
+
/** @deprecated */
|
23
|
+
isCopying: boolean | null;
|
24
|
+
/** @deprecated */
|
25
|
+
isCreating: boolean | null;
|
26
|
+
/** @deprecated */
|
27
|
+
isDeleting: boolean | null;
|
28
|
+
/** @deprecated */
|
29
|
+
isUpdating: boolean | null;
|
30
|
+
/**
|
31
|
+
* 表单控件当前数据.
|
32
|
+
*/
|
33
|
+
value: any;
|
34
|
+
/**
|
35
|
+
* 变量名称.
|
36
|
+
*/
|
37
|
+
varName: string;
|
38
|
+
/** @deprecated */
|
39
|
+
variableName: string;
|
40
|
+
};
|
41
|
+
export declare type IKgFormOnChangeEventListener = ((param: IKgFormOnChangeEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
42
|
+
export declare type IKgFormOnBlurEventListenerParameter = {
|
43
|
+
/**
|
44
|
+
* 表单控件所处环境.
|
45
|
+
*/
|
46
|
+
context: KG_FORM_CONTEXT;
|
47
|
+
/** @deprecated */
|
48
|
+
value: any;
|
49
|
+
/**
|
50
|
+
* 表单控件当前数据.
|
51
|
+
*/
|
52
|
+
values: Array<any>;
|
53
|
+
/**
|
54
|
+
* 变量名称.
|
55
|
+
*/
|
56
|
+
varName: string;
|
57
|
+
};
|
58
|
+
export declare type IKgFormOnBlurEventListener = ((param: IKgFormOnBlurEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
59
|
+
export declare type IKgFormOnSelectBeforeRequestEventListenerParameter = {
|
60
|
+
/**
|
61
|
+
* 表单控件所处环境.
|
62
|
+
*/
|
63
|
+
context: KG_FORM_CONTEXT;
|
64
|
+
/** 查询接口请求参数. */
|
65
|
+
params: Record<string, any>;
|
66
|
+
/** 查询接口返回的数据, 调用者可以直接修改该数据, 从而实现手动提供列表数据. */
|
67
|
+
response: Ref;
|
68
|
+
/**
|
69
|
+
* 变量名称.
|
70
|
+
*/
|
71
|
+
varName: string;
|
72
|
+
};
|
73
|
+
export declare type IKgFormOnSelectBeforeRequestEventListener = ((param: IKgFormOnSelectBeforeRequestEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
74
|
+
export declare type IKgFormOnSelectBeforeSetDatasEventListenerParameter<T = any> = {
|
75
|
+
/**
|
76
|
+
* 表单控件所处环境.
|
77
|
+
*/
|
78
|
+
context: KG_FORM_CONTEXT;
|
79
|
+
/** 列表数据. */
|
80
|
+
datas: Ref<Array<T>>;
|
81
|
+
/** @deprecated */
|
82
|
+
isCopying: boolean | null;
|
83
|
+
/** @deprecated */
|
84
|
+
isCreating: boolean | null;
|
85
|
+
/** @deprecated */
|
86
|
+
isDeleting: boolean | null;
|
87
|
+
/** @deprecated */
|
88
|
+
isUpdating: boolean | null;
|
89
|
+
/** 变量名称. */
|
90
|
+
varName: string;
|
91
|
+
};
|
92
|
+
export declare type IKgFormOnSelectBeforeSetDatasEventListener = ((param: IKgFormOnSelectBeforeSetDatasEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
93
|
+
export declare type IKgFormOnSelectChangeEventListenerParameter = {
|
94
|
+
/**
|
95
|
+
* 表单控件所处环境.
|
96
|
+
*/
|
97
|
+
context: KG_FORM_CONTEXT;
|
98
|
+
/** @deprecated */
|
99
|
+
isCopying: boolean | null;
|
100
|
+
/** @deprecated */
|
101
|
+
isCreating: boolean | null;
|
102
|
+
/** @deprecated */
|
103
|
+
isDeleting: boolean | null;
|
104
|
+
/** 是否多选, 否则单选. */
|
105
|
+
isMultiple: boolean;
|
106
|
+
/** @deprecated */
|
107
|
+
isUpdating: boolean | null;
|
108
|
+
/** @deprecated */
|
109
|
+
model: Ref<Record<string, any> | null> | null;
|
110
|
+
/**
|
111
|
+
* 表单数据对象.
|
112
|
+
* @deprecated
|
113
|
+
*/
|
114
|
+
formModel: Ref<Record<string, any> | null> | null;
|
115
|
+
/** 选中的数据对象组成的数组, 如果是单选则数组中只有一个数据对象. */
|
116
|
+
rows: Array<any> | null;
|
117
|
+
/** 选中的数据组成的数组, 如果是单选则数组中只有一个数据. */
|
118
|
+
values: Array<any>;
|
119
|
+
/** 变量. */
|
120
|
+
var_nam: string;
|
121
|
+
};
|
122
|
+
export declare type IKgFormOnSelectChangeEventListener = ((param: IKgFormOnSelectChangeEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
123
|
+
export declare type IKgFormOnLookupBeforeOpenEventListenerParameter = {
|
124
|
+
/**
|
125
|
+
* 表单控件所处环境.
|
126
|
+
*/
|
127
|
+
context: KG_FORM_CONTEXT;
|
128
|
+
/** 查找弹出的界面标识. */
|
129
|
+
lookupFormID: string;
|
130
|
+
/** 变量. */
|
131
|
+
var_nam: string;
|
132
|
+
};
|
133
|
+
export declare type IKgFormOnLookupBeforeOpenEventListener = ((param: IKgFormOnLookupBeforeOpenEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
134
|
+
export declare type IKgFormOnLookupBeforeOkEventListenerParameter = {
|
135
|
+
/**
|
136
|
+
* 表单控件所处环境.
|
137
|
+
*/
|
138
|
+
context: KG_FORM_CONTEXT;
|
139
|
+
/** 是否多选, 否则单选. */
|
140
|
+
isMultiple: boolean;
|
141
|
+
/**
|
142
|
+
* 单选时, 勾选的那一行.
|
143
|
+
* @deprecated 请直接使用属性 rows.
|
144
|
+
*/
|
145
|
+
row?: IKgTableRow | null;
|
146
|
+
/** 勾选的所有行. */
|
147
|
+
rows?: Array<IKgTableRow> | null;
|
148
|
+
/**
|
149
|
+
* 单选时, 对应的一个值.
|
150
|
+
* @deprecated 请直接使用属性 values.
|
151
|
+
*/
|
152
|
+
value?: any | null;
|
153
|
+
/** 勾选的所有值. */
|
154
|
+
values?: Array<any> | null;
|
155
|
+
/** 变量. */
|
156
|
+
varNam: string;
|
157
|
+
/** @deprecated. */
|
158
|
+
var_nam: string;
|
159
|
+
};
|
160
|
+
export declare type IKgFormOnLookupBeforeOkEventListener = ((param: IKgFormOnLookupBeforeOkEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
161
|
+
export declare type IKgFormOnLookupOkEventListenerParameter = {
|
162
|
+
/**
|
163
|
+
* 表单控件所处环境.
|
164
|
+
*/
|
165
|
+
context: KG_FORM_CONTEXT;
|
166
|
+
/** 是否多选, 否则单选. */
|
167
|
+
isMultiple: boolean;
|
168
|
+
/** 表单数据对象. */
|
169
|
+
model: ComputedRef<Record<string, any>>;
|
170
|
+
/**
|
171
|
+
* 单选时, 勾选的那一行.
|
172
|
+
* @deprecated 请直接使用属性 rows.
|
173
|
+
*/
|
174
|
+
row?: IKgTableRow | null;
|
175
|
+
/** 勾选的所有行. */
|
176
|
+
rows?: Array<IKgTableRow> | null;
|
177
|
+
/**
|
178
|
+
* 单选时, 对应的一个值.
|
179
|
+
* @deprecated 请直接使用属性 values.
|
180
|
+
*/
|
181
|
+
value?: any | null;
|
182
|
+
/** 勾选的所有值. */
|
183
|
+
values?: Array<any> | null;
|
184
|
+
/** 变量. */
|
185
|
+
varNam: string;
|
186
|
+
/** @deprecated. */
|
187
|
+
var_nam: string;
|
188
|
+
};
|
189
|
+
export declare type IKgFormOnLookupOkEventListener = ((param: IKgFormOnLookupOkEventListenerParameter) => Promise<boolean>) & IKgEventListener;
|
190
|
+
export declare type IKgFormEventListenerParameter = IKgFormOnChangeEventListenerParameter | IKgFormOnBlurEventListenerParameter | IKgFormOnSelectBeforeRequestEventListenerParameter | IKgFormOnSelectBeforeSetDatasEventListenerParameter | IKgFormOnSelectChangeEventListenerParameter | IKgFormOnLookupBeforeOpenEventListenerParameter | IKgFormOnLookupBeforeOkEventListenerParameter | IKgFormOnLookupOkEventListenerParameter;
|
191
|
+
export declare type IKgFormEventListener = IKgFormOnChangeEventListener | IKgFormOnBlurEventListener | IKgFormOnSelectBeforeRequestEventListener | IKgFormOnSelectBeforeSetDatasEventListener | IKgFormOnSelectChangeEventListener | IKgFormOnLookupBeforeOpenEventListener | IKgFormOnLookupBeforeOkEventListener | IKgFormOnLookupOkEventListener;
|
@@ -1,5 +1,6 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
1
|
+
import { IRemoveEventListener } from '@kengic/core.core';
|
2
|
+
import { IKgFormOnBlurEventListener, IKgFormOnChangeEventListener, IKgFormOnLookupBeforeOkEventListener, IKgFormOnLookupBeforeOpenEventListener, IKgFormOnLookupOkEventListener, IKgFormOnSelectBeforeRequestEventListener, IKgFormOnSelectBeforeSetDatasEventListener, IKgFormOnSelectChangeEventListener } from './index.event';
|
3
|
+
import { IKgFormStore } from './index.store';
|
3
4
|
export declare type IUseKgForm = {
|
4
5
|
Select: {
|
5
6
|
/**
|
@@ -12,34 +13,41 @@ export declare type IUseKgForm = {
|
|
12
13
|
}): void;
|
13
14
|
};
|
14
15
|
formID: string;
|
16
|
+
/**
|
17
|
+
* 监听事件: 失去焦点.
|
18
|
+
*
|
19
|
+
* @param listener 事件监听函数.
|
20
|
+
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
21
|
+
*/
|
22
|
+
onBlur(listener: IKgFormOnBlurEventListener, isOnce?: boolean): IRemoveEventListener;
|
15
23
|
/**
|
16
24
|
* 监听事件: 表单控件的值发生变更.
|
17
25
|
*
|
18
26
|
* @param listener 事件监听函数.
|
19
27
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
20
28
|
*/
|
21
|
-
onChange(listener:
|
29
|
+
onChange(listener: IKgFormOnChangeEventListener, isOnce?: boolean): IRemoveEventListener;
|
22
30
|
/**
|
23
31
|
* 监听事件: 查找弹窗点击确定之前. 如果返回 true 则查找弹窗不会触发 kgOk 事件.
|
24
32
|
*
|
25
33
|
* @param listener 事件监听函数.
|
26
34
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
27
35
|
*/
|
28
|
-
onLookupBeforeOk(listener:
|
36
|
+
onLookupBeforeOk(listener: IKgFormOnLookupBeforeOkEventListener, isOnce?: boolean): IRemoveEventListener;
|
29
37
|
/**
|
30
38
|
* 监听事件: 查找弹窗打开之前.
|
31
39
|
*
|
32
40
|
* @param listener 事件监听函数.
|
33
41
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
34
42
|
*/
|
35
|
-
onLookupBeforeOpen(listener:
|
43
|
+
onLookupBeforeOpen(listener: IKgFormOnLookupBeforeOpenEventListener, isOnce?: boolean): IRemoveEventListener;
|
36
44
|
/**
|
37
45
|
* 监听事件: 查找弹窗点击确定.
|
38
46
|
*
|
39
47
|
* @param listener 事件监听函数.
|
40
48
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
41
49
|
*/
|
42
|
-
onLookupOk(listener:
|
50
|
+
onLookupOk(listener: IKgFormOnLookupOkEventListener, isOnce?: boolean): IRemoveEventListener;
|
43
51
|
/**
|
44
52
|
* <p>监听事件: 即将发起查询请求, 如果返回 true 表示不会发起请求.</p>
|
45
53
|
* <p>通常在该事件中, 通过给 <code>response.value</code> 赋值, 来实现自定义下拉列表数据. 注意此时必须返回 true 来跳过后续的列表数据查询.</p>
|
@@ -47,21 +55,21 @@ export declare type IUseKgForm = {
|
|
47
55
|
* @param callback 事件监听函数.
|
48
56
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
49
57
|
*/
|
50
|
-
onSelectBeforeRequest(callback:
|
58
|
+
onSelectBeforeRequest(callback: IKgFormOnSelectBeforeRequestEventListener, isOnce?: boolean): IRemoveEventListener;
|
51
59
|
/**
|
52
60
|
* 监听事件: 查询请求成功, 列表数据尚未赋值. 此处可以对查询接口返回的列表数据作处理.
|
53
61
|
*
|
54
62
|
* @param callback 事件监听函数.
|
55
63
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
56
64
|
*/
|
57
|
-
onSelectBeforeSetDatas(callback:
|
65
|
+
onSelectBeforeSetDatas(callback: IKgFormOnSelectBeforeSetDatasEventListener, isOnce?: boolean): IRemoveEventListener;
|
58
66
|
/**
|
59
67
|
* 监听事件: 下拉列表选中某个(可能多个)数据.
|
60
68
|
*
|
61
69
|
* @param listener 事件监听函数.
|
62
70
|
* @param isOnce 是否只会触发一次. 默认为 undefined.
|
63
71
|
*/
|
64
|
-
onSelectChange(listener:
|
72
|
+
onSelectChange(listener: IKgFormOnSelectChangeEventListener, isOnce?: boolean): IRemoveEventListener;
|
65
73
|
/**
|
66
74
|
* 状态数据.
|
67
75
|
*/
|