form-custom-test 3.0.220 → 3.0.221
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 +20 -7
- package/dist/designer.style.css +1 -1
- package/dist/designer.umd.js +2 -2
- package/dist/render.es.js +20 -7
- package/dist/render.style.css +1 -1
- package/dist/render.umd.js +2 -2
- package/package.json +1 -1
package/dist/designer.es.js
CHANGED
|
@@ -69279,13 +69279,13 @@ function registerIcon(app) {
|
|
|
69279
69279
|
if (typeof window !== "undefined") {
|
|
69280
69280
|
let loadSvg = function() {
|
|
69281
69281
|
var body = document.body;
|
|
69282
|
-
var svgDom = document.getElementById("
|
|
69282
|
+
var svgDom = document.getElementById("__svg__icons__dom__1783062042423__");
|
|
69283
69283
|
if (!svgDom) {
|
|
69284
69284
|
svgDom = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
69285
69285
|
svgDom.style.position = "absolute";
|
|
69286
69286
|
svgDom.style.width = "0";
|
|
69287
69287
|
svgDom.style.height = "0";
|
|
69288
|
-
svgDom.id = "
|
|
69288
|
+
svgDom.id = "__svg__icons__dom__1783062042423__";
|
|
69289
69289
|
svgDom.setAttribute("xmlns", "http://www.w3.org/2000/svg");
|
|
69290
69290
|
svgDom.setAttribute("xmlns:link", "http://www.w3.org/1999/xlink");
|
|
69291
69291
|
}
|
|
@@ -80899,15 +80899,28 @@ const _sfc_main$b = {
|
|
|
80899
80899
|
getFormConfigCode(item) {
|
|
80900
80900
|
return (item == null ? void 0 : item.subCategoryCode) || (item == null ? void 0 : item.formCode) || this.documentTypeValue;
|
|
80901
80901
|
},
|
|
80902
|
+
buildReadonlyFormJson(formJson) {
|
|
80903
|
+
const json = lodash.exports.cloneDeep(formJson);
|
|
80904
|
+
if (json == null ? void 0 : json.widgetList) {
|
|
80905
|
+
traverseFieldWidgets(json.widgetList, (widget) => {
|
|
80906
|
+
if (widget == null ? void 0 : widget.options) {
|
|
80907
|
+
widget.options.disabled = true;
|
|
80908
|
+
widget.options.readonly = true;
|
|
80909
|
+
}
|
|
80910
|
+
});
|
|
80911
|
+
}
|
|
80912
|
+
return json;
|
|
80913
|
+
},
|
|
80902
80914
|
applyFormToRender(parsed, formData) {
|
|
80903
|
-
|
|
80915
|
+
const disabledJson = this.buildReadonlyFormJson(parsed);
|
|
80916
|
+
this.formJson = disabledJson;
|
|
80904
80917
|
this.showForm = true;
|
|
80905
80918
|
this.$nextTick(() => {
|
|
80906
80919
|
const ref2 = this.$refs.detailFormRender;
|
|
80907
80920
|
if (!ref2 || typeof ref2.setFormJson !== "function") {
|
|
80908
80921
|
return;
|
|
80909
80922
|
}
|
|
80910
|
-
ref2.setFormJson(lodash.exports.cloneDeep(
|
|
80923
|
+
ref2.setFormJson(lodash.exports.cloneDeep(disabledJson));
|
|
80911
80924
|
this.$nextTick(() => {
|
|
80912
80925
|
if (typeof ref2.setFormData === "function") {
|
|
80913
80926
|
ref2.setFormData(lodash.exports.cloneDeep(formData));
|
|
@@ -80924,7 +80937,7 @@ const _sfc_main$b = {
|
|
|
80924
80937
|
}
|
|
80925
80938
|
};
|
|
80926
80939
|
this.$nextTick(disable);
|
|
80927
|
-
setTimeout(disable,
|
|
80940
|
+
[300, 800, 1500].forEach((delay) => setTimeout(disable, delay));
|
|
80928
80941
|
},
|
|
80929
80942
|
async loadDocumentDetail(item) {
|
|
80930
80943
|
const formConfigCode = this.getFormConfigCode(item);
|
|
@@ -80970,7 +80983,7 @@ const _hoisted_1$9 = {
|
|
|
80970
80983
|
};
|
|
80971
80984
|
const _hoisted_2$7 = {
|
|
80972
80985
|
key: 1,
|
|
80973
|
-
class: "detail-form"
|
|
80986
|
+
class: "detail-form detail-form--readonly"
|
|
80974
80987
|
};
|
|
80975
80988
|
const _hoisted_3$5 = {
|
|
80976
80989
|
key: 2,
|
|
@@ -81034,7 +81047,7 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
81034
81047
|
_: 1
|
|
81035
81048
|
}, 8, ["modelValue", "onClose"]);
|
|
81036
81049
|
}
|
|
81037
|
-
var DocumentDetailDialog = /* @__PURE__ */ _export_sfc$1(_sfc_main$b, [["render", _sfc_render$b], ["__scopeId", "data-v-
|
|
81050
|
+
var DocumentDetailDialog = /* @__PURE__ */ _export_sfc$1(_sfc_main$b, [["render", _sfc_render$b], ["__scopeId", "data-v-ddc7afce"]]);
|
|
81038
81051
|
var index_vue_vue_type_style_index_0_lang$1 = "";
|
|
81039
81052
|
const _sfc_main$a = {
|
|
81040
81053
|
name: "document-select-widget",
|