cloud-web-corejs 1.0.54-dev.434 → 1.0.54-dev.436
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/package.json +1 -1
- package/src/components/scriptTest/mixins.js +1 -1
- package/src/components/xform/form-designer/form-widget/dialog/baseFormulaDialog copy.vue +971 -0
- package/src/components/xform/form-designer/form-widget/dialog/baseFormulaDialog.vue +1 -1
- package/src/components/xform/form-render/indexMixin.js +66 -42
- package/src/utils/request.js +1 -1
- package/src/utils/vab.js +1 -1100
|
@@ -1117,6 +1117,50 @@ modules = {
|
|
|
1117
1117
|
|
|
1118
1118
|
return hasModifyItem;
|
|
1119
1119
|
},
|
|
1120
|
+
loadFormData(options) {
|
|
1121
|
+
let config = options.config || {}
|
|
1122
|
+
let that = this;
|
|
1123
|
+
let formConfig = this.formConfig;
|
|
1124
|
+
let entity = formConfig.entity;
|
|
1125
|
+
let dataId = this.dataId;
|
|
1126
|
+
let reportTemplate = this.reportTemplate;
|
|
1127
|
+
let scriptCode = formConfig.formScriptCode || "getOne";
|
|
1128
|
+
|
|
1129
|
+
let formData = {};
|
|
1130
|
+
if (scriptCode) {
|
|
1131
|
+
let formCode = reportTemplate.formCode;
|
|
1132
|
+
|
|
1133
|
+
let formScriptParam = this.handleCustomEvent(
|
|
1134
|
+
this.formConfig.formScriptParam
|
|
1135
|
+
);
|
|
1136
|
+
|
|
1137
|
+
let defaultOption = {
|
|
1138
|
+
addCreateInfo: true,
|
|
1139
|
+
queryCreateInfo:
|
|
1140
|
+
window.$vueRoot.$store.getters.queryCreateInfo || "0",
|
|
1141
|
+
};
|
|
1142
|
+
return this.formHttp({
|
|
1143
|
+
// url: "/" + reportTemplate.serviceName + "/form_ins/getOne",
|
|
1144
|
+
scriptCode: scriptCode,
|
|
1145
|
+
data: {
|
|
1146
|
+
formCode: formCode,
|
|
1147
|
+
formVersion: reportTemplate.formVersion,
|
|
1148
|
+
taBm: entity,
|
|
1149
|
+
data: {
|
|
1150
|
+
id: dataId,
|
|
1151
|
+
...formScriptParam,
|
|
1152
|
+
},
|
|
1153
|
+
},
|
|
1154
|
+
...defaultOption,
|
|
1155
|
+
success: (res) => {
|
|
1156
|
+
formData = res.objx || {};
|
|
1157
|
+
this.setFormData(formData);
|
|
1158
|
+
options.callback && options.callback(formData);
|
|
1159
|
+
},
|
|
1160
|
+
...config,
|
|
1161
|
+
});
|
|
1162
|
+
}
|
|
1163
|
+
},
|
|
1120
1164
|
loadDefaultEntityData(callback) {
|
|
1121
1165
|
let that = this;
|
|
1122
1166
|
let formConfig = this.formConfig;
|
|
@@ -1132,8 +1176,8 @@ modules = {
|
|
|
1132
1176
|
if (entity && dataId && scriptCode) {
|
|
1133
1177
|
let formCode = reportTemplate.formCode;
|
|
1134
1178
|
let otherParam = {};
|
|
1135
|
-
let wfCode = reportTemplate.objTypeCode;
|
|
1136
1179
|
if (wfEnabled) {
|
|
1180
|
+
let wfCode = reportTemplate.objTypeCode;
|
|
1137
1181
|
wfConfig = (res) => {
|
|
1138
1182
|
let wfConfig1 = null;
|
|
1139
1183
|
let callback1 = null;
|
|
@@ -1243,44 +1287,24 @@ modules = {
|
|
|
1243
1287
|
return resOption;
|
|
1244
1288
|
};
|
|
1245
1289
|
}
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
taBm: entity,
|
|
1263
|
-
data: {
|
|
1264
|
-
id: dataId,
|
|
1265
|
-
...formScriptParam,
|
|
1266
|
-
},
|
|
1267
|
-
},
|
|
1268
|
-
...defaultOption,
|
|
1269
|
-
sync: false,
|
|
1270
|
-
wfConfig,
|
|
1271
|
-
success: (res) => {
|
|
1272
|
-
formData = res.objx || {};
|
|
1273
|
-
// this.currentFormData = res.objx || {};
|
|
1274
|
-
if (!wfConfig) {
|
|
1275
|
-
this.hanldeCommonWidget2(); //处理组件显隐,可编辑
|
|
1276
|
-
this.setFormData(formData);
|
|
1277
|
-
this.showFormContent = true;
|
|
1278
|
-
this.$nextTick(() => {
|
|
1279
|
-
this.handleShowHideRule();
|
|
1280
|
-
callback && callback();
|
|
1281
|
-
});
|
|
1290
|
+
return this.loadFormData({
|
|
1291
|
+
config:{
|
|
1292
|
+
sync: false,
|
|
1293
|
+
wfConfig,
|
|
1294
|
+
success: (res) => {
|
|
1295
|
+
formData = res.objx || {};
|
|
1296
|
+
// this.currentFormData = res.objx || {};
|
|
1297
|
+
if (!wfConfig) {
|
|
1298
|
+
this.hanldeCommonWidget2(); //处理组件显隐,可编辑
|
|
1299
|
+
this.setFormData(formData);
|
|
1300
|
+
this.showFormContent = true;
|
|
1301
|
+
this.$nextTick(() => {
|
|
1302
|
+
this.handleShowHideRule();
|
|
1303
|
+
callback && callback();
|
|
1304
|
+
});
|
|
1305
|
+
}
|
|
1282
1306
|
}
|
|
1283
|
-
}
|
|
1307
|
+
}
|
|
1284
1308
|
});
|
|
1285
1309
|
} else {
|
|
1286
1310
|
this.hanldeCommonWidget2(); //处理组件显隐,可编辑
|
|
@@ -1816,9 +1840,9 @@ modules = {
|
|
|
1816
1840
|
foundW.widget.type === "grid-sub-form"
|
|
1817
1841
|
) {
|
|
1818
1842
|
foundW.disableGridSubForm();
|
|
1819
|
-
}else if (!!foundW.widget && foundW.widget.type === "data-table") {
|
|
1843
|
+
} else if (!!foundW.widget && foundW.widget.type === "data-table") {
|
|
1820
1844
|
foundW.disableGridForm();
|
|
1821
|
-
}
|
|
1845
|
+
} else {
|
|
1822
1846
|
!!foundW.setDisabled && foundW.setDisabled(true);
|
|
1823
1847
|
}
|
|
1824
1848
|
}
|
|
@@ -1840,7 +1864,7 @@ modules = {
|
|
|
1840
1864
|
foundW.widget.type === "grid-sub-form"
|
|
1841
1865
|
) {
|
|
1842
1866
|
foundW.enableGridSubForm();
|
|
1843
|
-
}else if (!!foundW.widget && foundW.widget.type === "data-table") {
|
|
1867
|
+
} else if (!!foundW.widget && foundW.widget.type === "data-table") {
|
|
1844
1868
|
foundW.enableGridForm();
|
|
1845
1869
|
} else {
|
|
1846
1870
|
!!foundW.setDisabled && foundW.setDisabled(false);
|
|
@@ -2772,7 +2796,7 @@ modules = {
|
|
|
2772
2796
|
this.showFormDialog = true;
|
|
2773
2797
|
},
|
|
2774
2798
|
closeFormDialog() {
|
|
2775
|
-
if(this.showFormDialog){
|
|
2799
|
+
if (this.showFormDialog) {
|
|
2776
2800
|
this.$refs.formDialog.close();
|
|
2777
2801
|
}
|
|
2778
2802
|
},
|