amis-core 6.13.0-beta.0 → 6.13.0-beta.10
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 +15 -7
- package/esm/SchemaRenderer.d.ts +3 -0
- package/esm/SchemaRenderer.js +63 -10
- package/esm/Scoped.js +1 -1
- package/esm/StatusScoped.js +1 -1
- package/esm/StyleManager.js +1 -1
- package/esm/WithRootStore.js +1 -1
- package/esm/WithStore.js +8 -4
- 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/Animations.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 +1 -1
- package/esm/globalVar.js +15 -2
- package/esm/globalVarClientHandler.js +1 -1
- package/esm/globalVarDefaultValueHandler.js +1 -1
- package/esm/index.js +6 -6
- package/esm/locale.js +1 -1
- package/esm/polyfills.js +1 -1
- package/esm/renderers/Form.js +3 -5
- package/esm/renderers/Item.js +2 -17
- 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.js +10 -4
- package/esm/store/app.d.ts +4 -0
- package/esm/store/app.js +1 -1
- package/esm/store/combo.d.ts +12 -0
- package/esm/store/combo.js +1 -1
- package/esm/store/crud.d.ts +5 -0
- package/esm/store/crud.js +6 -2
- package/esm/store/form.d.ts +4 -1
- package/esm/store/form.js +3 -2
- package/esm/store/formItem.js +1 -1
- package/esm/store/iRenderer.d.ts +4 -0
- package/esm/store/iRenderer.js +27 -4
- package/esm/store/index.js +1 -1
- package/esm/store/list.d.ts +4 -0
- package/esm/store/list.js +1 -1
- package/esm/store/manager.js +1 -1
- package/esm/store/modal.d.ts +4 -0
- package/esm/store/modal.js +1 -1
- package/esm/store/node.js +1 -1
- package/esm/store/pagination.d.ts +4 -0
- package/esm/store/pagination.js +1 -1
- package/esm/store/root.d.ts +14 -2
- package/esm/store/root.js +181 -49
- package/esm/store/service.d.ts +4 -0
- package/esm/store/service.js +1 -1
- package/esm/store/status.js +1 -1
- package/esm/store/table.d.ts +53 -92
- package/esm/store/table.js +42 -20
- package/esm/store/table2.d.ts +5 -0
- package/esm/store/table2.js +17 -10
- package/esm/theme.js +1 -1
- 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/animations.js +1 -1
- package/esm/utils/api.js +8 -3
- 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 +11 -4
- package/esm/utils/errors.js +2 -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/getPageId.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/index.js +1 -1
- package/esm/utils/isPureVariable.js +2 -2
- package/esm/utils/json-schema-2-amis-schema.js +1 -1
- package/esm/utils/keyToPath.js +1 -1
- package/esm/utils/labelToString.js +1 -1
- package/esm/utils/loopTooMuch.js +1 -1
- package/esm/utils/makeSorter.js +1 -1
- package/esm/utils/math.d.ts +1 -0
- package/esm/utils/math.js +16 -2
- package/esm/utils/memoryParse.js +1 -1
- package/esm/utils/normalizeLink.js +1 -1
- package/esm/utils/normalizeOptions.js +6 -2
- 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 +14 -11
- 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.d.ts +13 -0
- package/esm/utils/style.js +43 -3
- 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 +6 -2
- 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 +15 -7
- package/lib/SchemaRenderer.d.ts +3 -0
- package/lib/SchemaRenderer.js +65 -8
- package/lib/Scoped.js +1 -1
- package/lib/StatusScoped.js +1 -1
- package/lib/StyleManager.js +1 -1
- package/lib/WithRootStore.js +1 -1
- package/lib/WithStore.js +8 -4
- 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/Animations.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 +1 -1
- package/lib/globalVar.js +19 -2
- package/lib/globalVarClientHandler.js +1 -1
- package/lib/globalVarDefaultValueHandler.js +1 -1
- package/lib/index.js +7 -4
- package/lib/locale.js +1 -1
- package/lib/polyfills.js +1 -1
- package/lib/renderers/Form.js +3 -5
- package/lib/renderers/Item.d.ts +1 -1
- package/lib/renderers/Item.js +2 -17
- 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.js +10 -4
- package/lib/store/app.d.ts +4 -0
- package/lib/store/app.js +1 -1
- package/lib/store/combo.d.ts +37 -24
- package/lib/store/combo.js +1 -1
- package/lib/store/crud.d.ts +5 -0
- package/lib/store/crud.js +6 -2
- package/lib/store/form.d.ts +15 -11
- package/lib/store/form.js +3 -2
- package/lib/store/formItem.js +1 -1
- package/lib/store/iRenderer.d.ts +4 -0
- package/lib/store/iRenderer.js +30 -3
- package/lib/store/index.js +1 -1
- package/lib/store/list.d.ts +4 -0
- package/lib/store/list.js +1 -1
- package/lib/store/manager.js +1 -1
- package/lib/store/modal.d.ts +4 -0
- package/lib/store/modal.js +1 -1
- package/lib/store/node.js +1 -1
- package/lib/store/pagination.d.ts +4 -0
- package/lib/store/pagination.js +1 -1
- package/lib/store/root.d.ts +15 -2
- package/lib/store/root.js +178 -46
- package/lib/store/service.d.ts +4 -0
- package/lib/store/service.js +1 -1
- package/lib/store/status.js +1 -1
- package/lib/store/table.d.ts +73 -112
- package/lib/store/table.js +41 -19
- package/lib/store/table2.d.ts +5 -0
- package/lib/store/table2.js +17 -10
- package/lib/theme.js +1 -1
- 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/animations.js +1 -1
- package/lib/utils/api.js +8 -3
- 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 +11 -4
- package/lib/utils/errors.js +2 -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/getPageId.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/index.js +1 -1
- package/lib/utils/isPureVariable.js +2 -2
- package/lib/utils/json-schema-2-amis-schema.js +1 -1
- package/lib/utils/keyToPath.js +1 -1
- package/lib/utils/labelToString.js +1 -1
- package/lib/utils/loopTooMuch.js +1 -1
- package/lib/utils/makeSorter.js +1 -1
- package/lib/utils/math.d.ts +1 -0
- package/lib/utils/math.js +16 -1
- package/lib/utils/memoryParse.js +1 -1
- package/lib/utils/normalizeLink.js +1 -1
- package/lib/utils/normalizeOptions.js +6 -2
- 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 +14 -11
- 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.d.ts +13 -0
- package/lib/utils/style.js +44 -2
- 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 +6 -2
- 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.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.13.0-beta.
|
|
2
|
+
* amis-core v6.13.0-beta.10
|
|
3
3
|
* Copyright 2018-2025 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -12,8 +12,6 @@ var React = require('react');
|
|
|
12
12
|
var hoistNonReactStatic = require('hoist-non-react-statics');
|
|
13
13
|
var mobx = require('mobx');
|
|
14
14
|
var mobxStateTree = require('mobx-state-tree');
|
|
15
|
-
var globalVar = require('../globalVar.js');
|
|
16
|
-
var resolveVariableAndFilter = require('../utils/resolveVariableAndFilter.js');
|
|
17
15
|
var factory = require('../factory.js');
|
|
18
16
|
var helper = require('../utils/helper.js');
|
|
19
17
|
var mobxReact = require('mobx-react');
|
|
@@ -1091,20 +1089,7 @@ function asFormItem(config) {
|
|
|
1091
1089
|
}
|
|
1092
1090
|
function registerFormItem(config) {
|
|
1093
1091
|
var Control = asFormItem(config)(config.component);
|
|
1094
|
-
return factory.registerRenderer(tslib.__assign(tslib.__assign({}, config), { weight: typeof config.weight !== 'undefined' ? config.weight : -100, component: Control, isFormItem: true
|
|
1095
|
-
var _a, _b, _c;
|
|
1096
|
-
if (((_a = config.onGlobalVarChanged) === null || _a === void 0 ? void 0 : _a.apply(this, arguments)) === false) {
|
|
1097
|
-
return false;
|
|
1098
|
-
}
|
|
1099
|
-
if (globalVar.isGlobalVarExpression(schema.source)) {
|
|
1100
|
-
(_c = (_b = instance.props).reloadOptions) === null || _c === void 0 ? void 0 : _c.call(_b);
|
|
1101
|
-
}
|
|
1102
|
-
// 目前表单项的全局变量更新要靠这个方式
|
|
1103
|
-
if (globalVar.isGlobalVarExpression(schema.value)) {
|
|
1104
|
-
instance.props.onChange(resolveVariableAndFilter.resolveVariableAndFilter(schema.value, data, '| raw'));
|
|
1105
|
-
return false;
|
|
1106
|
-
}
|
|
1107
|
-
} }));
|
|
1092
|
+
return factory.registerRenderer(tslib.__assign(tslib.__assign({}, config), { weight: typeof config.weight !== 'undefined' ? config.weight : -100, component: Control, isFormItem: true }));
|
|
1108
1093
|
}
|
|
1109
1094
|
function FormItem(config) {
|
|
1110
1095
|
return function (component) {
|
package/lib/renderers/Options.js
CHANGED
package/lib/renderers/builtin.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.13.0-beta.
|
|
2
|
+
* amis-core v6.13.0-beta.10
|
|
3
3
|
* Copyright 2018-2025 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -74,6 +74,7 @@ var _J$F_ = (__react_jsx__["default"] || __react_jsx__).Fragment;
|
|
|
74
74
|
if (!name) {
|
|
75
75
|
return _this;
|
|
76
76
|
}
|
|
77
|
+
var valueIsExp = formula.isExpression(value);
|
|
77
78
|
var propValue = _this.props.value;
|
|
78
79
|
var model = rootStore.addStore({
|
|
79
80
|
id: helper.guid(),
|
|
@@ -90,8 +91,7 @@ var _J$F_ = (__react_jsx__["default"] || __react_jsx__).Fragment;
|
|
|
90
91
|
? tslib.__assign(tslib.__assign({}, validations$1), validations.str2rules(config.validations)) : validations$1;
|
|
91
92
|
// @issue 打算干掉这个
|
|
92
93
|
formItem$1 === null || formItem$1 === void 0 ? void 0 : formItem$1.addSubFormItem(model);
|
|
93
|
-
model.config(tslib.__assign(tslib.__assign({}, pick__default["default"](tslib.__assign(tslib.__assign({}, ComposedComponent.defaultProps), _this.props.$schema), ['multiple'])), { id: id, type: type, required: props.required || required, unique: unique, value: value, isValueSchemaExp:
|
|
94
|
-
value.replace(/\s/g, '') !== "${".concat(name, "}"), rules: rules, messages: validationErrors, delimiter: delimiter, valueField: valueField, labelField: labelField, joinValues: joinValues, extractValue: extractValue, selectFirst: selectFirst, autoFill: autoFill, clearValueOnHidden: clearValueOnHidden, validateApi: validateApi, minLength: minLength, maxLength: maxLength, validateOnChange: validateOnChange, label: label, inputGroupControl: inputGroupControl, extraName: extraName, pagination: pagination }));
|
|
94
|
+
model.config(tslib.__assign(tslib.__assign({}, pick__default["default"](tslib.__assign(tslib.__assign({}, ComposedComponent.defaultProps), _this.props.$schema), ['multiple'])), { id: id, type: type, required: props.required || required, unique: unique, value: value, isValueSchemaExp: valueIsExp && value.replace(/\s/g, '') !== "${".concat(name, "}"), rules: rules, messages: validationErrors, delimiter: delimiter, valueField: valueField, labelField: labelField, joinValues: joinValues, extractValue: extractValue, selectFirst: selectFirst, autoFill: autoFill, clearValueOnHidden: clearValueOnHidden, validateApi: validateApi, minLength: minLength, maxLength: maxLength, validateOnChange: validateOnChange, label: label, inputGroupControl: inputGroupControl, extraName: extraName, pagination: pagination }));
|
|
95
95
|
// issue 这个逻辑应该在 combo 里面自己实现。
|
|
96
96
|
if (_this.model.unique &&
|
|
97
97
|
((_b = form === null || form === void 0 ? void 0 : form.parentStore) === null || _b === void 0 ? void 0 : _b.storeType) === combo.ComboStore.name) {
|
|
@@ -108,7 +108,13 @@ var _J$F_ = (__react_jsx__["default"] || __react_jsx__).Fragment;
|
|
|
108
108
|
}
|
|
109
109
|
if (onChange &&
|
|
110
110
|
value !== undefined &&
|
|
111
|
-
model.tmpValue !== undefined
|
|
111
|
+
model.tmpValue !== undefined &&
|
|
112
|
+
// 要么是默认值起作用了
|
|
113
|
+
// 要么是表达式起作用了
|
|
114
|
+
// 只有这两种情况才会触发 onChange
|
|
115
|
+
// 比如以下 case 就不应该触发
|
|
116
|
+
// 关联到上下文数据了,同时设置了默认值,因为是上下文数据优先,这个时候就不应该触发 onChange,因为没变化
|
|
117
|
+
(value === model.tmpValue || valueIsExp)) {
|
|
112
118
|
// 组件默认值支持表达式需要: 避免初始化时上下文中丢失组件默认值
|
|
113
119
|
if (model.extraName) {
|
|
114
120
|
var values = model.splitExtraValue(model.tmpValue);
|
package/lib/store/app.d.ts
CHANGED
|
@@ -17,8 +17,10 @@ export declare const AppStore: import("mobx-state-tree").IModelType<{
|
|
|
17
17
|
pristineRaw: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
18
18
|
upStreamData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
19
19
|
action: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
20
|
+
dialogSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
20
21
|
dialogOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
21
22
|
dialogData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
23
|
+
drawerSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
22
24
|
drawerOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
23
25
|
drawerData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
24
26
|
} & {
|
|
@@ -54,6 +56,8 @@ export declare const AppStore: import("mobx-state-tree").IModelType<{
|
|
|
54
56
|
} & {
|
|
55
57
|
setTopStore(value: any): void;
|
|
56
58
|
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
59
|
+
temporaryUpdateGlobalVars(globalVar: any): void;
|
|
60
|
+
unDoTemporaryUpdateGlobalVars(): void;
|
|
57
61
|
reset(): void;
|
|
58
62
|
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
59
63
|
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("../types").DataChangeReason | undefined): 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?: "
|
|
175
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | 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?: "
|
|
710
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
710
711
|
changeEmitedValue: (value: any) => void;
|
|
711
712
|
addSubFormItem: (item: {
|
|
712
713
|
id: string;
|
|
@@ -1099,8 +1100,10 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
1099
1100
|
pristineRaw: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
1100
1101
|
upStreamData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
1101
1102
|
action: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
1103
|
+
dialogSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
1102
1104
|
dialogOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
1103
1105
|
dialogData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
1106
|
+
drawerSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
1104
1107
|
drawerOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
1105
1108
|
drawerData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
1106
1109
|
} & {
|
|
@@ -1275,7 +1278,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
1275
1278
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
1276
1279
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
1277
1280
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
1278
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
1281
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
1279
1282
|
changeEmitedValue: (value: any) => void;
|
|
1280
1283
|
addSubFormItem: (item: {
|
|
1281
1284
|
id: string;
|
|
@@ -1810,7 +1813,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
1810
1813
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
1811
1814
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
1812
1815
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
1813
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
1816
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
1814
1817
|
changeEmitedValue: (value: any) => void;
|
|
1815
1818
|
addSubFormItem: (item: {
|
|
1816
1819
|
id: string;
|
|
@@ -2211,6 +2214,8 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2211
2214
|
} & {
|
|
2212
2215
|
setTopStore(value: any): void;
|
|
2213
2216
|
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2217
|
+
temporaryUpdateGlobalVars(globalVar: any): void;
|
|
2218
|
+
unDoTemporaryUpdateGlobalVars(): void;
|
|
2214
2219
|
reset(): void;
|
|
2215
2220
|
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2216
2221
|
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
@@ -2237,8 +2242,10 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2237
2242
|
pristineRaw: any;
|
|
2238
2243
|
upStreamData: any;
|
|
2239
2244
|
action: any;
|
|
2245
|
+
dialogSchema: any;
|
|
2240
2246
|
dialogOpen: boolean;
|
|
2241
2247
|
dialogData: any;
|
|
2248
|
+
drawerSchema: any;
|
|
2242
2249
|
drawerOpen: boolean;
|
|
2243
2250
|
drawerData: any;
|
|
2244
2251
|
msg: string;
|
|
@@ -2276,6 +2283,8 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2276
2283
|
} & {
|
|
2277
2284
|
setTopStore(value: any): void;
|
|
2278
2285
|
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2286
|
+
temporaryUpdateGlobalVars(globalVar: any): void;
|
|
2287
|
+
unDoTemporaryUpdateGlobalVars(): void;
|
|
2279
2288
|
reset(): void;
|
|
2280
2289
|
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
2281
2290
|
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
@@ -2469,7 +2478,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
2469
2478
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
2470
2479
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
2471
2480
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
2472
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
2481
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
2473
2482
|
changeEmitedValue: (value: any) => void;
|
|
2474
2483
|
addSubFormItem: (item: {
|
|
2475
2484
|
id: string;
|
|
@@ -3004,7 +3013,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
3004
3013
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
3005
3014
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
3006
3015
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
3007
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
3016
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
3008
3017
|
changeEmitedValue: (value: any) => void;
|
|
3009
3018
|
addSubFormItem: (item: {
|
|
3010
3019
|
id: string;
|
|
@@ -3545,7 +3554,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
3545
3554
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
3546
3555
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
3547
3556
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
3548
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
3557
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
3549
3558
|
changeEmitedValue: (value: any) => void;
|
|
3550
3559
|
addSubFormItem: (item: {
|
|
3551
3560
|
id: string;
|
|
@@ -4080,7 +4089,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
4080
4089
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
4081
4090
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
4082
4091
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
4083
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
4092
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
4084
4093
|
changeEmitedValue: (value: any) => void;
|
|
4085
4094
|
addSubFormItem: (item: {
|
|
4086
4095
|
id: string;
|
|
@@ -4624,7 +4633,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
4624
4633
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
4625
4634
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
4626
4635
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
4627
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
4636
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
4628
4637
|
changeEmitedValue: (value: any) => void;
|
|
4629
4638
|
addSubFormItem: (item: {
|
|
4630
4639
|
id: string;
|
|
@@ -5159,7 +5168,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
5159
5168
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
5160
5169
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
5161
5170
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
5162
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
5171
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
5163
5172
|
changeEmitedValue: (value: any) => void;
|
|
5164
5173
|
addSubFormItem: (item: {
|
|
5165
5174
|
id: string;
|
|
@@ -5698,7 +5707,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
5698
5707
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
5699
5708
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
5700
5709
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
5701
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
5710
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
5702
5711
|
changeEmitedValue: (value: any) => void;
|
|
5703
5712
|
addSubFormItem: (item: {
|
|
5704
5713
|
id: string;
|
|
@@ -6233,7 +6242,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
6233
6242
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
6234
6243
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
6235
6244
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
6236
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
6245
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
6237
6246
|
changeEmitedValue: (value: any) => void;
|
|
6238
6247
|
addSubFormItem: (item: {
|
|
6239
6248
|
id: string;
|
|
@@ -6772,7 +6781,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
6772
6781
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
6773
6782
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
6774
6783
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
6775
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
6784
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
6776
6785
|
changeEmitedValue: (value: any) => void;
|
|
6777
6786
|
addSubFormItem: (item: {
|
|
6778
6787
|
id: string;
|
|
@@ -7307,7 +7316,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7307
7316
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
7308
7317
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
7309
7318
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
7310
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
7319
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
7311
7320
|
changeEmitedValue: (value: any) => void;
|
|
7312
7321
|
addSubFormItem: (item: {
|
|
7313
7322
|
id: string;
|
|
@@ -7734,8 +7743,10 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7734
7743
|
pristineRaw: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
7735
7744
|
upStreamData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
7736
7745
|
action: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
7746
|
+
dialogSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
7737
7747
|
dialogOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
7738
7748
|
dialogData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
7749
|
+
drawerSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
7739
7750
|
drawerOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
7740
7751
|
drawerData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
7741
7752
|
} & {
|
|
@@ -7775,6 +7786,8 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7775
7786
|
} & {
|
|
7776
7787
|
setTopStore(value: any): void;
|
|
7777
7788
|
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
7789
|
+
temporaryUpdateGlobalVars(globalVar: any): void;
|
|
7790
|
+
unDoTemporaryUpdateGlobalVars(): void;
|
|
7778
7791
|
reset(): void;
|
|
7779
7792
|
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
7780
7793
|
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("..").DataChangeReason | undefined): void;
|
|
@@ -7968,7 +7981,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
7968
7981
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
7969
7982
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
7970
7983
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
7971
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
7984
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
7972
7985
|
changeEmitedValue: (value: any) => void;
|
|
7973
7986
|
addSubFormItem: (item: {
|
|
7974
7987
|
id: string;
|
|
@@ -8503,7 +8516,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
8503
8516
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
8504
8517
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
8505
8518
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
8506
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
8519
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
8507
8520
|
changeEmitedValue: (value: any) => void;
|
|
8508
8521
|
addSubFormItem: (item: {
|
|
8509
8522
|
id: string;
|
|
@@ -9044,7 +9057,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
9044
9057
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
9045
9058
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
9046
9059
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
9047
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
9060
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
9048
9061
|
changeEmitedValue: (value: any) => void;
|
|
9049
9062
|
addSubFormItem: (item: {
|
|
9050
9063
|
id: string;
|
|
@@ -9579,7 +9592,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
9579
9592
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
9580
9593
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
9581
9594
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
9582
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
9595
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
9583
9596
|
changeEmitedValue: (value: any) => void;
|
|
9584
9597
|
addSubFormItem: (item: {
|
|
9585
9598
|
id: string;
|
|
@@ -10123,7 +10136,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
10123
10136
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
10124
10137
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
10125
10138
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
10126
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
10139
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
10127
10140
|
changeEmitedValue: (value: any) => void;
|
|
10128
10141
|
addSubFormItem: (item: {
|
|
10129
10142
|
id: string;
|
|
@@ -10658,7 +10671,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
10658
10671
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
10659
10672
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
10660
10673
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
10661
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
10674
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
10662
10675
|
changeEmitedValue: (value: any) => void;
|
|
10663
10676
|
addSubFormItem: (item: {
|
|
10664
10677
|
id: string;
|
|
@@ -11197,7 +11210,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
11197
11210
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
11198
11211
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
11199
11212
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
11200
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
11213
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
11201
11214
|
changeEmitedValue: (value: any) => void;
|
|
11202
11215
|
addSubFormItem: (item: {
|
|
11203
11216
|
id: string;
|
|
@@ -11732,7 +11745,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
11732
11745
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
11733
11746
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
11734
11747
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
11735
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
11748
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
11736
11749
|
changeEmitedValue: (value: any) => void;
|
|
11737
11750
|
addSubFormItem: (item: {
|
|
11738
11751
|
id: string;
|
|
@@ -12271,7 +12284,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
12271
12284
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
12272
12285
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
12273
12286
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
12274
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
12287
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
12275
12288
|
changeEmitedValue: (value: any) => void;
|
|
12276
12289
|
addSubFormItem: (item: {
|
|
12277
12290
|
id: string;
|
|
@@ -12806,7 +12819,7 @@ export declare const ComboStore: import("mobx-state-tree").IModelType<{
|
|
|
12806
12819
|
closeDialog: (confirmed?: any, result?: any) => void;
|
|
12807
12820
|
openPopOver: (schema: any, ctx: any, callback?: ((confirmed?: any, value?: any) => void) | undefined) => void;
|
|
12808
12821
|
closePopOver: (confirmed?: any, result?: any) => void;
|
|
12809
|
-
changeTmpValue: (value: any, changeReason?: "
|
|
12822
|
+
changeTmpValue: (value: any, changeReason?: "defaultValue" | "formInited" | "input" | "initialValue" | "dataChanged" | "formulaChanged" | "controlled" | undefined) => void;
|
|
12810
12823
|
changeEmitedValue: (value: any) => void;
|
|
12811
12824
|
addSubFormItem: (item: {
|
|
12812
12825
|
id: string;
|
package/lib/store/combo.js
CHANGED
package/lib/store/crud.d.ts
CHANGED
|
@@ -30,8 +30,10 @@ export declare const CRUDStore: import("mobx-state-tree").IModelType<{
|
|
|
30
30
|
pristineRaw: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
31
31
|
upStreamData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
32
32
|
action: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
33
|
+
dialogSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
33
34
|
dialogOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
34
35
|
dialogData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
36
|
+
drawerSchema: import("mobx-state-tree").IType<any, any, any>;
|
|
35
37
|
drawerOpen: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
36
38
|
drawerData: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
37
39
|
} & {
|
|
@@ -79,6 +81,8 @@ export declare const CRUDStore: import("mobx-state-tree").IModelType<{
|
|
|
79
81
|
} & {
|
|
80
82
|
setTopStore(value: any): void;
|
|
81
83
|
initData(data?: object, skipSetPristine?: boolean, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
84
|
+
temporaryUpdateGlobalVars(globalVar: any): void;
|
|
85
|
+
unDoTemporaryUpdateGlobalVars(): void;
|
|
82
86
|
reset(): void;
|
|
83
87
|
updateData(data?: object, tag?: object | undefined, replace?: boolean | undefined, concatFields?: string | string[] | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
84
88
|
changeValue(name: string, value: any, changePristine?: boolean | undefined, force?: boolean | undefined, otherModifier?: ((data: Object) => void) | undefined, changeReason?: import("../types").DataChangeReason | undefined): void;
|
|
@@ -122,6 +126,7 @@ export declare const CRUDStore: import("mobx-state-tree").IModelType<{
|
|
|
122
126
|
unSelectedItems: any[];
|
|
123
127
|
selectedIndexes: string[];
|
|
124
128
|
};
|
|
129
|
+
readonly offset: number;
|
|
125
130
|
} & {
|
|
126
131
|
getData: (superData: any) => any;
|
|
127
132
|
updateSelectData: (selected: Array<any>, unSelected: Array<any>) => void;
|
package/lib/store/crud.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.13.0-beta.
|
|
2
|
+
* amis-core v6.13.0-beta.10
|
|
3
3
|
* Copyright 2018-2025 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -34,6 +34,7 @@ var ServerError = /** @class */ (function (_super) {
|
|
|
34
34
|
function ServerError(msg, response) {
|
|
35
35
|
var _this = _super.call(this, msg) || this;
|
|
36
36
|
_this.type = 'ServerError';
|
|
37
|
+
Object.setPrototypeOf(_this, ServerError.prototype);
|
|
37
38
|
_this.response = response;
|
|
38
39
|
return _this;
|
|
39
40
|
}
|
|
@@ -98,6 +99,9 @@ var CRUDStore = service.ServiceStore.named('CRUDStore')
|
|
|
98
99
|
})
|
|
99
100
|
};
|
|
100
101
|
return context;
|
|
102
|
+
},
|
|
103
|
+
get offset() {
|
|
104
|
+
return (self.page - 1) * self.perPage;
|
|
101
105
|
}
|
|
102
106
|
}); })
|
|
103
107
|
.actions(function (self) {
|
|
@@ -169,7 +173,7 @@ var CRUDStore = service.ServiceStore.named('CRUDStore')
|
|
|
169
173
|
dir = /desc/i.test(self.query.orderDir) ? -1 : 1;
|
|
170
174
|
items = helper.sortArray(items, self.query.orderBy, dir);
|
|
171
175
|
}
|
|
172
|
-
data_1 = tslib.__assign(tslib.__assign({}, self.data), (_c = {}, _c[options.totalField || 'total'] = items.length, _c.items = items.slice((self.page - 1) * self.perPage, self.page * self.perPage), _c));
|
|
176
|
+
data_1 = tslib.__assign(tslib.__assign({}, self.data), (_c = { count: items.length }, _c[options.totalField || 'total'] = items.length, _c.items = items.slice((self.page - 1) * self.perPage, self.page * self.perPage), _c));
|
|
173
177
|
self.total =
|
|
174
178
|
parseInt((_f = data_1[options.totalField || 'total']) !== null && _f !== void 0 ? _f : data_1.count, 10) ||
|
|
175
179
|
0;
|