cnhis-design-vue 3.1.42-beta.64 → 3.1.42-beta.66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +87 -87
- package/es/components/form-config/index.d.ts +2 -2
- package/es/components/form-config/src/FormConfig.vue.d.ts +2 -2
- package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +1 -1
- package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +1 -1
- package/es/components/form-render/index.d.ts +1 -1
- package/es/components/form-render/src/FormRender.vue.d.ts +1 -1
- package/es/components/form-render/src/FormRender.vue.js +1 -1
- package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +1 -1
- package/es/components/form-render/src/components/renderer/searchCascade.js +1 -1
- package/es/components/form-render/src/hooks/useBusinessBinding.d.ts +1 -0
- package/es/components/form-render/src/hooks/useBusinessBinding.js +1 -1
- package/es/components/form-render/src/hooks/useFormEvent.d.ts +1 -1
- package/es/components/form-render/src/hooks/useFormEvent.js +1 -1
- package/es/components/form-render/src/types/index.d.ts +1 -1
- package/es/components/iho-table/src/plugins/filterDaterangeRenderPlugin/filter.vue.d.ts +44 -0
- package/es/components/iho-table/src/plugins/filterDaterangeRenderPlugin/filter.vue.js +1 -0
- package/es/components/iho-table/src/plugins/filterDaterangeRenderPlugin/index.d.ts +1 -0
- package/es/components/iho-table/src/plugins/filterDaterangeRenderPlugin/index.js +1 -0
- package/es/components/iho-table/src/plugins/index.js +1 -1
- package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +1 -1
- package/es/components/iho-table/src/types/index.d.ts +4 -0
- package/es/components/iho-table/src/utils/index.d.ts +1 -0
- package/es/components/iho-table/src/utils/index.js +1 -1
- package/es/components/info-header/index.d.ts +2 -2
- package/es/components/info-header/src/InfoHeader.vue.d.ts +2 -2
- package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +1 -1
- package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +1 -1
- package/es/components/scale-view/src/ScaleView.vue.js +1 -1
- package/es/components/select-label/src/LabelFormContent.vue.js +1 -1
- package/es/components/shortcut-setter/index.d.ts +1 -1
- package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +1 -1
- package/es/env.d.ts +25 -25
- package/es/shared/package.json.js +1 -1
- package/package.json +65 -65
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +0 -1
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +0 -1
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +0 -1
- package/es/components/fabric-chart/src/utils/index.d.ts +0 -6823
- package/es/components/form-render/src/components/renderer/dist/levelSearchCascader.d.ts +0 -77
- package/es/components/form-render/src/components/renderer/dist/searchCascade.d.ts +0 -84
- package/es/components/iho-table/src/plugins/dist/highLightSetPlugin.d.ts +0 -3
- package/es/components/iho-table/src/plugins/filterRenderPlugin/dist/index.d.ts +0 -3
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/dist/defaultRendererPlugin.d.ts +0 -3
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/dist/seqRendererPlugin.d.ts +0 -3
- package/es/components/scale-view/src/components/formitem/dist/r-address.d.ts +0 -36
- package/es/components/scale-view/src/components/formitem/dist/r-sign.d.ts +0 -36
- package/es/components/scale-view/src/components/formitem/dist/standard-modal.d.ts +0 -82
- package/es/components/search-cascader/src/components/dist/SearchMenu.d.ts +0 -57
- package/es/components/search-cascader/src/components/dist/SearchMenu1.d.ts +0 -57
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +0 -86
- package/es/shared/utils/tapable/index.d.ts +0 -139
package/README.md
CHANGED
|
@@ -1,87 +1,87 @@
|
|
|
1
|
-
# 安装
|
|
2
|
-
|
|
3
|
-
```shell
|
|
4
|
-
npm i cnhis-design-vue@[版本号]
|
|
5
|
-
# or
|
|
6
|
-
yarn add cnhis-design-vue@[版本号] #推荐
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
## 1.全局引入
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
// main.ts
|
|
13
|
-
import { createApp } from 'vue';
|
|
14
|
-
import App from './App.vue';
|
|
15
|
-
import 'cnhis-design-vue/es/packages/index.css';
|
|
16
|
-
import cui from 'cnhis-design-vue';
|
|
17
|
-
|
|
18
|
-
const app = createApp(App);
|
|
19
|
-
app.use(cui).mount('#app');
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
## 2. 按需引入
|
|
23
|
-
|
|
24
|
-
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
|
25
|
-
|
|
26
|
-
### 2.1 样式处理方式1 (按需引入样式)
|
|
27
|
-
|
|
28
|
-
```shell
|
|
29
|
-
# 安装自动导入样式的插件
|
|
30
|
-
npm i -d vite-plugin-style-import
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
```typescript
|
|
34
|
-
// vite.config.ts
|
|
35
|
-
import { defineConfig } from 'vite';
|
|
36
|
-
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
|
37
|
-
|
|
38
|
-
export default defineConfig({
|
|
39
|
-
plugins: [
|
|
40
|
-
// ...otherPlugins
|
|
41
|
-
createStyleImportPlugin({
|
|
42
|
-
libs: [
|
|
43
|
-
{
|
|
44
|
-
libraryName: 'cnhis-design-vue',
|
|
45
|
-
esModule: true,
|
|
46
|
-
ensureStyleFile: true,
|
|
47
|
-
resolveStyle: name => {
|
|
48
|
-
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
]
|
|
52
|
-
})
|
|
53
|
-
]
|
|
54
|
-
});
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
### 2.2 样式处理方式2 (全局引入样式)
|
|
58
|
-
|
|
59
|
-
```typescript
|
|
60
|
-
// main.ts
|
|
61
|
-
import 'cnhis-design-vue/es/components/index.css';
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
## 3.FAQ
|
|
65
|
-
|
|
66
|
-
### 3.1 项目打包后样式丢失
|
|
67
|
-
|
|
68
|
-
处理方法, 将 cnhis-design-vue 从 vendor 包中移除 (没有出现此问题则不需要)
|
|
69
|
-
|
|
70
|
-
```typescript
|
|
71
|
-
// vite.config.ts
|
|
72
|
-
import { defineConfig } from 'vite';
|
|
73
|
-
|
|
74
|
-
export default defineConfig({
|
|
75
|
-
build: {
|
|
76
|
-
rollupOptions: {
|
|
77
|
-
// ..otherOptions
|
|
78
|
-
output: {
|
|
79
|
-
dir: './dist',
|
|
80
|
-
manualChunks: {
|
|
81
|
-
'cnhis-vendor': ['cnhis-design-vue']
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
});
|
|
87
|
-
```
|
|
1
|
+
# 安装
|
|
2
|
+
|
|
3
|
+
```shell
|
|
4
|
+
npm i cnhis-design-vue@[版本号]
|
|
5
|
+
# or
|
|
6
|
+
yarn add cnhis-design-vue@[版本号] #推荐
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## 1.全局引入
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
// main.ts
|
|
13
|
+
import { createApp } from 'vue';
|
|
14
|
+
import App from './App.vue';
|
|
15
|
+
import 'cnhis-design-vue/es/packages/index.css';
|
|
16
|
+
import cui from 'cnhis-design-vue';
|
|
17
|
+
|
|
18
|
+
const app = createApp(App);
|
|
19
|
+
app.use(cui).mount('#app');
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## 2. 按需引入
|
|
23
|
+
|
|
24
|
+
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
|
25
|
+
|
|
26
|
+
### 2.1 样式处理方式1 (按需引入样式)
|
|
27
|
+
|
|
28
|
+
```shell
|
|
29
|
+
# 安装自动导入样式的插件
|
|
30
|
+
npm i -d vite-plugin-style-import
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
```typescript
|
|
34
|
+
// vite.config.ts
|
|
35
|
+
import { defineConfig } from 'vite';
|
|
36
|
+
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
|
37
|
+
|
|
38
|
+
export default defineConfig({
|
|
39
|
+
plugins: [
|
|
40
|
+
// ...otherPlugins
|
|
41
|
+
createStyleImportPlugin({
|
|
42
|
+
libs: [
|
|
43
|
+
{
|
|
44
|
+
libraryName: 'cnhis-design-vue',
|
|
45
|
+
esModule: true,
|
|
46
|
+
ensureStyleFile: true,
|
|
47
|
+
resolveStyle: name => {
|
|
48
|
+
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
]
|
|
52
|
+
})
|
|
53
|
+
]
|
|
54
|
+
});
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### 2.2 样式处理方式2 (全局引入样式)
|
|
58
|
+
|
|
59
|
+
```typescript
|
|
60
|
+
// main.ts
|
|
61
|
+
import 'cnhis-design-vue/es/components/index.css';
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
## 3.FAQ
|
|
65
|
+
|
|
66
|
+
### 3.1 项目打包后样式丢失
|
|
67
|
+
|
|
68
|
+
处理方法, 将 cnhis-design-vue 从 vendor 包中移除 (没有出现此问题则不需要)
|
|
69
|
+
|
|
70
|
+
```typescript
|
|
71
|
+
// vite.config.ts
|
|
72
|
+
import { defineConfig } from 'vite';
|
|
73
|
+
|
|
74
|
+
export default defineConfig({
|
|
75
|
+
build: {
|
|
76
|
+
rollupOptions: {
|
|
77
|
+
// ..otherOptions
|
|
78
|
+
output: {
|
|
79
|
+
dir: './dist',
|
|
80
|
+
manualChunks: {
|
|
81
|
+
'cnhis-vendor': ['cnhis-design-vue']
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
});
|
|
87
|
+
```
|
|
@@ -3952,7 +3952,7 @@ declare const FormConfig: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
3952
3952
|
exposeEvent: {
|
|
3953
3953
|
validate(path?: string): Promise<void>;
|
|
3954
3954
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
3955
|
-
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
3955
|
+
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
3956
3956
|
setFieldState(path: string, handler: (field: Partial<Pick<import("@formily/core").Field<any, any, any, any>, import("@formily/core").NonFunctionPropertyNames<{
|
|
3957
3957
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
3958
3958
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -9891,7 +9891,7 @@ declare const FormConfig: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
9891
9891
|
exposeEvent: {
|
|
9892
9892
|
validate(path?: string): Promise<void>;
|
|
9893
9893
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
9894
|
-
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
9894
|
+
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
9895
9895
|
setFieldState(path: string, handler: (field: Partial<Pick<import("@formily/core").Field<any, any, any, any>, import("@formily/core").NonFunctionPropertyNames<{
|
|
9896
9896
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
9897
9897
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -3954,7 +3954,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
3954
3954
|
exposeEvent: {
|
|
3955
3955
|
validate(path?: string): Promise<void>;
|
|
3956
3956
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
3957
|
-
setFormValues(values: import("../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
3957
|
+
setFormValues(values: import("../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
3958
3958
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
3959
3959
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
3960
3960
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -9893,7 +9893,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
9893
9893
|
exposeEvent: {
|
|
9894
9894
|
validate(path?: string): Promise<void>;
|
|
9895
9895
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
9896
|
-
setFormValues(values: import("../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
9896
|
+
setFormValues(values: import("../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
9897
9897
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
9898
9898
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
9899
9899
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -439,7 +439,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
439
439
|
exposeEvent: {
|
|
440
440
|
validate(path?: string): Promise<void>;
|
|
441
441
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
442
|
-
setFormValues(values: import("../../../../shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
442
|
+
setFormValues(values: import("../../../../shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
443
443
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
444
444
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
445
445
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -5520,7 +5520,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
5520
5520
|
exposeEvent: {
|
|
5521
5521
|
validate(path?: string): Promise<void>;
|
|
5522
5522
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
5523
|
-
setFormValues(values: import("../../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
5523
|
+
setFormValues(values: import("../../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
5524
5524
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
5525
5525
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
5526
5526
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -426,7 +426,7 @@ declare const FormRender: SFCWithInstall<import("vue").DefineComponent<{}, {
|
|
|
426
426
|
exposeEvent: {
|
|
427
427
|
validate(path?: string): Promise<void>;
|
|
428
428
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
429
|
-
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
429
|
+
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
430
430
|
setFieldState(path: string, handler: (field: Partial<Pick<import("@formily/core/esm/models/Field").Field<any, any, any, any>, import("@formily/core/esm/types").NonFunctionPropertyNames<{
|
|
431
431
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
432
432
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -420,7 +420,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
420
420
|
exposeEvent: {
|
|
421
421
|
validate(path?: string): Promise<void>;
|
|
422
422
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
423
|
-
setFormValues(values: AnyObject, needSplitExtendKey?: boolean): void;
|
|
423
|
+
setFormValues(values: AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
424
424
|
setFieldState(path: string, handler: (field: Partial<Pick<import("@formily/core").Field<any, any, any, any>, import("@formily/core").NonFunctionPropertyNames<{
|
|
425
425
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
426
426
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,ref as o,computed as t,provide as r,onMounted as s,onUnmounted as a,openBlock as i,createBlock as l,unref as n,normalizeClass as m,normalizeStyle as p,withCtx as d,createElementBlock as u,createVNode as c,isRef as f,Fragment as h,renderList as y,createCommentVNode as j,createElementVNode as
|
|
1
|
+
import{defineComponent as e,ref as o,computed as t,provide as r,onMounted as s,onUnmounted as a,openBlock as i,createBlock as l,unref as n,normalizeClass as m,normalizeStyle as p,withCtx as d,createElementBlock as u,createVNode as c,isRef as f,Fragment as h,renderList as y,createCommentVNode as j,createElementVNode as g,withKeys as b,withModifiers as k,toDisplayString as v,renderSlot as F}from"vue";import{useTheme as x}from"../../../shared/hooks/useTheme.js";import"@vueuse/core";import"date-fns";import{isNumber as C,cloneDeep as H}from"lodash-es";import{createForm as S,onFieldValueChange as A,onFieldMount as L,onFieldUnmount as R,onFieldReact as _,onFormMount as O}from"@formily/core";import{FormProvider as B,FormConsumer as w}from"@formily/vue";import{NForm as V,NTabs as I,NTabPane as N,NConfigProvider as D}from"naive-ui";import{InjectionFormGraph as q}from"./constants/index.js";import{useAutoHidden as U}from"./hooks/useAutoHidden.js";import{useComplexOptionsSpan as W}from"./hooks/useComplexOptions.js";import{useFormDomEvent as G,useFormExposeEvent as T}from"./hooks/useFormEvent.js";import{useFormGraph as K}from"./hooks/useFormGraph.js";import{useFormRenderLifeCycle as M}from"./hooks/useFormRenderLifeCycle.js";import{useLowCodeReactions as E}from"./hooks/useLowCodeReactions.js";import{useNuiThemeOverrides as P}from"./hooks/useNuiThemeOverrides.js";import"./utils/index.js";import{useFieldListAdaptor as J}from"./hooks/useFieldListAdaptor.js";import"../../../shared/utils/index.js";import"../index.js";import{useFieldVisitor as $}from"./hooks/useFieldVisitor.js";import"../../../shared/utils/tapable/SyncHook.js";import"../../../shared/utils/tapable/SyncBailHook.js";import"../../../shared/utils/tapable/SyncWaterfallHook.js";import"../../../shared/utils/tapable/SyncLoopHook.js";import"../../../shared/utils/tapable/AsyncParallelHook.js";import"../../../shared/utils/tapable/AsyncParallelBailHook.js";import"../../../shared/utils/tapable/AsyncSeriesHook.js";import"../../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";import{validateMessageLocale as z}from"./hooks/useFormValidator.js";import{useAnchor as Q}from"./hooks/useAnchor.js";import{useFormContext as X}from"./hooks/useFormContext.js";import"./hooks/useFormRenderOptions.js";import Y from"../../../_virtual/plugin-vue_export-helper.js";import{createObjSchema as Z}from"./utils/schema.js";const ee={key:0,style:{height:"54px"}},oe={style:{"white-space":"pre"}};var te=Y(e({__name:"FormRender",props:{fieldList:{type:Array},initialData:{type:Object,default:()=>({})},fieldVisitor:{type:Object},column:{type:Number,default:24},maxHeight:{type:[Number,String],default:""},anchor:{type:Boolean,default:!1},parallelism:{type:Number,default:3},businessFormatter:{type:Function},schema:{type:Object},components:{type:Object,default:()=>({})},scope:{type:Object,default:()=>({})},annotation:{type:Object},consumer:{type:Boolean,default:!1},uuid:{type:String},lifeCycle:{type:Object},requestInstance:{type:Object},enterToNextWidget:{type:[Boolean,Function],default:!0},lowCodeReactions:{type:Array},linebarAutoHidden:{type:Boolean},bordered:{type:Boolean,default:!0}},emits:["formChange","annotationChange","scroll"],setup(e,{expose:Y,emit:te}){const re=e,se=x(),{nuiThemeOverrides:ae}=P();z();const ie=o(),le=t((()=>C(re.maxHeight)?re.maxHeight+"px":re.maxHeight)),{SchemaField:ne,businessCollector:me,formItemDepsCollector:pe,changeContextCollector:de,formUUID:ue}=X(re,te),{anchorBarRef:ce,currentAnchor:fe,generateAnchorList:he,updateAnchorList:ye,anchorIdList:je,onScroll:ge}=Q(re,te,ie,pe);M(re).callLifeCycle("onSetup");const{trigger:be}=U(),{observeFormGraph:ke,setGraph:ve,removeGraph:Fe}=K();r(q,ke);const xe=S({initialValues:re.initialData,effects(e){A("*",(o=>{const t=o.props.name.toString();me.trigger(e,t),pe.trigger(t),te("formChange",{fieldInstance:o,fieldKey:t,fieldName:o.title,value:o.value,context:de.getContext(t,o.value)}),Ce(t,o.value)})),L("*",ve),R("*",Fe),re.linebarAutoHidden&&(_("*",be),O((e=>e.query("*").forEach(be)))),re.anchor&&(_("*",ye),O(he))}}),{lowCodeReactionsHandler:Ce,triggerAllReactionsHandler:He}=E(t((()=>re.lowCodeReactions)),xe);s(He);const{schemaAdaptor:Se}=J(me);let Ae=re.fieldList||[];const Le=t((()=>re.schema?re.schema:re.fieldList?(Ae=$().traverse(H(re.fieldList),re.fieldVisitor),Z(Se(Ae))):Z({}))),{onKeydown:Re}=G({formModel:xe,formRenderRef:ie,props:re}),{clearSpan:_e}=W();a((()=>_e(ue)));const Oe=T({formModel:xe,formRenderRef:ie,formItemDepsCollector:pe,getFieldList:()=>Ae,formUUID:ue});return Y({formModel:xe,validate:(e="*")=>Oe.validate(e),getFormValues:(e=!0)=>Oe.getFormValues(e),setFormValues(e,o=!0,t=!1,r=!0){t&&(me.triggerLock=!0),Oe.setFormValues(e,o,r),me.triggerLock=!1},setFieldState(e,o){Oe.setFieldState(e,o)},resetFields(e="*"){Oe.resetFields(e)},queryWidget:async e=>Oe.queryWidget(e),getFieldList:()=>Ae,async reload(){console.error("reload function is abstract,it should be overwrite!")}}),(o,t)=>(i(),l(n(V),{class:m(["form-render",{"form-render--no-border":!e.bordered}]),"require-mark-placement":"left",style:p(n(se))},{default:d((()=>[e.anchor?(i(),u("section",ee,[c(n(I),{value:n(fe),"onUpdate:value":t[0]||(t[0]=e=>f(fe)?fe.value=e:null),type:"line",ref_key:"anchorBarRef",ref:ce},{default:d((()=>[(i(!0),u(h,null,y(n(je),(e=>(i(),l(n(N),{name:e.name,tab:e.title,key:e.name},null,8,["name","tab"])))),128))])),_:1},8,["value"])])):j("v-if",!0),c(n(D),{"theme-overrides":n(ae)},{default:d((()=>[g("section",{class:"form-render__wrapper",style:p({"--column":e.column,"--form-height":n(le)}),ref_key:"formRenderRef",ref:ie,onScroll:t[1]||(t[1]=(...e)=>n(ge)&&n(ge)(...e)),onKeydownCapture:t[2]||(t[2]=b(k(((...e)=>n(Re)&&n(Re)(...e)),["prevent"]),["enter"]))},[c(n(B),{form:n(xe)},{default:d((()=>[c(n(ne),{schema:n(Le)},null,8,["schema"]),e.consumer?(i(),l(n(w),{key:0},{default:d((({form:e})=>[g("div",oe,v(JSON.stringify(e.values,null,2)),1)])),_:1})):j("v-if",!0),F(o.$slots,"default")])),_:3},8,["form"])],36)])),_:3},8,["theme-overrides"])])),_:3},8,["class","style"]))}}),[["__file","FormRender.vue"]]);export{te as default};
|
|
@@ -424,7 +424,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
424
424
|
exposeEvent: {
|
|
425
425
|
validate(path?: string): Promise<void>;
|
|
426
426
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
427
|
-
setFormValues(values: import("../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
427
|
+
setFormValues(values: import("../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
428
428
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
429
429
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
430
430
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,ref as t,computed as a,inject as l,watch as r,createVNode as o,nextTick as n}from"vue";import{isEqual as
|
|
1
|
+
import{defineComponent as e,ref as t,computed as a,inject as l,watch as r,createVNode as o,nextTick as n}from"vue";import{isEqual as i,isArray as u,isString as s}from"lodash-es";import"../../../index.js";import{useCommonInjection as c}from"../../hooks/useCommonInjection.js";import{InjectionAsyncQueue as p,InjectionFormUUID as d}from"../../constants/index.js";import"../../../../../shared/utils/index.js";import"../../utils/index.js";import{useFormField as m}from"../../hooks/useFormField.js";import{NCascader as v}from"naive-ui";import"@vueuse/core";import"date-fns";import"../../../../../shared/utils/tapable/SyncHook.js";import"../../../../../shared/utils/tapable/SyncBailHook.js";import"../../../../../shared/utils/tapable/SyncWaterfallHook.js";import"../../../../../shared/utils/tapable/SyncLoopHook.js";import"../../../../../shared/utils/tapable/AsyncParallelHook.js";import"../../../../../shared/utils/tapable/AsyncParallelBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";import"../../hooks/useFormValidator.js";import"@formily/core";import"@formily/reactive";import{connect as f,mapProps as h}from"@formily/vue";import"@vue/shared";import"./index.js";import"../../hooks/useFormRenderOptions.js";import{createVisitedSetter as y,assignUpdateValue as k,traverseDependKey as j}from"../../utils/schema.js";const g=f(e({name:"FormCascader",props:{options:{type:Array,default:()=>[]},depth:{type:[Number,String]},urlConfig:{type:Object},requestCache:{type:Boolean,default:!0},onFocus:{type:Function},filterable:{type:Boolean,default:!1},checkStrategy:{type:String,default:"child"},labelField:{type:String,default:"text"},valueField:{type:String,default:"value"},onChange:{},value:{}},emits:["update:value"],setup(e,{slots:f,emit:h}){const k=t(),{field:g,title:b}=m(),S=t(1),C=a((()=>{var t,a,l;return null!=(l=null!=(a=null==(t=e.urlConfig)?void 0:t.nameKey)?a:e.labelField)?l:"text"})),w=a((()=>{var t,a,l;return null!=(l=null!=(a=null==(t=e.urlConfig)?void 0:t.valueKey)?a:e.valueField)?l:"value"})),F=a((()=>{try{const t=Array.isArray(e.value)?e.value:JSON.parse(e.value||"");return Array.isArray(t)&&t.length?t.map((e=>e[w.value])).slice(-1).join(""):null}catch(e){return null}}));function A(e,t,a){h("update:value",u(a)?a.map((function(e){return{...e,label:e[C.value],children:void 0,parent:void 0,mergeItemValue:void 0}})):null)}const H=l(p);async function x(t){e.filterable?await async function(){if(!e.urlConfig||k.value&&e.requestCache)return;const t=await H.addAsync({...e.urlConfig,params:{lvlnr:"1"},key:b.value,cache:e.requestCache});function a(e,t,r){const o=[...r,...l(e)],n={[C.value]:e[C.value],[w.value]:e[w.value],depth:t+1,isLeaf:!0,keyword:e.keyword,mergeItemValue:o};return u(e.children)&&(n.children=e.children.map((e=>a(e,t+1,o))),n.isLeaf=!e.children.length),S.value=Math.max(S.value,t+1),n}function l(e){let t=[];if(s(e[C.value])&&(t=[...t,e[C.value]]),s(e.keyword)&&e.keyword.length>0){const a=e.keyword.split(",");t=[...t,...a]}return t}k.value=t.map((e=>a(e,0,[])))}():await async function(t){if(r(e,t))return;const a=await H.addAsync(o(s(t),u(e),b.value,t));if(!a.length&&t)return t.isLeaf=!0,A(0,0,n(t)),void(E.value=!1);const l=a.map((e=>i(e,s(t))));function r(e,t){return!u(e)||!t&&k.value&&e.requestCache||s(t)>=s(e)-1}function o(t,a,l,r){const o={lvlnr:t+1+""};return r&&a.dependKey&&j(a.dependKey,((e,t)=>{o[t]=r[e]})),{params:o,...a,key:l,cache:e.requestCache}}function n(e){let t=e;const a=[e];for(;t.parent;)a.unshift(t.parent),t=t.parent;return a}function i(a,l){return{[C.value]:a[C.value],[w.value]:a[w.value],depth:l+1,parent:t,isLeaf:l+2>=s(e)}}function u(e){return e.urlConfig}function s(e){var t;return null!=(t=null==e?void 0:e.depth)?t:-1}t?t.children=l:k.value=l}(t),await L()}const V=`form-render__cascade--menu-${l(d)}`;async function L(){await n();const e=document.querySelector(`.${V} .v-vl`);e&&e.dispatchEvent(new CustomEvent("scroll"))}function q(t,a){if(!t||!a)return!1;const{mergeItemValue:l}=a;if(e.checkStrategy.includes("child")&&a.depth<S.value)return!1;return l.length>0&&l.some((e=>e.includes(t.trim())))}const{injectValueValidate:B,injectValueWatchFromEmpty:K,injectValueBindKey:I}=c();K((()=>e.value),x),B((()=>e.value)),r((()=>e.urlConfig),(async(e,t)=>{i(e,t)||(k.value=null,await x())}));const E=t(!1);function O(e){E.value=!!e,e&&x()}const W=a((()=>k.value||e.options||[])),N=a((()=>!e.filterable)),P=I(F);return()=>o(v,{key:P.value,remote:N.value,filterable:e.filterable,"menu-props":{class:V,onClick:L},"check-strategy":e.checkStrategy,show:!!E.value,"onUpdate:show":O,value:F.value,filter:q,"onUpdate:value":A,labelField:C.value,valueField:w.value,options:W.value,onLoad:x,onFocus:y(g)},f)}}),h({dataSource:"options"},k));export{g as SEARCH_CASCADER};
|
|
@@ -3,6 +3,7 @@ import { FieldItem, FormBusinessFormatter } from '../../../../../es/components/f
|
|
|
3
3
|
import { FIELD_BUSINESS_TYPE } from '../constants';
|
|
4
4
|
export declare class BusinessCollector {
|
|
5
5
|
private businessFormatter?;
|
|
6
|
+
triggerLock: boolean;
|
|
6
7
|
private readonly typeLockMap;
|
|
7
8
|
private readonly typeCollector;
|
|
8
9
|
private readonly fieldNameCollector;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isField as e}from"@formily/core";import{isString as t}from"@vueuse/core";import{format as s}from"date-fns";import{isFunction as i,isNumber as r}from"lodash-es";import{FIELD_BUSINESS_TYPE as n}from"../constants/index.js";import"../utils/index.js";import{isIdCard as a,parseIdCard as l,parseAgeFromContext as o,parseBirthday as u,parseAge2Birthday as y}from"../utils/business.js";class h{constructor(e){this.businessFormatter=e,this.typeLockMap=new Map,this.typeCollector=new Map,this.fieldNameCollector=new Map,this.changeHandlerMap=new Map([])}formatter(...e){return i(this.businessFormatter)?this.businessFormatter(...e):e[0].value}collect(e,t){this.typeCollector.set(e,t),this.fieldNameCollector.set(t.val_key,e)}getField(e){return this.typeCollector.get(e)}getFieldInstanceByType(e,t){const s=this.getField(t);return s?e.query(s.val_key).take():null}getType(e){return this.fieldNameCollector.get(e)}getValueByField(t,s){const i=t.query(s).take();return e(i)?i.value:null}getValueByType(e,t){const s=this.getField(t);return s?this.getValueByField(e,s.val_key):null}setValueByType(e,t,s){const i=this.getField(t);i&&e.setFieldState(i.val_key,(e=>{if(e.value===s)return;const n=this.typeLockMap.get(t);this.typeLockMap.set(t,r(n)?n+1:1),e.value=this.formatter({value:s,type:t,fieldKey:i.val_key})}))}registerChangeBusiness(e,t){return this.changeHandlerMap.set(e,t),this}trigger(e,t,s="change"){var i;const r=this.getType(t);if(!r)return;if("change"===s&&this.typeLockMap.get(r)>0)return this.typeLockMap.set(r,this.typeLockMap.get(r)-1);const n="change"===s?this.changeHandlerMap:null;n&&(null==(i=n.get(r))||i.call(this,e))}}function c(){function e(){var e;const t=this.getField(n.BIRTHDAY);return null!=(e=null==t?void 0:t.date_format)?e:"yyyy-MM-dd HH:mm"}function i(i){const r=this.getValueByType(i,n.ID_CARD);if(!r||!t(r)||!a(r))return;const u=l(r),{age:y,ageUnit:h}=o(u);this.setValueByType(i,n.AGE_UNIT,h),this.setValueByType(i,n.AGE,y),this.setValueByType(i,n.SEX,u.sex),this.setValueByType(i,n.BIRTHDAY,s(new Date(u.birthday),e.call(this)))}function c(e){const s=this.getValueByType(e,n.BIRTHDAY);if(!t(s))return;const{age:i,ageUnit:r}=o(u(s));this.setValueByType(e,n.AGE_UNIT,r),this.setValueByType(e,n.AGE,i)}function
|
|
1
|
+
import{isField as e}from"@formily/core";import{isString as t}from"@vueuse/core";import{format as s}from"date-fns";import{isFunction as i,isNumber as r}from"lodash-es";import{FIELD_BUSINESS_TYPE as n}from"../constants/index.js";import"../utils/index.js";import{isIdCard as a,parseIdCard as l,parseAgeFromContext as o,parseBirthday as u,parseAge2Birthday as y}from"../utils/business.js";class h{constructor(e){this.businessFormatter=e,this.triggerLock=!1,this.typeLockMap=new Map,this.typeCollector=new Map,this.fieldNameCollector=new Map,this.changeHandlerMap=new Map([])}formatter(...e){return i(this.businessFormatter)?this.businessFormatter(...e):e[0].value}collect(e,t){this.typeCollector.set(e,t),this.fieldNameCollector.set(t.val_key,e)}getField(e){return this.typeCollector.get(e)}getFieldInstanceByType(e,t){const s=this.getField(t);return s?e.query(s.val_key).take():null}getType(e){return this.fieldNameCollector.get(e)}getValueByField(t,s){const i=t.query(s).take();return e(i)?i.value:null}getValueByType(e,t){const s=this.getField(t);return s?this.getValueByField(e,s.val_key):null}setValueByType(e,t,s){const i=this.getField(t);i&&e.setFieldState(i.val_key,(e=>{if(e.value===s)return;const n=this.typeLockMap.get(t);this.typeLockMap.set(t,r(n)?n+1:1),e.value=this.formatter({value:s,type:t,fieldKey:i.val_key})}))}registerChangeBusiness(e,t){return this.changeHandlerMap.set(e,t),this}trigger(e,t,s="change"){var i;if(this.triggerLock)return;const r=this.getType(t);if(!r)return;if("change"===s&&this.typeLockMap.get(r)>0)return this.typeLockMap.set(r,this.typeLockMap.get(r)-1);const n="change"===s?this.changeHandlerMap:null;n&&(null==(i=n.get(r))||i.call(this,e))}}function c(){function e(){var e;const t=this.getField(n.BIRTHDAY);return null!=(e=null==t?void 0:t.date_format)?e:"yyyy-MM-dd HH:mm"}function i(i){const r=this.getValueByType(i,n.ID_CARD);if(!r||!t(r)||!a(r))return;const u=l(r),{age:y,ageUnit:h}=o(u);this.setValueByType(i,n.AGE_UNIT,h),this.setValueByType(i,n.AGE,y),this.setValueByType(i,n.SEX,u.sex),this.setValueByType(i,n.BIRTHDAY,s(new Date(u.birthday),e.call(this)))}function c(e){const s=this.getValueByType(e,n.BIRTHDAY);if(!t(s))return;const{age:i,ageUnit:r}=o(u(s));this.setValueByType(e,n.AGE_UNIT,r),this.setValueByType(e,n.AGE,i)}function g(s){const i=this.getValueByType(s,n.AGE),a=this.getValueByType(s,n.AGE_UNIT);(t(i)||r(i))&&""!==i&&t(a)&&""!==a&&this.setValueByType(s,n.BIRTHDAY,y(+i,a,e.call(this)))}return{create:function(e){return new h(e).registerChangeBusiness(n.ID_CARD,i).registerChangeBusiness(n.AGE_UNIT,g).registerChangeBusiness(n.AGE,g).registerChangeBusiness(n.BIRTHDAY,c)}}}export{h as BusinessCollector,c as useBusinessBinding};
|
|
@@ -11,7 +11,7 @@ export declare function useFormExposeEvent({ formModel, formRenderRef, formUUID,
|
|
|
11
11
|
}): {
|
|
12
12
|
validate(path?: string): Promise<void>;
|
|
13
13
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
14
|
-
setFormValues(values: AnyObject, needSplitExtendKey?: boolean): void;
|
|
14
|
+
setFormValues(values: AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
15
15
|
setFieldState(path: string, handler: (field: IFieldState) => void): void;
|
|
16
16
|
resetFields(path?: string): Promise<void>;
|
|
17
17
|
queryWidget(key: string): Promise<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{arrayed as e,findAncestor as t}from"../../../../shared/utils/index.js";import{isField as r}from"@formily/core";import{Path as o}from"@formily/path";import{isObject as i}from"@vue/shared";import{promiseTimeout as n}from"@vueuse/shared";import{isArray as s,isFunction as a}from"lodash-es";import{nextTick as m}from"vue";import"../../index.js";import{FormItemLineBarDepKeyPrepend as u,NESTED_FORM_ITEM_TYPE as f}from"../constants/index.js";import{queryDecoratorByAddress as l,queryInput as d,queryDecoratorByFieldKey as c,findNextWidget as p}from"../utils/dom.js";import{validateMessageParser as g,combineExtendKey as v,splitExtendKey as y}from"../utils/index.js";import{getParentLinebar as h}from"../utils/schema.js";function I({formModel:t,formRenderRef:n,formUUID:a,getFieldList:f,formItemDepsCollector:p}){return{validate(r="*"){return t.validate(r).catch((e=>Promise.reject(Array.isArray(e)?e.reduce(o,[]):e)));function o(t,r){if(!i(r))return t;let o=!1;return s(r.messages)&&r.messages.forEach((r=>{i(r)&&(t.push(...e(r).map(m)),o=!0)})),!o&&t.push(m(r)),t}function m(e){if(e.decoratorElement)return e;const r=t.query(e.path),o=r.get("title"),s=e.messages.map((e=>function(e,t){var r;return t&&i(t.fieldItem)?g(null!=(r=t.fieldItem.defined_error_msg)?r:e,t.fieldItem):e}(e,r.get("decoratorProps")))),m=l(e.address,n.value,a);return{...e,messages:s,title:o,decoratorElement:m,...d(m)}}},getFormValues(e=!0){let r=t.getFormState().values;return e&&(r=v(f(),r)),r},setFormValues(e,i=!0){i&&(e=y(f(),e)),t.setFieldState("*",(t=>{r(t)&&(t.value=o.getIn(e,t.path))}))},setFieldState(e,r){t.setFieldState(e,r)},resetFields:(e="*")=>t.reset(e),queryWidget:async e=>n.value?await async function(e,t,r){if(!n.value)return s();const o=c(e,t,a);if(o)return s(o);const i=h(e,r);return i?(p.trigger(u+i,!0),await m(),s(c(e,t,a))):s();function s(e){return{decoratorElement:e,...d(e)}}}(e,n.value,f()):null}}function x({props:e,formRenderRef:r,formModel:o}){return{onKeydown:function i(s){var m;if(!e.enterToNextWidget||!r.value)return;const u=t(s.target,(e=>e.classList.contains("form-render__formItem")));if(!u)return;const l=`.form-render__formItem${f.map((e=>`:not([widget-type=${e}])`)).join("")}`,d=Array.from(r.value.querySelectorAll(l)),c=d.findIndex((e=>e.id===u.id));if(!~c)return;const{widget:g,field:v}=p(d,c,s.target);if(g)if(a(e.enterToNextWidget)){const t=v&&o.query(v).take();!t||e.enterToNextWidget(null==(m=t.decoratorProps)?void 0:m.fieldItem)?y():i({target:g})}else y();async function y(){await n(0),g.focus()}}}}export{x as useFormDomEvent,I as useFormExposeEvent};
|
|
1
|
+
import{arrayed as e,findAncestor as t}from"../../../../shared/utils/index.js";import{isField as r}from"@formily/core";import{Path as o}from"@formily/path";import{isObject as i}from"@vue/shared";import{promiseTimeout as n}from"@vueuse/shared";import{isArray as s,isFunction as a}from"lodash-es";import{nextTick as m}from"vue";import"../../index.js";import{FormItemLineBarDepKeyPrepend as u,NESTED_FORM_ITEM_TYPE as f}from"../constants/index.js";import{queryDecoratorByAddress as l,queryInput as d,queryDecoratorByFieldKey as c,findNextWidget as p}from"../utils/dom.js";import{validateMessageParser as g,combineExtendKey as v,splitExtendKey as y}from"../utils/index.js";import{getParentLinebar as h}from"../utils/schema.js";function I({formModel:t,formRenderRef:n,formUUID:a,getFieldList:f,formItemDepsCollector:p}){return{validate(r="*"){return t.validate(r).catch((e=>Promise.reject(Array.isArray(e)?e.reduce(o,[]):e)));function o(t,r){if(!i(r))return t;let o=!1;return s(r.messages)&&r.messages.forEach((r=>{i(r)&&(t.push(...e(r).map(m)),o=!0)})),!o&&t.push(m(r)),t}function m(e){if(e.decoratorElement)return e;const r=t.query(e.path),o=r.get("title"),s=e.messages.map((e=>function(e,t){var r;return t&&i(t.fieldItem)?g(null!=(r=t.fieldItem.defined_error_msg)?r:e,t.fieldItem):e}(e,r.get("decoratorProps")))),m=l(e.address,n.value,a);return{...e,messages:s,title:o,decoratorElement:m,...d(m)}}},getFormValues(e=!0){let r=t.getFormState().values;return e&&(r=v(f(),r)),r},setFormValues(e,i=!0,n=!0){i&&(e=y(f(),e)),t.setFieldState("*",(t=>{r(t)&&(n||o.existIn(e,t.path))&&(t.value=o.getIn(e,t.path))}))},setFieldState(e,r){t.setFieldState(e,r)},resetFields:(e="*")=>t.reset(e),queryWidget:async e=>n.value?await async function(e,t,r){if(!n.value)return s();const o=c(e,t,a);if(o)return s(o);const i=h(e,r);return i?(p.trigger(u+i,!0),await m(),s(c(e,t,a))):s();function s(e){return{decoratorElement:e,...d(e)}}}(e,n.value,f()):null}}function x({props:e,formRenderRef:r,formModel:o}){return{onKeydown:function i(s){var m;if(!e.enterToNextWidget||!r.value)return;const u=t(s.target,(e=>e.classList.contains("form-render__formItem")));if(!u)return;const l=`.form-render__formItem${f.map((e=>`:not([widget-type=${e}])`)).join("")}`,d=Array.from(r.value.querySelectorAll(l)),c=d.findIndex((e=>e.id===u.id));if(!~c)return;const{widget:g,field:v}=p(d,c,s.target);if(g)if(a(e.enterToNextWidget)){const t=v&&o.query(v).take();!t||e.enterToNextWidget(null==(m=t.decoratorProps)?void 0:m.fieldItem)?y():i({target:g})}else y();async function y(){await n(0),g.focus()}}}}export{x as useFormDomEvent,I as useFormExposeEvent};
|
|
@@ -31,7 +31,7 @@ export declare type FormRenderExpose = {
|
|
|
31
31
|
formModel: Form;
|
|
32
32
|
validate(path?: string): Promise<unknown>;
|
|
33
33
|
getFormValues(needCombineExtendKey?: boolean): AnyObject;
|
|
34
|
-
setFormValues(values: AnyObject, needSplitExtendKey?: boolean): AnyObject;
|
|
34
|
+
setFormValues(values: AnyObject, needSplitExtendKey?: boolean, avoidBusinessConnection?: boolean, overwrite?: boolean): AnyObject;
|
|
35
35
|
setFieldState(path: string, setter: (field: Field) => void): void;
|
|
36
36
|
resetFields(path?: string): void;
|
|
37
37
|
queryWidget(key: string): Promise<{
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { PropType } from 'vue';
|
|
2
|
+
import { VxeColumnPropTypes } from 'vxe-table';
|
|
3
|
+
declare const _default: import("vue").DefineComponent<{
|
|
4
|
+
payload: {
|
|
5
|
+
type: PropType<VxeColumnPropTypes.FilterSlotParams>;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
}, {
|
|
9
|
+
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
10
|
+
payload: {
|
|
11
|
+
type: PropType<VxeColumnPropTypes.FilterSlotParams>;
|
|
12
|
+
required: true;
|
|
13
|
+
};
|
|
14
|
+
}>> & {}>>;
|
|
15
|
+
optionRef: {
|
|
16
|
+
label: string | number;
|
|
17
|
+
value: any;
|
|
18
|
+
data: any;
|
|
19
|
+
resetValue: any;
|
|
20
|
+
checked: boolean;
|
|
21
|
+
_checked: boolean;
|
|
22
|
+
};
|
|
23
|
+
onConfirm: (value: [number, number], formattedValue: [string, string] | null) => void;
|
|
24
|
+
CDatePicker: import("../../../../../shared/types").SFCWithInstall<import("vue").DefineComponent<{}, {
|
|
25
|
+
attrs: {
|
|
26
|
+
[x: string]: unknown;
|
|
27
|
+
};
|
|
28
|
+
datePickerRef: import("vue").Ref<import("../../../../../shared/types").AnyObject | null>;
|
|
29
|
+
panelInstRef: import("vue").Ref<null>;
|
|
30
|
+
isDateTime: import("vue").ComputedRef<boolean>;
|
|
31
|
+
formatRef: import("vue").ComputedRef<string>;
|
|
32
|
+
panelFormatRef: import("vue").ComputedRef<string | [string, string]>;
|
|
33
|
+
focus: () => any;
|
|
34
|
+
blur: () => any;
|
|
35
|
+
onUpdateShow: (show: boolean) => void;
|
|
36
|
+
NDatePicker: any;
|
|
37
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>>;
|
|
38
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
39
|
+
payload: {
|
|
40
|
+
type: PropType<VxeColumnPropTypes.FilterSlotParams>;
|
|
41
|
+
required: true;
|
|
42
|
+
};
|
|
43
|
+
}>>, {}>;
|
|
44
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{defineComponent as e,reactive as a,openBlock as l,createBlock as t,unref as o}from"vue";import r from"../../../../date-picker/index.js";import n from"../../../../../_virtual/plugin-vue_export-helper.js";var i=n(e({__name:"filter",props:{payload:{type:Object,required:!0}},setup(e){var n,i,p;const d=e,u=a((null==(p=null==(i=null==(n=d.payload)?void 0:n.column)?void 0:i.filters)?void 0:p[0])||{data:void 0});function v(e,a){var l;u.value=a,(null==(l=d.payload)?void 0:l.$panel)&&(d.payload.$panel.changeOption(null,!!a,u),d.payload.$panel.confirmFilter(new CustomEvent("click")))}return(e,a)=>(l(),t(o(r),{type:"datetimerange",panel:"",clearable:"","formatted-value":u.data,"onUpdate:formatted-value":a[0]||(a[0]=e=>u.data=e),onConfirm:v},null,8,["formatted-value"]))}}),[["__file","filter.vue"]]);export{i as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function filterDaterangeRenderPlugin(): import("../../../../../../es/components/iho-table").TablePlugin;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createVNode as e}from"vue";import"../../../index.js";import t from"./filter.vue.js";import{isValid as i}from"date-fns";import{isObject as o}from"@vue/shared";import{defineTablePlugin as r}from"../../hooks/useTablePlugin.js";function n(){const n="filterDaterangeRenderPlugin";return r({name:n,vxe(i){i.renderer.mixin({filterDaterangeRenderPlugin:{showFilterFooter:!1,renderFilter:(i,o)=>e(t,{payload:o,key:o.column.field},null)}})},apply(e){e.fieldHooks.field.tap(n,((e,t,r,{$table:n})=>{var l,a;const f=null==(l=e.editRender)?void 0:l.props;return o(f)&&(null==(a=null==f?void 0:f.filterSetting)?void 0:a.daterange)?(e.filterRender={name:"filterDaterangeRenderPlugin"},e.filters=[{data:void 0}],e.filterMethod||(e.filterMethod=function({option:e,row:t,column:o}){const{data:r}=e,n=t[o.field];if(!i(new Date(n)))return!1;const l=new Date(n).getTime(),a=new Date(r[0]).getTime(),f=new Date(r[1]).getTime();return l>=a&&l<=f}),e.sortable?e.headerClassName=({$table:e,column:t})=>{const i=["iho-table__hideSortIcon"];return e.isSort(t)&&i.push("is--filter-active"),i}:e.headerClassName="iho-table__hideSortIcon",r.filterConfig={iconMatch:"iho-table--iconfont iho-table-icon-filter",iconNone:"iho-table--iconfont iho-table-icon-filter",...r.filterConfig},e):e}))}})}export{n as filterDaterangeRenderPlugin};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as e from"./anchorPlugin/index.js";import*as r from"./defaultConfigPlugin/index.js";import*as i from"./
|
|
1
|
+
import*as e from"./anchorPlugin/index.js";import*as r from"./defaultConfigPlugin/index.js";import*as i from"./filterDaterangeRenderPlugin/index.js";import*as n from"./filterRenderPlugin/index.js";import*as d from"./highLightSetPlugin.js";import*as s from"./keyboardEventPlugin/index.js";import*as t from"./lowCodeFieldAdaptorPlugin/index.js";import*as l from"./maxCheckSizePlugin.js";import*as g from"./rendererPlugins/editableWidgets/dateRendererPlugin/index.js";import*as u from"./rendererPlugins/editableWidgets/inputRendererPlugin.js";import*as o from"./rendererPlugins/editableWidgets/numberRendererPlugin.js";import*as a from"./rendererPlugins/editableWidgets/selectRendererPlugin/index.js";import*as P from"./rendererPlugins/editableWidgets/separateRendererPlugin/index.js";import*as m from"./rendererPlugins/editableWidgets/timeRendererPlugin/index.js";import*as x from"./rendererPlugins/widgets/checkRendererPlugin.js";import*as f from"./rendererPlugins/widgets/colorRendererPlugin.js";import*as p from"./rendererPlugins/widgets/defaultRendererPlugin.js";import*as R from"./rendererPlugins/widgets/labelRendererPlugin.js";import*as j from"./rendererPlugins/widgets/pictureRendererPlugin.js";import*as b from"./rendererPlugins/widgets/seqRendererPlugin.js";import*as w from"./rowClickPlugin/index.js";import*as c from"./rowDragPlugin/index.js";import*as h from"./rowGroupSettingPlugin/index.js";import*as W from"./varialbleHeightPlugin/index.js";import*as k from"./virtualTreePlugin/index.js";import{separateMetaModule as C}from"../../../../shared/utils/index.js";var v=C(Object.assign({"./anchorPlugin/index.tsx":e,"./defaultConfigPlugin/index.ts":r,"./filterDaterangeRenderPlugin/index.tsx":i,"./filterRenderPlugin/index.tsx":n,"./highLightSetPlugin.tsx":d,"./keyboardEventPlugin/index.ts":s,"./lowCodeFieldAdaptorPlugin/index.tsx":t,"./maxCheckSizePlugin.ts":l,"./rendererPlugins/editableWidgets/dateRendererPlugin/index.tsx":g,"./rendererPlugins/editableWidgets/inputRendererPlugin.tsx":u,"./rendererPlugins/editableWidgets/numberRendererPlugin.tsx":o,"./rendererPlugins/editableWidgets/selectRendererPlugin/index.tsx":a,"./rendererPlugins/editableWidgets/separateRendererPlugin/index.tsx":P,"./rendererPlugins/editableWidgets/timeRendererPlugin/index.tsx":m,"./rendererPlugins/widgets/checkRendererPlugin.tsx":x,"./rendererPlugins/widgets/colorRendererPlugin.tsx":f,"./rendererPlugins/widgets/defaultRendererPlugin.tsx":p,"./rendererPlugins/widgets/labelRendererPlugin.tsx":R,"./rendererPlugins/widgets/pictureRendererPlugin.tsx":j,"./rendererPlugins/widgets/seqRendererPlugin.tsx":b,"./rowClickPlugin/index.ts":w,"./rowDragPlugin/index.ts":c,"./rowGroupSettingPlugin/index.ts":h,"./varialbleHeightPlugin/index.tsx":W,"./virtualTreePlugin/index.ts":k}));export{v as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{toRaw as e,h as t,inject as l,createVNode as i}from"vue";import{arrayed as o,widthAppend as s}from"../../../../../shared/utils/index.js";import{isObject as n,isFunction as d,cloneDeep as a,isString as r}from"lodash-es";import{NEllipsis as u}from"naive-ui";import f from"../../../../annotation-edit/index.js";import{HIGHEST_PRIORITY as m,IHO_TABLE_FIXED_STATUS as c,LOWEST_PRIORITY as p,WIDGET_TYPE as h,InjectionIhoTableAnnotation as v,InjectionIhoTableConfig as b}from"../../constants/index.js";import{defineTablePlugin as g}from"../../hooks/useTablePlugin.js";import{IhoTableStatusHelper as R,IhoTableUtils as j,IhoTableRenderHelper as x}from"../../utils/index.js";import{getDefaultValue as P}from"../rendererPlugins/editableWidgets/selectRendererPlugin/selectUtils.js";function F(){const F="lowCodeFieldAdaptorPlugin";return g({name:F,apply(g){g.fieldHooks.field.tap({name:F,stage:m},((m,p,g)=>{const F=m,S={className:F.bold?"iho-table__boldCell":"",field:F.columnName,showOverflow:"tooltip",visible:R.notNegative(F.isShow),minWidth:F.colWidth,sortable:R.isPositive(F.isSort),fixed:c[F.isFixed],...F,title:F.alias||F.title};return function(e,a){const m={default:a.slotFn,header:a.headerSlotFn,edit:a.editSlotFn,footer:a.footerSlotFn,...a.slots};if(d(a.checkEditStatus)){const{default:e}=m;d(e)&&(m.default=l=>a.checkEditStatus(l)?e(l):[t("span",null,P(l.row,l.column.editRender.props))])}const c=m.header;m.header=e=>function(e,t,a){const m=l(v),c=l(b),p=e.column||{},h=n(null==m?void 0:m.value)&&!1!==t.annotation,g=x.isEditableColumn(c.value,p),R=p.sortable||x.hasFilter(t),j=r(a)?a:d(a)?a(e):null;let P=!1;if(c.value){const e=c.value.editRules&&c.value.editRules[p.field];e&&(P=o(e).some((e=>e.required)))}return i("section",{class:"iho-table__headerWrapper"},[i("section",{style:{width:s(Math.max(0,p.renderWidth-20-(P?14:0)-(h?18:0)-(R?23:0)-(g?22:0)))}},[null!=j?j:i(u,{style:{maxWidth:"100%"}},{default:()=>p.title})]),h?i(f,{modelValue:m.value[p.field],"onUpdate:modelValue":e=>m.value[p.field]=e},null):null])}(e,a,c),e.slots=m}(S,F),function(t,l,i){var o,s;const r=a(e(l));r.componentProps={size:"mini"===i.size?"small":i.size,...r.componentProps},t.editRender={autofocus:"input",name:j.getCellType(l),props:r},t.editRender.enabled=!Reflect.get(h,t.editRender.name),d(null==(o=t.slots)?void 0:o.default)&&(t.editRender.enabled=t.editRender.enabled&&d(null==(s=t.slots)?void 0:s.edit));if(!n(l.settingObj))return;Reflect.has(l.settingObj,"isHide")&&(t.visible=t.visible&&R.notPositive(l.settingObj.isHide))}(S,F,g),S})),g.fieldHooks.field.tap({name:F+"After",stage:p},(e=>(n(e.slots)&&Object.entries(e.slots).forEach((([t,l])=>{null==l&&Reflect.deleteProperty(e.slots,t)})),e)))}})}export{F as lowCodeFieldAdaptorPlugin};
|
|
1
|
+
import{toRaw as e,h as t,inject as l,createVNode as i}from"vue";import{arrayed as o,widthAppend as s}from"../../../../../shared/utils/index.js";import{isObject as n,isFunction as d,cloneDeep as a,isString as r}from"lodash-es";import{NEllipsis as u}from"naive-ui";import f from"../../../../annotation-edit/index.js";import{HIGHEST_PRIORITY as m,IHO_TABLE_FIXED_STATUS as c,LOWEST_PRIORITY as p,WIDGET_TYPE as h,InjectionIhoTableAnnotation as v,InjectionIhoTableConfig as b}from"../../constants/index.js";import{defineTablePlugin as g}from"../../hooks/useTablePlugin.js";import{IhoTableStatusHelper as R,IhoTableUtils as j,IhoTableRenderHelper as x}from"../../utils/index.js";import{getDefaultValue as P}from"../rendererPlugins/editableWidgets/selectRendererPlugin/selectUtils.js";function F(){const F="lowCodeFieldAdaptorPlugin";return g({name:F,apply(g){g.fieldHooks.field.tap({name:F,stage:m},((m,p,g)=>{const F=m,S={className:F.bold?"iho-table__boldCell":"",field:F.columnName,showOverflow:"tooltip",visible:R.notNegative(F.isShow),minWidth:F.colWidth,sortable:R.isPositive(F.isSort),fixed:c[F.isFixed],...F,title:F.alias||F.title};return function(e,a){const m={default:a.slotFn,header:a.headerSlotFn,edit:a.editSlotFn,footer:a.footerSlotFn,...a.slots};if(d(a.checkEditStatus)){const{default:e}=m;d(e)&&(m.default=l=>a.checkEditStatus(l)?e(l):[t("span",null,P(l.row,l.column.editRender.props))])}const c=m.header;m.header=e=>function(e,t,a){const m=l(v),c=l(b),p=e.column||{},h=n(null==m?void 0:m.value)&&!1!==t.annotation,g=x.isEditableColumn(c.value,p),R=p.sortable||x.hasFilter(t)||x.hasDateFiler(t),j=r(a)?a:d(a)?a(e):null;let P=!1;if(c.value){const e=c.value.editRules&&c.value.editRules[p.field];e&&(P=o(e).some((e=>e.required)))}return i("section",{class:"iho-table__headerWrapper"},[i("section",{style:{width:s(Math.max(0,p.renderWidth-20-(P?14:0)-(h?18:0)-(R?23:0)-(g?22:0)))}},[null!=j?j:i(u,{style:{maxWidth:"100%"}},{default:()=>p.title})]),h?i(f,{modelValue:m.value[p.field],"onUpdate:modelValue":e=>m.value[p.field]=e},null):null])}(e,a,c),e.slots=m}(S,F),function(t,l,i){var o,s;const r=a(e(l));r.componentProps={size:"mini"===i.size?"small":i.size,...r.componentProps},t.editRender={autofocus:"input",name:j.getCellType(l),props:r},t.editRender.enabled=!Reflect.get(h,t.editRender.name),d(null==(o=t.slots)?void 0:o.default)&&(t.editRender.enabled=t.editRender.enabled&&d(null==(s=t.slots)?void 0:s.edit));if(!n(l.settingObj))return;Reflect.has(l.settingObj,"isHide")&&(t.visible=t.visible&&R.notPositive(l.settingObj.isHide))}(S,F,g),S})),g.fieldHooks.field.tap({name:F+"After",stage:p},(e=>(n(e.slots)&&Object.entries(e.slots).forEach((([t,l])=>{null==l&&Reflect.deleteProperty(e.slots,t)})),e)))}})}export{F as lowCodeFieldAdaptorPlugin};
|
|
@@ -51,6 +51,9 @@ export declare namespace IhoTableLowCodeField {
|
|
|
51
51
|
}>;
|
|
52
52
|
};
|
|
53
53
|
}>;
|
|
54
|
+
type FilterSetting = Partial<{
|
|
55
|
+
daterange: boolean;
|
|
56
|
+
}>;
|
|
54
57
|
type ColorAndIconItem = {
|
|
55
58
|
condition?: {
|
|
56
59
|
con: LOW_CODE_VALUE_RELATION;
|
|
@@ -111,6 +114,7 @@ export declare type LowCodeTableFieldItem = {
|
|
|
111
114
|
checkEditStatus: (payload: VxeTableDefines.CellRenderBodyParams) => boolean | void;
|
|
112
115
|
colorAndIcon: IhoTableLowCodeField.ColorAndIconItem[];
|
|
113
116
|
variableHeight: boolean;
|
|
117
|
+
filterSetting: IhoTableLowCodeField.FilterSetting;
|
|
114
118
|
}> & Partial<VxeTableDefines.ColumnInfo>;
|
|
115
119
|
export declare type IhoTableFormChangePayload = {
|
|
116
120
|
column: IhoTableFieldItem;
|
|
@@ -36,6 +36,7 @@ export declare const IhoTableRenderHelper: Readonly<{
|
|
|
36
36
|
createRenderEdit: typeof createRenderEdit;
|
|
37
37
|
isEditableColumn(config: IhoTableConfig, column: IhoTableFieldItem): boolean | undefined;
|
|
38
38
|
hasFilter(lowCodeField: LowCodeTableFieldItem): boolean;
|
|
39
|
+
hasDateFiler(lowCodeField: LowCodeTableFieldItem): boolean | undefined;
|
|
39
40
|
}>;
|
|
40
41
|
export declare const IhoTableStatusHelper: Readonly<{
|
|
41
42
|
isPositive(value: string | number | undefined | null): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{reactive as e,inject as n,unref as t,toRaw as r,createVNode as i}from"vue";import{jsonParse as o,arrayed as u,findAncestor as l}from"../../../../shared/utils/index.js";import{promiseTimeout as c}from"@vueuse/shared";import{isNumber as
|
|
1
|
+
import{reactive as e,inject as n,unref as t,toRaw as r,createVNode as i}from"vue";import{jsonParse as o,arrayed as u,findAncestor as l}from"../../../../shared/utils/index.js";import{promiseTimeout as c}from"@vueuse/shared";import{isNumber as a,cloneDeep as d,isString as s,isObject as f,isArray as m}from"lodash-es";import{InjectionIhoTableEmits as p,InjectionIhoTableConfig as v,IHO_TABLE_STRING_STATUS as g,IHO_TABLE_NUMBER_STATUS as E,IHO_TABLE_TREE_TYPE as I}from"../constants/index.js";function h(e){return console.warn(`[IhoTable]: ${e}`)}const T=Object.freeze({getCellType(e){var n;return((null==(n=e.settingObj)?void 0:n.attr)||e.formType||"DEFAULT").toUpperCase()}});function C(){var e,t,r;const i=n(v);return i||h("this function(getRowHeight) only can be used in setup environment"),null!=(r=null==(t=null==(e=null==i?void 0:i.value)?void 0:e.rowConfig)?void 0:t.height)?r:32}function R(e){const n=e.slice(2);return`${n[0].toLowerCase()}${n.slice(1)}`}function S(e){return`on${e[0].toUpperCase()}${e.slice(1)}`}function w(n,t=!0){const r=t?e(new Map):new Map;return{getItemFromUUID:function(e){return r.set(e,r.get(e)||n()).get(e)},setItemFromUUID:function(e,n){r.set(e,n)},removeItemFromUUID:function(e){r.delete(e)}}}async function O(e,n){return r()||await c(0),r()||function(){const n=+e.colWidth;return a(n)?n:64}();function r(){var r,i;return null==(i=null==(r=t(n))?void 0:r.getColumnByField(e.field))?void 0:i.renderWidth}}function F(e){const t=n(p);function i(){var n;return{value:e.row[e.column.field],row:e.row,column:{...e.column,...null==(n=e.column.editRender)?void 0:n.props},index:e.rowIndex>-1?e.rowIndex:e.$rowIndex}}function o(e={}){t("formChange",{...i(),...d(r(e))})}function u(e={}){t("formClick",{...i(),...d(r(e))})}return{emitFormChange:function(){o()},emitFormClick:function(){u()},emitFormChangeWithParams:o,emitFormClickWithParams:u}}const P=Object.freeze({createDefaultRenderCell:function(){return function(e,{row:n,column:t}){return[i("span",null,[n[t.field]])]}},createRenderEdit:function(e){return function({props:n},t){return e({...t,fieldItem:n||{},...F(t)})}},isEditableColumn(e,n){var t;return!1!==(null==(t=e.editConfig)?void 0:t.showIcon)&&n.editRender&&!1!==n.editRender.enabled},hasFilter(e){if(y(e))return!0;let n=e.fieldSetting;return s(n)&&(n=o(n||"")),f(n)&&((t=n).notParticipatingSearch!==g.POSITIVE&&"manual"===(null==(r=t.mapping)?void 0:r.type));var t,r},hasDateFiler(e){var n;return null==(n=null==e?void 0:e.filterSetting)?void 0:n.daterange}}),A=Object.freeze({isPositive:e=>e===E.POSITIVE||e===g.POSITIVE,isNegative:e=>e===E.NEGATIVE||e===g.NEGATIVE,notPositive:e=>e!==E.POSITIVE&&e!==g.POSITIVE,notNegative:e=>e!==E.NEGATIVE&&e!==g.NEGATIVE}),N=(e,n)=>({$event:t,column:r})=>{var i;if(!u(e).includes(null==(i=r.editRender)?void 0:i.name))return!0;const o=null==t?void 0:t.target;return!f(o)||!l(o,n)};function V(e){return[I.TRANSFORM_WITH_SPAN_METHOD,I.TRANSFORM_TREE_TYPE].includes(`${e.isTree}`)}function $(e){return s(e)&&!!e.match(/^###\{[^{}]+}$/)}function x(e){try{return JSON.parse(e.replace(/^###/,""))}catch(e){return{}}}function U(e,n){if(e.$__SEPARATE||!n.editRender||!n.editRender.props)return e[n.field];const{fieldSetting:t}=n.editRender.props;if(!s(t))return e[n.field];const{mergedFeildExpression:r}=o(t);return r&&s(r)?r.replace(/#{(.+?)}/g,(function(n,t){let r=t?e[t.trim()]:null;$(r)&&(r=x(r).change_text);return r||(null==r?"--":r)})):e[n.field]}const b=["SEARCH","SELECT","RADIO","CHECKBOX"];function y(e){return e.notParticipatingSearch===E.NEGATIVE&&b.includes(T.getCellType(e))&&m(e.options)&&e.options.length}export{P as IhoTableRenderHelper,A as IhoTableStatusHelper,T as IhoTableUtils,h as IhoTableWarn,N as createIhoTableClearActivedInterceptor,R as eventListener2EventName,S as eventName2EventListener,O as getColumnRenderWidth,C as getRowHeight,y as isCompatibleColumn,$ as isRichContent,V as isTransformTreeType,U as parseMergeField,x as parseRichContent,F as useIhoTableFormEvent,w as useUUIDMap};
|
|
@@ -2878,7 +2878,7 @@ declare const InfoHeader: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
2878
2878
|
exposeEvent: {
|
|
2879
2879
|
validate(path?: string): Promise<void>;
|
|
2880
2880
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
2881
|
-
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
2881
|
+
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
2882
2882
|
setFieldState(path: string, handler: (field: Partial<Pick<import("@formily/core").Field<any, any, any, any>, import("@formily/core").NonFunctionPropertyNames<{
|
|
2883
2883
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
2884
2884
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -3727,7 +3727,7 @@ declare const InfoHeader: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
3727
3727
|
exposeEvent: {
|
|
3728
3728
|
validate(path?: string): Promise<void>;
|
|
3729
3729
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
3730
|
-
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
3730
|
+
setFormValues(values: import("../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
3731
3731
|
setFieldState(path: string, handler: (field: Partial<Pick<import("@formily/core").Field<any, any, any, any>, import("@formily/core").NonFunctionPropertyNames<{
|
|
3732
3732
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
3733
3733
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -2872,7 +2872,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
2872
2872
|
exposeEvent: {
|
|
2873
2873
|
validate(path?: string): Promise<void>;
|
|
2874
2874
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
2875
|
-
setFormValues(values: AnyObject, needSplitExtendKey?: boolean): void;
|
|
2875
|
+
setFormValues(values: AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
2876
2876
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
2877
2877
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
2878
2878
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -3721,7 +3721,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
3721
3721
|
exposeEvent: {
|
|
3722
3722
|
validate(path?: string): Promise<void>;
|
|
3723
3723
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
3724
|
-
setFormValues(values: AnyObject, needSplitExtendKey?: boolean): void;
|
|
3724
|
+
setFormValues(values: AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
3725
3725
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
3726
3726
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
3727
3727
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|
|
@@ -2460,7 +2460,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
2460
2460
|
exposeEvent: {
|
|
2461
2461
|
validate(path?: string): Promise<void>;
|
|
2462
2462
|
getFormValues(needCombineExtendKey?: boolean): any;
|
|
2463
|
-
setFormValues(values: import("../../../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean): void;
|
|
2463
|
+
setFormValues(values: import("../../../../../../es/shared/types").AnyObject, needSplitExtendKey?: boolean, overwrite?: boolean): void;
|
|
2464
2464
|
setFieldState(path: string, handler: (field: Partial<Pick<import("../../../../../../es/components/form-render").Field<any, any, any, any>, import("../../../../../../es/components/form-render").NonFunctionPropertyNames<{
|
|
2465
2465
|
match: (pattern: import("@formily/path").Pattern) => boolean;
|
|
2466
2466
|
validate: (triggerType?: import("@formily/validator").ValidatorTriggerType | undefined) => any;
|