@byteluck-fe/model-driven-engine 2.3.5 → 2.3.6
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/dist/esm/common/Engine.js +3 -2
- package/dist/index.umd.js +7 -7
- package/package.json +2 -2
|
@@ -1213,12 +1213,13 @@ var Engine = /*#__PURE__*/ function(Watcher) {
|
|
|
1213
1213
|
newState[mapping.dataViewId][mapping.controlId].push(newRow);
|
|
1214
1214
|
});
|
|
1215
1215
|
} else if (entity) {
|
|
1216
|
+
var _Object_keys;
|
|
1216
1217
|
var skipKey = [] //qiyu ObjectDataBind中会提前将相关key拿出来赋值,为了避免重复赋值,设置了此变量
|
|
1217
1218
|
;
|
|
1218
1219
|
var emptyState = JSONCopy(_this.store.emptyState);
|
|
1219
|
-
if (!Object.keys(entity).length) {
|
|
1220
|
+
if (!((_Object_keys = Object.keys(entity)) === null || _Object_keys === void 0 ? void 0 : _Object_keys.length)) {
|
|
1220
1221
|
//判断entity 为空对象就给表单赋值默认值
|
|
1221
|
-
newState = emptyState;
|
|
1222
|
+
newState = JSONCopy(emptyState);
|
|
1222
1223
|
} else {
|
|
1223
1224
|
Object.keys(entity).map(function(fieldCode) {
|
|
1224
1225
|
if (skipKey.includes(fieldCode)) {
|