form-custom-test 3.0.135 → 3.0.137
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/designer.es.js +78 -5
- package/dist/designer.style.css +1 -1
- package/dist/designer.umd.js +101 -101
- package/dist/render.es.js +69 -5
- package/dist/render.style.css +1 -1
- package/dist/render.umd.js +63 -63
- package/package.json +1 -1
package/dist/render.es.js
CHANGED
|
@@ -25866,6 +25866,69 @@ const _sfc_main$v = {
|
|
|
25866
25866
|
getStaticTextRefs() {
|
|
25867
25867
|
return Object.values(this.widgetRefList).filter((ref2) => ref2 && ref2.field && ref2.field.type === "static-text");
|
|
25868
25868
|
},
|
|
25869
|
+
updateFieldLabel(fieldName, newLabel) {
|
|
25870
|
+
if (!fieldName)
|
|
25871
|
+
return false;
|
|
25872
|
+
const labelText = newLabel == null ? "" : String(newLabel);
|
|
25873
|
+
const seen = new Set();
|
|
25874
|
+
const refsToUpdate = [];
|
|
25875
|
+
const pushRef = (r) => {
|
|
25876
|
+
if (!r || !r.field || !r.field.options || seen.has(r))
|
|
25877
|
+
return;
|
|
25878
|
+
if (r.field.options.name !== fieldName)
|
|
25879
|
+
return;
|
|
25880
|
+
seen.add(r);
|
|
25881
|
+
refsToUpdate.push(r);
|
|
25882
|
+
};
|
|
25883
|
+
Object.keys(this.widgetRefList).forEach((k) => {
|
|
25884
|
+
if (k === "v_form_ref")
|
|
25885
|
+
return;
|
|
25886
|
+
if (k === fieldName || k.startsWith(fieldName + "@row")) {
|
|
25887
|
+
pushRef(this.widgetRefList[k]);
|
|
25888
|
+
}
|
|
25889
|
+
});
|
|
25890
|
+
if (refsToUpdate.length > 0) {
|
|
25891
|
+
refsToUpdate.forEach((r) => {
|
|
25892
|
+
r.field.options.label = labelText;
|
|
25893
|
+
});
|
|
25894
|
+
this.$forceUpdate();
|
|
25895
|
+
return true;
|
|
25896
|
+
}
|
|
25897
|
+
const formJson = this.getFormJson();
|
|
25898
|
+
let updated = false;
|
|
25899
|
+
const walk = (list) => {
|
|
25900
|
+
if (!Array.isArray(list) || updated)
|
|
25901
|
+
return;
|
|
25902
|
+
list.forEach((w) => {
|
|
25903
|
+
if (updated || !w)
|
|
25904
|
+
return;
|
|
25905
|
+
if (w.options && w.options.name === fieldName) {
|
|
25906
|
+
w.options.label = labelText;
|
|
25907
|
+
updated = true;
|
|
25908
|
+
return;
|
|
25909
|
+
}
|
|
25910
|
+
if (Array.isArray(w.widgetList))
|
|
25911
|
+
walk(w.widgetList);
|
|
25912
|
+
if (Array.isArray(w.cols)) {
|
|
25913
|
+
w.cols.forEach((c) => walk(c && c.widgetList));
|
|
25914
|
+
}
|
|
25915
|
+
if (Array.isArray(w.rows)) {
|
|
25916
|
+
w.rows.forEach((r) => Array.isArray(r && r.cols) && r.cols.forEach((c) => walk(c && c.widgetList)));
|
|
25917
|
+
}
|
|
25918
|
+
if (Array.isArray(w.tabs)) {
|
|
25919
|
+
w.tabs.forEach((t) => walk(t && t.widgetList));
|
|
25920
|
+
}
|
|
25921
|
+
});
|
|
25922
|
+
};
|
|
25923
|
+
walk(formJson && formJson.widgetList);
|
|
25924
|
+
if (!updated)
|
|
25925
|
+
return false;
|
|
25926
|
+
this.setFormJson(formJson);
|
|
25927
|
+
return true;
|
|
25928
|
+
},
|
|
25929
|
+
setFieldLabel(fieldName, newLabel) {
|
|
25930
|
+
return this.updateFieldLabel(fieldName, newLabel);
|
|
25931
|
+
},
|
|
25869
25932
|
clearFormDataModel() {
|
|
25870
25933
|
for (let pkey in this.formDataModel) {
|
|
25871
25934
|
delete this.formDataModel[pkey];
|
|
@@ -26212,7 +26275,7 @@ function _sfc_render$v(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
26212
26275
|
_: 3
|
|
26213
26276
|
}, 8, ["label-position", "size", "class", "label-width", "model"]);
|
|
26214
26277
|
}
|
|
26215
|
-
var VFormRender = /* @__PURE__ */ _export_sfc$1(_sfc_main$v, [["render", _sfc_render$v], ["__scopeId", "data-v-
|
|
26278
|
+
var VFormRender = /* @__PURE__ */ _export_sfc$1(_sfc_main$v, [["render", _sfc_render$v], ["__scopeId", "data-v-4626d18a"]]);
|
|
26216
26279
|
function registerIcon(app) {
|
|
26217
26280
|
app.component("el-icon-edit", edit);
|
|
26218
26281
|
app.component("el-icon-minus", minus);
|
|
@@ -26227,13 +26290,13 @@ function registerIcon(app) {
|
|
|
26227
26290
|
if (typeof window !== "undefined") {
|
|
26228
26291
|
let loadSvg = function() {
|
|
26229
26292
|
var body = document.body;
|
|
26230
|
-
var svgDom = document.getElementById("
|
|
26293
|
+
var svgDom = document.getElementById("__svg__icons__dom__1778740544035__");
|
|
26231
26294
|
if (!svgDom) {
|
|
26232
26295
|
svgDom = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
26233
26296
|
svgDom.style.position = "absolute";
|
|
26234
26297
|
svgDom.style.width = "0";
|
|
26235
26298
|
svgDom.style.height = "0";
|
|
26236
|
-
svgDom.id = "
|
|
26299
|
+
svgDom.id = "__svg__icons__dom__1778740544035__";
|
|
26237
26300
|
svgDom.setAttribute("xmlns", "http://www.w3.org/2000/svg");
|
|
26238
26301
|
svgDom.setAttribute("xmlns:link", "http://www.w3.org/1999/xlink");
|
|
26239
26302
|
}
|
|
@@ -61924,6 +61987,7 @@ const _sfc_main$6 = {
|
|
|
61924
61987
|
assetOwnerUnit: "",
|
|
61925
61988
|
labelName: ""
|
|
61926
61989
|
};
|
|
61990
|
+
this.searchValue = "";
|
|
61927
61991
|
this.$emit("close");
|
|
61928
61992
|
},
|
|
61929
61993
|
handleConfirm() {
|
|
@@ -61963,7 +62027,7 @@ const _sfc_main$6 = {
|
|
|
61963
62027
|
service$1({
|
|
61964
62028
|
method: "post",
|
|
61965
62029
|
url: "/asset-business/overview/pageList",
|
|
61966
|
-
data: __spreadProps(__spreadValues({ size: this.pageSize, current: this.currentPage, reqType: "disposal" }, this.form), { assetType: this.form.assetType === "all" ? "" : this.form.assetType })
|
|
62030
|
+
data: __spreadProps(__spreadValues({ size: this.pageSize, current: this.currentPage, reqType: "disposal" }, this.form), { assetType: this.form.assetType === "all" ? "" : this.form.assetType, systemStatusList: ["2"] })
|
|
61967
62031
|
}).then(({ data: data2 }) => {
|
|
61968
62032
|
const { records, total, current } = data2;
|
|
61969
62033
|
this.tableData = records.map((item) => {
|
|
@@ -62371,7 +62435,7 @@ function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
62371
62435
|
_: 1
|
|
62372
62436
|
}, 8, ["modelValue", "onClose"]);
|
|
62373
62437
|
}
|
|
62374
|
-
var AssetDialog = /* @__PURE__ */ _export_sfc$1(_sfc_main$6, [["render", _sfc_render$6], ["__scopeId", "data-v-
|
|
62438
|
+
var AssetDialog = /* @__PURE__ */ _export_sfc$1(_sfc_main$6, [["render", _sfc_render$6], ["__scopeId", "data-v-d9c3eebc"]]);
|
|
62375
62439
|
var index_vue_vue_type_style_index_0_lang$1 = "";
|
|
62376
62440
|
const _sfc_main$5 = {
|
|
62377
62441
|
name: "asset-select-widget",
|