@kengic/vue 0.16.7 → 0.19.0
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +32 -16
- package/dist/index.css +1 -1
- package/dist/kengic-vue.js +5058 -4029
- package/dist/src/apis/WMS/Controllers/SysPermissionController/List.d.ts +73 -0
- package/dist/src/apis/WMS/Controllers/SysPermissionController/index.d.ts +1 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/Create.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/GetResultSetMetadataFromSql.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/ValidateCopySql.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/ValidateCreateSql.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/ValidateDeleteSql.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/ValidateFrmId.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/ValidateSearchSql.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/ValidateUpdateSql.d.ts +16 -0
- package/dist/src/apis/WMS/Controllers/VarDdaController/index.d.ts +8 -0
- package/dist/src/apis/WMS/Controllers/index.d.ts +2 -0
- package/dist/src/apis/WMS/models.d.ts +206 -2
- package/dist/src/components/KgSubmit/index.hooks.d.ts +3 -3
- package/dist/src/components/KgSubmit/index.store.d.ts +11 -11
- package/dist/src/components/KgTable/index.hooks.d.ts +7 -7
- package/dist/src/components/KgTable/index.store.d.ts +485 -45
- package/dist/src/components/KgTable/index.vm.d.ts +3 -3
- package/dist/src/config/index.hooks.d.ts +76 -15
- package/dist/src/config/index.store.d.ts +2 -2
- package/dist/src/consts/i18n/en.d.ts +8 -5
- package/dist/src/consts/i18n/zh_CN.d.ts +8 -5
- package/dist/src/pages/KgPageDda/components/KgPageDda.Create.Menu.d.ts +1 -1
- package/dist/src/pages/KgPageDda/components/KgPageDda.Create.Submit.d.ts +1 -1
- package/dist/src/pages/KgPageDda/components/KgPageDda.Create.Table.d.ts +1 -1
- package/dist/src/pages/KgPageDda/components/KgPageDda.Create.d.ts +5 -1
- package/dist/src/pages/KgPageDda/components/KgPageDda.Create.store.d.ts +1643 -26
- package/dist/src/pages/KgPageDda/index.const.d.ts +1 -1
- package/dist/src/utils/kg-route.util.d.ts +1 -1
- package/package.json +2 -1
@@ -1,5 +1,4 @@
|
|
1
1
|
import { Key } from 'ant-design-vue/lib/_util/type';
|
2
|
-
import { StoreDefinition } from 'pinia';
|
3
2
|
import { Ref } from 'vue';
|
4
3
|
import { IPage } from '../../apis/WMS/models';
|
5
4
|
import { IKgEventCb } from '../../consts';
|
@@ -34,8 +33,6 @@ export declare type IKgTableBeforeSearchCb = ((param: IKgTableBeforeSearchCbPara
|
|
34
33
|
export declare type IKgTableBeforeSetDatasCbParam = {
|
35
34
|
/** 列表数据. */
|
36
35
|
datas: Ref<Array<IKgTableRow>>;
|
37
|
-
/** 设置列表数据. */
|
38
|
-
setDatas(datas: Array<IKgTableRow>): void;
|
39
36
|
};
|
40
37
|
export declare type IKgTableBeforeSetDatasCb = ((param: IKgTableBeforeSetDatasCbParam) => Promise<boolean>) & IKgEventCb;
|
41
38
|
/** 事件监听函数: afterSearch. */
|
@@ -46,24 +43,19 @@ export declare type IKgTableAfterSearchCbParam = {
|
|
46
43
|
response: IPage<IKgTableRow> | null | undefined;
|
47
44
|
/** 列表数据. */
|
48
45
|
datas: Ref<Array<IKgTableRow>>;
|
49
|
-
/**
|
50
|
-
* 设置列表数据的方法.
|
51
|
-
* 在事件的回调函数中, 可以直接调用该方法来手动设置列表数据, 该方法内部实际上就是调用的 kgTable.store.setDatas() 方法.
|
52
|
-
*/
|
53
|
-
setDatas<T = IKgTableRow>(datas: Array<T>): void;
|
54
46
|
};
|
55
47
|
export declare type IKgTableAfterSearchCb = ((param: IKgTableAfterSearchCbParam) => Promise<boolean>) & IKgEventCb;
|
56
48
|
export declare type IKgTableCbParam = IKgTableReadyParam | IKgTableRowDoubleClickParam | IKgTableBeforeSearchCbParam | IKgTableBeforeSetDatasCbParam | IKgTableAfterSearchCbParam;
|
57
49
|
export declare type IKgTableCb = IKgTableReadyCb | IKgTableRowDoubleClickCb | IKgTableBeforeSearchCb | IKgTableBeforeSetDatasCb | IKgTableAfterSearchCb;
|
58
|
-
export
|
50
|
+
export declare const useKgTableStore: import("pinia").StoreDefinition<"KgTable", {
|
59
51
|
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
60
52
|
isReadyMap: Map<string, boolean>;
|
61
53
|
/** 列表数据. */
|
62
|
-
datasMap: Map<String,
|
54
|
+
datasMap: Map<String, any[]>;
|
63
55
|
/** 勾选的行的主键. */
|
64
|
-
selectedRowKeysMap: Map<string, Ref<
|
56
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
65
57
|
/** 勾选的行. */
|
66
|
-
selectedRowsMap: Map<string,
|
58
|
+
selectedRowsMap: Map<string, any[]>;
|
67
59
|
/**
|
68
60
|
* 是否已经查询过一次了.
|
69
61
|
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
@@ -77,42 +69,487 @@ export interface IKgTableState {
|
|
77
69
|
/** 行高. */
|
78
70
|
rowHeightMap: Map<string, IKgTableRowHeight>;
|
79
71
|
/** 事件监听函数列表: ready. */
|
80
|
-
onReadyListenersMap: Map<string,
|
72
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
81
73
|
/** '双击某行'事件监听函数列表. */
|
82
|
-
rowDoubleClickListenersMap: Map<string,
|
83
|
-
beforeSearchListenersMap: Map<string,
|
84
|
-
beforeSetDatasListenersMap: Map<string,
|
85
|
-
afterSearchListenersMap: Map<string,
|
86
|
-
}
|
87
|
-
export declare type IKgTableStoreDefinition = StoreDefinition<'KgTable', IKgTableState, {
|
74
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
75
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
76
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
77
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
78
|
+
}, {
|
88
79
|
/** 是否就绪. */
|
89
|
-
getIsReady(
|
80
|
+
getIsReady(state: {
|
81
|
+
isReadyMap: Map<string, boolean>;
|
82
|
+
datasMap: Map<String, any[]>;
|
83
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
84
|
+
selectedRowsMap: Map<string, any[]>;
|
85
|
+
isSearchedMap: Map<string, boolean>;
|
86
|
+
isRetrievingMap: Map<string, boolean>;
|
87
|
+
tableWidthMap: Map<string, number>;
|
88
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
89
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
90
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
91
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
92
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
93
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
94
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
95
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
96
|
+
isReadyMap: Map<string, boolean>;
|
97
|
+
/** 列表数据. */
|
98
|
+
datasMap: Map<String, any[]>;
|
99
|
+
/** 勾选的行的主键. */
|
100
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
101
|
+
/** 勾选的行. */
|
102
|
+
selectedRowsMap: Map<string, any[]>;
|
103
|
+
/**
|
104
|
+
* 是否已经查询过一次了.
|
105
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
106
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
107
|
+
*/
|
108
|
+
isSearchedMap: Map<string, boolean>;
|
109
|
+
/** 是否正在查询. */
|
110
|
+
isRetrievingMap: Map<string, boolean>;
|
111
|
+
/** 表格宽度. */
|
112
|
+
tableWidthMap: Map<string, number>;
|
113
|
+
/** 行高. */
|
114
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
115
|
+
/** 事件监听函数列表: ready. */
|
116
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
117
|
+
/** '双击某行'事件监听函数列表. */
|
118
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
119
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
120
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
121
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
122
|
+
}>): (formID: string | null | undefined) => boolean;
|
90
123
|
/** 列表数据. */
|
91
|
-
getDatas(
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
124
|
+
getDatas(state: {
|
125
|
+
isReadyMap: Map<string, boolean>;
|
126
|
+
datasMap: Map<String, any[]>;
|
127
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
128
|
+
selectedRowsMap: Map<string, any[]>;
|
129
|
+
isSearchedMap: Map<string, boolean>;
|
130
|
+
isRetrievingMap: Map<string, boolean>;
|
131
|
+
tableWidthMap: Map<string, number>;
|
132
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
133
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
134
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
135
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
136
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
137
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
138
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
139
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
140
|
+
isReadyMap: Map<string, boolean>;
|
141
|
+
/** 列表数据. */
|
142
|
+
datasMap: Map<String, any[]>;
|
143
|
+
/** 勾选的行的主键. */
|
144
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
145
|
+
/** 勾选的行. */
|
146
|
+
selectedRowsMap: Map<string, any[]>;
|
147
|
+
/**
|
148
|
+
* 是否已经查询过一次了.
|
149
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
150
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
151
|
+
*/
|
152
|
+
isSearchedMap: Map<string, boolean>;
|
153
|
+
/** 是否正在查询. */
|
154
|
+
isRetrievingMap: Map<string, boolean>;
|
155
|
+
/** 表格宽度. */
|
156
|
+
tableWidthMap: Map<string, number>;
|
157
|
+
/** 行高. */
|
158
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
159
|
+
/** 事件监听函数列表: ready. */
|
160
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
161
|
+
/** '双击某行'事件监听函数列表. */
|
162
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
163
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
164
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
165
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
166
|
+
}>): <T = IKgTableRow>(formID: string | null | undefined) => T[];
|
167
|
+
/** 当前勾选的行的主键. */
|
168
|
+
getSelectedRowKeys(state: {
|
169
|
+
isReadyMap: Map<string, boolean>;
|
170
|
+
datasMap: Map<String, any[]>;
|
171
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
172
|
+
selectedRowsMap: Map<string, any[]>;
|
173
|
+
isSearchedMap: Map<string, boolean>;
|
174
|
+
isRetrievingMap: Map<string, boolean>;
|
175
|
+
tableWidthMap: Map<string, number>;
|
176
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
177
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
178
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
179
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
180
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
181
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
182
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
183
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
184
|
+
isReadyMap: Map<string, boolean>;
|
185
|
+
/** 列表数据. */
|
186
|
+
datasMap: Map<String, any[]>;
|
187
|
+
/** 勾选的行的主键. */
|
188
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
189
|
+
/** 勾选的行. */
|
190
|
+
selectedRowsMap: Map<string, any[]>;
|
191
|
+
/**
|
192
|
+
* 是否已经查询过一次了.
|
193
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
194
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
195
|
+
*/
|
196
|
+
isSearchedMap: Map<string, boolean>;
|
197
|
+
/** 是否正在查询. */
|
198
|
+
isRetrievingMap: Map<string, boolean>;
|
199
|
+
/** 表格宽度. */
|
200
|
+
tableWidthMap: Map<string, number>;
|
201
|
+
/** 行高. */
|
202
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
203
|
+
/** 事件监听函数列表: ready. */
|
204
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
205
|
+
/** '双击某行'事件监听函数列表. */
|
206
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
207
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
208
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
209
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
210
|
+
}>): (formID: string | null | undefined) => Ref<Array<Key>>;
|
211
|
+
/** 当前勾选的行. */
|
212
|
+
getSelectedRows(state: {
|
213
|
+
isReadyMap: Map<string, boolean>;
|
214
|
+
datasMap: Map<String, any[]>;
|
215
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
216
|
+
selectedRowsMap: Map<string, any[]>;
|
217
|
+
isSearchedMap: Map<string, boolean>;
|
218
|
+
isRetrievingMap: Map<string, boolean>;
|
219
|
+
tableWidthMap: Map<string, number>;
|
220
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
221
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
222
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
223
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
224
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
225
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
226
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
227
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
228
|
+
isReadyMap: Map<string, boolean>;
|
229
|
+
/** 列表数据. */
|
230
|
+
datasMap: Map<String, any[]>;
|
231
|
+
/** 勾选的行的主键. */
|
232
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
233
|
+
/** 勾选的行. */
|
234
|
+
selectedRowsMap: Map<string, any[]>;
|
235
|
+
/**
|
236
|
+
* 是否已经查询过一次了.
|
237
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
238
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
239
|
+
*/
|
240
|
+
isSearchedMap: Map<string, boolean>;
|
241
|
+
/** 是否正在查询. */
|
242
|
+
isRetrievingMap: Map<string, boolean>;
|
243
|
+
/** 表格宽度. */
|
244
|
+
tableWidthMap: Map<string, number>;
|
245
|
+
/** 行高. */
|
246
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
247
|
+
/** 事件监听函数列表: ready. */
|
248
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
249
|
+
/** '双击某行'事件监听函数列表. */
|
250
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
251
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
252
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
253
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
254
|
+
}>): (formID: string | null | undefined) => Array<IKgTableRow> | null;
|
96
255
|
/** 当前勾选的第一行. */
|
97
|
-
getSelectedFirstRow(
|
256
|
+
getSelectedFirstRow(state: {
|
257
|
+
isReadyMap: Map<string, boolean>;
|
258
|
+
datasMap: Map<String, any[]>;
|
259
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
260
|
+
selectedRowsMap: Map<string, any[]>;
|
261
|
+
isSearchedMap: Map<string, boolean>;
|
262
|
+
isRetrievingMap: Map<string, boolean>;
|
263
|
+
tableWidthMap: Map<string, number>;
|
264
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
265
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
266
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
267
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
268
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
269
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
270
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
271
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
272
|
+
isReadyMap: Map<string, boolean>;
|
273
|
+
/** 列表数据. */
|
274
|
+
datasMap: Map<String, any[]>;
|
275
|
+
/** 勾选的行的主键. */
|
276
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
277
|
+
/** 勾选的行. */
|
278
|
+
selectedRowsMap: Map<string, any[]>;
|
279
|
+
/**
|
280
|
+
* 是否已经查询过一次了.
|
281
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
282
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
283
|
+
*/
|
284
|
+
isSearchedMap: Map<string, boolean>;
|
285
|
+
/** 是否正在查询. */
|
286
|
+
isRetrievingMap: Map<string, boolean>;
|
287
|
+
/** 表格宽度. */
|
288
|
+
tableWidthMap: Map<string, number>;
|
289
|
+
/** 行高. */
|
290
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
291
|
+
/** 事件监听函数列表: ready. */
|
292
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
293
|
+
/** '双击某行'事件监听函数列表. */
|
294
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
295
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
296
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
297
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
298
|
+
}>): (formID: string | null | undefined) => IKgTableRow | null;
|
98
299
|
/** 当前勾选的唯一行. */
|
99
|
-
getSelectedRow(
|
300
|
+
getSelectedRow(state: {
|
301
|
+
isReadyMap: Map<string, boolean>;
|
302
|
+
datasMap: Map<String, any[]>;
|
303
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
304
|
+
selectedRowsMap: Map<string, any[]>;
|
305
|
+
isSearchedMap: Map<string, boolean>;
|
306
|
+
isRetrievingMap: Map<string, boolean>;
|
307
|
+
tableWidthMap: Map<string, number>;
|
308
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
309
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
310
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
311
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
312
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
313
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
314
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
315
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
316
|
+
isReadyMap: Map<string, boolean>;
|
317
|
+
/** 列表数据. */
|
318
|
+
datasMap: Map<String, any[]>;
|
319
|
+
/** 勾选的行的主键. */
|
320
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
321
|
+
/** 勾选的行. */
|
322
|
+
selectedRowsMap: Map<string, any[]>;
|
323
|
+
/**
|
324
|
+
* 是否已经查询过一次了.
|
325
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
326
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
327
|
+
*/
|
328
|
+
isSearchedMap: Map<string, boolean>;
|
329
|
+
/** 是否正在查询. */
|
330
|
+
isRetrievingMap: Map<string, boolean>;
|
331
|
+
/** 表格宽度. */
|
332
|
+
tableWidthMap: Map<string, number>;
|
333
|
+
/** 行高. */
|
334
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
335
|
+
/** 事件监听函数列表: ready. */
|
336
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
337
|
+
/** '双击某行'事件监听函数列表. */
|
338
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
339
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
340
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
341
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
342
|
+
}>): (formID: string | null | undefined) => IKgTableRow | null;
|
100
343
|
/**
|
101
344
|
* 根据 formID 获取是否已经查询过一次了.
|
102
345
|
*/
|
103
|
-
getIsSearched(
|
104
|
-
|
105
|
-
|
106
|
-
|
346
|
+
getIsSearched(state: {
|
347
|
+
isReadyMap: Map<string, boolean>;
|
348
|
+
datasMap: Map<String, any[]>;
|
349
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
350
|
+
selectedRowsMap: Map<string, any[]>;
|
351
|
+
isSearchedMap: Map<string, boolean>;
|
352
|
+
isRetrievingMap: Map<string, boolean>;
|
353
|
+
tableWidthMap: Map<string, number>;
|
354
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
355
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
356
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
357
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
358
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
359
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
360
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
361
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
362
|
+
isReadyMap: Map<string, boolean>;
|
363
|
+
/** 列表数据. */
|
364
|
+
datasMap: Map<String, any[]>;
|
365
|
+
/** 勾选的行的主键. */
|
366
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
367
|
+
/** 勾选的行. */
|
368
|
+
selectedRowsMap: Map<string, any[]>;
|
369
|
+
/**
|
370
|
+
* 是否已经查询过一次了.
|
371
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
372
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
373
|
+
*/
|
374
|
+
isSearchedMap: Map<string, boolean>;
|
375
|
+
/** 是否正在查询. */
|
376
|
+
isRetrievingMap: Map<string, boolean>;
|
377
|
+
/** 表格宽度. */
|
378
|
+
tableWidthMap: Map<string, number>;
|
379
|
+
/** 行高. */
|
380
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
381
|
+
/** 事件监听函数列表: ready. */
|
382
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
383
|
+
/** '双击某行'事件监听函数列表. */
|
384
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
385
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
386
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
387
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
388
|
+
}>): (formID: string | null | undefined) => boolean;
|
389
|
+
/**
|
390
|
+
* 根据 formID 获取是否正在查询.
|
391
|
+
* @param state
|
392
|
+
*/
|
393
|
+
getIsRetrieving(state: {
|
394
|
+
isReadyMap: Map<string, boolean>;
|
395
|
+
datasMap: Map<String, any[]>;
|
396
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
397
|
+
selectedRowsMap: Map<string, any[]>;
|
398
|
+
isSearchedMap: Map<string, boolean>;
|
399
|
+
isRetrievingMap: Map<string, boolean>;
|
400
|
+
tableWidthMap: Map<string, number>;
|
401
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
402
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
403
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
404
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
405
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
406
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
407
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
408
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
409
|
+
isReadyMap: Map<string, boolean>;
|
410
|
+
/** 列表数据. */
|
411
|
+
datasMap: Map<String, any[]>;
|
412
|
+
/** 勾选的行的主键. */
|
413
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
414
|
+
/** 勾选的行. */
|
415
|
+
selectedRowsMap: Map<string, any[]>;
|
416
|
+
/**
|
417
|
+
* 是否已经查询过一次了.
|
418
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
419
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
420
|
+
*/
|
421
|
+
isSearchedMap: Map<string, boolean>;
|
422
|
+
/** 是否正在查询. */
|
423
|
+
isRetrievingMap: Map<string, boolean>;
|
424
|
+
/** 表格宽度. */
|
425
|
+
tableWidthMap: Map<string, number>;
|
426
|
+
/** 行高. */
|
427
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
428
|
+
/** 事件监听函数列表: ready. */
|
429
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
430
|
+
/** '双击某行'事件监听函数列表. */
|
431
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
432
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
433
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
434
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
435
|
+
}>): (formID: string | null | undefined) => boolean | null;
|
436
|
+
/**
|
437
|
+
* 根据 formID 获取表格宽度.
|
438
|
+
* @param state
|
439
|
+
*/
|
440
|
+
getTableWidth(state: {
|
441
|
+
isReadyMap: Map<string, boolean>;
|
442
|
+
datasMap: Map<String, any[]>;
|
443
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
444
|
+
selectedRowsMap: Map<string, any[]>;
|
445
|
+
isSearchedMap: Map<string, boolean>;
|
446
|
+
isRetrievingMap: Map<string, boolean>;
|
447
|
+
tableWidthMap: Map<string, number>;
|
448
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
449
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
450
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
451
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
452
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
453
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
454
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
455
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
456
|
+
isReadyMap: Map<string, boolean>;
|
457
|
+
/** 列表数据. */
|
458
|
+
datasMap: Map<String, any[]>;
|
459
|
+
/** 勾选的行的主键. */
|
460
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
461
|
+
/** 勾选的行. */
|
462
|
+
selectedRowsMap: Map<string, any[]>;
|
463
|
+
/**
|
464
|
+
* 是否已经查询过一次了.
|
465
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
466
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
467
|
+
*/
|
468
|
+
isSearchedMap: Map<string, boolean>;
|
469
|
+
/** 是否正在查询. */
|
470
|
+
isRetrievingMap: Map<string, boolean>;
|
471
|
+
/** 表格宽度. */
|
472
|
+
tableWidthMap: Map<string, number>;
|
473
|
+
/** 行高. */
|
474
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
475
|
+
/** 事件监听函数列表: ready. */
|
476
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
477
|
+
/** '双击某行'事件监听函数列表. */
|
478
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
479
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
480
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
481
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
482
|
+
}>): (formID: string | null | undefined) => number | null;
|
483
|
+
getRowHeight(state: {
|
484
|
+
isReadyMap: Map<string, boolean>;
|
485
|
+
datasMap: Map<String, any[]>;
|
486
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
487
|
+
selectedRowsMap: Map<string, any[]>;
|
488
|
+
isSearchedMap: Map<string, boolean>;
|
489
|
+
isRetrievingMap: Map<string, boolean>;
|
490
|
+
tableWidthMap: Map<string, number>;
|
491
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
492
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
493
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
494
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
495
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
496
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
497
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
498
|
+
/** 是否就绪: 配置初始完成, 组件渲染完成. */
|
499
|
+
isReadyMap: Map<string, boolean>;
|
500
|
+
/** 列表数据. */
|
501
|
+
datasMap: Map<String, any[]>;
|
502
|
+
/** 勾选的行的主键. */
|
503
|
+
selectedRowKeysMap: Map<string, Ref<Key[]>>;
|
504
|
+
/** 勾选的行. */
|
505
|
+
selectedRowsMap: Map<string, any[]>;
|
506
|
+
/**
|
507
|
+
* 是否已经查询过一次了.
|
508
|
+
* 如果表格禁用了自动查询, 当用户手动点击查询按钮后, 该属性会设置为 true,
|
509
|
+
* 如果表格启用了自动查询, 当第一次自动查询之后, 该属性会设置为 true.
|
510
|
+
*/
|
511
|
+
isSearchedMap: Map<string, boolean>;
|
512
|
+
/** 是否正在查询. */
|
513
|
+
isRetrievingMap: Map<string, boolean>;
|
514
|
+
/** 表格宽度. */
|
515
|
+
tableWidthMap: Map<string, number>;
|
516
|
+
/** 行高. */
|
517
|
+
rowHeightMap: Map<string, IKgTableRowHeight>;
|
518
|
+
/** 事件监听函数列表: ready. */
|
519
|
+
onReadyListenersMap: Map<string, IKgTableReadyCb[]>;
|
520
|
+
/** '双击某行'事件监听函数列表. */
|
521
|
+
rowDoubleClickListenersMap: Map<string, IKgTableRowDoubleClickCb[]>;
|
522
|
+
beforeSearchListenersMap: Map<string, IKgTableBeforeSearchCb[]>;
|
523
|
+
beforeSetDatasListenersMap: Map<string, IKgTableBeforeSetDatasCb[]>;
|
524
|
+
afterSearchListenersMap: Map<string, IKgTableAfterSearchCb[]>;
|
525
|
+
}>): (formID: string | null | undefined) => IKgTableRowHeight;
|
107
526
|
}, {
|
108
527
|
/**
|
109
528
|
* 清理数据.
|
110
529
|
* @param formID 页面标识.
|
111
530
|
*/
|
112
|
-
dispose(formID: string | null | undefined):
|
531
|
+
dispose(formID: string | null | undefined): null | undefined;
|
532
|
+
/**
|
533
|
+
* 注册事件监听.
|
534
|
+
* @param formID 界面标识.
|
535
|
+
* @param event 事件名称.
|
536
|
+
* @param cb 回调函数.
|
537
|
+
*/
|
113
538
|
addEventListener(formID: string | null | undefined, event: IKgTableEvent, cb: IKgTableCb): void;
|
539
|
+
/**
|
540
|
+
* 退订事件监听.
|
541
|
+
* @param formID 界面标识.
|
542
|
+
* @param event 事件名称.
|
543
|
+
* @param cb 回调函数.
|
544
|
+
*/
|
114
545
|
removeEventListener(formID: string | null | undefined, event: IKgTableEvent, cb?: IKgTableCb): void;
|
115
|
-
|
546
|
+
/**
|
547
|
+
* 触发事件.
|
548
|
+
* @param formID 界面标识.
|
549
|
+
* @param event 事件名称.
|
550
|
+
* @param param 数据.
|
551
|
+
*/
|
552
|
+
emit<T_1 = IKgTableCbParam>(formID: string | null | undefined, event: IKgTableEvent, param: T_1): Promise<boolean>;
|
116
553
|
/**
|
117
554
|
* 设置是否就绪.
|
118
555
|
* @param formID 界面标识.
|
@@ -121,29 +558,34 @@ export declare type IKgTableStoreDefinition = StoreDefinition<'KgTable', IKgTabl
|
|
121
558
|
setIsReady(formID: string | null | undefined, ready?: boolean): void;
|
122
559
|
/**
|
123
560
|
* 设置列表数据.
|
124
|
-
* @param
|
125
|
-
* @param datas 列表数据.
|
561
|
+
* @param param.frmId 界面标识.
|
562
|
+
* @param param.datas 列表数据.
|
563
|
+
* @param param.isPreserveSelectedRows 是否保留行的勾选状态.
|
126
564
|
*/
|
127
|
-
setDatas<
|
565
|
+
setDatas<T_2 = any>(param: {
|
566
|
+
frmId: string | null | undefined;
|
567
|
+
datas: T_2[];
|
568
|
+
isPreserveSelectedRows?: boolean | undefined;
|
569
|
+
}): void;
|
128
570
|
/**
|
129
571
|
* 设置勾选的行.
|
130
|
-
* @param
|
572
|
+
* @param frmId 界面标识.
|
131
573
|
* @param selectedRows 勾选的行.
|
132
574
|
*/
|
133
|
-
setSelectedRows(
|
575
|
+
setSelectedRows(frmId: string | null | undefined, selectedRows: Array<IKgTableRow>): void;
|
134
576
|
/**
|
135
577
|
* 刷新勾选的行. 表格列表数据变更之后, 需要同步到勾选的行.
|
136
|
-
* @param
|
578
|
+
* @param frmId 界面标识.
|
137
579
|
*/
|
138
|
-
refreshSelectedRows(
|
580
|
+
refreshSelectedRows(frmId: string | null | undefined): void;
|
139
581
|
/**
|
140
582
|
* 设置某行的勾选状态.
|
141
|
-
* @param
|
583
|
+
* @param frmId 界面标识.
|
142
584
|
* @param row 行.
|
143
585
|
* @param selected 是否勾选.
|
144
586
|
*/
|
145
|
-
setRowSelect(
|
146
|
-
setIsSearched(
|
587
|
+
setRowSelect(frmId: string | null | undefined, row: IKgTableRow, selected: boolean): void;
|
588
|
+
setIsSearched(frmId: string | null | undefined, value: boolean): void;
|
147
589
|
setIsRetrieving(formID: string | null | undefined, value: boolean): void;
|
148
590
|
setTableWidth(formID: string | null | undefined, value: number): void;
|
149
591
|
setRowHeight(formID: string | null | undefined, value: IKgTableRowHeight): void;
|
@@ -153,5 +595,3 @@ export declare type IKgTableStoreDefinition = StoreDefinition<'KgTable', IKgTabl
|
|
153
595
|
*/
|
154
596
|
clearDatas(formID: string | null | undefined): void;
|
155
597
|
}>;
|
156
|
-
export declare type IKgTableStore = ReturnType<IKgTableStoreDefinition>;
|
157
|
-
export declare const useKgTableStore: () => IKgTableStoreDefinition;
|
@@ -22,14 +22,14 @@ export interface IKgTableSearchParams {
|
|
22
22
|
isPreserveSelectedRows?: boolean;
|
23
23
|
}
|
24
24
|
/** 插槽参数. */
|
25
|
-
export interface IKgTableSlotParams<
|
25
|
+
export interface IKgTableSlotParams<T = IKgTableRow> {
|
26
26
|
bodyCell: {
|
27
27
|
column: ColumnType;
|
28
28
|
index: number;
|
29
|
-
record:
|
29
|
+
record: T;
|
30
30
|
text: any | null;
|
31
31
|
value: any | null;
|
32
|
-
row:
|
32
|
+
row: T;
|
33
33
|
varGridDetail: VarGridDetail | null;
|
34
34
|
defaultRender: JSX.Element;
|
35
35
|
};
|