@kengic/vue 0.26.6-beta.98 → 0.26.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (71) hide show
  1. package/dist/card-text-outline.6e053122.mjs +8 -0
  2. package/dist/index.css +1 -1
  3. package/dist/kengic-vue.js +52291 -50331
  4. package/dist/project/build/vite/plugin/index.ts +0 -1
  5. package/dist/src/component/KgAppSelect/index.event.d.ts +17 -0
  6. package/dist/src/component/KgAppSelect/index.hooks.d.ts +13 -11
  7. package/dist/src/component/KgAppSelect/index.store.d.ts +6 -21
  8. package/dist/src/component/KgButton/index.event.d.ts +27 -0
  9. package/dist/src/component/KgButton/index.hooks.d.ts +8 -6
  10. package/dist/src/component/KgButton/index.store.d.ts +8 -32
  11. package/dist/src/component/KgCanvas/KgCanvas.ContextMenu.d.ts +0 -3
  12. package/dist/src/component/KgCanvas/KgCanvas.d.ts +15 -0
  13. package/dist/src/component/KgCanvas/KgCanvas.service.d.ts +2 -2
  14. package/dist/src/component/KgCanvas/index.event.d.ts +213 -0
  15. package/dist/src/component/KgCanvas/index.hooks.d.ts +18 -13
  16. package/dist/src/component/KgCanvas/index.store.d.ts +0 -229
  17. package/dist/src/component/KgCanvas/index.vm.d.ts +4 -0
  18. package/dist/src/component/KgForm/index.event.d.ts +191 -0
  19. package/dist/src/component/KgForm/index.hooks.d.ts +17 -9
  20. package/dist/src/component/KgForm/index.store.d.ts +11 -177
  21. package/dist/src/component/KgForm.Item/KgForm.Item.service.d.ts +1 -1
  22. package/dist/src/component/KgForm.Item/components/KgForm.Item.Checkbox.d.ts +3 -1
  23. package/dist/src/component/KgForm.Item/components/KgForm.Item.CheckboxGroup.d.ts +3 -3
  24. package/dist/src/component/KgForm.Item/components/KgForm.Item.Date.d.ts +1 -1
  25. package/dist/src/component/KgForm.Item/components/KgForm.Item.DateRange.d.ts +1 -1
  26. package/dist/src/component/KgForm.Item/components/KgForm.Item.Input.d.ts +1 -1
  27. package/dist/src/component/KgForm.Item/components/KgForm.Item.InputNumber.d.ts +1 -1
  28. package/dist/src/component/KgForm.Item/components/KgForm.Item.InputPassword.d.ts +1 -1
  29. package/dist/src/component/KgForm.Item/components/KgForm.Item.RadioGroup.d.ts +1 -1
  30. package/dist/src/component/KgForm.Item/components/KgForm.Item.Select.d.ts +1 -1
  31. package/dist/src/component/KgForm.Item/components/KgForm.Item.Switch.d.ts +1 -1
  32. package/dist/src/component/KgForm.Item/components/KgForm.Item.TextArea.d.ts +1 -1
  33. package/dist/src/component/KgSearch/KgSearch.service.d.ts +1 -1
  34. package/dist/src/component/KgSearch/index.event.d.ts +17 -0
  35. package/dist/src/component/KgSearch/index.hooks.d.ts +6 -5
  36. package/dist/src/component/KgSearch/index.store.d.ts +14 -29
  37. package/dist/src/component/KgSubmit/KgSubmit.service.d.ts +1 -1
  38. package/dist/src/component/KgSubmit/index.event.d.ts +105 -0
  39. package/dist/src/component/KgSubmit/index.hooks.d.ts +15 -13
  40. package/dist/src/component/KgSubmit/index.store.d.ts +13 -115
  41. package/dist/src/component/KgTable/KgTable.service.d.ts +2 -2
  42. package/dist/src/component/KgTable/index.event.d.ts +57 -0
  43. package/dist/src/component/KgTable/index.hooks.d.ts +13 -12
  44. package/dist/src/component/KgTable/index.store.d.ts +10 -63
  45. package/dist/src/component/KgVar/index.event.d.ts +60 -0
  46. package/dist/src/component/KgVar/index.hooks.d.ts +31 -3
  47. package/dist/src/component/KgVar/index.store.d.ts +1 -38
  48. package/dist/src/component/KgVar/index.vm.d.ts +16 -2
  49. package/dist/src/component/KgWarehouse/index.hooks.d.ts +3 -3
  50. package/dist/src/component/KgWarehouse/index.store.d.ts +6 -6
  51. package/dist/src/config/setup/setup.d.ts +1 -1
  52. package/dist/src/const/i18n/en.d.ts +1 -1
  53. package/dist/src/const/i18n/es_ES.d.ts +1 -1
  54. package/dist/src/const/i18n/fr_FR.d.ts +1 -1
  55. package/dist/src/const/i18n/km_KH.d.ts +1 -1
  56. package/dist/src/const/i18n/ko_KR.d.ts +1 -1
  57. package/dist/src/const/i18n/vi_VN.d.ts +1 -1
  58. package/dist/src/const/i18n/zh_CN.d.ts +1 -1
  59. package/dist/src/const/index.vm.d.ts +22 -24
  60. package/dist/src/const/injection-keys.const.d.ts +2 -0
  61. package/dist/src/index.d.ts +2 -2
  62. package/dist/src/util/index.d.ts +14 -0
  63. package/dist/src/util/kg-var.util.d.ts +14 -0
  64. package/dist/src/util/kg.util.d.ts +7 -5
  65. package/package.json +5 -4
  66. package/dist/src/component/KgSearch/components/KgSearch.ConfigModal.d.ts +0 -16
  67. package/dist/src/component/KgTable/components/setting/config/KgTable.Setting.ConfigModal.d.ts +0 -16
  68. package/dist/src/component/util.d.ts +0 -14
  69. /package/dist/{close-outlined-DMcSQWxQ.90085278.mjs → close-outlined-DMcSQWxQ.ecd794e3.mjs} +0 -0
  70. /package/dist/{fullscreen-exit-outlined-X1iYkFc4.7f925ac4.mjs → fullscreen-exit-outlined-X1iYkFc4.81ef5f5d.mjs} +0 -0
  71. /package/dist/{fullscreen-outlined-DDBrsRcy.3af91f63.mjs → fullscreen-outlined-DDBrsRcy.678cfca5.mjs} +0 -0
@@ -0,0 +1,60 @@
1
+ import { IKgEventListener } from '@kengic/core.core';
2
+ /**
3
+ * 事件类型.
4
+ * 'onRequest': 变量配置查询完成
5
+ * 'onSetup': 页面创建
6
+ * 'onUnmounted': 页面卸载
7
+ */
8
+ export declare type IKgVarEvent = 'onRequest' | 'onSetup' | 'onUnmounted';
9
+ export declare type IKgVarOnRequestEventListenerParameter = {
10
+ /**
11
+ * 界面标识.
12
+ */
13
+ formID: string;
14
+ };
15
+ export declare type IKgVarOnRequestEventListener = ((param: IKgVarOnRequestEventListenerParameter) => Promise<boolean>) & IKgEventListener;
16
+ export declare type IKgVarOnSetupEventListenerParameter = {
17
+ /**
18
+ * 界面标识.
19
+ */
20
+ formID: string;
21
+ };
22
+ export declare type IKgVarOnSetupEventListener = ((param: IKgVarOnSetupEventListenerParameter) => void) & IKgEventListener;
23
+ export declare type IKgVarOnUnmountedEventListenerParameter = {
24
+ /**
25
+ * 界面标识.
26
+ */
27
+ formID: string;
28
+ };
29
+ export declare type IKgVarOnUnmountedEventListener = ((param: IKgVarOnUnmountedEventListenerParameter) => Promise<boolean>) & IKgEventListener;
30
+ export declare type IKgVarEventListenerParameter = IKgVarOnRequestEventListenerParameter | IKgVarOnSetupEventListenerParameter | IKgVarOnUnmountedEventListenerParameter;
31
+ export declare type IKgVarEventListener = IKgVarOnRequestEventListener | IKgVarOnSetupEventListener | IKgVarOnUnmountedEventListener;
32
+ export declare const eventListenerListRecordRecord: Record<string, {
33
+ onRequest: Array<IKgVarOnRequestEventListener>;
34
+ onSetup: Array<IKgVarOnSetupEventListener>;
35
+ onUnmounted: Array<IKgVarOnUnmountedEventListener>;
36
+ }>;
37
+ /**
38
+ * 触发事件.
39
+ *
40
+ * @param param.event 事件名称.
41
+ * @param param.id 唯一标识.
42
+ * @param param.parameter 事件参数.
43
+ */
44
+ export declare function emit<P extends IKgVarEventListenerParameter>(param: {
45
+ event: IKgVarEvent;
46
+ id?: string | undefined;
47
+ parameter: P;
48
+ }): Promise<boolean>;
49
+ /**
50
+ * 触发事件:同步.
51
+ *
52
+ * @param param.event 事件名称.
53
+ * @param param.id 唯一标识.
54
+ * @param param.parameter 事件参数.
55
+ */
56
+ export declare function emitSync<P extends IKgVarEventListenerParameter>(param: {
57
+ event: IKgVarEvent;
58
+ id?: string | undefined;
59
+ parameter: P;
60
+ }): void;
@@ -1,13 +1,15 @@
1
+ import { IRemoveEventListener } from '@kengic/core.core';
1
2
  import { ComputedRef } from 'vue';
2
3
  import { VarConfigControl, VarConfigDescription, VarConfigPossibility } from '../../api/WMS/models';
3
- import { IRemoveEventListenerHandler, KG__VAR_BUTTON__TYPE } from '../../const';
4
+ import { KG__VAR_BUTTON__TYPE } from '../../const';
4
5
  import { IUseKgButton } from '../KgButton';
5
6
  import { IUseKgForm } from '../KgForm';
6
7
  import { type IUseKgSearch } from '../KgSearch';
7
8
  import { IUseKgSubmit } from '../KgSubmit';
8
9
  import { IUseKgTable } from '../KgTable';
9
10
  import { IUseKgVarConfig } from '../KgVarConfig';
10
- import { IKgVarRequestEventListener, IKgVarStore } from './index.store';
11
+ import { IKgVarOnRequestEventListener, IKgVarOnSetupEventListener, IKgVarOnUnmountedEventListener } from './index.event';
12
+ import { IKgVarStore } from './index.store';
11
13
  import { IKgProps, IKgSlots } from './index.vm';
12
14
  export declare type IUseKgVar = {
13
15
  /**
@@ -128,7 +130,21 @@ export declare type IUseKgVar = {
128
130
  * @param listener 事件监听函数.
129
131
  * @param isOnce 是否只会触发一次. 默认为 undefined.
130
132
  */
131
- onRetrieve(listener: IKgVarRequestEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
133
+ onRetrieve(listener: IKgVarOnRequestEventListener, isOnce?: boolean): IRemoveEventListener;
134
+ /**
135
+ * 监听事件: 页面创建.
136
+ *
137
+ * @param listener 事件监听函数.
138
+ * @param isOnce 是否只会触发一次. 默认为 undefined.
139
+ */
140
+ onSetup(listener: IKgVarOnSetupEventListener, isOnce?: boolean): IRemoveEventListener;
141
+ /**
142
+ * 监听事件: 页面卸载.
143
+ *
144
+ * @param listener 事件监听函数.
145
+ * @param isOnce 是否只会触发一次. 默认为 undefined.
146
+ */
147
+ onUnmounted(listener: IKgVarOnUnmountedEventListener, isOnce?: boolean): IRemoveEventListener;
132
148
  /**
133
149
  * 父亲界面.
134
150
  */
@@ -142,7 +158,19 @@ export declare type IUseKgVar = {
142
158
  requestAll(param?: {
143
159
  isForceRequest?: boolean;
144
160
  }): Promise<void>;
161
+ /**
162
+ * <p>设置组件参数.</p>
163
+ * <p>用于设置内部的组件的参数.</p>
164
+ *
165
+ * @param props
166
+ */
145
167
  setProps(props: IKgProps): void;
168
+ /**
169
+ * <p>设置插槽.</p>
170
+ * <p>用于自定义页面的显示内容.</p>
171
+ *
172
+ * @param slots 插槽.
173
+ */
146
174
  setSlots(slots: IKgSlots): void;
147
175
  slots: ComputedRef<ReturnType<IKgVarStore['getSlots']>>;
148
176
  /** 状态数据. */
@@ -1,22 +1,8 @@
1
1
  import { StoreDefinition } from 'pinia';
2
2
  import { VarButton, VarButtonConfig, VarChildDetail, VarConfigControl, VarConfigDescription, VarConfigInput, VarConfigLookup, VarConfigPossibility, VarConfigTip, VarDda, VarGridConfig, VarGridDetail, VarGridMasterDTO, VarProfileConfig, VarProfileDetail, VarProfileMasterDTO, VarSubmitConfig, VarSubmitDetail, VarVariable } from '../../api/WMS/models';
3
- import { IKgEventListener, KG__VAR_BUTTON__TYPE } from '../../const';
3
+ import { KG__VAR_BUTTON__TYPE } from '../../const';
4
4
  import { IUseKgVar } from './index.hooks';
5
5
  import { IKgProps, IKgSlots } from './index.vm';
6
- /**
7
- * 事件类型.
8
- * 'onRequest': 变量配置查询完成
9
- */
10
- export declare type IKgVarEvent = 'onRequest';
11
- export declare type IKgVarRequestEventListenerParameter = {
12
- /**
13
- * 界面标识.
14
- */
15
- formID: string;
16
- };
17
- export declare type IKgVarRequestEventListener = ((param: IKgVarRequestEventListenerParameter) => Promise<boolean>) & IKgEventListener;
18
- export declare type IKgVarEventListenerParameter = IKgVarRequestEventListenerParameter;
19
- export declare type IKgVarEventListener = IKgVarRequestEventListener;
20
6
  export interface IUseKgVarStoreState {
21
7
  /** 正在复制: 正在调用接口. */
22
8
  isCopyingRequestingMap: Map<string, boolean>;
@@ -42,8 +28,6 @@ export interface IUseKgVarStoreState {
42
28
  * 界面层级.
43
29
  */
44
30
  levelMap: Map<string, number>;
45
- /** 事件监听函数列表: onRequest. */
46
- onRequestEventListenerMap: Map<string, Array<IKgVarRequestEventListener>>;
47
31
  propsMap: Map<string, IKgProps>;
48
32
  slotsMap: Map<string, IKgSlots>;
49
33
  varButtonConfigMap: Map<string, VarButtonConfig | null>;
@@ -156,13 +140,6 @@ export interface IUseKgVarStoreGetters {
156
140
  t(): (formID: string | null | undefined, varName: string | null | undefined) => string;
157
141
  }
158
142
  export interface IUseKgVarStoreActions {
159
- /**
160
- * 注册事件监听.
161
- * @param formID 界面标识.
162
- * @param event 事件名称.
163
- * @param listener 事件监听函数.
164
- */
165
- addEventListener(formID: string | null | undefined, event: IKgVarEvent, listener: any): void;
166
143
  createVarConfigControl(formID: string | null | undefined, varConfigControl: VarConfigControl): void;
167
144
  createVarConfigDescription(formID: string | null | undefined, varConfigDescription: VarConfigDescription): void;
168
145
  createVarConfigPossibility(formID: string | null | undefined, varConfigPossibility: VarConfigPossibility): void;
@@ -180,13 +157,6 @@ export interface IUseKgVarStoreActions {
180
157
  * @param toVarName 被放下的变量名称.
181
158
  */
182
159
  dragSortCurrentVarGridDetails(formID: string | null | undefined, fromVarName: string | null | undefined, toVarName: string | null | undefined): void;
183
- /**
184
- * 触发事件.
185
- * @param formID 界面标识.
186
- * @param event 事件名称.
187
- * @param param 事件参数.
188
- */
189
- emit<T = IKgVarEventListenerParameter>(formID: string, event: IKgVarEvent, param: T): Promise<boolean>;
190
160
  /**
191
161
  * 进入一个界面. 同一个界面不允许进入多次.
192
162
  * @param param.formID 界面标识.
@@ -210,13 +180,6 @@ export interface IUseKgVarStoreActions {
210
180
  * @param properties 要修改的部分属性.
211
181
  */
212
182
  patchVarProfileDetail(formID: string, var_nam: string | null | undefined, properties: VarProfileDetail): Promise<void>;
213
- /**
214
- * 退订事件监听.
215
- * @param formID 界面标识.
216
- * @param event 事件名称.
217
- * @param listener 事件监听函数.
218
- */
219
- removeEventListener(formID: string, event: IKgVarEvent, listener?: any): void;
220
183
  /**
221
184
  * 查询所有变量配置.
222
185
  *
@@ -6,14 +6,17 @@ import { KgSubmitProps } from '../KgSubmit';
6
6
  import { IKgTableSlotParams } from '../KgTable';
7
7
  import { IKgTableProps } from '../KgTable/KgTable';
8
8
  export declare type IKgSlots = {
9
+ /** 按钮. */
9
10
  KgButton?: {
10
11
  /** 右侧. */
11
12
  right?: () => any;
12
13
  };
14
+ /** 查询条件. */
13
15
  KgSearch?: {
14
16
  /** 左侧. */
15
17
  left?: () => any;
16
18
  };
19
+ /** 表单. */
17
20
  KgSubmit?: {
18
21
  /**
19
22
  * 某个表单控件.
@@ -26,6 +29,7 @@ export declare type IKgSlots = {
26
29
  [variable: string]: (param: IKgFormItemSlotControlRightParameter) => any;
27
30
  };
28
31
  };
32
+ /** 表格. */
29
33
  KgTable?: {
30
34
  /** 单元格. */
31
35
  bodyCell?: (param: IKgTableSlotParams['bodyCell']) => any;
@@ -34,9 +38,19 @@ export declare type IKgSlots = {
34
38
  /** 表格底部的汇总行.单元格. */
35
39
  'summary.bodyCell'?: (param: IKgTableSlotParams['summary.bodyCell']) => any;
36
40
  };
37
- /** KgTable 下面. */
41
+ /** 按钮下面. */
42
+ afterKgButton?: () => any;
43
+ /** 查询条件下面. */
44
+ afterKgSearch?: () => any;
45
+ /** 表格下面. */
38
46
  afterKgTable?: () => any;
39
- /** 底部. */
47
+ /** 按钮上面. */
48
+ beforeKgButton?: () => any;
49
+ /** 查询条件上面. */
50
+ beforeKgSearch?: () => any;
51
+ /** 表格上面. */
52
+ beforeKgTable?: () => any;
53
+ /** 页面底部. */
40
54
  bottom?: () => any;
41
55
  /**
42
56
  * 孩子页面.
@@ -1,14 +1,14 @@
1
+ import { IRemoveEventListener } from '@kengic/core.core';
1
2
  import { Pinia } from 'pinia';
2
3
  import { ComputedRef } from 'vue';
3
- import { IRemoveEventListenerHandler } from '../../const';
4
- import { IKgWarehouseMountedEventListener, IKgWarehouseStore } from './index.store';
4
+ import { IKgWarehouseOnMountedEventListener, IKgWarehouseStore } from './index.store';
5
5
  export declare type IUseKgWarehouse = {
6
6
  /**
7
7
  * 监听事件: 组件加载完成.
8
8
  * @param listener 事件监听函数.
9
9
  * @param isOnce 是否只会触发一次. 默认为 undefined.
10
10
  */
11
- onMounted(listener: IKgWarehouseMountedEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
11
+ onMounted(listener: IKgWarehouseOnMountedEventListener, isOnce?: boolean): IRemoveEventListener;
12
12
  store: IKgWarehouseStore;
13
13
  /**
14
14
  * 是否显示弹窗.
@@ -1,15 +1,15 @@
1
+ import { IKgEventListener } from '@kengic/core.core';
1
2
  import { StoreDefinition } from 'pinia';
2
3
  import { WhDTO } from '../../api/WMS/models';
3
- import { IKgEventListener } from '../../const';
4
4
  /**
5
5
  * 事件类型.
6
- * 'mounted': 组件加载完成
6
+ * 'onMounted': 组件挂载完成
7
7
  */
8
- export declare type IKgWarehouseEvent = 'mounted';
9
- export declare type IKgWarehouseMountedEventListener = (() => void) & IKgEventListener;
10
- export declare type IKgWarehouseEventListener = IKgWarehouseMountedEventListener;
8
+ export declare type IKgWarehouseEvent = 'onMounted';
9
+ export declare type IKgWarehouseOnMountedEventListener = (() => void) & IKgEventListener;
10
+ export declare type IKgWarehouseEventListener = IKgWarehouseOnMountedEventListener;
11
11
  export interface IUseKgWarehouseStoreState {
12
- mountedListeners: Array<IKgWarehouseMountedEventListener>;
12
+ onMounted: Array<IKgWarehouseOnMountedEventListener>;
13
13
  /**
14
14
  * 是否显示弹窗.
15
15
  */
@@ -2,7 +2,7 @@ import { StoreDefinition } from 'pinia';
2
2
  import { App } from 'vue';
3
3
  import { Router } from 'vue-router';
4
4
  import { IKgOption, P } from '../index.store';
5
- import '@kengic/core/react/index.css';
5
+ import '@kengic/core.react/index.css';
6
6
  export declare type IKgOptions = {
7
7
  /**
8
8
  * 语言数据.
@@ -150,7 +150,6 @@ declare const _default: {
150
150
  locate: string;
151
151
  row: string;
152
152
  };
153
- KgTableSettingConfigModal: {};
154
153
  KgTableSettingVarGridConfig: {};
155
154
  KgTableSettingVarGridMasterSaveAs: {
156
155
  title: string;
@@ -208,6 +207,7 @@ declare const _default: {
208
207
  };
209
208
  KgVarConfigModalTableVarGridMaster: {
210
209
  DESC: string;
210
+ DESC__UPDATE_LINK: string;
211
211
  FILE_SIZE: string;
212
212
  ICON: string;
213
213
  IMAGE: string;
@@ -150,7 +150,6 @@ declare const _default: {
150
150
  locate: string;
151
151
  row: string;
152
152
  };
153
- KgTableSettingConfigModal: {};
154
153
  KgTableSettingVarGridConfig: {};
155
154
  KgTableSettingVarGridMasterSaveAs: {
156
155
  title: string;
@@ -208,6 +207,7 @@ declare const _default: {
208
207
  };
209
208
  KgVarConfigModalTableVarGridMaster: {
210
209
  DESC: string;
210
+ DESC__UPDATE_LINK: string;
211
211
  FILE_SIZE: string;
212
212
  ICON: string;
213
213
  IMAGE: string;
@@ -150,7 +150,6 @@ declare const _default: {
150
150
  locate: string;
151
151
  row: string;
152
152
  };
153
- KgTableSettingConfigModal: {};
154
153
  KgTableSettingVarGridConfig: {};
155
154
  KgTableSettingVarGridMasterSaveAs: {
156
155
  title: string;
@@ -208,6 +207,7 @@ declare const _default: {
208
207
  };
209
208
  KgVarConfigModalTableVarGridMaster: {
210
209
  DESC: string;
210
+ DESC__UPDATE_LINK: string;
211
211
  FILE_SIZE: string;
212
212
  ICON: string;
213
213
  IMAGE: string;
@@ -150,7 +150,6 @@ declare const _default: {
150
150
  locate: string;
151
151
  row: string;
152
152
  };
153
- KgTableSettingConfigModal: {};
154
153
  KgTableSettingVarGridConfig: {};
155
154
  KgTableSettingVarGridMasterSaveAs: {
156
155
  title: string;
@@ -208,6 +207,7 @@ declare const _default: {
208
207
  };
209
208
  KgVarConfigModalTableVarGridMaster: {
210
209
  DESC: string;
210
+ DESC__UPDATE_LINK: string;
211
211
  FILE_SIZE: string;
212
212
  ICON: string;
213
213
  IMAGE: string;
@@ -150,7 +150,6 @@ declare const _default: {
150
150
  locate: string;
151
151
  row: string;
152
152
  };
153
- KgTableSettingConfigModal: {};
154
153
  KgTableSettingVarGridConfig: {};
155
154
  KgTableSettingVarGridMasterSaveAs: {
156
155
  title: string;
@@ -208,6 +207,7 @@ declare const _default: {
208
207
  };
209
208
  KgVarConfigModalTableVarGridMaster: {
210
209
  DESC: string;
210
+ DESC__UPDATE_LINK: string;
211
211
  FILE_SIZE: string;
212
212
  ICON: string;
213
213
  IMAGE: string;
@@ -150,7 +150,6 @@ declare const _default: {
150
150
  locate: string;
151
151
  row: string;
152
152
  };
153
- KgTableSettingConfigModal: {};
154
153
  KgTableSettingVarGridConfig: {};
155
154
  KgTableSettingVarGridMasterSaveAs: {
156
155
  title: string;
@@ -208,6 +207,7 @@ declare const _default: {
208
207
  };
209
208
  KgVarConfigModalTableVarGridMaster: {
210
209
  DESC: string;
210
+ DESC__UPDATE_LINK: string;
211
211
  FILE_SIZE: string;
212
212
  ICON: string;
213
213
  IMAGE: string;
@@ -151,7 +151,6 @@ declare const _default: {
151
151
  locate: string;
152
152
  row: string;
153
153
  };
154
- KgTableSettingConfigModal: {};
155
154
  KgTableSettingVarGridConfig: {};
156
155
  KgTableSettingVarGridMasterSaveAs: {
157
156
  title: string;
@@ -209,6 +208,7 @@ declare const _default: {
209
208
  };
210
209
  KgVarConfigModalTableVarGridMaster: {
211
210
  DESC: string;
211
+ DESC__UPDATE_LINK: string;
212
212
  FILE_SIZE: string;
213
213
  ICON: string;
214
214
  IMAGE: string;
@@ -130,9 +130,7 @@ export declare enum KG__API_METHOD {
130
130
  * @see VarGridDetail.display_type_properties
131
131
  * @see IKgVarGridDetailDisplayTypeProperties
132
132
  */
133
- export declare const enum KG__VAR_GRID_DETAIL__DISPLAY_TYPE {
134
- /** 布尔数据, 使用 KgYesOrNo 组件显示. */
135
- YN = "YN",
133
+ export declare const KG__VAR_GRID_DETAIL__DISPLAY_TYPE: {
136
134
  /**
137
135
  * <p>描述. 显示该列的值所对应的描述, 而不是直接显示该列的值.</p>
138
136
  * <p>
@@ -146,24 +144,28 @@ export declare const enum KG__VAR_GRID_DETAIL__DISPLAY_TYPE {
146
144
  * </ul>
147
145
  * </p>
148
146
  */
149
- DESC = "DESC",
150
- /** 进度条, 使用 KgProgressA 组件显示. */
151
- PROGRESS = "PROGRESS",
147
+ DESC: string;
148
+ /** {@link DESC} + {@link UPDATE_LINK}. */
149
+ DESC__UPDATE_LINK: string;
152
150
  /** 文件大小, 将以字节(byte)为单位的数字格式化显示(XXX MB, XXX GB, ...). */
153
- FILE_SIZE = "FILE_SIZE",
154
- /** 超链接, 点击打开更新弹窗. */
155
- UPDATE_LINK = "UPDATE_LINK",
156
- /** 超链接, 点击跳转到其他页面. */
157
- ROUTE_LINK = "ROUTE_LINK",
151
+ FILE_SIZE: string;
158
152
  /**
159
- * <p>图片, 可以点击预览大图.</p>
153
+ * <p>图标, 使用 iconify 进行渲染.</p>
160
154
  */
161
- IMAGE = "IMAGE",
155
+ ICON: string;
162
156
  /**
163
- * <p>图标, 使用 iconify 进行渲染.</p>
157
+ * <p>图片, 可以点击预览大图.</p>
164
158
  */
165
- ICON = "ICON"
166
- }
159
+ IMAGE: string;
160
+ /** 进度条, 使用 KgProgressA 组件显示. */
161
+ PROGRESS: string;
162
+ /** 超链接, 点击跳转到其他页面. */
163
+ ROUTE_LINK: string;
164
+ /** 超链接, 点击打开更新弹窗. */
165
+ UPDATE_LINK: string;
166
+ /** 布尔数据, 使用 KgYesOrNo 组件显示. */
167
+ YN: string;
168
+ };
167
169
  /**
168
170
  * 表格单元格的对齐方式.
169
171
  */
@@ -459,6 +461,10 @@ export declare enum KG_DYNAMIC_QUERY_OPERATOR {
459
461
  }
460
462
  /** 请求头部. */
461
463
  export declare enum KG_HTTP_HEADERS {
464
+ /** 当前页码. */
465
+ KG_PAGE_INDEX = "Kg-Page-Index",
466
+ /** 每页条数. */
467
+ KG_PAGE_SISE = "Kg-Page-Size",
462
468
  /** 界面标识. */
463
469
  KG_FORM_ID = "Kg-Form-Id",
464
470
  KG_BUTTON_VAR_NAME = "Kg-Button-Var-Name",
@@ -502,14 +508,6 @@ export declare const KG_TMP_MENU_ID__WCS = "KG_TMP_MENU_ID__WCS";
502
508
  export declare const KG_TMP_MENU_ID__SYS = "KG_TMP_MENU_ID__SYS";
503
509
  /** 模块菜单的临时ID:PDA. */
504
510
  export declare const KG_TMP_MENU_ID__PDA = "KG_TMP_MENU_ID__PDA";
505
- /** 移除事件监听函数. */
506
- export declare type IRemoveEventListenerHandler = () => void;
507
- export declare type IKgEventListener = {
508
- /** 是否只会触发一次. */
509
- isOnce?: boolean;
510
- /** 是否已经触发过一次了. */
511
- invoked?: boolean;
512
- };
513
511
  /** 菜单. */
514
512
  export interface Menu {
515
513
  id: string;
@@ -1,4 +1,6 @@
1
1
  import { InjectionKey } from 'vue';
2
+ /** 唯一标识. */
3
+ export declare const KG__DI__ID: InjectionKey<string>;
2
4
  /** 界面标识. */
3
5
  export declare const KG__DI__FORM_ID: InjectionKey<string>;
4
6
  /** 宿主界面标识. */
@@ -1,6 +1,6 @@
1
1
  import './asset/index.less';
2
- export * from '@kengic/core/react';
3
- export { API as KG_API } from './api';
2
+ export * from '@kengic/core.react';
3
+ export { API } from './api';
4
4
  export * from './api/WMS/models';
5
5
  export * from './component';
6
6
  export * from './config';
@@ -1,4 +1,18 @@
1
+ import { IKgEventListener, IRemoveEventListener } from '@kengic/core.core';
1
2
  export * from './kg-auth.util';
2
3
  export * from './kg.util';
3
4
  export * from './kg-route.util';
4
5
  export * from './kg-var.util';
6
+ /**
7
+ * 构造事件监听.
8
+ * @param formID 界面标识.
9
+ * @param store 状态管理.
10
+ * @param event 事件名称.
11
+ */
12
+ export declare function onEventFactory<S extends {
13
+ addEventListener(formID: string, event: E, listener: L): void;
14
+ removeEventListener(formID: string, event: E, listener?: L): void;
15
+ } | {
16
+ addEventListener(event: E, listener: L): void;
17
+ removeEventListener(event: E, listener?: L): void;
18
+ } = any, E = any, L extends IKgEventListener = any>(formID: string | null, store: S, event: E): (listener: L, isOnce?: boolean) => IRemoveEventListener;
@@ -28,6 +28,20 @@ export declare class KgVarUtil {
28
28
  value: any;
29
29
  varName: string;
30
30
  }): any;
31
+ /**
32
+ * 计算某个列表数据的文本.
33
+ *
34
+ * <p>
35
+ * labelColumn 可以是一个 JS 表达式, 组件库会解析该表达式, 并得到真正的值. 比如表达式 \`${row.id}\` 表示获取该行的 id 列的值. 表达式中可以使用下列变量:
36
+ * <ul>
37
+ * <li>row: 表示该行数据,</li>
38
+ * </ul>
39
+ * </p>
40
+ *
41
+ * @param row 该行数据.
42
+ * @param labelColumn 文本对应的字段或者表达式.
43
+ */
44
+ static evaluateVarConfigPossibilityLabel(row: any, labelColumn: string): string;
31
45
  /**
32
46
  * 根据控件类型, 将任意的高级查询操作符(可能非法)转换为合法的值.
33
47
  *
@@ -33,7 +33,7 @@ export declare class KgUtil {
33
33
  * <ul>
34
34
  * <li>删除无用属性,</li>
35
35
  * <li>日期转换为字符串,</li>
36
- * <li>解析动态属性, 比如「仓库号」,</li>
36
+ * <li>解析动态属性, 比如「仓库号」等等,</li>
37
37
  * </ul>
38
38
  *
39
39
  * @param params 请求参数.
@@ -45,7 +45,7 @@ export declare class KgUtil {
45
45
  * 处理请求参数: 解析字符串类型的参数值.
46
46
  *
47
47
  * <ol>
48
- * <li>填充通用参数的值:
48
+ * <li>解析动态参数的值, 若参数值是用{}包裹的, 则该参数值称为'动态参数', '动态参数'需要被替换成实际的值,
49
49
  * <ul>
50
50
  * <li>{WAREHOUSE}: 当前仓库编号</li>
51
51
  * <li>{WORK_STATION}: 当前工作站</li>
@@ -63,7 +63,7 @@ export declare class KgUtil {
63
63
  * @param param.value 参数的原始值.
64
64
  * @param param.varName 变量名称.
65
65
  */
66
- static parseParamFromString(param: {
66
+ static parseParamsFromString(param: {
67
67
  $dayjs?: typeof dayjs;
68
68
  formID?: string | null;
69
69
  value: string;
@@ -76,7 +76,7 @@ export declare class KgUtil {
76
76
  * @param param.key 属性名.
77
77
  * @param param.value 参数的原始值.
78
78
  */
79
- static parseParamFromDayjs(param: {
79
+ static parseParamsFromDayjs(param: {
80
80
  formID?: string | null;
81
81
  isPad?: boolean;
82
82
  key: string;
@@ -140,7 +140,9 @@ export declare class KgUtil {
140
140
  *
141
141
  * @return UUID.
142
142
  */
143
- static uuid(): string;
143
+ static uuid(param?: {
144
+ prefix?: string;
145
+ }): string;
144
146
  }
145
147
  export declare type ModalFunc = {
146
148
  destroy: () => void;
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@kengic/vue",
3
- "version": "0.26.6-beta.98",
3
+ "version": "0.26.6",
4
4
  "scripts": {
5
5
  "build": "npm run use-node && rimraf dist && vue-tsc && vite build",
6
6
  "build:dev": "npm run use-node && rimraf dist && vue-tsc && vite build --mode development",
7
7
  "--------------------------------------------------": "",
8
8
  "gen:apis:WMS": "npm run use-node && kengic-pont generate-apis --config kg.config.ts --origin WMS",
9
9
  "- ------------------------------------------------": "",
10
- "use-node": "nvm use 18.20.4 && corepack enable && corepack use pnpm@7.30.5",
10
+ "use-node": "npm cache clean -f && nvm use 18.20.4 && corepack enable && corepack use pnpm@9.12.1",
11
11
  "cnpm:sync": "npm run use-node && npx cnpm --yes sync @kengic/vue",
12
12
  "-- -----------------------------------------------": "",
13
13
  "publish:major": "npm run bump:major && tsx script/publish.ts",
@@ -39,7 +39,8 @@
39
39
  "@iconify-icons/mdi": "1.2.48",
40
40
  "@iconify-icons/ph": "1.2.5",
41
41
  "@iconify/vue": "4.1.2",
42
- "@kengic/core": "6.0.1-beta.110",
42
+ "@kengic/core.core": "0.0.1-beta.17",
43
+ "@kengic/core.react": "0.0.1-beta.23",
43
44
  "@kengic/pont": "1.2.17-beta.1",
44
45
  "@rys-fe/vite-plugin-theme": "0.8.6",
45
46
  "@thymine/xunee": "0.4.9-beta.8",
@@ -121,7 +122,7 @@
121
122
  }
122
123
  }
123
124
  ],
124
- "printWidth": 160,
125
+ "printWidth": 200,
125
126
  "semi": true,
126
127
  "singleAttributePerLine": true,
127
128
  "singleQuote": true,
@@ -1,16 +0,0 @@
1
- import { ExtractPropTypes, PropType } from 'vue';
2
- export declare const getProps: () => {
3
- 'onUpdate:visible': PropType<(value: boolean) => void>;
4
- visible: PropType<boolean>;
5
- };
6
- export declare type KgSearchConfigModalProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
7
- declare const _default: import("vue").DefineComponent<{
8
- 'onUpdate:visible': PropType<(value: boolean) => void>;
9
- visible: PropType<boolean>;
10
- }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:visible"[], "update:visible", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
11
- 'onUpdate:visible': PropType<(value: boolean) => void>;
12
- visible: PropType<boolean>;
13
- }>> & {
14
- "onUpdate:visible"?: ((...args: any[]) => any) | undefined;
15
- }, {}>;
16
- export default _default;