amis-core 6.9.0-rc.0 → 6.9.0-rc.1
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/esm/Root.js +1 -1
- package/esm/RootRenderer.js +2 -2
- package/esm/SchemaRenderer.js +1 -1
- package/esm/Scoped.js +1 -1
- package/esm/StatusScoped.js +1 -1
- package/esm/WithRootStore.js +1 -1
- package/esm/WithStore.js +10 -10
- package/esm/actions/Action.js +1 -1
- package/esm/actions/AjaxAction.js +1 -1
- package/esm/actions/BreakAction.js +1 -1
- package/esm/actions/BroadcastAction.js +1 -1
- package/esm/actions/CmptAction.js +1 -1
- package/esm/actions/ContinueAction.js +1 -1
- package/esm/actions/CopyAction.js +1 -1
- package/esm/actions/CustomAction.js +1 -1
- package/esm/actions/DialogAction.js +1 -1
- package/esm/actions/DrawerAction.js +1 -1
- package/esm/actions/EmailAction.js +1 -1
- package/esm/actions/EventAction.js +1 -1
- package/esm/actions/LinkAction.js +1 -1
- package/esm/actions/LoopAction.js +1 -1
- package/esm/actions/PageAction.js +1 -1
- package/esm/actions/ParallelAction.js +1 -1
- package/esm/actions/PrintAction.js +1 -1
- package/esm/actions/StatusAction.js +1 -1
- package/esm/actions/SwitchAction.js +1 -1
- package/esm/actions/ToastAction.js +1 -1
- package/esm/actions/WaitAction.js +1 -1
- package/esm/components/CustomStyle.js +1 -1
- package/esm/components/ErrorBoundary.js +1 -1
- package/esm/components/LazyComponent.js +1 -1
- package/esm/components/Overlay.js +1 -1
- package/esm/components/PopOver.js +1 -1
- package/esm/env.js +1 -1
- package/esm/envOverwrite.js +1 -1
- package/esm/factory.js +4 -2
- package/esm/index.js +2 -2
- package/esm/locale.js +1 -1
- package/esm/polyfills.js +1 -1
- package/esm/renderers/Form.d.ts +3 -3
- package/esm/renderers/Form.js +15 -7
- package/esm/renderers/Item.d.ts +18 -12
- package/esm/renderers/Item.js +1 -1
- package/esm/renderers/Options.js +1 -1
- package/esm/renderers/Placeholder.js +1 -1
- package/esm/renderers/builtin.js +1 -1
- package/esm/renderers/register.js +1 -1
- package/esm/renderers/wrapControl.d.ts +3 -3
- package/esm/renderers/wrapControl.js +19 -6
- package/esm/store/app.d.ts +3 -3
- package/esm/store/app.js +1 -1
- package/esm/store/combo.d.ts +15 -15
- package/esm/store/combo.js +1 -1
- package/esm/store/crud.d.ts +3 -3
- package/esm/store/crud.js +1 -1
- package/esm/store/form.d.ts +7 -7
- package/esm/store/form.js +24 -6
- package/esm/store/formItem.js +1 -1
- package/esm/store/iRenderer.d.ts +4 -3
- package/esm/store/iRenderer.js +28 -4
- package/esm/store/index.js +1 -1
- package/esm/store/list.d.ts +3 -3
- package/esm/store/list.js +1 -1
- package/esm/store/manager.js +1 -1
- package/esm/store/modal.d.ts +3 -3
- package/esm/store/modal.js +1 -1
- package/esm/store/node.js +1 -1
- package/esm/store/pagination.d.ts +3 -3
- package/esm/store/pagination.js +1 -1
- package/esm/store/root.d.ts +3 -3
- package/esm/store/root.js +1 -1
- package/esm/store/service.d.ts +3 -3
- package/esm/store/service.js +10 -4
- package/esm/store/status.js +1 -1
- package/esm/store/table.d.ts +15 -15
- package/esm/store/table.js +1 -1
- package/esm/store/table2.d.ts +3 -3
- package/esm/store/table2.js +1 -1
- package/esm/theme.js +1 -1
- package/esm/types.d.ts +15 -0
- package/esm/utils/Animation.js +1 -1
- package/esm/utils/ColorScale.js +1 -1
- package/esm/utils/DataSchema.js +1 -1
- package/esm/utils/DataScope.js +1 -1
- package/esm/utils/RootClose.js +1 -1
- package/esm/utils/SimpleMap.js +1 -1
- package/esm/utils/api.js +1 -1
- package/esm/utils/arraySlice.js +1 -1
- package/esm/utils/attachmentAdpator.js +1 -1
- package/esm/utils/autobind.js +1 -1
- package/esm/utils/browser.js +1 -1
- package/esm/utils/columnsSplit.js +1 -1
- package/esm/utils/concatData.js +1 -1
- package/esm/utils/dataMapping.js +1 -1
- package/esm/utils/date.js +1 -1
- package/esm/utils/debug.js +1 -1
- package/esm/utils/decodeEntity.js +1 -1
- package/esm/utils/dom.js +1 -1
- package/esm/utils/errors.js +1 -1
- package/esm/utils/escapeHtml.js +1 -1
- package/esm/utils/filter-schema.js +1 -1
- package/esm/utils/filter.js +1 -1
- package/esm/utils/formatDuration.js +1 -1
- package/esm/utils/formula.js +1 -1
- package/esm/utils/getVariable.js +1 -1
- package/esm/utils/grammar.js +1 -1
- package/esm/utils/handleAction.js +1 -1
- package/esm/utils/helper.js +1 -1
- package/esm/utils/highlight.js +1 -1
- package/esm/utils/icon.js +1 -1
- package/esm/utils/image.js +1 -1
- package/esm/utils/isPureVariable.js +1 -1
- package/esm/utils/json-schema-2-amis-schema.js +1 -1
- package/esm/utils/keyToPath.js +1 -1
- package/esm/utils/labelToString.js +4 -1
- package/esm/utils/makeSorter.js +1 -1
- package/esm/utils/math.js +1 -1
- package/esm/utils/memoryParse.js +1 -1
- package/esm/utils/normalizeLink.js +1 -1
- package/esm/utils/normalizeOptions.js +1 -1
- package/esm/utils/object.js +1 -1
- package/esm/utils/offset.js +1 -1
- package/esm/utils/offsetParent.js +1 -1
- package/esm/utils/optionValueCompare.js +1 -1
- package/esm/utils/position.js +1 -1
- package/esm/utils/prettyBytes.js +1 -1
- package/esm/utils/printElement.js +1 -1
- package/esm/utils/renderer-event.js +1 -1
- package/esm/utils/replaceText.js +1 -1
- package/esm/utils/resize-sensor.js +1 -1
- package/esm/utils/resolveCondition.js +1 -1
- package/esm/utils/resolveVariable.js +1 -1
- package/esm/utils/resolveVariableAndFilter.js +1 -1
- package/esm/utils/resolveVariableAndFilterForAsync.js +1 -1
- package/esm/utils/scrollPosition.js +1 -1
- package/esm/utils/string2regExp.js +1 -1
- package/esm/utils/stripNumber.js +1 -1
- package/esm/utils/style-helper.js +1 -1
- package/esm/utils/style.js +1 -1
- package/esm/utils/toNumber.js +1 -1
- package/esm/utils/tokenize.js +1 -1
- package/esm/utils/tpl-builtin.js +1 -1
- package/esm/utils/tpl-lodash.js +1 -1
- package/esm/utils/tpl.js +1 -1
- package/esm/utils/uncontrollable.js +1 -1
- package/esm/utils/validateId.js +1 -1
- package/esm/utils/validations.js +1 -1
- package/esm/utils/visitedCache.js +1 -1
- package/lib/Root.js +1 -1
- package/lib/RootRenderer.d.ts +1 -1
- package/lib/RootRenderer.js +2 -2
- package/lib/SchemaRenderer.js +1 -1
- package/lib/Scoped.js +1 -1
- package/lib/StatusScoped.js +1 -1
- package/lib/WithRootStore.js +1 -1
- package/lib/WithStore.js +10 -10
- package/lib/actions/Action.js +1 -1
- package/lib/actions/AjaxAction.js +1 -1
- package/lib/actions/BreakAction.js +1 -1
- package/lib/actions/BroadcastAction.js +1 -1
- package/lib/actions/CmptAction.js +1 -1
- package/lib/actions/ContinueAction.js +1 -1
- package/lib/actions/CopyAction.js +1 -1
- package/lib/actions/CustomAction.js +1 -1
- package/lib/actions/DialogAction.js +1 -1
- package/lib/actions/DrawerAction.js +1 -1
- package/lib/actions/EmailAction.js +1 -1
- package/lib/actions/EventAction.js +1 -1
- package/lib/actions/LinkAction.js +1 -1
- package/lib/actions/LoopAction.js +1 -1
- package/lib/actions/PageAction.js +1 -1
- package/lib/actions/ParallelAction.js +1 -1
- package/lib/actions/PrintAction.js +1 -1
- package/lib/actions/StatusAction.js +1 -1
- package/lib/actions/SwitchAction.js +1 -1
- package/lib/actions/ToastAction.js +1 -1
- package/lib/actions/WaitAction.js +1 -1
- package/lib/components/CustomStyle.js +1 -1
- package/lib/components/ErrorBoundary.js +1 -1
- package/lib/components/LazyComponent.js +1 -1
- package/lib/components/Overlay.js +1 -1
- package/lib/components/PopOver.js +1 -1
- package/lib/env.js +1 -1
- package/lib/envOverwrite.js +1 -1
- package/lib/factory.js +4 -2
- package/lib/index.js +2 -2
- package/lib/locale.js +1 -1
- package/lib/polyfills.js +1 -1
- package/lib/renderers/Form.d.ts +3 -3
- package/lib/renderers/Form.js +15 -7
- package/lib/renderers/Item.d.ts +18 -12
- package/lib/renderers/Item.js +1 -1
- package/lib/renderers/Options.js +1 -1
- package/lib/renderers/Placeholder.js +1 -1
- package/lib/renderers/builtin.js +1 -1
- package/lib/renderers/register.js +1 -1
- package/lib/renderers/wrapControl.d.ts +3 -3
- package/lib/renderers/wrapControl.js +19 -6
- package/lib/store/app.d.ts +3 -3
- package/lib/store/app.js +1 -1
- package/lib/store/combo.d.ts +40 -39
- package/lib/store/combo.js +1 -1
- package/lib/store/crud.d.ts +3 -3
- package/lib/store/crud.js +1 -1
- package/lib/store/form.d.ts +18 -17
- package/lib/store/form.js +24 -6
- package/lib/store/formItem.js +1 -1
- package/lib/store/iRenderer.d.ts +4 -3
- package/lib/store/iRenderer.js +28 -4
- package/lib/store/index.js +1 -1
- package/lib/store/list.d.ts +3 -3
- package/lib/store/list.js +1 -1
- package/lib/store/manager.js +1 -1
- package/lib/store/modal.d.ts +3 -3
- package/lib/store/modal.js +1 -1
- package/lib/store/node.js +1 -1
- package/lib/store/pagination.d.ts +3 -3
- package/lib/store/pagination.js +1 -1
- package/lib/store/root.d.ts +3 -3
- package/lib/store/root.js +1 -1
- package/lib/store/service.d.ts +3 -3
- package/lib/store/service.js +10 -4
- package/lib/store/status.js +1 -1
- package/lib/store/table.d.ts +36 -35
- package/lib/store/table.js +1 -1
- package/lib/store/table2.d.ts +3 -3
- package/lib/store/table2.js +1 -1
- package/lib/theme.js +1 -1
- package/lib/types.d.ts +15 -0
- package/lib/utils/Animation.js +1 -1
- package/lib/utils/ColorScale.js +1 -1
- package/lib/utils/DataSchema.js +1 -1
- package/lib/utils/DataScope.js +1 -1
- package/lib/utils/RootClose.js +1 -1
- package/lib/utils/SimpleMap.js +1 -1
- package/lib/utils/api.js +1 -1
- package/lib/utils/arraySlice.js +1 -1
- package/lib/utils/attachmentAdpator.js +1 -1
- package/lib/utils/autobind.js +1 -1
- package/lib/utils/browser.js +1 -1
- package/lib/utils/columnsSplit.js +1 -1
- package/lib/utils/concatData.js +1 -1
- package/lib/utils/dataMapping.js +1 -1
- package/lib/utils/date.js +1 -1
- package/lib/utils/debug.js +1 -1
- package/lib/utils/decodeEntity.js +1 -1
- package/lib/utils/dom.js +1 -1
- package/lib/utils/errors.js +1 -1
- package/lib/utils/escapeHtml.js +1 -1
- package/lib/utils/filter-schema.js +1 -1
- package/lib/utils/filter.js +1 -1
- package/lib/utils/formatDuration.js +1 -1
- package/lib/utils/formula.js +1 -1
- package/lib/utils/getVariable.js +1 -1
- package/lib/utils/grammar.js +1 -1
- package/lib/utils/handleAction.js +1 -1
- package/lib/utils/helper.js +1 -1
- package/lib/utils/highlight.js +1 -1
- package/lib/utils/icon.js +1 -1
- package/lib/utils/image.js +1 -1
- package/lib/utils/isPureVariable.js +1 -1
- package/lib/utils/json-schema-2-amis-schema.js +1 -1
- package/lib/utils/keyToPath.js +1 -1
- package/lib/utils/labelToString.js +4 -1
- package/lib/utils/makeSorter.js +1 -1
- package/lib/utils/math.js +1 -1
- package/lib/utils/memoryParse.js +1 -1
- package/lib/utils/normalizeLink.js +1 -1
- package/lib/utils/normalizeOptions.js +1 -1
- package/lib/utils/object.js +1 -1
- package/lib/utils/offset.js +1 -1
- package/lib/utils/offsetParent.js +1 -1
- package/lib/utils/optionValueCompare.js +1 -1
- package/lib/utils/position.js +1 -1
- package/lib/utils/prettyBytes.js +1 -1
- package/lib/utils/printElement.js +1 -1
- package/lib/utils/renderer-event.js +1 -1
- package/lib/utils/replaceText.js +1 -1
- package/lib/utils/resize-sensor.js +1 -1
- package/lib/utils/resolveCondition.js +1 -1
- package/lib/utils/resolveVariable.js +1 -1
- package/lib/utils/resolveVariableAndFilter.js +1 -1
- package/lib/utils/resolveVariableAndFilterForAsync.js +1 -1
- package/lib/utils/scrollPosition.js +1 -1
- package/lib/utils/string2regExp.js +1 -1
- package/lib/utils/stripNumber.js +1 -1
- package/lib/utils/style-helper.js +1 -1
- package/lib/utils/style.js +1 -1
- package/lib/utils/toNumber.js +1 -1
- package/lib/utils/tokenize.js +1 -1
- package/lib/utils/tpl-builtin.js +1 -1
- package/lib/utils/tpl-lodash.js +1 -1
- package/lib/utils/tpl.js +1 -1
- package/lib/utils/uncontrollable.js +1 -1
- package/lib/utils/validateId.js +1 -1
- package/lib/utils/validations.js +1 -1
- package/lib/utils/visitedCache.js +1 -1
- package/package.json +2 -2
package/lib/renderers/Item.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import hoistNonReactStatic from 'hoist-non-react-statics';
|
|
|
4
4
|
import { IFormItemStore, IFormStore } from '../store/form';
|
|
5
5
|
import { RendererProps, TestFunc, RendererConfig } from '../factory';
|
|
6
6
|
import { FormHorizontal, FormSchemaBase } from './Form';
|
|
7
|
-
import { ActionObject, BaseApiObject, BaseSchemaWithoutType, ClassName, Schema } from '../types';
|
|
7
|
+
import { ActionObject, BaseApiObject, BaseSchemaWithoutType, ClassName, DataChangeReason, Schema } from '../types';
|
|
8
8
|
import { IScopedContext } from '../Scoped';
|
|
9
9
|
export type LabelAlign = 'right' | 'left' | 'top' | 'inherit';
|
|
10
10
|
export interface FormBaseControl extends BaseSchemaWithoutType {
|
|
@@ -403,7 +403,7 @@ export interface FormItemProps extends RendererProps {
|
|
|
403
403
|
onChange: (value: any, submitOnChange?: boolean, changeImmediately?: boolean) => void;
|
|
404
404
|
onBulkChange?: (values: {
|
|
405
405
|
[propName: string]: any;
|
|
406
|
-
}, submitOnChange?: boolean) => void;
|
|
406
|
+
}, submitOnChange?: boolean, changeReason?: DataChangeReason) => void;
|
|
407
407
|
addHook: (fn: Function, mode?: 'validate' | 'init' | 'flush', enforce?: 'prev' | 'post') => () => void;
|
|
408
408
|
removeHook: (fn: Function, mode?: 'validate' | 'init' | 'flush') => void;
|
|
409
409
|
renderFormItems: (schema: Partial<FormSchemaBase>, region: string, props: any) => JSX.Element;
|
|
@@ -643,9 +643,7 @@ export declare function asFormItem(config: Omit<FormItemConfig, 'component'>): (
|
|
|
643
643
|
storeType: string;
|
|
644
644
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
645
645
|
readonly fetcher: any;
|
|
646
|
-
readonly notify: any;
|
|
647
|
-
* 显示一个小图标, 鼠标放上去的时候显示提示内容
|
|
648
|
-
*/
|
|
646
|
+
readonly notify: any;
|
|
649
647
|
readonly isCancel: (value: any) => boolean;
|
|
650
648
|
readonly __: import("..").TranslateFn<any>;
|
|
651
649
|
getStoreById(id: string): {
|
|
@@ -727,7 +725,10 @@ export declare function asFormItem(config: Omit<FormItemConfig, 'component'>): (
|
|
|
727
725
|
} & {
|
|
728
726
|
addStore(store: {
|
|
729
727
|
[propName: string]: any;
|
|
730
|
-
storeType: string;
|
|
728
|
+
storeType: string; /**
|
|
729
|
+
* 不设置时,当表单提交过后表单项每次修改都会触发重新验证,
|
|
730
|
+
* 如果设置了,则由此配置项来决定要不要每次修改都触发验证。
|
|
731
|
+
*/
|
|
731
732
|
id: string;
|
|
732
733
|
path: string;
|
|
733
734
|
parentId?: string | undefined;
|
|
@@ -804,14 +805,14 @@ export declare function asFormItem(config: Omit<FormItemConfig, 'component'>): (
|
|
|
804
805
|
dispose: (callback?: (() => void) | undefined) => void;
|
|
805
806
|
addChildId: (id: string) => void;
|
|
806
807
|
removeChildId: (id: string) => void;
|
|
807
|
-
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>): void;
|
|
808
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>): void; /**
|
|
809
|
+
* 配置 input className
|
|
810
|
+
*/
|
|
808
811
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
809
812
|
storeType: import("mobx-state-tree").IType<string | undefined, string, string>;
|
|
810
813
|
}, {
|
|
811
814
|
readonly fetcher: any;
|
|
812
|
-
readonly notify: any;
|
|
813
|
-
* 显示一个小图标, 鼠标放上去的时候显示提示内容
|
|
814
|
-
*/
|
|
815
|
+
readonly notify: any;
|
|
815
816
|
readonly isCancel: (value: any) => boolean;
|
|
816
817
|
readonly __: import("..").TranslateFn<any>;
|
|
817
818
|
getStoreById(id: string): {
|
|
@@ -893,7 +894,10 @@ export declare function asFormItem(config: Omit<FormItemConfig, 'component'>): (
|
|
|
893
894
|
} & {
|
|
894
895
|
addStore(store: {
|
|
895
896
|
[propName: string]: any;
|
|
896
|
-
storeType: string;
|
|
897
|
+
storeType: string; /**
|
|
898
|
+
* 不设置时,当表单提交过后表单项每次修改都会触发重新验证,
|
|
899
|
+
* 如果设置了,则由此配置项来决定要不要每次修改都触发验证。
|
|
900
|
+
*/
|
|
897
901
|
id: string;
|
|
898
902
|
path: string;
|
|
899
903
|
parentId?: string | undefined;
|
|
@@ -970,7 +974,9 @@ export declare function asFormItem(config: Omit<FormItemConfig, 'component'>): (
|
|
|
970
974
|
dispose: (callback?: (() => void) | undefined) => void;
|
|
971
975
|
addChildId: (id: string) => void;
|
|
972
976
|
removeChildId: (id: string) => void;
|
|
973
|
-
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>): void;
|
|
977
|
+
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>): void; /**
|
|
978
|
+
* 配置 input className
|
|
979
|
+
*/
|
|
974
980
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>>;
|
|
975
981
|
ComposedComponent: React.ComponentType<any>;
|
|
976
982
|
} & hoistNonReactStatic.NonReactStatics<any, {}> & {
|
package/lib/renderers/Item.js
CHANGED
package/lib/renderers/Options.js
CHANGED
package/lib/renderers/builtin.js
CHANGED
|
@@ -3,7 +3,7 @@ import { IFormStore, IFormItemStore } from '../store/form';
|
|
|
3
3
|
import { RendererProps } from '../factory';
|
|
4
4
|
import { IIRendererStore } from '../store';
|
|
5
5
|
import hoistNonReactStatic from 'hoist-non-react-statics';
|
|
6
|
-
import { Api } from '../types';
|
|
6
|
+
import { Api, DataChangeReason } from '../types';
|
|
7
7
|
export interface ControlOutterProps extends RendererProps {
|
|
8
8
|
formStore?: IFormStore;
|
|
9
9
|
name?: string;
|
|
@@ -40,12 +40,12 @@ export interface ControlOutterProps extends RendererProps {
|
|
|
40
40
|
[propName: string]: any;
|
|
41
41
|
};
|
|
42
42
|
store?: IIRendererStore;
|
|
43
|
-
onChange?: (value: any, name: string, submit?: boolean, changePristine?: boolean) => void;
|
|
43
|
+
onChange?: (value: any, name: string, submit?: boolean, changePristine?: boolean, changeReason?: DataChangeReason) => void;
|
|
44
44
|
formItemDispatchEvent: (type: string, data: any) => void;
|
|
45
45
|
formItemRef?: (control: any) => void;
|
|
46
46
|
}
|
|
47
47
|
export interface ControlProps {
|
|
48
|
-
onBulkChange?: (values: Object) => void;
|
|
48
|
+
onBulkChange?: (values: Object, submitOnChange?: boolean, changeReason?: DataChangeReason) => void;
|
|
49
49
|
onChange?: (value: any, name: string, submit: boolean) => void;
|
|
50
50
|
store: IIRendererStore;
|
|
51
51
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.9.0-rc.
|
|
2
|
+
* amis-core v6.9.0-rc.1
|
|
3
3
|
* Copyright 2018-2024 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -340,7 +340,9 @@ function wrapControl(ComposedComponent) {
|
|
|
340
340
|
mobxStateTree.isAlive(formItem) &&
|
|
341
341
|
formItem.removeSubFormItem(this.model);
|
|
342
342
|
this.model.clearValueOnHidden &&
|
|
343
|
-
((_a = this.model.form) === null || _a === void 0 ? void 0 : _a.deleteValueByName(this.model.name
|
|
343
|
+
((_a = this.model.form) === null || _a === void 0 ? void 0 : _a.deleteValueByName(this.model.name, {
|
|
344
|
+
type: 'hide'
|
|
345
|
+
}));
|
|
344
346
|
mobxStateTree.isAlive(rootStore) && rootStore.removeStore(this.model);
|
|
345
347
|
}
|
|
346
348
|
delete this.model;
|
|
@@ -463,7 +465,7 @@ function wrapControl(ComposedComponent) {
|
|
|
463
465
|
var oldValue = this.model.value;
|
|
464
466
|
value = api.callStrFunction.call(this, pipeOut, ['value', 'oldValue', 'data'], value, oldValue, data);
|
|
465
467
|
}
|
|
466
|
-
this.model.changeTmpValue(value, 'input');
|
|
468
|
+
this.model.changeTmpValue(value, type === 'formula' ? 'formulaChanged' : 'input');
|
|
467
469
|
if (changeImmediately || conrolChangeImmediately || !formInited) {
|
|
468
470
|
this.emitChange(submitOnChange);
|
|
469
471
|
}
|
|
@@ -513,13 +515,24 @@ function wrapControl(ComposedComponent) {
|
|
|
513
515
|
if (!this.model) {
|
|
514
516
|
return;
|
|
515
517
|
}
|
|
518
|
+
var changeReason = {
|
|
519
|
+
type: 'input'
|
|
520
|
+
};
|
|
521
|
+
if (model.changeMotivation === 'formulaChanged') {
|
|
522
|
+
changeReason.type = 'formula';
|
|
523
|
+
}
|
|
524
|
+
else if (model.changeMotivation === 'initialValue' ||
|
|
525
|
+
model.changeMotivation === 'formInited' ||
|
|
526
|
+
model.changeMotivation === 'defaultValue') {
|
|
527
|
+
changeReason.type = 'init';
|
|
528
|
+
}
|
|
516
529
|
if (model.extraName) {
|
|
517
530
|
var values = model.splitExtraValue(value);
|
|
518
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(values[0], model.name);
|
|
519
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(values[1], model.extraName, submitOnChange === true);
|
|
531
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(values[0], model.name, undefined, undefined, changeReason);
|
|
532
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(values[1], model.extraName, submitOnChange === true, undefined, changeReason);
|
|
520
533
|
}
|
|
521
534
|
else {
|
|
522
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(value, model.name, submitOnChange === true);
|
|
535
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(value, model.name, submitOnChange === true, undefined, changeReason);
|
|
523
536
|
}
|
|
524
537
|
this.checkValidate();
|
|
525
538
|
};
|
package/lib/store/app.d.ts
CHANGED
|
@@ -53,10 +53,10 @@ export declare const AppStore: import("mobx-state-tree").IModelType<{
|
|
|
53
53
|
readonly pristineDiff: any;
|
|
54
54
|
} & {
|
|
55
55
|
setTopStore(value: any): void;
|
|
56
|
-
initData(data?: object, skipSetPristine?: boolean): void;
|
|
56
|
+
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
57
57
|
reset(): void;
|
|
58
|
-
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined): void;
|
|
59
|
-
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined): void;
|
|
58
|
+
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
59
|
+
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
60
60
|
setCurrentAction(action: any, resolveDefinitions?: ((schema: any) => any) | undefined): void;
|
|
61
61
|
openDialog(ctx: any, additonal?: object | undefined, callback?: ((confirmed: boolean, values: any) => void) | undefined, scoped?: import("..").IScopedContext | undefined): void;
|
|
62
62
|
closeDialog(confirmed?: any, data?: any): void;
|
package/lib/store/app.js
CHANGED
package/lib/store/combo.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="lodash" />
|
|
1
2
|
import { SnapshotIn, Instance } from 'mobx-state-tree';
|
|
2
3
|
import type { IFormStore, IFormItemStore } from './form';
|
|
3
4
|
export declare const UniqueGroup: import("mobx-state-tree").IModelType<{
|
|
@@ -171,7 +172,7 @@ export declare const UniqueGroup: import("mobx-state-tree").IModelType<{
|
|
|
171
172
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
172
173
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
173
174
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
174
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
175
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
175
176
|
changeEmitedValue: (value: any) => void;
|
|
176
177
|
addSubFormItem: (item: {
|
|
177
178
|
id: string;
|
|
@@ -706,7 +707,7 @@ export declare const UniqueGroup: import("mobx-state-tree").IModelType<{
|
|
|
706
707
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
707
708
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
708
709
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
709
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
710
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
710
711
|
changeEmitedValue: (value: any) => void;
|
|
711
712
|
addSubFormItem: (item: {
|
|
712
713
|
id: string;
|
|
@@ -1275,7 +1276,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
1275
1276
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
1276
1277
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
1277
1278
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
1278
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
1279
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
1279
1280
|
changeEmitedValue: (value: any) => void;
|
|
1280
1281
|
addSubFormItem: (item: {
|
|
1281
1282
|
id: string;
|
|
@@ -1810,7 +1811,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
1810
1811
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
1811
1812
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
1812
1813
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
1813
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
1814
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
1814
1815
|
changeEmitedValue: (value: any) => void;
|
|
1815
1816
|
addSubFormItem: (item: {
|
|
1816
1817
|
id: string;
|
|
@@ -2210,10 +2211,10 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2210
2211
|
readonly pristineDiff: any;
|
|
2211
2212
|
} & {
|
|
2212
2213
|
setTopStore(value: any): void;
|
|
2213
|
-
initData(data?: object, skipSetPristine?: boolean): void;
|
|
2214
|
+
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2214
2215
|
reset(): void;
|
|
2215
|
-
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined): void;
|
|
2216
|
-
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined): void;
|
|
2216
|
+
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2217
|
+
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2217
2218
|
setCurrentAction(action: any, resolveDefinitions?: ((schema: any) => any) | undefined): void;
|
|
2218
2219
|
openDialog(ctx: any, additonal?: object | undefined, callback?: ((confirmed: boolean, values: any) => void) | undefined, scoped?: import("..").IScopedContext | undefined): void;
|
|
2219
2220
|
closeDialog(confirmed?: any, data?: any): void;
|
|
@@ -2275,10 +2276,10 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2275
2276
|
readonly pristineDiff: any;
|
|
2276
2277
|
} & {
|
|
2277
2278
|
setTopStore(value: any): void;
|
|
2278
|
-
initData(data?: object, skipSetPristine?: boolean): void;
|
|
2279
|
+
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2279
2280
|
reset(): void;
|
|
2280
|
-
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined): void;
|
|
2281
|
-
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined): void;
|
|
2281
|
+
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2282
|
+
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2282
2283
|
setCurrentAction(action: any, resolveDefinitions?: ((schema: any) => any) | undefined): void;
|
|
2283
2284
|
openDialog(ctx: any, additonal?: object | undefined, callback?: ((confirmed: boolean, values: any) => void) | undefined, scoped?: import("..").IScopedContext | undefined): void;
|
|
2284
2285
|
closeDialog(confirmed?: any, data?: any): void;
|
|
@@ -2470,7 +2471,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2470
2471
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
2471
2472
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
2472
2473
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
2473
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
2474
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
2474
2475
|
changeEmitedValue: (value: any) => void;
|
|
2475
2476
|
addSubFormItem: (item: {
|
|
2476
2477
|
id: string;
|
|
@@ -3005,7 +3006,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
3005
3006
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
3006
3007
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
3007
3008
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
3008
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
3009
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
3009
3010
|
changeEmitedValue: (value: any) => void;
|
|
3010
3011
|
addSubFormItem: (item: {
|
|
3011
3012
|
id: string;
|
|
@@ -3544,7 +3545,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
3544
3545
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
3545
3546
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
3546
3547
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
3547
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
3548
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
3548
3549
|
changeEmitedValue: (value: any) => void;
|
|
3549
3550
|
addSubFormItem: (item: {
|
|
3550
3551
|
id: string;
|
|
@@ -4079,7 +4080,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
4079
4080
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
4080
4081
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
4081
4082
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
4082
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
4083
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
4083
4084
|
changeEmitedValue: (value: any) => void;
|
|
4084
4085
|
addSubFormItem: (item: {
|
|
4085
4086
|
id: string;
|
|
@@ -4623,7 +4624,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
4623
4624
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
4624
4625
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
4625
4626
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
4626
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
4627
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
4627
4628
|
changeEmitedValue: (value: any) => void;
|
|
4628
4629
|
addSubFormItem: (item: {
|
|
4629
4630
|
id: string;
|
|
@@ -5158,7 +5159,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
5158
5159
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
5159
5160
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
5160
5161
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
5161
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
5162
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
5162
5163
|
changeEmitedValue: (value: any) => void;
|
|
5163
5164
|
addSubFormItem: (item: {
|
|
5164
5165
|
id: string;
|
|
@@ -5697,7 +5698,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
5697
5698
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
5698
5699
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
5699
5700
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
5700
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
5701
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
5701
5702
|
changeEmitedValue: (value: any) => void;
|
|
5702
5703
|
addSubFormItem: (item: {
|
|
5703
5704
|
id: string;
|
|
@@ -6232,7 +6233,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
6232
6233
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
6233
6234
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
6234
6235
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
6235
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
6236
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
6236
6237
|
changeEmitedValue: (value: any) => void;
|
|
6237
6238
|
addSubFormItem: (item: {
|
|
6238
6239
|
id: string;
|
|
@@ -6771,7 +6772,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
6771
6772
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
6772
6773
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
6773
6774
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
6774
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
6775
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
6775
6776
|
changeEmitedValue: (value: any) => void;
|
|
6776
6777
|
addSubFormItem: (item: {
|
|
6777
6778
|
id: string;
|
|
@@ -7306,7 +7307,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7306
7307
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
7307
7308
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
7308
7309
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
7309
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
7310
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
7310
7311
|
changeEmitedValue: (value: any) => void;
|
|
7311
7312
|
addSubFormItem: (item: {
|
|
7312
7313
|
id: string;
|
|
@@ -7685,8 +7686,8 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7685
7686
|
readonly persistKey: string;
|
|
7686
7687
|
} & {
|
|
7687
7688
|
setInited: (value: boolean) => void;
|
|
7688
|
-
setValues: (values: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined) => void;
|
|
7689
|
-
setValueByName: (name: string, value: any, isPristine?: boolean, force?: boolean) => void;
|
|
7689
|
+
setValues: (values: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined) => void;
|
|
7690
|
+
setValueByName: (name: string, value: any, isPristine?: boolean, force?: boolean, changeReason?: import("..").DataChangeReason | undefined) => void;
|
|
7690
7691
|
trimValues: () => void;
|
|
7691
7692
|
submit: (fn?: ((values: object) => Promise<any>) | undefined, hooks?: (() => Promise<any>)[] | undefined, failedMessage?: string | undefined, validateErrCb?: (() => void) | undefined, throwErrors?: boolean | undefined) => Promise<any>;
|
|
7692
7693
|
validate: (hooks?: (() => Promise<any>)[] | undefined, forceValidate?: boolean | undefined, throwErrors?: boolean | undefined, failedMessage?: string | undefined, validateErrCb?: (() => void) | undefined) => Promise<boolean>;
|
|
@@ -7701,7 +7702,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7701
7702
|
reset: (cb?: ((data: any) => void) | undefined, resetData?: boolean) => void;
|
|
7702
7703
|
syncOptions: import("lodash").DebouncedFunc<() => void>;
|
|
7703
7704
|
setCanAccessSuperData: (value?: boolean) => void;
|
|
7704
|
-
deleteValueByName: (name: string) => void;
|
|
7705
|
+
deleteValueByName: (name: string, changeReason?: import("..").DataChangeReason | undefined) => void;
|
|
7705
7706
|
getLocalPersistData: () => void;
|
|
7706
7707
|
setLocalPersistData: (keys?: string[] | undefined) => void;
|
|
7707
7708
|
clearLocalPersistData: () => void;
|
|
@@ -7772,10 +7773,10 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7772
7773
|
readonly pristineDiff: any;
|
|
7773
7774
|
} & {
|
|
7774
7775
|
setTopStore(value: any): void;
|
|
7775
|
-
initData(data?: object, skipSetPristine?: boolean): void;
|
|
7776
|
+
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
7776
7777
|
reset(): void;
|
|
7777
|
-
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined): void;
|
|
7778
|
-
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined): void;
|
|
7778
|
+
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
7779
|
+
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
7779
7780
|
setCurrentAction(action: any, resolveDefinitions?: ((schema: any) => any) | undefined): void;
|
|
7780
7781
|
openDialog(ctx: any, additonal?: object | undefined, callback?: ((confirmed: boolean, values: any) => void) | undefined, scoped?: import("..").IScopedContext | undefined): void;
|
|
7781
7782
|
closeDialog(confirmed?: any, data?: any): void;
|
|
@@ -7967,7 +7968,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7967
7968
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
7968
7969
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
7969
7970
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
7970
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
7971
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
7971
7972
|
changeEmitedValue: (value: any) => void;
|
|
7972
7973
|
addSubFormItem: (item: {
|
|
7973
7974
|
id: string;
|
|
@@ -8502,7 +8503,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
8502
8503
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
8503
8504
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
8504
8505
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
8505
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
8506
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
8506
8507
|
changeEmitedValue: (value: any) => void;
|
|
8507
8508
|
addSubFormItem: (item: {
|
|
8508
8509
|
id: string;
|
|
@@ -9041,7 +9042,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
9041
9042
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
9042
9043
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
9043
9044
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
9044
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
9045
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
9045
9046
|
changeEmitedValue: (value: any) => void;
|
|
9046
9047
|
addSubFormItem: (item: {
|
|
9047
9048
|
id: string;
|
|
@@ -9576,7 +9577,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
9576
9577
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
9577
9578
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
9578
9579
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
9579
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
9580
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
9580
9581
|
changeEmitedValue: (value: any) => void;
|
|
9581
9582
|
addSubFormItem: (item: {
|
|
9582
9583
|
id: string;
|
|
@@ -10120,7 +10121,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
10120
10121
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
10121
10122
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
10122
10123
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
10123
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
10124
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
10124
10125
|
changeEmitedValue: (value: any) => void;
|
|
10125
10126
|
addSubFormItem: (item: {
|
|
10126
10127
|
id: string;
|
|
@@ -10655,7 +10656,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
10655
10656
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
10656
10657
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
10657
10658
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
10658
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
10659
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
10659
10660
|
changeEmitedValue: (value: any) => void;
|
|
10660
10661
|
addSubFormItem: (item: {
|
|
10661
10662
|
id: string;
|
|
@@ -11194,7 +11195,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
11194
11195
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
11195
11196
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
11196
11197
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
11197
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
11198
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
11198
11199
|
changeEmitedValue: (value: any) => void;
|
|
11199
11200
|
addSubFormItem: (item: {
|
|
11200
11201
|
id: string;
|
|
@@ -11729,7 +11730,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
11729
11730
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
11730
11731
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
11731
11732
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
11732
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
11733
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
11733
11734
|
changeEmitedValue: (value: any) => void;
|
|
11734
11735
|
addSubFormItem: (item: {
|
|
11735
11736
|
id: string;
|
|
@@ -12268,7 +12269,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
12268
12269
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
12269
12270
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
12270
12271
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
12271
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
12272
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
12272
12273
|
changeEmitedValue: (value: any) => void;
|
|
12273
12274
|
addSubFormItem: (item: {
|
|
12274
12275
|
id: string;
|
|
@@ -12803,7 +12804,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
12803
12804
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
12804
12805
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
12805
12806
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
12806
|
-
changeTmpValue: (value: any, changeReason?: "input" | "
|
|
12807
|
+
changeTmpValue: (value: any, changeReason?: "input" | "initialValue" | "formInited" | "dataChanged" | "formulaChanged" | "controlled" | "defaultValue" | undefined) => void;
|
|
12807
12808
|
changeEmitedValue: (value: any) => void;
|
|
12808
12809
|
addSubFormItem: (item: {
|
|
12809
12810
|
id: string;
|
|
@@ -13182,8 +13183,8 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
13182
13183
|
readonly persistKey: string;
|
|
13183
13184
|
} & {
|
|
13184
13185
|
setInited: (value: boolean) => void;
|
|
13185
|
-
setValues: (values: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined) => void;
|
|
13186
|
-
setValueByName: (name: string, value: any, isPristine?: boolean, force?: boolean) => void;
|
|
13186
|
+
setValues: (values: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined) => void;
|
|
13187
|
+
setValueByName: (name: string, value: any, isPristine?: boolean, force?: boolean, changeReason?: import("..").DataChangeReason | undefined) => void;
|
|
13187
13188
|
trimValues: () => void;
|
|
13188
13189
|
submit: (fn?: ((values: object) => Promise<any>) | undefined, hooks?: (() => Promise<any>)[] | undefined, failedMessage?: string | undefined, validateErrCb?: (() => void) | undefined, throwErrors?: boolean | undefined) => Promise<any>;
|
|
13189
13190
|
validate: (hooks?: (() => Promise<any>)[] | undefined, forceValidate?: boolean | undefined, throwErrors?: boolean | undefined, failedMessage?: string | undefined, validateErrCb?: (() => void) | undefined) => Promise<boolean>;
|
|
@@ -13198,7 +13199,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
13198
13199
|
reset: (cb?: ((data: any) => void) | undefined, resetData?: boolean) => void;
|
|
13199
13200
|
syncOptions: import("lodash").DebouncedFunc<() => void>;
|
|
13200
13201
|
setCanAccessSuperData: (value?: boolean) => void;
|
|
13201
|
-
deleteValueByName: (name: string) => void;
|
|
13202
|
+
deleteValueByName: (name: string, changeReason?: import("..").DataChangeReason | undefined) => void;
|
|
13202
13203
|
getLocalPersistData: () => void;
|
|
13203
13204
|
setLocalPersistData: (keys?: string[] | undefined) => void;
|
|
13204
13205
|
clearLocalPersistData: () => void;
|
package/lib/store/combo.js
CHANGED
package/lib/store/crud.d.ts
CHANGED
|
@@ -78,10 +78,10 @@ export declare const CRUDStore: import("mobx-state-tree").IModelType<{
|
|
|
78
78
|
readonly pristineDiff: any;
|
|
79
79
|
} & {
|
|
80
80
|
setTopStore(value: any): void;
|
|
81
|
-
initData(data?: object, skipSetPristine?: boolean): void;
|
|
81
|
+
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
82
82
|
reset(): void;
|
|
83
|
-
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined): void;
|
|
84
|
-
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined): void;
|
|
83
|
+
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
84
|
+
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
85
85
|
setCurrentAction(action: any, resolveDefinitions?: ((schema: any) => any) | undefined): void;
|
|
86
86
|
openDialog(ctx: any, additonal?: object | undefined, callback?: ((confirmed: boolean, values: any) => void) | undefined, scoped?: import("..").IScopedContext | undefined): void;
|
|
87
87
|
closeDialog(confirmed?: any, data?: any): void;
|
package/lib/store/crud.js
CHANGED