@kengic/vue 0.24.1-beta.2 → 0.25.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (38) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/index.css +1 -1
  3. package/dist/kengic-vue.js +4491 -4598
  4. package/dist/src/apis/WMS/models.d.ts +2 -2
  5. package/dist/src/components/KgForm/index.hooks.d.ts +10 -0
  6. package/dist/src/components/KgForm/index.store.d.ts +13 -3
  7. package/dist/src/components/KgForm.Item/KgForm.Item.d.ts +1 -4
  8. package/dist/src/components/KgForm.Item/addon/KgForm.Item.Addon.DynamicQueryOperator.d.ts +49 -0
  9. package/dist/src/components/KgForm.Item/components/KgForm.Item.Checkbox.d.ts +1 -6
  10. package/dist/src/components/KgForm.Item/components/KgForm.Item.CheckboxGroup.d.ts +1 -6
  11. package/dist/src/components/KgForm.Item/components/KgForm.Item.Date.d.ts +1 -4
  12. package/dist/src/components/KgForm.Item/components/KgForm.Item.DateRange.d.ts +1 -4
  13. package/dist/src/components/KgForm.Item/components/KgForm.Item.Image.d.ts +0 -2
  14. package/dist/src/components/KgForm.Item/components/KgForm.Item.Input.d.ts +1 -4
  15. package/dist/src/components/KgForm.Item/components/KgForm.Item.InputNumber.d.ts +1 -4
  16. package/dist/src/components/KgForm.Item/components/KgForm.Item.InputPassword.d.ts +96 -0
  17. package/dist/src/components/KgForm.Item/components/KgForm.Item.RadioGroup.d.ts +5 -6
  18. package/dist/src/components/KgForm.Item/components/KgForm.Item.Select.d.ts +1 -6
  19. package/dist/src/components/KgForm.Item/components/KgForm.Item.Select.service.d.ts +8 -9
  20. package/dist/src/components/KgForm.Item/components/KgForm.Item.Switch.d.ts +1 -4
  21. package/dist/src/components/KgForm.Item/components/KgForm.Item.TextArea.d.ts +1 -4
  22. package/dist/src/components/KgForm.Item/index.vm.d.ts +8 -4
  23. package/dist/src/components/KgSearch/index.store.d.ts +1 -1
  24. package/dist/src/components/KgVar/KgVar.d.ts +14 -4
  25. package/dist/src/components/KgVar/index.hooks.d.ts +4 -0
  26. package/dist/src/components/KgVar/index.store.d.ts +2 -0
  27. package/dist/src/components/KgVar/index.vm.d.ts +6 -0
  28. package/dist/src/components/KgVarConfig/index.store.d.ts +0 -17
  29. package/dist/src/config/index.store.d.ts +5 -0
  30. package/dist/src/consts/i18n/en.d.ts +1 -8
  31. package/dist/src/consts/i18n/zh_CN.d.ts +1 -7
  32. package/dist/src/pages/KgVarFactory/KgVarFactory.d.ts +62 -0
  33. package/dist/src/pages/KgVarFactory/index.d.ts +1 -0
  34. package/dist/src/pages/index.d.ts +1 -1
  35. package/package.json +1 -1
  36. package/dist/src/components/KgVarConfig/components/var/KgVarConfig.Modal.Var.d.ts +0 -2
  37. package/dist/src/pages/KgVarContainer/KgVarContainer.d.ts +0 -6
  38. package/dist/src/pages/KgVarContainer/index.d.ts +0 -1
@@ -38,10 +38,9 @@ declare const _default: import("vue").DefineComponent<{
38
38
  };
39
39
  'onUpdate:value': import("vue").PropType<(value: import("../index.vm").IKgFormItemValue | null) => void>;
40
40
  onKgSubmit: import("vue").PropType<() => void>;
41
- onKgChange: import("vue").PropType<(value: any) => void>;
42
41
  onKgSelectChange: import("vue").PropType<(value: any) => void>;
43
42
  onKgSelectDatasChange: import("vue").PropType<(datas: any[]) => void>;
44
- }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:value" | "kgSubmit" | "kgChange")[], "update:value" | "kgSubmit" | "kgChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
43
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:value" | "kgSubmit")[], "update:value" | "kgSubmit", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
45
44
  kgVarName: {
46
45
  type: import("vue").PropType<string>;
47
46
  required: boolean;
@@ -80,13 +79,11 @@ declare const _default: import("vue").DefineComponent<{
80
79
  };
81
80
  'onUpdate:value': import("vue").PropType<(value: import("../index.vm").IKgFormItemValue | null) => void>;
82
81
  onKgSubmit: import("vue").PropType<() => void>;
83
- onKgChange: import("vue").PropType<(value: any) => void>;
84
82
  onKgSelectChange: import("vue").PropType<(value: any) => void>;
85
83
  onKgSelectDatasChange: import("vue").PropType<(datas: any[]) => void>;
86
84
  }>> & {
87
85
  "onUpdate:value"?: ((...args: any[]) => any) | undefined;
88
86
  onKgSubmit?: ((...args: any[]) => any) | undefined;
89
- onKgChange?: ((...args: any[]) => any) | undefined;
90
87
  }, {
91
88
  value: import("../index.vm").IKgFormItemValue;
92
89
  kgDisabled: boolean;
@@ -78,11 +78,15 @@ export declare const getProps: () => {
78
78
  };
79
79
  'onUpdate:value': PropType<(value: IKgFormItemValue | null) => void>;
80
80
  onKgSubmit: PropType<() => void>;
81
- /** 表单控件的值发生变更. */
82
- onKgChange: PropType<(value: any | null) => void>;
83
- /** 下拉列表选中某个(可能多个)数据. */
81
+ /**
82
+ * 下拉列表选中某个(可能多个)数据.
83
+ * @deprecated
84
+ */
84
85
  onKgSelectChange: PropType<(value: any | null) => void>;
85
- /** 下拉列表数据发生变更. */
86
+ /**
87
+ * 下拉列表数据发生变更.
88
+ * @deprecated
89
+ */
86
90
  onKgSelectDatasChange: PropType<(datas: Array<any>) => void>;
87
91
  };
88
92
  export declare type KgFormItemProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
@@ -51,7 +51,7 @@ export interface IUseKgSearchStoreGetters {
51
51
  /**
52
52
  * @param formID 界面标识.
53
53
  */
54
- getDynamicQueryOperatorModel(): (formID: string | null | undefined) => Record<string, string> | null;
54
+ getDynamicQueryOperatorModel(): (formID: string | null | undefined) => Record<string, string>;
55
55
  /**
56
56
  * @param formID 界面标识.
57
57
  */
@@ -1,13 +1,16 @@
1
1
  import { ExtractPropTypes, PropType } from 'vue';
2
2
  import { IKgProps, IKgSlots } from './index.vm';
3
3
  import './KgVar.less';
4
- export declare const getProps: () => {
4
+ export declare function getProps(): {
5
5
  /**
6
6
  * 是否使用灰色背景.
7
7
  *
8
8
  * @default false
9
9
  */
10
- KgBackgroundGray: PropType<boolean>;
10
+ kgBackgroundGray: {
11
+ type: PropType<boolean>;
12
+ default: undefined;
13
+ };
11
14
  /**
12
15
  * 界面标识.
13
16
  *
@@ -42,7 +45,10 @@ declare const _default: import("vue").DefineComponent<{
42
45
  *
43
46
  * @default false
44
47
  */
45
- KgBackgroundGray: PropType<boolean>;
48
+ kgBackgroundGray: {
49
+ type: PropType<boolean>;
50
+ default: undefined;
51
+ };
46
52
  /**
47
53
  * 界面标识.
48
54
  *
@@ -73,7 +79,10 @@ declare const _default: import("vue").DefineComponent<{
73
79
  *
74
80
  * @default false
75
81
  */
76
- KgBackgroundGray: PropType<boolean>;
82
+ kgBackgroundGray: {
83
+ type: PropType<boolean>;
84
+ default: undefined;
85
+ };
77
86
  /**
78
87
  * 界面标识.
79
88
  *
@@ -99,6 +108,7 @@ declare const _default: import("vue").DefineComponent<{
99
108
  */
100
109
  kgSlots: PropType<IKgSlots>;
101
110
  }>>, {
111
+ kgBackgroundGray: boolean;
102
112
  kgLevel: number;
103
113
  }>;
104
114
  export default _default;
@@ -98,6 +98,10 @@ export declare type IUseKgVar = {
98
98
  * @param isOnce 是否只会触发一次. 默认为 undefined.
99
99
  */
100
100
  onRetrieve(listener: IKgVarRetrieveEventListener, isOnce?: boolean): IRemoveEventListenerHandler;
101
+ /**
102
+ * 父亲界面.
103
+ */
104
+ parent: ComputedRef<ReturnType<IKgVarStore['getParent']>>;
101
105
  /**
102
106
  * 查询所有变量配置.
103
107
  *
@@ -1,6 +1,7 @@
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 '../../apis/WMS/models';
3
3
  import { IKgEventListener, KG__VAR_BUTTON__TYPE } from '../../consts';
4
+ import { IUseKgVar } from './index.hooks';
4
5
  /**
5
6
  * 事件类型.
6
7
  * 'retrieve': 变量配置查询完成
@@ -88,6 +89,7 @@ export interface IUseKgVarStoreGetters {
88
89
  * 获取界面层级.
89
90
  */
90
91
  getLevel(): (formID: string | null | undefined) => number;
92
+ getParent(): (formID: string | null | undefined) => IUseKgVar | null;
91
93
  /**
92
94
  * 获取系统的 VarGridDetail 列表, 即 customLevel 为 0 的 VarGridMaster 下面的所有 VarGridDetail.
93
95
  */
@@ -36,6 +36,12 @@ export declare type IKgSlots = {
36
36
  };
37
37
  /** KgTable 下面. */
38
38
  afterKgTable?: () => any;
39
+ /**
40
+ * 孩子页面.
41
+ */
42
+ children?: {
43
+ [childFormID: string]: () => any;
44
+ };
39
45
  };
40
46
  /** 注入 kgSlots 参数. */
41
47
  export declare const KG__DI__KG_VAR__KG_SLOTS: InjectionKey<IKgSlots | undefined>;
@@ -1,23 +1,7 @@
1
1
  import { StoreDefinition } from 'pinia';
2
- import { VarConfigDescription, VarVariable } from '../../apis/WMS/models';
3
2
  export interface IUseKgVarConfigStoreState {
4
- /**
5
- * 变量.
6
- */
7
- variable: {
8
- /**
9
- * 当前选中的变量翻译.
10
- */
11
- currentVarConfigDescription: VarConfigDescription | null;
12
- /**
13
- * 当前选中的变量.
14
- */
15
- currentVarVariable: VarVariable | null;
16
- };
17
3
  }
18
4
  export interface IUseKgVarConfigStoreGetters {
19
- getCurrentVarConfigDescription: VarConfigDescription | null;
20
- getCurrentVarVariable: VarVariable | null;
21
5
  }
22
6
  export interface IUseKgVarConfigStoreActions {
23
7
  /**
@@ -26,7 +10,6 @@ export interface IUseKgVarConfigStoreActions {
26
10
  * @param hostFormID 宿主界面标识
27
11
  */
28
12
  open(hostFormID: string): void;
29
- setCurrentVarConfigDescription(variable: VarConfigDescription | null): void;
30
13
  }
31
14
  export declare type IUseKgVarConfigStore = StoreDefinition<'KgVarConfig', IUseKgVarConfigStoreState, IUseKgVarConfigStoreGetters, IUseKgVarConfigStoreActions>;
32
15
  export declare type IKgVarConfigStore = ReturnType<IUseKgVarConfigStore>;
@@ -195,6 +195,11 @@ export interface IUseKgStoreState {
195
195
  * <p>第一层 key 为 codeName, 第二层 key 为 codeValue.</p>
196
196
  */
197
197
  descriptionMap: Map<string, Map<string, Description>>;
198
+ /**
199
+ * <p>某个系统描述是否正在查询.</p>
200
+ * <p>其中的 key 表示 codeName.</p>
201
+ */
202
+ isDescriptionsRequestingMap: Map<string, boolean>;
198
203
  /** 语言. */
199
204
  locale: ComputedRef<IKgLocale> | null;
200
205
  /** 配置参数. */
@@ -23,6 +23,7 @@ declare const _default: {
23
23
  formValidationMessageForLTE: string;
24
24
  formValidationMessageForMaxLength: string;
25
25
  formValidationMessageForMinLength: string;
26
+ formValidationMessageForRegularExpression: string;
26
27
  };
27
28
  KgPageDdaCreate: {
28
29
  'confirm-cancel': string;
@@ -169,15 +170,7 @@ declare const _default: {
169
170
  tabSearch: string;
170
171
  tabSubmit: string;
171
172
  tabTable: string;
172
- varConfigControl: string;
173
- varConfigDescription: string;
174
- varConfigInput: string;
175
- varConfigLookup: string;
176
- varConfigPossibility: string;
177
- varConfigTip: string;
178
- varVariable: string;
179
173
  variable: string;
180
- variableName: string;
181
174
  };
182
175
  KgVarConfigModalButton: {
183
176
  VarButton: string;
@@ -23,6 +23,7 @@ declare const _default: {
23
23
  formValidationMessageForLTE: string;
24
24
  formValidationMessageForMaxLength: string;
25
25
  formValidationMessageForMinLength: string;
26
+ formValidationMessageForRegularExpression: string;
26
27
  };
27
28
  KgPageDdaCreate: {
28
29
  'confirm-cancel': string;
@@ -168,15 +169,8 @@ declare const _default: {
168
169
  tabSearch: string;
169
170
  tabSubmit: string;
170
171
  tabTable: string;
171
- varConfigControl: string;
172
- varConfigDescription: string;
173
- varConfigInput: string;
174
- varConfigLookup: string;
175
- varConfigPossibility: string;
176
- varConfigTip: string;
177
172
  varVariable: string;
178
173
  variable: string;
179
- variableName: string;
180
174
  };
181
175
  KgVarConfigModalButton: {
182
176
  VarButton: string;
@@ -0,0 +1,62 @@
1
+ import './KgVarFactory.less';
2
+ export declare function KgVarFactory(param?: {
3
+ formID?: string | null | undefined;
4
+ }): import("vue").DefineComponent<{
5
+ kgBackgroundGray: {
6
+ type: import("vue").PropType<boolean>;
7
+ default: undefined;
8
+ };
9
+ kgFormID: import("vue").PropType<string>;
10
+ kgLevel: {
11
+ type: import("vue").PropType<number>;
12
+ default: number;
13
+ };
14
+ kgProps: import("vue").PropType<import("../../components").IKgProps>;
15
+ kgSlots: import("vue").PropType<import("../../components").IKgSlots>;
16
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
17
+ kgBackgroundGray: {
18
+ type: import("vue").PropType<boolean>;
19
+ default: undefined;
20
+ };
21
+ kgFormID: import("vue").PropType<string>;
22
+ kgLevel: {
23
+ type: import("vue").PropType<number>;
24
+ default: number;
25
+ };
26
+ kgProps: import("vue").PropType<import("../../components").IKgProps>;
27
+ kgSlots: import("vue").PropType<import("../../components").IKgSlots>;
28
+ }>>, {
29
+ kgBackgroundGray: boolean;
30
+ kgLevel: number;
31
+ }>;
32
+ /**
33
+ * 默认的 KgVar 组件.
34
+ */
35
+ export declare const DEFAULT: import("vue").DefineComponent<{
36
+ kgBackgroundGray: {
37
+ type: import("vue").PropType<boolean>;
38
+ default: undefined;
39
+ };
40
+ kgFormID: import("vue").PropType<string>;
41
+ kgLevel: {
42
+ type: import("vue").PropType<number>;
43
+ default: number;
44
+ };
45
+ kgProps: import("vue").PropType<import("../../components").IKgProps>;
46
+ kgSlots: import("vue").PropType<import("../../components").IKgSlots>;
47
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
48
+ kgBackgroundGray: {
49
+ type: import("vue").PropType<boolean>;
50
+ default: undefined;
51
+ };
52
+ kgFormID: import("vue").PropType<string>;
53
+ kgLevel: {
54
+ type: import("vue").PropType<number>;
55
+ default: number;
56
+ };
57
+ kgProps: import("vue").PropType<import("../../components").IKgProps>;
58
+ kgSlots: import("vue").PropType<import("../../components").IKgSlots>;
59
+ }>>, {
60
+ kgBackgroundGray: boolean;
61
+ kgLevel: number;
62
+ }>;
@@ -0,0 +1 @@
1
+ export { KgVarFactory, DEFAULT as KgVar2 } from './KgVarFactory';
@@ -1,6 +1,6 @@
1
1
  export * from './KgPageDda';
2
2
  export { default as KgPageDda } from './KgPageDda';
3
- export * from './KgVarContainer';
3
+ export * from './KgVarFactory';
4
4
  /**
5
5
  * 路由.
6
6
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kengic/vue",
3
- "version": "0.24.1-beta.2",
3
+ "version": "0.25.0",
4
4
  "scripts": {
5
5
  "build": "npm run switch-node-version && rimraf dist && vue-tsc && vite build",
6
6
  "build:dev": "npm run switch-node-version && rimraf dist && vue-tsc && vite build --mode development",
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, () => JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
2
- export default _default;
@@ -1,6 +0,0 @@
1
- import { KgVarProps } from '../../components';
2
- import './KgVarContainer.less';
3
- export declare function KgVarContainer(param: {
4
- formID: string | null | undefined;
5
- props?: KgVarProps;
6
- }): import("vue").DefineComponent<{}, () => null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}> | import("vue").DefineComponent<{}, () => JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
@@ -1 +0,0 @@
1
- export { KgVarContainer } from './KgVarContainer';