form-custom-test 3.0.42 → 3.0.43
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 +184 -60
- package/dist/designer.style.css +1 -1
- package/dist/designer.umd.js +98 -98
- package/dist/render.es.js +129 -43
- package/dist/render.style.css +1 -1
- package/dist/render.umd.js +67 -67
- package/package.json +1 -1
package/dist/designer.es.js
CHANGED
|
@@ -4077,7 +4077,7 @@ const _hoisted_5$h = ["title", "onDblclick"];
|
|
|
4077
4077
|
const _hoisted_6$g = ["src"];
|
|
4078
4078
|
const _hoisted_7$d = ["src"];
|
|
4079
4079
|
const _hoisted_8$9 = { class: "bottom clear-fix" };
|
|
4080
|
-
const _hoisted_9$
|
|
4080
|
+
const _hoisted_9$7 = { class: "ft-title" };
|
|
4081
4081
|
function _sfc_render$3s(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4082
4082
|
const _component_svg_icon = resolveComponent("svg-icon");
|
|
4083
4083
|
const _component_draggable = resolveComponent("draggable");
|
|
@@ -4297,7 +4297,7 @@ function _sfc_render$3s(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
4297
4297
|
_: 2
|
|
4298
4298
|
}, 1024),
|
|
4299
4299
|
createElementVNode("div", _hoisted_8$9, [
|
|
4300
|
-
createElementVNode("span", _hoisted_9$
|
|
4300
|
+
createElementVNode("span", _hoisted_9$7, "#" + toDisplayString(idx + 1) + " " + toDisplayString(ft.title), 1),
|
|
4301
4301
|
createVNode(_component_el_button, {
|
|
4302
4302
|
link: "",
|
|
4303
4303
|
type: "primary",
|
|
@@ -10472,6 +10472,14 @@ var fieldMixin = {
|
|
|
10472
10472
|
getFormRef() {
|
|
10473
10473
|
return this.refList["v_form_ref"];
|
|
10474
10474
|
},
|
|
10475
|
+
findColByName(colName) {
|
|
10476
|
+
const formRef = this.getFormRef();
|
|
10477
|
+
return formRef && typeof formRef.findColByName === "function" ? formRef.findColByName(null, colName) : null;
|
|
10478
|
+
},
|
|
10479
|
+
setColHidden(colName, hidden) {
|
|
10480
|
+
const formRef = this.getFormRef();
|
|
10481
|
+
return formRef && typeof formRef.setColHidden === "function" ? formRef.setColHidden(colName, hidden) : false;
|
|
10482
|
+
},
|
|
10475
10483
|
getWidgetRef(widgetName, showError, rowId) {
|
|
10476
10484
|
let foundRef = null;
|
|
10477
10485
|
if (this.subFormItemFlag && !this.designState) {
|
|
@@ -10586,8 +10594,7 @@ var fieldMixin = {
|
|
|
10586
10594
|
this.field.options.optionItems = deepClone(options || []);
|
|
10587
10595
|
}
|
|
10588
10596
|
} else {
|
|
10589
|
-
this.field.options.optionItems = options;
|
|
10590
|
-
console.log(this.field, "this.field.options.optionItems");
|
|
10597
|
+
this.field.options.optionItems = deepClone(options || []);
|
|
10591
10598
|
}
|
|
10592
10599
|
this.clearSelectedOptions();
|
|
10593
10600
|
},
|
|
@@ -10875,7 +10882,7 @@ const _hoisted_7$b = {
|
|
|
10875
10882
|
class: "drag-handler background-opacity"
|
|
10876
10883
|
};
|
|
10877
10884
|
const _hoisted_8$7 = ["title"];
|
|
10878
|
-
const _hoisted_9$
|
|
10885
|
+
const _hoisted_9$6 = { key: 0 };
|
|
10879
10886
|
function _sfc_render$3o(_ctx, _cache, $props, $setup, $data, $options) {
|
|
10880
10887
|
const _component_svg_icon = resolveComponent("svg-icon");
|
|
10881
10888
|
const _component_el_tooltip = resolveComponent("el-tooltip");
|
|
@@ -10984,7 +10991,7 @@ function _sfc_render$3o(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
10984
10991
|
createVNode(_component_svg_icon, { "icon-class": "el-drag-move" })
|
|
10985
10992
|
], 8, _hoisted_8$7),
|
|
10986
10993
|
createElementVNode("i", null, toDisplayString(_ctx.i18n2t(`designer.widgetLabel.${$props.field.type}`, `extension.widgetLabel.${$props.field.type}`)), 1),
|
|
10987
|
-
$props.field.options.hidden === true ? (openBlock(), createElementBlock("i", _hoisted_9$
|
|
10994
|
+
$props.field.options.hidden === true ? (openBlock(), createElementBlock("i", _hoisted_9$6, [
|
|
10988
10995
|
createVNode(_component_svg_icon, { "icon-class": "el-hide" })
|
|
10989
10996
|
])) : createCommentVNode("", true)
|
|
10990
10997
|
])) : createCommentVNode("", true)
|
|
@@ -24893,7 +24900,6 @@ const _sfc_main$2Y = {
|
|
|
24893
24900
|
if (this.field.options.optionItems) {
|
|
24894
24901
|
return this.field.options.optionItems;
|
|
24895
24902
|
}
|
|
24896
|
-
console.log(this.field.options.optionItems);
|
|
24897
24903
|
return [];
|
|
24898
24904
|
}
|
|
24899
24905
|
}
|
|
@@ -24952,7 +24958,7 @@ function _sfc_render$2Y(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
24952
24958
|
_: 1
|
|
24953
24959
|
}, 8, ["designer", "field", "rules", "design-state", "parent-widget", "parent-list", "index-of-parent-list", "sub-form-row-index", "sub-form-col-index", "sub-form-row-id"]);
|
|
24954
24960
|
}
|
|
24955
|
-
var selectWidget = /* @__PURE__ */ _export_sfc$1(_sfc_main$2Y, [["render", _sfc_render$2Y], ["__scopeId", "data-v-
|
|
24961
|
+
var selectWidget = /* @__PURE__ */ _export_sfc$1(_sfc_main$2Y, [["render", _sfc_render$2Y], ["__scopeId", "data-v-70a357a0"]]);
|
|
24956
24962
|
var __glob_0_17$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
24957
24963
|
__proto__: null,
|
|
24958
24964
|
"default": selectWidget
|
|
@@ -25659,6 +25665,9 @@ const _sfc_main$2Q = {
|
|
|
25659
25665
|
formConfig() {
|
|
25660
25666
|
return this.getFormConfig();
|
|
25661
25667
|
},
|
|
25668
|
+
colVisible() {
|
|
25669
|
+
return !!(this.widget && this.widget.options && !this.widget.options.hidden);
|
|
25670
|
+
},
|
|
25662
25671
|
customClass() {
|
|
25663
25672
|
if (!this.widget || !this.widget.options) {
|
|
25664
25673
|
return "";
|
|
@@ -25673,7 +25682,20 @@ const _sfc_main$2Q = {
|
|
|
25673
25682
|
this.initLayoutProps();
|
|
25674
25683
|
this.initRefList();
|
|
25675
25684
|
},
|
|
25685
|
+
beforeUnmount() {
|
|
25686
|
+
var _a2, _b2;
|
|
25687
|
+
if (this.refList != null && ((_b2 = (_a2 = this.widget) == null ? void 0 : _a2.options) == null ? void 0 : _b2.name)) {
|
|
25688
|
+
delete this.refList[this.widget.options.name];
|
|
25689
|
+
}
|
|
25690
|
+
},
|
|
25691
|
+
watch: {},
|
|
25676
25692
|
methods: {
|
|
25693
|
+
setHidden(flag) {
|
|
25694
|
+
if (this.widget && this.widget.options) {
|
|
25695
|
+
this.widget.options.hidden = !!flag;
|
|
25696
|
+
this.$nextTick(() => this.$forceUpdate());
|
|
25697
|
+
}
|
|
25698
|
+
},
|
|
25677
25699
|
initLayoutProps() {
|
|
25678
25700
|
if (!this.widget || !this.widget.options) {
|
|
25679
25701
|
return;
|
|
@@ -25766,10 +25788,10 @@ function _sfc_render$2Q(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
25766
25788
|
]),
|
|
25767
25789
|
_: 3
|
|
25768
25790
|
}, 16, ["class", "style"])), [
|
|
25769
|
-
[vShow, $
|
|
25791
|
+
[vShow, $options.colVisible]
|
|
25770
25792
|
]) : createCommentVNode("", true);
|
|
25771
25793
|
}
|
|
25772
|
-
var GridColItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$2Q, [["render", _sfc_render$2Q], ["__scopeId", "data-v-
|
|
25794
|
+
var GridColItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$2Q, [["render", _sfc_render$2Q], ["__scopeId", "data-v-76952447"]]);
|
|
25773
25795
|
var __glob_0_1$2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
25774
25796
|
__proto__: null,
|
|
25775
25797
|
"default": GridColItem
|
|
@@ -25991,7 +26013,7 @@ function _sfc_render$2P(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
25991
26013
|
ref: $props.widget.id
|
|
25992
26014
|
}, {
|
|
25993
26015
|
default: withCtx(() => [
|
|
25994
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList($props.widget.cols || [], (colWidget, colIdx) => {
|
|
26016
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList($props.widget.cols.filter((item) => !item.options.hidden) || [], (colWidget, colIdx) => {
|
|
25995
26017
|
return openBlock(), createBlock(_component_grid_col_item, {
|
|
25996
26018
|
key: colIdx,
|
|
25997
26019
|
widget: colWidget,
|
|
@@ -27231,6 +27253,45 @@ const _sfc_main$2K = {
|
|
|
27231
27253
|
},
|
|
27232
27254
|
getGlobalDsv() {
|
|
27233
27255
|
return this.globalDsv;
|
|
27256
|
+
},
|
|
27257
|
+
findColByName(list, colName) {
|
|
27258
|
+
const listToSearch = list != null ? list : this.formJsonObj && this.formJsonObj.widgetList;
|
|
27259
|
+
if (!listToSearch || !colName)
|
|
27260
|
+
return null;
|
|
27261
|
+
for (const w of listToSearch) {
|
|
27262
|
+
if (w.type === "grid" && w.cols && w.cols.length) {
|
|
27263
|
+
const col = w.cols.find((c) => c.options && c.options.name === colName);
|
|
27264
|
+
if (col)
|
|
27265
|
+
return col;
|
|
27266
|
+
}
|
|
27267
|
+
if (w.type === "grid-col" && w.options && w.options.name === colName)
|
|
27268
|
+
return w;
|
|
27269
|
+
if (w.widgetList && w.widgetList.length) {
|
|
27270
|
+
const found = this.findColByName(w.widgetList, colName);
|
|
27271
|
+
if (found)
|
|
27272
|
+
return found;
|
|
27273
|
+
}
|
|
27274
|
+
if (w.cols && w.cols.length) {
|
|
27275
|
+
for (const c of w.cols) {
|
|
27276
|
+
if (c.options && c.options.name === colName)
|
|
27277
|
+
return c;
|
|
27278
|
+
if (c.widgetList && c.widgetList.length) {
|
|
27279
|
+
const found = this.findColByName(c.widgetList, colName);
|
|
27280
|
+
if (found)
|
|
27281
|
+
return found;
|
|
27282
|
+
}
|
|
27283
|
+
}
|
|
27284
|
+
}
|
|
27285
|
+
}
|
|
27286
|
+
return null;
|
|
27287
|
+
},
|
|
27288
|
+
setColHidden(colName, hidden) {
|
|
27289
|
+
const col = this.findColByName(null, colName);
|
|
27290
|
+
if (!col || !col.options)
|
|
27291
|
+
return false;
|
|
27292
|
+
col.options.hidden = !!hidden;
|
|
27293
|
+
this.$nextTick(() => this.$forceUpdate());
|
|
27294
|
+
return true;
|
|
27234
27295
|
}
|
|
27235
27296
|
}
|
|
27236
27297
|
};
|
|
@@ -27289,7 +27350,7 @@ function _sfc_render$2K(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
27289
27350
|
_: 3
|
|
27290
27351
|
}, 8, ["label-position", "size", "class", "label-width", "model"]);
|
|
27291
27352
|
}
|
|
27292
|
-
var VFormRender = /* @__PURE__ */ _export_sfc$1(_sfc_main$2K, [["render", _sfc_render$2K], ["__scopeId", "data-v-
|
|
27353
|
+
var VFormRender = /* @__PURE__ */ _export_sfc$1(_sfc_main$2K, [["render", _sfc_render$2K], ["__scopeId", "data-v-32478e29"]]);
|
|
27293
27354
|
var ace$2 = { exports: {} };
|
|
27294
27355
|
(function(module, exports) {
|
|
27295
27356
|
(function() {
|
|
@@ -53273,7 +53334,7 @@ const _hoisted_8$6 = {
|
|
|
53273
53334
|
key: 2,
|
|
53274
53335
|
class: ""
|
|
53275
53336
|
};
|
|
53276
|
-
const _hoisted_9$
|
|
53337
|
+
const _hoisted_9$5 = { class: "dialog-footer" };
|
|
53277
53338
|
const _hoisted_10$4 = {
|
|
53278
53339
|
key: 3,
|
|
53279
53340
|
class: ""
|
|
@@ -53283,8 +53344,8 @@ const _hoisted_12$2 = {
|
|
|
53283
53344
|
key: 4,
|
|
53284
53345
|
class: ""
|
|
53285
53346
|
};
|
|
53286
|
-
const _hoisted_13$
|
|
53287
|
-
const _hoisted_14$
|
|
53347
|
+
const _hoisted_13$2 = { style: { "border": "1px solid #DCDFE6" } };
|
|
53348
|
+
const _hoisted_14$2 = { class: "dialog-footer" };
|
|
53288
53349
|
const _hoisted_15$1 = {
|
|
53289
53350
|
key: 5,
|
|
53290
53351
|
class: ""
|
|
@@ -53634,7 +53695,7 @@ function _sfc_render$2I(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
53634
53695
|
"destroy-on-close": true
|
|
53635
53696
|
}, {
|
|
53636
53697
|
footer: withCtx(() => [
|
|
53637
|
-
createElementVNode("div", _hoisted_9$
|
|
53698
|
+
createElementVNode("div", _hoisted_9$5, [
|
|
53638
53699
|
createVNode(_component_el_button, {
|
|
53639
53700
|
type: "primary",
|
|
53640
53701
|
class: "copy-json-btn",
|
|
@@ -53796,7 +53857,7 @@ function _sfc_render$2I(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
53796
53857
|
"append-to-body": true
|
|
53797
53858
|
}, {
|
|
53798
53859
|
footer: withCtx(() => [
|
|
53799
|
-
createElementVNode("div", _hoisted_14$
|
|
53860
|
+
createElementVNode("div", _hoisted_14$2, [
|
|
53800
53861
|
createVNode(_component_el_button, {
|
|
53801
53862
|
type: "primary",
|
|
53802
53863
|
class: "copy-form-data-json-btn",
|
|
@@ -53825,7 +53886,7 @@ function _sfc_render$2I(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
53825
53886
|
])
|
|
53826
53887
|
]),
|
|
53827
53888
|
default: withCtx(() => [
|
|
53828
|
-
createElementVNode("div", _hoisted_13$
|
|
53889
|
+
createElementVNode("div", _hoisted_13$2, [
|
|
53829
53890
|
createVNode(_component_code_editor, {
|
|
53830
53891
|
mode: "json",
|
|
53831
53892
|
readonly: true,
|
|
@@ -55577,7 +55638,6 @@ const _sfc_main$27 = {
|
|
|
55577
55638
|
const records = (data2 == null ? void 0 : data2.records) || (data2 == null ? void 0 : data2.data) || data2 || [];
|
|
55578
55639
|
if (Array.isArray(records) && records.length > 0) {
|
|
55579
55640
|
const dictItems = records.filter((item) => item.dictType === dictCode);
|
|
55580
|
-
console.log(dictItems, "dictItems222222");
|
|
55581
55641
|
if (dictItems.length > 0) {
|
|
55582
55642
|
this.optionModel.optionItems = dictItems.map((item) => ({
|
|
55583
55643
|
id: generateId(),
|
|
@@ -55626,7 +55686,7 @@ const _hoisted_8$5 = {
|
|
|
55626
55686
|
key: 6,
|
|
55627
55687
|
style: { "margin-bottom": "10px" }
|
|
55628
55688
|
};
|
|
55629
|
-
const _hoisted_9$
|
|
55689
|
+
const _hoisted_9$4 = { key: 7 };
|
|
55630
55690
|
const _hoisted_10$3 = {
|
|
55631
55691
|
key: 8,
|
|
55632
55692
|
class: ""
|
|
@@ -55636,8 +55696,8 @@ const _hoisted_12$1 = {
|
|
|
55636
55696
|
key: 9,
|
|
55637
55697
|
class: ""
|
|
55638
55698
|
};
|
|
55639
|
-
const _hoisted_13 = { class: "dialog-footer" };
|
|
55640
|
-
const _hoisted_14 = {
|
|
55699
|
+
const _hoisted_13$1 = { class: "dialog-footer" };
|
|
55700
|
+
const _hoisted_14$1 = {
|
|
55641
55701
|
key: 10,
|
|
55642
55702
|
class: ""
|
|
55643
55703
|
};
|
|
@@ -55891,7 +55951,7 @@ function _sfc_render$27(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
55891
55951
|
_: 1
|
|
55892
55952
|
})
|
|
55893
55953
|
])) : createCommentVNode("", true),
|
|
55894
|
-
$props.selectedWidget.type === "radio" || $props.selectedWidget.type === "radio-other" || $props.selectedWidget.type === "checkbox" || $props.selectedWidget.type === "select" || $props.selectedWidget.type === "select-other" ? (openBlock(), createElementBlock("div", _hoisted_9$
|
|
55954
|
+
$props.selectedWidget.type === "radio" || $props.selectedWidget.type === "radio-other" || $props.selectedWidget.type === "checkbox" || $props.selectedWidget.type === "select" || $props.selectedWidget.type === "select-other" ? (openBlock(), createElementBlock("div", _hoisted_9$4, [
|
|
55895
55955
|
createVNode(_component_el_button, {
|
|
55896
55956
|
link: "",
|
|
55897
55957
|
type: "primary",
|
|
@@ -55989,7 +56049,7 @@ function _sfc_render$27(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
55989
56049
|
"destroy-on-close": true
|
|
55990
56050
|
}, {
|
|
55991
56051
|
footer: withCtx(() => [
|
|
55992
|
-
createElementVNode("div", _hoisted_13, [
|
|
56052
|
+
createElementVNode("div", _hoisted_13$1, [
|
|
55993
56053
|
createVNode(_component_el_button, {
|
|
55994
56054
|
size: "large",
|
|
55995
56055
|
type: "primary",
|
|
@@ -56024,7 +56084,7 @@ function _sfc_render$27(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
56024
56084
|
])), [
|
|
56025
56085
|
[_directive_drag, [".drag-dialog.el-dialog", ".drag-dialog .el-dialog__header"]]
|
|
56026
56086
|
]) : createCommentVNode("", true),
|
|
56027
|
-
$data.showImportTreeDialogFlag ? withDirectives((openBlock(), createElementBlock("div", _hoisted_14, [
|
|
56087
|
+
$data.showImportTreeDialogFlag ? withDirectives((openBlock(), createElementBlock("div", _hoisted_14$1, [
|
|
56028
56088
|
createVNode(_component_el_dialog, {
|
|
56029
56089
|
title: _ctx.i18nt("designer.setting.importOptions"),
|
|
56030
56090
|
modelValue: $data.showImportTreeDialogFlag,
|
|
@@ -56074,7 +56134,7 @@ function _sfc_render$27(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
56074
56134
|
]) : createCommentVNode("", true)
|
|
56075
56135
|
]);
|
|
56076
56136
|
}
|
|
56077
|
-
var OptionItemsSetting = /* @__PURE__ */ _export_sfc$1(_sfc_main$27, [["render", _sfc_render$27], ["__scopeId", "data-v-
|
|
56137
|
+
var OptionItemsSetting = /* @__PURE__ */ _export_sfc$1(_sfc_main$27, [["render", _sfc_render$27], ["__scopeId", "data-v-77962d50"]]);
|
|
56078
56138
|
const _sfc_main$26 = {
|
|
56079
56139
|
name: "optionItems-editor",
|
|
56080
56140
|
mixins: [i18n$1],
|
|
@@ -61679,7 +61739,7 @@ const _hoisted_5$7 = ["title"];
|
|
|
61679
61739
|
const _hoisted_6$7 = ["title"];
|
|
61680
61740
|
const _hoisted_7$5 = ["title"];
|
|
61681
61741
|
const _hoisted_8$4 = ["title"];
|
|
61682
|
-
const _hoisted_9$
|
|
61742
|
+
const _hoisted_9$3 = {
|
|
61683
61743
|
key: 1,
|
|
61684
61744
|
class: "drag-handler"
|
|
61685
61745
|
};
|
|
@@ -61740,7 +61800,7 @@ function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
61740
61800
|
createVNode(_component_svg_icon, { "icon-class": "el-delete" })
|
|
61741
61801
|
], 8, _hoisted_8$4)
|
|
61742
61802
|
])) : createCommentVNode("", true),
|
|
61743
|
-
$props.designer.selectedId === $props.widget.id && !$props.widget.internal ? (openBlock(), createElementBlock("div", _hoisted_9$
|
|
61803
|
+
$props.designer.selectedId === $props.widget.id && !$props.widget.internal ? (openBlock(), createElementBlock("div", _hoisted_9$3, [
|
|
61744
61804
|
createElementVNode("i", {
|
|
61745
61805
|
title: _ctx.i18nt("designer.hint.dragHandler")
|
|
61746
61806
|
}, [
|
|
@@ -61828,6 +61888,11 @@ const _sfc_main$n = {
|
|
|
61828
61888
|
}
|
|
61829
61889
|
},
|
|
61830
61890
|
watch: {
|
|
61891
|
+
"widget.options.name": {
|
|
61892
|
+
handler(newVal, oldVal) {
|
|
61893
|
+
this.registerToRefList(oldVal);
|
|
61894
|
+
}
|
|
61895
|
+
},
|
|
61831
61896
|
"designer.formConfig.layoutType": {
|
|
61832
61897
|
handler(val) {
|
|
61833
61898
|
if (!!this.widget.options.responsive) {
|
|
@@ -61899,7 +61964,17 @@ const _sfc_main$n = {
|
|
|
61899
61964
|
this.initRefList();
|
|
61900
61965
|
this.initLayoutProps();
|
|
61901
61966
|
},
|
|
61967
|
+
beforeUnmount() {
|
|
61968
|
+
var _a2, _b2;
|
|
61969
|
+
if (this.refList != null && ((_b2 = (_a2 = this.widget) == null ? void 0 : _a2.options) == null ? void 0 : _b2.name)) {
|
|
61970
|
+
delete this.refList[this.widget.options.name];
|
|
61971
|
+
}
|
|
61972
|
+
},
|
|
61902
61973
|
methods: {
|
|
61974
|
+
setHidden(flag) {
|
|
61975
|
+
this.widget.options.hidden = !!flag;
|
|
61976
|
+
this.$nextTick(() => this.$forceUpdate());
|
|
61977
|
+
},
|
|
61903
61978
|
initLayoutProps() {
|
|
61904
61979
|
if (!!this.widget.options.responsive) {
|
|
61905
61980
|
let lyType = this.designer.formConfig.layoutType;
|
|
@@ -61984,11 +62059,15 @@ const _hoisted_8$3 = {
|
|
|
61984
62059
|
key: 1,
|
|
61985
62060
|
class: "grid-col-handler"
|
|
61986
62061
|
};
|
|
62062
|
+
const _hoisted_9$2 = {
|
|
62063
|
+
key: 0,
|
|
62064
|
+
class: "col-hidden-tag"
|
|
62065
|
+
};
|
|
61987
62066
|
function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
|
|
61988
62067
|
const _component_draggable = resolveComponent("draggable");
|
|
61989
62068
|
const _component_svg_icon = resolveComponent("svg-icon");
|
|
61990
62069
|
const _component_el_col = resolveComponent("el-col");
|
|
61991
|
-
return $props.widget.type === "grid-col" ? (openBlock(), createBlock(_component_el_col, mergeProps({
|
|
62070
|
+
return $props.widget.type === "grid-col" && (!$props.widget.options.hidden || $props.designer) ? (openBlock(), createBlock(_component_el_col, mergeProps({
|
|
61992
62071
|
key: 0,
|
|
61993
62072
|
class: "grid-cell"
|
|
61994
62073
|
}, $data.layoutProps, {
|
|
@@ -62071,13 +62150,16 @@ function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
62071
62150
|
], 8, _hoisted_7$4)
|
|
62072
62151
|
])) : createCommentVNode("", true),
|
|
62073
62152
|
$props.designer.selectedId === $props.widget.id && $props.widget.type === "grid-col" ? (openBlock(), createElementBlock("div", _hoisted_8$3, [
|
|
62074
|
-
createElementVNode("i", null, toDisplayString(_ctx.i18nt("designer.widgetLabel." + $props.widget.type)), 1)
|
|
62153
|
+
createElementVNode("i", null, toDisplayString(_ctx.i18nt("designer.widgetLabel." + $props.widget.type)), 1),
|
|
62154
|
+
$props.widget.options.hidden === true ? (openBlock(), createElementBlock("i", _hoisted_9$2, [
|
|
62155
|
+
createVNode(_component_svg_icon, { "icon-class": "el-hide" })
|
|
62156
|
+
])) : createCommentVNode("", true)
|
|
62075
62157
|
])) : createCommentVNode("", true)
|
|
62076
62158
|
]),
|
|
62077
62159
|
_: 1
|
|
62078
62160
|
}, 16, ["class", "style"])) : createCommentVNode("", true);
|
|
62079
62161
|
}
|
|
62080
|
-
var GridColWidget = /* @__PURE__ */ _export_sfc$1(_sfc_main$n, [["render", _sfc_render$n], ["__scopeId", "data-v-
|
|
62162
|
+
var GridColWidget = /* @__PURE__ */ _export_sfc$1(_sfc_main$n, [["render", _sfc_render$n], ["__scopeId", "data-v-cb053c20"]]);
|
|
62081
62163
|
var __glob_0_1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
62082
62164
|
__proto__: null,
|
|
62083
62165
|
"default": GridColWidget
|
|
@@ -63452,6 +63534,45 @@ function createDesigner(vueInstance) {
|
|
|
63452
63534
|
}
|
|
63453
63535
|
return Object.keys(originalWidget.options).indexOf(configName) > -1;
|
|
63454
63536
|
},
|
|
63537
|
+
findColByName(list, colName) {
|
|
63538
|
+
const listToSearch = list != null ? list : this.widgetList;
|
|
63539
|
+
if (!listToSearch || !colName)
|
|
63540
|
+
return null;
|
|
63541
|
+
for (const w of listToSearch) {
|
|
63542
|
+
if (w.type === "grid" && w.cols && w.cols.length) {
|
|
63543
|
+
const col = w.cols.find((c) => c.options && c.options.name === colName);
|
|
63544
|
+
if (col)
|
|
63545
|
+
return col;
|
|
63546
|
+
}
|
|
63547
|
+
if (w.type === "grid-col" && w.options && w.options.name === colName)
|
|
63548
|
+
return w;
|
|
63549
|
+
if (w.widgetList && w.widgetList.length) {
|
|
63550
|
+
const found = this.findColByName(w.widgetList, colName);
|
|
63551
|
+
if (found)
|
|
63552
|
+
return found;
|
|
63553
|
+
}
|
|
63554
|
+
if (w.cols && w.cols.length) {
|
|
63555
|
+
for (const c of w.cols) {
|
|
63556
|
+
if (c.options && c.options.name === colName)
|
|
63557
|
+
return c;
|
|
63558
|
+
if (c.widgetList && c.widgetList.length) {
|
|
63559
|
+
const found = this.findColByName(c.widgetList, colName);
|
|
63560
|
+
if (found)
|
|
63561
|
+
return found;
|
|
63562
|
+
}
|
|
63563
|
+
}
|
|
63564
|
+
}
|
|
63565
|
+
}
|
|
63566
|
+
return null;
|
|
63567
|
+
},
|
|
63568
|
+
setColHidden(colName, hidden) {
|
|
63569
|
+
const col = this.findColByName(null, colName);
|
|
63570
|
+
if (!col || !col.options)
|
|
63571
|
+
return false;
|
|
63572
|
+
col.options.hidden = !!hidden;
|
|
63573
|
+
this.saveCurrentHistoryStep();
|
|
63574
|
+
return true;
|
|
63575
|
+
},
|
|
63455
63576
|
upgradeWidgetConfig(oldWidget) {
|
|
63456
63577
|
let newWidget = null;
|
|
63457
63578
|
if (!!oldWidget.category) {
|
|
@@ -64048,7 +64169,7 @@ function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
64048
64169
|
_: 3
|
|
64049
64170
|
});
|
|
64050
64171
|
}
|
|
64051
|
-
var VFormDesigner = /* @__PURE__ */ _export_sfc$1(_sfc_main$h, [["render", _sfc_render$h], ["__scopeId", "data-v-
|
|
64172
|
+
var VFormDesigner = /* @__PURE__ */ _export_sfc$1(_sfc_main$h, [["render", _sfc_render$h], ["__scopeId", "data-v-cd16a5dc"]]);
|
|
64052
64173
|
var vuedraggable_umd = { exports: {} };
|
|
64053
64174
|
var require$$0 = /* @__PURE__ */ getDefaultExportFromNamespaceIfPresent(vue);
|
|
64054
64175
|
(function(module, exports) {
|
|
@@ -67634,13 +67755,13 @@ function registerIcon(app) {
|
|
|
67634
67755
|
if (typeof window !== "undefined") {
|
|
67635
67756
|
let loadSvg = function() {
|
|
67636
67757
|
var body = document.body;
|
|
67637
|
-
var svgDom = document.getElementById("
|
|
67758
|
+
var svgDom = document.getElementById("__svg__icons__dom__1772271186397__");
|
|
67638
67759
|
if (!svgDom) {
|
|
67639
67760
|
svgDom = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
67640
67761
|
svgDom.style.position = "absolute";
|
|
67641
67762
|
svgDom.style.width = "0";
|
|
67642
67763
|
svgDom.style.height = "0";
|
|
67643
|
-
svgDom.id = "
|
|
67764
|
+
svgDom.id = "__svg__icons__dom__1772271186397__";
|
|
67644
67765
|
svgDom.setAttribute("xmlns", "http://www.w3.org/2000/svg");
|
|
67645
67766
|
svgDom.setAttribute("xmlns:link", "http://www.w3.org/1999/xlink");
|
|
67646
67767
|
}
|
|
@@ -74805,6 +74926,7 @@ const _sfc_main$8 = {
|
|
|
74805
74926
|
fieldSchemas.push(this.cloneFieldSchema(swItem));
|
|
74806
74927
|
});
|
|
74807
74928
|
if (rowIndex === void 0) {
|
|
74929
|
+
console.log(fieldSchemas, "fieldSchemas");
|
|
74808
74930
|
this.fieldSchemaData.push(fieldSchemas);
|
|
74809
74931
|
} else {
|
|
74810
74932
|
this.fieldSchemaData.splice(rowIndex, 0, fieldSchemas);
|
|
@@ -74983,34 +75105,36 @@ const _sfc_main$8 = {
|
|
|
74983
75105
|
}
|
|
74984
75106
|
}
|
|
74985
75107
|
};
|
|
74986
|
-
const _hoisted_1$7 = { class: "
|
|
74987
|
-
const _hoisted_2$5 = { class: "
|
|
74988
|
-
const _hoisted_3$5 = {
|
|
75108
|
+
const _hoisted_1$7 = { class: "sub-form-header" };
|
|
75109
|
+
const _hoisted_2$5 = { class: "sub-form-label" };
|
|
75110
|
+
const _hoisted_3$5 = { class: "group-header" };
|
|
75111
|
+
const _hoisted_4$4 = { class: "group-title" };
|
|
75112
|
+
const _hoisted_5$2 = {
|
|
74989
75113
|
key: 0,
|
|
74990
75114
|
class: "row-number-span"
|
|
74991
75115
|
};
|
|
74992
|
-
const
|
|
75116
|
+
const _hoisted_6$2 = {
|
|
74993
75117
|
key: 1,
|
|
74994
75118
|
class: "row-number-span"
|
|
74995
75119
|
};
|
|
74996
|
-
const
|
|
74997
|
-
const
|
|
74998
|
-
const
|
|
75120
|
+
const _hoisted_7$1 = { class: "group-actions" };
|
|
75121
|
+
const _hoisted_8$1 = { class: "group-content" };
|
|
75122
|
+
const _hoisted_9 = {
|
|
74999
75123
|
key: 1,
|
|
75000
75124
|
class: "field-loading",
|
|
75001
75125
|
style: { "color": "#909399", "font-size": "12px", "padding": "8px" }
|
|
75002
75126
|
};
|
|
75003
|
-
const
|
|
75127
|
+
const _hoisted_10 = {
|
|
75004
75128
|
key: 1,
|
|
75005
75129
|
class: "empty-hint"
|
|
75006
75130
|
};
|
|
75007
|
-
const
|
|
75008
|
-
const
|
|
75009
|
-
const
|
|
75131
|
+
const _hoisted_11 = { key: 0 };
|
|
75132
|
+
const _hoisted_12 = { key: 1 };
|
|
75133
|
+
const _hoisted_13 = {
|
|
75010
75134
|
key: 0,
|
|
75011
75135
|
class: "empty-hint"
|
|
75012
75136
|
};
|
|
75013
|
-
const
|
|
75137
|
+
const _hoisted_14 = {
|
|
75014
75138
|
key: 1,
|
|
75015
75139
|
class: "empty-hint"
|
|
75016
75140
|
};
|
|
@@ -75024,16 +75148,19 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
75024
75148
|
key: $props.widget.id,
|
|
75025
75149
|
class: normalizeClass(["custom-sub-form-container", $options.customClass])
|
|
75026
75150
|
}, [
|
|
75151
|
+
createElementVNode("div", _hoisted_1$7, [
|
|
75152
|
+
createElementVNode("span", _hoisted_2$5, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355"), 1)
|
|
75153
|
+
]),
|
|
75027
75154
|
(openBlock(true), createElementBlock(Fragment, null, renderList($data.rowIdData, (subFormRowId, sfrIdx) => {
|
|
75028
75155
|
return openBlock(), createElementBlock("div", {
|
|
75029
75156
|
class: "form-group-row",
|
|
75030
75157
|
key: subFormRowId
|
|
75031
75158
|
}, [
|
|
75032
|
-
createElementVNode("div",
|
|
75033
|
-
createElementVNode("div",
|
|
75034
|
-
$props.widget.options.showRowNumber ? (openBlock(), createElementBlock("span",
|
|
75159
|
+
createElementVNode("div", _hoisted_3$5, [
|
|
75160
|
+
createElementVNode("div", _hoisted_4$4, [
|
|
75161
|
+
$props.widget.options.showRowNumber ? (openBlock(), createElementBlock("span", _hoisted_5$2, toDisplayString($props.widget.options.label || "\u81EA\u5B9A\u4E49\u5B50\u8868\u5355") + " " + toDisplayString(sfrIdx + 1), 1)) : (openBlock(), createElementBlock("span", _hoisted_6$2, "\u8868\u5355\u7EC4"))
|
|
75035
75162
|
]),
|
|
75036
|
-
createElementVNode("div",
|
|
75163
|
+
createElementVNode("div", _hoisted_7$1, [
|
|
75037
75164
|
sfrIdx > 0 ? (openBlock(), createBlock(_component_el_button, {
|
|
75038
75165
|
key: 0,
|
|
75039
75166
|
size: "small",
|
|
@@ -75049,7 +75176,7 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
75049
75176
|
}, 8, ["onClick"])) : createCommentVNode("", true)
|
|
75050
75177
|
])
|
|
75051
75178
|
]),
|
|
75052
|
-
createElementVNode("div",
|
|
75179
|
+
createElementVNode("div", _hoisted_8$1, [
|
|
75053
75180
|
$props.widget && $props.widget.widgetList && $props.widget.widgetList.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList($props.widget.widgetList, (subWidget, swIdx) => {
|
|
75054
75181
|
return openBlock(), createElementBlock(Fragment, {
|
|
75055
75182
|
key: subWidget ? subWidget.id + "gc" + subFormRowId + "-" + swIdx : "gc" + subFormRowId + "-" + swIdx
|
|
@@ -75074,16 +75201,16 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
75074
75201
|
"sub-form-row-id": subFormRowId,
|
|
75075
75202
|
"sub-form-row-index": sfrIdx,
|
|
75076
75203
|
"sub-form-col-index": swIdx
|
|
75077
|
-
}, null, 8, ["field", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index"])) : (openBlock(), createElementBlock("div",
|
|
75204
|
+
}, null, 8, ["field", "parent-list", "index-of-parent-list", "parent-widget", "sub-form-row-id", "sub-form-row-index", "sub-form-col-index"])) : (openBlock(), createElementBlock("div", _hoisted_9, " \u5B57\u6BB5\u52A0\u8F7D\u4E2D... "))
|
|
75078
75205
|
], 64)) : createCommentVNode("", true)
|
|
75079
75206
|
], 64);
|
|
75080
|
-
}), 128)) : (openBlock(), createElementBlock("div",
|
|
75081
|
-
!$props.widget ? (openBlock(), createElementBlock("div",
|
|
75207
|
+
}), 128)) : (openBlock(), createElementBlock("div", _hoisted_10, [
|
|
75208
|
+
!$props.widget ? (openBlock(), createElementBlock("div", _hoisted_11, "\u7EC4\u4EF6\u672A\u521D\u59CB\u5316")) : !$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_12, " \u8BF7\u5148\u5728\u8BBE\u8BA1\u5668\u4E2D\u62D6\u62FD\u7EC4\u4EF6\u5230\u5B50\u8868\u5355\u4E2D ")) : createCommentVNode("", true)
|
|
75082
75209
|
]))
|
|
75083
75210
|
])
|
|
75084
75211
|
]);
|
|
75085
75212
|
}), 128)),
|
|
75086
|
-
!$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div",
|
|
75213
|
+
!$props.widget.widgetList || $props.widget.widgetList.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_13, " \u8BF7\u5148\u5728\u8BBE\u8BA1\u5668\u4E2D\u62D6\u62FD\u7EC4\u4EF6\u5230\u5B50\u8868\u5355\u4E2D ")) : $data.rowIdData.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_14, ' \u70B9\u51FB"\u6DFB\u52A0"\u6309\u94AE\u6DFB\u52A0\u6570\u636E\u884C ')) : createCommentVNode("", true),
|
|
75087
75214
|
createVNode(_component_el_button, {
|
|
75088
75215
|
disabled: $data.actionDisabled,
|
|
75089
75216
|
type: "primary",
|
|
@@ -75104,7 +75231,7 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
75104
75231
|
_: 1
|
|
75105
75232
|
}, 8, ["widget"]);
|
|
75106
75233
|
}
|
|
75107
|
-
var CustomSubFormItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$8, [["render", _sfc_render$8], ["__scopeId", "data-v-
|
|
75234
|
+
var CustomSubFormItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$8, [["render", _sfc_render$8], ["__scopeId", "data-v-489afa42"]]);
|
|
75108
75235
|
const customTableCellSchema = {
|
|
75109
75236
|
type: "custom-table-cell",
|
|
75110
75237
|
category: "container",
|
|
@@ -76823,7 +76950,6 @@ const _sfc_main$1 = {
|
|
|
76823
76950
|
let dictManager = null;
|
|
76824
76951
|
if (typeof window !== "undefined" && window.getDictData) {
|
|
76825
76952
|
const dictItems = window.getDictData(dictCode);
|
|
76826
|
-
console.log(dictItems, "dictItems");
|
|
76827
76953
|
if (dictItems && Array.isArray(dictItems) && dictItems.length > 0) {
|
|
76828
76954
|
col.options = dictItems.map((item) => ({
|
|
76829
76955
|
label: item.dictLabel || item.label || item.name || item.text || "",
|
|
@@ -76839,7 +76965,6 @@ const _sfc_main$1 = {
|
|
|
76839
76965
|
}
|
|
76840
76966
|
if (typeof window !== "undefined" && window.dictCache && window.dictCache[dictCode]) {
|
|
76841
76967
|
const dictItems = window.dictCache[dictCode];
|
|
76842
|
-
console.log(dictItems, "dictItems");
|
|
76843
76968
|
if (Array.isArray(dictItems) && dictItems.length > 0) {
|
|
76844
76969
|
col.options = dictItems.map((item) => ({
|
|
76845
76970
|
label: item.dictLabel || item.label || item.name || item.text || "",
|
|
@@ -76854,7 +76979,6 @@ const _sfc_main$1 = {
|
|
|
76854
76979
|
}
|
|
76855
76980
|
}
|
|
76856
76981
|
if (typeof window !== "undefined" && window.service) {
|
|
76857
|
-
console.log(window.service, "window.service");
|
|
76858
76982
|
window.service.post("/unified-dict/sysItemDict/page", {
|
|
76859
76983
|
current: 1,
|
|
76860
76984
|
size: 1e4,
|
|
@@ -77361,7 +77485,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
77361
77485
|
}, 8, ["modelValue", "title"])
|
|
77362
77486
|
], 64);
|
|
77363
77487
|
}
|
|
77364
|
-
var SubTableColumnsEditor = /* @__PURE__ */ _export_sfc$1(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-
|
|
77488
|
+
var SubTableColumnsEditor = /* @__PURE__ */ _export_sfc$1(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-514d67ae"]]);
|
|
77365
77489
|
const _sfc_main = {
|
|
77366
77490
|
name: "current-user-widget",
|
|
77367
77491
|
componentName: "FieldWidget",
|