amis-core 6.13.0-beta.6 → 6.13.0-beta.7
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 +13 -3
- package/esm/SchemaRenderer.js +8 -3
- 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 +1 -1
- 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 +1 -1
- package/esm/globalVarClientHandler.js +1 -1
- package/esm/globalVarDefaultValueHandler.js +1 -1
- package/esm/index.js +4 -4
- package/esm/locale.js +1 -1
- package/esm/polyfills.js +1 -1
- package/esm/renderers/Form.js +1 -1
- 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.js +1 -1
- package/esm/store/app.js +1 -1
- package/esm/store/combo.js +1 -1
- package/esm/store/crud.js +1 -1
- package/esm/store/form.js +1 -1
- package/esm/store/formItem.js +1 -1
- package/esm/store/iRenderer.js +1 -1
- package/esm/store/index.js +1 -1
- package/esm/store/list.js +1 -1
- package/esm/store/manager.js +1 -1
- package/esm/store/modal.js +1 -1
- package/esm/store/node.js +1 -1
- package/esm/store/pagination.js +1 -1
- package/esm/store/root.d.ts +3 -2
- package/esm/store/root.js +73 -56
- package/esm/store/service.js +1 -1
- package/esm/store/status.js +1 -1
- package/esm/store/table.d.ts +39 -4
- package/esm/store/table.js +28 -11
- package/esm/store/table2.js +1 -1
- 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 +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/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.js +1 -1
- 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 +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 +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.js +13 -3
- package/lib/SchemaRenderer.js +8 -3
- 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 +1 -1
- 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 +1 -1
- package/lib/globalVarClientHandler.js +1 -1
- package/lib/globalVarDefaultValueHandler.js +1 -1
- package/lib/index.js +4 -4
- package/lib/locale.js +1 -1
- package/lib/polyfills.js +1 -1
- package/lib/renderers/Form.js +1 -1
- 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.js +1 -1
- package/lib/store/app.js +1 -1
- package/lib/store/combo.js +1 -1
- package/lib/store/crud.js +1 -1
- package/lib/store/form.js +1 -1
- package/lib/store/formItem.js +1 -1
- package/lib/store/iRenderer.js +1 -1
- package/lib/store/index.js +1 -1
- package/lib/store/list.js +1 -1
- package/lib/store/manager.js +1 -1
- package/lib/store/modal.js +1 -1
- package/lib/store/node.js +1 -1
- package/lib/store/pagination.js +1 -1
- package/lib/store/root.d.ts +3 -2
- package/lib/store/root.js +71 -54
- package/lib/store/service.js +1 -1
- package/lib/store/status.js +1 -1
- package/lib/store/table.d.ts +39 -4
- package/lib/store/table.js +28 -11
- package/lib/store/table2.js +1 -1
- 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 +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/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.js +1 -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 +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 +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/esm/store/root.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.13.0-beta.
|
|
2
|
+
* amis-core v6.13.0-beta.7
|
|
3
3
|
* Copyright 2018-2025 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { __assign, __generator, __values, __awaiter, __read } from 'tslib';
|
|
6
|
+
import { __assign, __generator, __rest, __values, __awaiter, __read } from 'tslib';
|
|
7
7
|
import { types, flow } from 'mobx-state-tree';
|
|
8
8
|
import { parseQuery, isObjectShallowModified } from '../utils/helper.js';
|
|
9
9
|
import { ServiceStore } from './service.js';
|
|
@@ -13,7 +13,7 @@ import '../utils/browser.js';
|
|
|
13
13
|
import '../utils/ColorScale.js';
|
|
14
14
|
import 'react';
|
|
15
15
|
import 'lodash/chunk';
|
|
16
|
-
import {
|
|
16
|
+
import { extractObjectChain, createObjectFromChain, cloneObject } from '../utils/object.js';
|
|
17
17
|
import '../utils/memoryParse.js';
|
|
18
18
|
import 'amis-formula';
|
|
19
19
|
import isPlainObject from 'lodash/isPlainObject';
|
|
@@ -66,6 +66,7 @@ var RootStore = ServiceStore.named('RootStore')
|
|
|
66
66
|
.volatile(function (self) {
|
|
67
67
|
return {
|
|
68
68
|
context: {},
|
|
69
|
+
legacyGlobalTempContext: {},
|
|
69
70
|
globalVars: [],
|
|
70
71
|
globalData: {
|
|
71
72
|
global: {},
|
|
@@ -77,13 +78,53 @@ var RootStore = ServiceStore.named('RootStore')
|
|
|
77
78
|
get nextGlobalData() {
|
|
78
79
|
var globalData = {};
|
|
79
80
|
var globalState = {};
|
|
80
|
-
|
|
81
|
+
var chain = extractObjectChain(self.data);
|
|
82
|
+
var touched = false;
|
|
83
|
+
var saved = true;
|
|
84
|
+
var errors = {};
|
|
85
|
+
var initialized = true;
|
|
86
|
+
self.globalVarTempStates.forEach(function (state, key) {
|
|
87
|
+
globalData[key] = state.value;
|
|
88
|
+
touched = touched || state.touched;
|
|
89
|
+
if (!state.saved) {
|
|
90
|
+
saved = false;
|
|
91
|
+
}
|
|
92
|
+
if (state.errorMessages.length) {
|
|
93
|
+
errors[key] = state.errorMessages;
|
|
94
|
+
}
|
|
95
|
+
if (!state.initialized) {
|
|
96
|
+
initialized = false;
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
globalState = {
|
|
100
|
+
fields: self.globalVarTempStates.toJSON(),
|
|
101
|
+
initialized: initialized,
|
|
102
|
+
touched: touched,
|
|
103
|
+
saved: saved,
|
|
104
|
+
errors: errors,
|
|
105
|
+
valid: !Object.keys(errors).length
|
|
106
|
+
};
|
|
107
|
+
chain.unshift({
|
|
108
|
+
global: globalData,
|
|
109
|
+
globalState: globalState
|
|
110
|
+
});
|
|
111
|
+
chain.unshift(self.legacyGlobalTempContext);
|
|
112
|
+
chain.unshift(self.context);
|
|
113
|
+
return createObjectFromChain(chain);
|
|
114
|
+
},
|
|
115
|
+
get downStream() {
|
|
116
|
+
var result = self.data;
|
|
117
|
+
if (self.context || self.query) {
|
|
118
|
+
var chain = extractObjectChain(result);
|
|
119
|
+
// 数据链中添加 global 和 globalState
|
|
120
|
+
// 对应的是全局变量的值和全局变量的状态
|
|
121
|
+
var globalData_1 = {};
|
|
81
122
|
var touched_1 = false;
|
|
82
123
|
var saved_1 = true;
|
|
83
124
|
var errors_1 = {};
|
|
84
125
|
var initialized_1 = true;
|
|
85
|
-
self.
|
|
86
|
-
|
|
126
|
+
self.globalVarStates.forEach(function (state, key) {
|
|
127
|
+
globalData_1[key] = state.value;
|
|
87
128
|
touched_1 = touched_1 || state.touched;
|
|
88
129
|
if (!state.saved) {
|
|
89
130
|
saved_1 = false;
|
|
@@ -95,59 +136,19 @@ var RootStore = ServiceStore.named('RootStore')
|
|
|
95
136
|
initialized_1 = false;
|
|
96
137
|
}
|
|
97
138
|
});
|
|
98
|
-
|
|
99
|
-
|
|
139
|
+
// 保存全局变量的值和状态
|
|
140
|
+
Object.assign(self.globalData.global, globalData_1);
|
|
141
|
+
Object.assign(self.globalData.globalState, {
|
|
142
|
+
fields: self.globalVarStates.toJSON(),
|
|
100
143
|
initialized: initialized_1,
|
|
101
144
|
touched: touched_1,
|
|
102
145
|
saved: saved_1,
|
|
103
146
|
errors: errors_1,
|
|
104
147
|
valid: !Object.keys(errors_1).length
|
|
105
|
-
};
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
globalState: globalState
|
|
110
|
-
});
|
|
111
|
-
},
|
|
112
|
-
get downStream() {
|
|
113
|
-
var result = self.data;
|
|
114
|
-
if (self.context || self.query || self.globalVarStates.size) {
|
|
115
|
-
var chain = extractObjectChain(result);
|
|
116
|
-
// 数据链中添加 global 和 globalState
|
|
117
|
-
// 对应的是全局变量的值和全局变量的状态
|
|
118
|
-
if (self.globalVarStates.size) {
|
|
119
|
-
var globalData_1 = {};
|
|
120
|
-
var touched_2 = false;
|
|
121
|
-
var saved_2 = true;
|
|
122
|
-
var errors_2 = {};
|
|
123
|
-
var initialized_2 = true;
|
|
124
|
-
self.globalVarStates.forEach(function (state, key) {
|
|
125
|
-
globalData_1[key] = state.value;
|
|
126
|
-
touched_2 = touched_2 || state.touched;
|
|
127
|
-
if (!state.saved) {
|
|
128
|
-
saved_2 = false;
|
|
129
|
-
}
|
|
130
|
-
if (state.errorMessages.length) {
|
|
131
|
-
errors_2[key] = state.errorMessages;
|
|
132
|
-
}
|
|
133
|
-
if (!state.initialized) {
|
|
134
|
-
initialized_2 = false;
|
|
135
|
-
}
|
|
136
|
-
});
|
|
137
|
-
// 保存全局变量的值和状态
|
|
138
|
-
Object.assign(self.globalData.global, globalData_1);
|
|
139
|
-
Object.assign(self.globalData.globalState, {
|
|
140
|
-
fields: self.globalVarStates.toJSON(),
|
|
141
|
-
initialized: initialized_2,
|
|
142
|
-
touched: touched_2,
|
|
143
|
-
saved: saved_2,
|
|
144
|
-
errors: errors_2,
|
|
145
|
-
valid: !Object.keys(errors_2).length
|
|
146
|
-
});
|
|
147
|
-
// self.globalData 一直都是那个对象,这样组件里面始终拿到的都是最新的
|
|
148
|
-
chain.unshift(self.globalData);
|
|
149
|
-
}
|
|
150
|
-
self.context && chain.unshift(self.context);
|
|
148
|
+
});
|
|
149
|
+
// self.globalData 一直都是那个对象,这样组件里面始终拿到的都是最新的
|
|
150
|
+
chain.unshift(self.globalData);
|
|
151
|
+
chain.unshift(self.context);
|
|
151
152
|
self.query &&
|
|
152
153
|
chain.splice(chain.length - 1, 0, __assign(__assign({}, self.query), { __query: self.query }));
|
|
153
154
|
result = createObjectFromChain(chain);
|
|
@@ -600,6 +601,11 @@ var RootStore = ServiceStore.named('RootStore')
|
|
|
600
601
|
self.globalVarTempStates.forEach(function (state, key) {
|
|
601
602
|
self.globalVarStates.set(key, __assign({}, state));
|
|
602
603
|
});
|
|
604
|
+
if (self.legacyGlobalTempContext.__page !== self.context.__page ||
|
|
605
|
+
self.legacyGlobalTempContext.appVariables !== self.context.appVariables) {
|
|
606
|
+
Object.assign(self.context, self.legacyGlobalTempContext);
|
|
607
|
+
self.data = cloneObject(self.data);
|
|
608
|
+
}
|
|
603
609
|
}
|
|
604
610
|
var pendingCount = 0;
|
|
605
611
|
var callbacks = [];
|
|
@@ -616,10 +622,21 @@ var RootStore = ServiceStore.named('RootStore')
|
|
|
616
622
|
});
|
|
617
623
|
}
|
|
618
624
|
return {
|
|
619
|
-
updateContext: function (context) {
|
|
625
|
+
updateContext: function (context, isInit) {
|
|
620
626
|
// 因为 context 不是受控属性,直接共用引用好了
|
|
621
627
|
// 否则还会触发孩子节点的重新渲染
|
|
622
|
-
|
|
628
|
+
if (isInit === void 0) { isInit = false; }
|
|
629
|
+
var _a = context || {}, __page = _a.__page, appVariables = _a.appVariables, rest = __rest(_a, ["__page", "appVariables"]);
|
|
630
|
+
// 对历史用法做兼容
|
|
631
|
+
if (__page || appVariables) {
|
|
632
|
+
if (isInit) {
|
|
633
|
+
self.context.__page = context.__page;
|
|
634
|
+
self.context.appVariables = context.appVariables;
|
|
635
|
+
}
|
|
636
|
+
self.legacyGlobalTempContext.__page = __page;
|
|
637
|
+
self.legacyGlobalTempContext.appVariables = appVariables;
|
|
638
|
+
}
|
|
639
|
+
Object.assign(self.context, rest);
|
|
623
640
|
},
|
|
624
641
|
updateGlobalVarState: function (key, state) {
|
|
625
642
|
var origin = self.globalVarTempStates.get(key);
|
package/esm/store/service.js
CHANGED
package/esm/store/status.js
CHANGED
package/esm/store/table.d.ts
CHANGED
|
@@ -31,6 +31,7 @@ export declare const Column: import("mobx-state-tree").IModelType<{
|
|
|
31
31
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
32
32
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
33
33
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
34
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
34
35
|
}, {
|
|
35
36
|
readonly isPrimary: boolean;
|
|
36
37
|
readonly columnKey: any;
|
|
@@ -41,6 +42,7 @@ export declare const Column: import("mobx-state-tree").IModelType<{
|
|
|
41
42
|
setMinWidth(value: number): void;
|
|
42
43
|
setWidth(value: number): void;
|
|
43
44
|
setRealWidth(value: number): void;
|
|
45
|
+
markAppeared(value: boolean): void;
|
|
44
46
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>;
|
|
45
47
|
export type IColumn = Instance<typeof Column>;
|
|
46
48
|
export type SColumn = SnapshotIn<typeof Column>;
|
|
@@ -152,6 +154,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
152
154
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
153
155
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
154
156
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
157
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
155
158
|
}, {
|
|
156
159
|
readonly isPrimary: boolean;
|
|
157
160
|
readonly columnKey: any;
|
|
@@ -162,6 +165,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
162
165
|
setMinWidth(value: number): void;
|
|
163
166
|
setWidth(value: number): void;
|
|
164
167
|
setRealWidth(value: number): void;
|
|
168
|
+
markAppeared(value: boolean): void;
|
|
165
169
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>;
|
|
166
170
|
rows: import("mobx-state-tree").IArrayType<import("mobx-state-tree").IModelType<{
|
|
167
171
|
storeType: import("mobx-state-tree").IType<string | undefined, string, string>;
|
|
@@ -308,7 +312,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
308
312
|
exportExcelLoading: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
309
313
|
searchFormExpanded: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
310
314
|
lazyRenderAfter: import("mobx-state-tree").IType<number | undefined, number, number>;
|
|
311
|
-
|
|
315
|
+
tableLayout: import("mobx-state-tree").IType<string | undefined, string, string>;
|
|
312
316
|
theadHeight: import("mobx-state-tree").IType<number | undefined, number, number>;
|
|
313
317
|
persistKey: import("mobx-state-tree").IType<string | undefined, string, string>;
|
|
314
318
|
}, {
|
|
@@ -343,7 +347,6 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
343
347
|
getDrawerScoped(): import("..").IScopedContext | null;
|
|
344
348
|
} & {
|
|
345
349
|
readonly __: any;
|
|
346
|
-
readonly tableLayout: string;
|
|
347
350
|
getSelectionUpperLimit: () => number;
|
|
348
351
|
readonly columnsKey: string;
|
|
349
352
|
readonly columnsData: ({
|
|
@@ -371,6 +374,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
371
374
|
pristine: any;
|
|
372
375
|
remark: any;
|
|
373
376
|
className: any;
|
|
377
|
+
appeared: boolean;
|
|
374
378
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
375
379
|
readonly isPrimary: boolean;
|
|
376
380
|
readonly columnKey: any;
|
|
@@ -381,6 +385,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
381
385
|
setMinWidth(value: number): void;
|
|
382
386
|
setWidth(value: number): void;
|
|
383
387
|
setRealWidth(value: number): void;
|
|
388
|
+
markAppeared(value: boolean): void;
|
|
384
389
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
385
390
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
386
391
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -406,6 +411,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
406
411
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
407
412
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
408
413
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
414
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
409
415
|
}, {
|
|
410
416
|
readonly isPrimary: boolean;
|
|
411
417
|
readonly columnKey: any;
|
|
@@ -416,6 +422,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
416
422
|
setMinWidth(value: number): void;
|
|
417
423
|
setWidth(value: number): void;
|
|
418
424
|
setRealWidth(value: number): void;
|
|
425
|
+
markAppeared(value: boolean): void;
|
|
419
426
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
420
427
|
readonly forms: {
|
|
421
428
|
store: {
|
|
@@ -492,7 +499,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
492
499
|
markFetching: (fetching?: boolean) => void;
|
|
493
500
|
markSaving: (saving?: boolean) => void;
|
|
494
501
|
markBusying: (busying?: boolean) => void;
|
|
495
|
-
fetchInitData: (api: import("..").Api, data?: object | undefined, options?: import("..").fetchOptions | undefined) => Promise<any>;
|
|
502
|
+
fetchInitData: (api: import("..").Api, data?: object | undefined, options?: import("..").fetchOptions | undefined) => Promise<any>; /** 排除掉内置的列和不可见的列 */
|
|
496
503
|
fetchData: (api: import("..").Api, data?: object | undefined, options?: import("..").fetchOptions | undefined) => Promise<any>;
|
|
497
504
|
reInitData: (data: object | undefined, replace?: boolean, concatFields?: string | string[] | undefined) => void;
|
|
498
505
|
updateMessage: (msg?: string | undefined, error?: boolean) => void;
|
|
@@ -5995,7 +6002,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
5995
6002
|
markFetching: (fetching?: boolean) => void;
|
|
5996
6003
|
markSaving: (saving?: boolean) => void;
|
|
5997
6004
|
markBusying: (busying?: boolean) => void;
|
|
5998
|
-
fetchInitData: (api: import("..").Api, data?: object | undefined, options?: import("..").fetchOptions | undefined) => Promise<any>;
|
|
6005
|
+
fetchInitData: (api: import("..").Api, data?: object | undefined, options?: import("..").fetchOptions | undefined) => Promise<any>; /** 排除掉内置的列和不可见的列 */
|
|
5999
6006
|
fetchData: (api: import("..").Api, data?: object | undefined, options?: import("..").fetchOptions | undefined) => Promise<any>;
|
|
6000
6007
|
reInitData: (data: object | undefined, replace?: boolean, concatFields?: string | string[] | undefined) => void;
|
|
6001
6008
|
updateMessage: (msg?: string | undefined, error?: boolean) => void;
|
|
@@ -11449,6 +11456,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11449
11456
|
pristine: any;
|
|
11450
11457
|
remark: any;
|
|
11451
11458
|
className: any;
|
|
11459
|
+
appeared: boolean;
|
|
11452
11460
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11453
11461
|
readonly isPrimary: boolean;
|
|
11454
11462
|
readonly columnKey: any;
|
|
@@ -11459,6 +11467,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11459
11467
|
setMinWidth(value: number): void;
|
|
11460
11468
|
setWidth(value: number): void;
|
|
11461
11469
|
setRealWidth(value: number): void;
|
|
11470
|
+
markAppeared(value: boolean): void;
|
|
11462
11471
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11463
11472
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11464
11473
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11484,6 +11493,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11484
11493
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11485
11494
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11486
11495
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11496
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11487
11497
|
}, {
|
|
11488
11498
|
readonly isPrimary: boolean;
|
|
11489
11499
|
readonly columnKey: any;
|
|
@@ -11494,6 +11504,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11494
11504
|
setMinWidth(value: number): void;
|
|
11495
11505
|
setWidth(value: number): void;
|
|
11496
11506
|
setRealWidth(value: number): void;
|
|
11507
|
+
markAppeared(value: boolean): void;
|
|
11497
11508
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11498
11509
|
readonly activedSearchableColumns: ({
|
|
11499
11510
|
label: any;
|
|
@@ -11520,6 +11531,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11520
11531
|
pristine: any;
|
|
11521
11532
|
remark: any;
|
|
11522
11533
|
className: any;
|
|
11534
|
+
appeared: boolean;
|
|
11523
11535
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11524
11536
|
readonly isPrimary: boolean;
|
|
11525
11537
|
readonly columnKey: any;
|
|
@@ -11530,6 +11542,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11530
11542
|
setMinWidth(value: number): void;
|
|
11531
11543
|
setWidth(value: number): void;
|
|
11532
11544
|
setRealWidth(value: number): void;
|
|
11545
|
+
markAppeared(value: boolean): void;
|
|
11533
11546
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11534
11547
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11535
11548
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11555,6 +11568,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11555
11568
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11556
11569
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11557
11570
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11571
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11558
11572
|
}, {
|
|
11559
11573
|
readonly isPrimary: boolean;
|
|
11560
11574
|
readonly columnKey: any;
|
|
@@ -11565,6 +11579,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11565
11579
|
setMinWidth(value: number): void;
|
|
11566
11580
|
setWidth(value: number): void;
|
|
11567
11581
|
setRealWidth(value: number): void;
|
|
11582
|
+
markAppeared(value: boolean): void;
|
|
11568
11583
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11569
11584
|
/** 导出excel列(包含breakpoint列) */
|
|
11570
11585
|
readonly exportColumns: ({
|
|
@@ -11592,6 +11607,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11592
11607
|
pristine: any;
|
|
11593
11608
|
remark: any;
|
|
11594
11609
|
className: any;
|
|
11610
|
+
appeared: boolean;
|
|
11595
11611
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11596
11612
|
readonly isPrimary: boolean;
|
|
11597
11613
|
readonly columnKey: any;
|
|
@@ -11602,6 +11618,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11602
11618
|
setMinWidth(value: number): void;
|
|
11603
11619
|
setWidth(value: number): void;
|
|
11604
11620
|
setRealWidth(value: number): void;
|
|
11621
|
+
markAppeared(value: boolean): void;
|
|
11605
11622
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11606
11623
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11607
11624
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11627,6 +11644,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11627
11644
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11628
11645
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11629
11646
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11647
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11630
11648
|
}, {
|
|
11631
11649
|
readonly isPrimary: boolean;
|
|
11632
11650
|
readonly columnKey: any;
|
|
@@ -11637,6 +11655,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11637
11655
|
setMinWidth(value: number): void;
|
|
11638
11656
|
setWidth(value: number): void;
|
|
11639
11657
|
setRealWidth(value: number): void;
|
|
11658
|
+
markAppeared(value: boolean): void;
|
|
11640
11659
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11641
11660
|
readonly filteredColumns: ({
|
|
11642
11661
|
label: any;
|
|
@@ -11663,6 +11682,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11663
11682
|
pristine: any;
|
|
11664
11683
|
remark: any;
|
|
11665
11684
|
className: any;
|
|
11685
|
+
appeared: boolean;
|
|
11666
11686
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11667
11687
|
readonly isPrimary: boolean;
|
|
11668
11688
|
readonly columnKey: any;
|
|
@@ -11673,6 +11693,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11673
11693
|
setMinWidth(value: number): void;
|
|
11674
11694
|
setWidth(value: number): void;
|
|
11675
11695
|
setRealWidth(value: number): void;
|
|
11696
|
+
markAppeared(value: boolean): void;
|
|
11676
11697
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11677
11698
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11678
11699
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11698,6 +11719,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11698
11719
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11699
11720
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11700
11721
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11722
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11701
11723
|
}, {
|
|
11702
11724
|
readonly isPrimary: boolean;
|
|
11703
11725
|
readonly columnKey: any;
|
|
@@ -11708,6 +11730,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11708
11730
|
setMinWidth(value: number): void;
|
|
11709
11731
|
setWidth(value: number): void;
|
|
11710
11732
|
setRealWidth(value: number): void;
|
|
11733
|
+
markAppeared(value: boolean): void;
|
|
11711
11734
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11712
11735
|
readonly footableColumns: ({
|
|
11713
11736
|
label: any;
|
|
@@ -11734,6 +11757,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11734
11757
|
pristine: any;
|
|
11735
11758
|
remark: any;
|
|
11736
11759
|
className: any;
|
|
11760
|
+
appeared: boolean;
|
|
11737
11761
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11738
11762
|
readonly isPrimary: boolean;
|
|
11739
11763
|
readonly columnKey: any;
|
|
@@ -11744,6 +11768,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11744
11768
|
setMinWidth(value: number): void;
|
|
11745
11769
|
setWidth(value: number): void;
|
|
11746
11770
|
setRealWidth(value: number): void;
|
|
11771
|
+
markAppeared(value: boolean): void;
|
|
11747
11772
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11748
11773
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11749
11774
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11769,6 +11794,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11769
11794
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11770
11795
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11771
11796
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11797
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11772
11798
|
}, {
|
|
11773
11799
|
readonly isPrimary: boolean;
|
|
11774
11800
|
readonly columnKey: any;
|
|
@@ -11779,6 +11805,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11779
11805
|
setMinWidth(value: number): void;
|
|
11780
11806
|
setWidth(value: number): void;
|
|
11781
11807
|
setRealWidth(value: number): void;
|
|
11808
|
+
markAppeared(value: boolean): void;
|
|
11782
11809
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11783
11810
|
readonly toggableColumns: ({
|
|
11784
11811
|
label: any;
|
|
@@ -11805,6 +11832,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11805
11832
|
pristine: any;
|
|
11806
11833
|
remark: any;
|
|
11807
11834
|
className: any;
|
|
11835
|
+
appeared: boolean;
|
|
11808
11836
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11809
11837
|
readonly isPrimary: boolean;
|
|
11810
11838
|
readonly columnKey: any;
|
|
@@ -11815,6 +11843,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11815
11843
|
setMinWidth(value: number): void;
|
|
11816
11844
|
setWidth(value: number): void;
|
|
11817
11845
|
setRealWidth(value: number): void;
|
|
11846
|
+
markAppeared(value: boolean): void;
|
|
11818
11847
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11819
11848
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11820
11849
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11840,6 +11869,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11840
11869
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11841
11870
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11842
11871
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11872
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11843
11873
|
}, {
|
|
11844
11874
|
readonly isPrimary: boolean;
|
|
11845
11875
|
readonly columnKey: any;
|
|
@@ -11850,6 +11880,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11850
11880
|
setMinWidth(value: number): void;
|
|
11851
11881
|
setWidth(value: number): void;
|
|
11852
11882
|
setRealWidth(value: number): void;
|
|
11883
|
+
markAppeared(value: boolean): void;
|
|
11853
11884
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11854
11885
|
readonly activeToggaleColumns: ({
|
|
11855
11886
|
label: any;
|
|
@@ -11876,6 +11907,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11876
11907
|
pristine: any;
|
|
11877
11908
|
remark: any;
|
|
11878
11909
|
className: any;
|
|
11910
|
+
appeared: boolean;
|
|
11879
11911
|
} & import("mobx-state-tree/dist/internal").NonEmptyObject & {
|
|
11880
11912
|
readonly isPrimary: boolean;
|
|
11881
11913
|
readonly columnKey: any;
|
|
@@ -11886,6 +11918,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11886
11918
|
setMinWidth(value: number): void;
|
|
11887
11919
|
setWidth(value: number): void;
|
|
11888
11920
|
setRealWidth(value: number): void;
|
|
11921
|
+
markAppeared(value: boolean): void;
|
|
11889
11922
|
} & import("mobx-state-tree").IStateTreeNode<import("mobx-state-tree").IModelType<{
|
|
11890
11923
|
label: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11891
11924
|
type: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").ISimpleType<string>, [undefined]>;
|
|
@@ -11911,6 +11944,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11911
11944
|
pristine: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11912
11945
|
remark: import("mobx-state-tree").IOptionalIType<import("mobx-state-tree").IType<any, any, any>, [undefined]>;
|
|
11913
11946
|
className: import("mobx-state-tree").ITypeUnion<any, any, any>;
|
|
11947
|
+
appeared: import("mobx-state-tree").IType<boolean | undefined, boolean, boolean>;
|
|
11914
11948
|
}, {
|
|
11915
11949
|
readonly isPrimary: boolean;
|
|
11916
11950
|
readonly columnKey: any;
|
|
@@ -11921,6 +11955,7 @@ export declare const TableStore: import("mobx-state-tree").IModelType<{
|
|
|
11921
11955
|
setMinWidth(value: number): void;
|
|
11922
11956
|
setWidth(value: number): void;
|
|
11923
11957
|
setRealWidth(value: number): void;
|
|
11958
|
+
markAppeared(value: boolean): void;
|
|
11924
11959
|
}, import("mobx-state-tree")._NotCustomized, import("mobx-state-tree")._NotCustomized>>)[];
|
|
11925
11960
|
readonly someChecked: boolean;
|
|
11926
11961
|
readonly allChecked: boolean;
|
package/esm/store/table.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* amis-core v6.13.0-beta.
|
|
2
|
+
* amis-core v6.13.0-beta.7
|
|
3
3
|
* Copyright 2018-2025 fex
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -89,7 +89,8 @@ var Column = types
|
|
|
89
89
|
breakpoint: types.optional(types.frozen(), undefined),
|
|
90
90
|
pristine: types.optional(types.frozen(), undefined),
|
|
91
91
|
remark: types.optional(types.frozen(), undefined),
|
|
92
|
-
className: types.union(types.string, types.frozen())
|
|
92
|
+
className: types.union(types.string, types.frozen()),
|
|
93
|
+
appeared: false
|
|
93
94
|
})
|
|
94
95
|
.views(function (self) { return ({
|
|
95
96
|
get isPrimary() {
|
|
@@ -130,6 +131,9 @@ var Column = types
|
|
|
130
131
|
},
|
|
131
132
|
setRealWidth: function (value) {
|
|
132
133
|
self.realWidth = value;
|
|
134
|
+
},
|
|
135
|
+
markAppeared: function (value) {
|
|
136
|
+
self.appeared = self.appeared || value;
|
|
133
137
|
}
|
|
134
138
|
}); });
|
|
135
139
|
var Row = types
|
|
@@ -152,6 +156,8 @@ var Row = types
|
|
|
152
156
|
loading: false,
|
|
153
157
|
error: '',
|
|
154
158
|
depth: types.number // 当前children位于第几层,便于使用getParent获取最顶层TableStore
|
|
159
|
+
// appeared: true,
|
|
160
|
+
// lazyRender: false
|
|
155
161
|
})
|
|
156
162
|
.views(function (self) { return ({
|
|
157
163
|
get parent() {
|
|
@@ -349,6 +355,9 @@ var Row = types
|
|
|
349
355
|
index++;
|
|
350
356
|
}
|
|
351
357
|
},
|
|
358
|
+
// markAppeared(value: any) {
|
|
359
|
+
// value && (self.appeared = !!value);
|
|
360
|
+
// },
|
|
352
361
|
markLoading: function (value) {
|
|
353
362
|
self.loading = !!value;
|
|
354
363
|
},
|
|
@@ -418,7 +427,7 @@ var TableStore = iRendererStore
|
|
|
418
427
|
exportExcelLoading: false,
|
|
419
428
|
searchFormExpanded: false,
|
|
420
429
|
lazyRenderAfter: 100,
|
|
421
|
-
|
|
430
|
+
tableLayout: 'auto',
|
|
422
431
|
theadHeight: 0,
|
|
423
432
|
persistKey: ''
|
|
424
433
|
})
|
|
@@ -606,12 +615,6 @@ var TableStore = iRendererStore
|
|
|
606
615
|
get __() {
|
|
607
616
|
return getEnv(self).translate;
|
|
608
617
|
},
|
|
609
|
-
get tableLayout() {
|
|
610
|
-
if (self.rows.length > self.lazyRenderAfter) {
|
|
611
|
-
return 'fixed';
|
|
612
|
-
}
|
|
613
|
-
return self.tableLayoutConfig;
|
|
614
|
-
},
|
|
615
618
|
getSelectionUpperLimit: getSelectionUpperLimit,
|
|
616
619
|
get columnsKey() {
|
|
617
620
|
if (self.persistKey) {
|
|
@@ -892,8 +895,8 @@ var TableStore = iRendererStore
|
|
|
892
895
|
(self.canAccessSuperData = !!config.canAccessSuperData);
|
|
893
896
|
typeof config.lazyRenderAfter === 'number' &&
|
|
894
897
|
(self.lazyRenderAfter = config.lazyRenderAfter);
|
|
895
|
-
typeof config.
|
|
896
|
-
(self.
|
|
898
|
+
typeof config.tableLayout === 'string' &&
|
|
899
|
+
(self.tableLayout = config.tableLayout);
|
|
897
900
|
config.showIndex !== undefined && (self.showIndex = config.showIndex);
|
|
898
901
|
config.persistKey !== undefined && (self.persistKey = config.persistKey);
|
|
899
902
|
if (config.columns && Array.isArray(config.columns)) {
|
|
@@ -1162,6 +1165,20 @@ var TableStore = iRendererStore
|
|
|
1162
1165
|
var allMatched = replaceRow(arr, reUseRow);
|
|
1163
1166
|
self.isNested = self.rows.some(function (item) { return item.children.length || (item.defer && !item.loaded); });
|
|
1164
1167
|
if (!allMatched) {
|
|
1168
|
+
// 前 20 个直接渲染,后面的按需渲染
|
|
1169
|
+
// if (
|
|
1170
|
+
// self.lazyRenderAfter &&
|
|
1171
|
+
// self.falttenedRows.length > self.lazyRenderAfter
|
|
1172
|
+
// ) {
|
|
1173
|
+
// for (
|
|
1174
|
+
// let i = self.lazyRenderAfter, len = self.falttenedRows.length;
|
|
1175
|
+
// i < len;
|
|
1176
|
+
// i++
|
|
1177
|
+
// ) {
|
|
1178
|
+
// self.falttenedRows[i].appeared = false;
|
|
1179
|
+
// self.falttenedRows[i].lazyRender = true;
|
|
1180
|
+
// }
|
|
1181
|
+
// }
|
|
1165
1182
|
var expand = self.footable && self.footable.expand;
|
|
1166
1183
|
if (expand === 'first' ||
|
|
1167
1184
|
(self.expandConfig && self.expandConfig.expand === 'first')) {
|
package/esm/store/table2.js
CHANGED
package/esm/theme.js
CHANGED
package/esm/utils/Animation.js
CHANGED
package/esm/utils/ColorScale.js
CHANGED
package/esm/utils/DataSchema.js
CHANGED
package/esm/utils/DataScope.js
CHANGED