slw 0.5.962 → 0.5.964
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/lib/index.js +665 -343
- package/lib/index.umd.cjs +4 -4
- package/lib/style.css +1 -1
- package/package.json +1 -1
package/lib/index.js
CHANGED
|
@@ -8281,12 +8281,12 @@ assign$1(XEUtils, {
|
|
|
8281
8281
|
cookie
|
|
8282
8282
|
});
|
|
8283
8283
|
var xeUtils = XEUtils;
|
|
8284
|
-
const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils),
|
|
8284
|
+
const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_vue_vue_type_style_index_0_scoped_3c299fd2_lang = "", _export_sfc = (Q, H) => {
|
|
8285
8285
|
const G = Q.__vccOpts || Q;
|
|
8286
8286
|
for (const [X, Z] of H)
|
|
8287
8287
|
G[X] = Z;
|
|
8288
8288
|
return G;
|
|
8289
|
-
}, _withScopeId$2 = (Q) => (pushScopeId("data-v-
|
|
8289
|
+
}, _withScopeId$2 = (Q) => (pushScopeId("data-v-3c299fd2"), Q = Q(), popScopeId(), Q), _hoisted_1$kW = {
|
|
8290
8290
|
class: "slw-window-grid-container",
|
|
8291
8291
|
style: { height: "100%" }
|
|
8292
8292
|
}, _hoisted_2$kS = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("span", { class: "vxe-table--cell-main-area" }, null, -1)), _hoisted_3$hT = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("span", { class: "vxe-table--cell-active-area" }, null, -1)), _hoisted_4$au = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("span", { class: "vxe-table--cell-copy-area" }, null, -1)), _hoisted_5$4U = [
|
|
@@ -8367,8 +8367,13 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8367
8367
|
let result = !1;
|
|
8368
8368
|
try {
|
|
8369
8369
|
for (const Q in data)
|
|
8370
|
-
displayStr = displayStr.replace(
|
|
8371
|
-
|
|
8370
|
+
displayStr = displayStr.replace(
|
|
8371
|
+
new RegExp("@" + Q + "@", "gi"),
|
|
8372
|
+
typeof data[Q] == "string" ? "'" + data[Q] + "'" : data[Q]
|
|
8373
|
+
);
|
|
8374
|
+
result = eval(
|
|
8375
|
+
displayStr.replaceAll("this.$data.", "").replaceAll("this.", "")
|
|
8376
|
+
);
|
|
8372
8377
|
} catch (Q) {
|
|
8373
8378
|
result = !1;
|
|
8374
8379
|
}
|
|
@@ -8416,7 +8421,10 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8416
8421
|
if (K != null && K.clearGrid) {
|
|
8417
8422
|
for (let le in Z)
|
|
8418
8423
|
Z[le] = null;
|
|
8419
|
-
return localStorage.setItem(
|
|
8424
|
+
return localStorage.setItem(
|
|
8425
|
+
gridData.value.params._region_id + preTag.value,
|
|
8426
|
+
JSON.stringify(Z)
|
|
8427
|
+
), {
|
|
8420
8428
|
data: {
|
|
8421
8429
|
data: [],
|
|
8422
8430
|
count: 0
|
|
@@ -8440,8 +8448,14 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8440
8448
|
}), Q ? Object.keys(Q).forEach((ae) => {
|
|
8441
8449
|
const le = ae.toLowerCase();
|
|
8442
8450
|
ne.hasOwnProperty(le) && (ne[le] = Q[ae]);
|
|
8443
|
-
}) : localStorage.setItem(
|
|
8444
|
-
|
|
8451
|
+
}) : localStorage.setItem(
|
|
8452
|
+
gridData.value.params._region_id + preTag.value,
|
|
8453
|
+
JSON.stringify(Z)
|
|
8454
|
+
);
|
|
8455
|
+
const oe = axios.post(
|
|
8456
|
+
"/window/data/" + gridData.value.params.datasourceCode,
|
|
8457
|
+
ne
|
|
8458
|
+
);
|
|
8445
8459
|
return oe.then((ae) => {
|
|
8446
8460
|
let le = {};
|
|
8447
8461
|
if (ae && ae.data && ae.data.result && ae.data.data && ae.data.data.length > 0) {
|
|
@@ -8451,7 +8465,10 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8451
8465
|
gridData.value.toolbarConfig.buttons.forEach((fe) => {
|
|
8452
8466
|
if (typeof fe.type < "u") {
|
|
8453
8467
|
fe.btnLoad[ue] = !1;
|
|
8454
|
-
const me = fe.displayLogic ? displayLogic(fe.displayLogic, {
|
|
8468
|
+
const me = fe.displayLogic ? displayLogic(fe.displayLogic, {
|
|
8469
|
+
...he,
|
|
8470
|
+
...assembleParentData(gridData.value.params.parentData)
|
|
8471
|
+
}) : !0, ve = fe.showInGrid && me, ge = !fe.showInGrid && me;
|
|
8455
8472
|
if (fe.btnShowInGrid[ue] = ve, fe.btnShow[ue] = ge, se = se || ve, ve) {
|
|
8456
8473
|
pe++;
|
|
8457
8474
|
let _e = fe.name.match(/[\u4e00-\u9fa5]/g);
|
|
@@ -8491,7 +8508,10 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8491
8508
|
hasData: !(typeof Q > "u" || Object.keys(Q).length === 0),
|
|
8492
8509
|
...Q
|
|
8493
8510
|
}, X = Object.assign({}, G);
|
|
8494
|
-
delete X._region_id, gridData.value.params.parentData = getParentData(), emitButtonDisplayLogic(
|
|
8511
|
+
delete X._region_id, gridData.value.params.parentData = getParentData(), emitButtonDisplayLogic(
|
|
8512
|
+
{ ...Q, ...assembleParentData(gridData.value.params.parentData) },
|
|
8513
|
+
H
|
|
8514
|
+
), rowIndex.value = H, G.hasData && (evalEvent(gridData.value.params.formEvents.rowClickFunction, Q), getCurRegion().setCurrentRow(Q)), callGridClickEvents(X, gridData.value.params._region_id);
|
|
8495
8515
|
}, emitButtonDisplayLogic = (Q, H) => {
|
|
8496
8516
|
gridData.value.toolbarConfig.buttons.forEach((G) => {
|
|
8497
8517
|
G.displayLogic && (G.showInGrid || (G.visible = displayLogic(G.displayLogic, Q)), G.btnShowInGrid[H] = G.showInGrid && displayLogic(G.displayLogic, Q), G.btnShow[H] = !G.showInGrid && G.showInGrid);
|
|
@@ -8511,7 +8531,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8511
8531
|
let X;
|
|
8512
8532
|
if (typeof H > "u" && Q.type !== "EXPORT" && (H = getSelectRecord() || getCheckedData(), X = getCheckedData(), gridData.value.type !== "EDIT_GRID" && Q.type !== "NEW" && Q.type !== "IMPORT" && Q.code.toUpperCase() !== "ROLLBACK" && Q.type !== "EVENT")) {
|
|
8513
8533
|
if (!H || H.length === 0) {
|
|
8514
|
-
$vxeMessage({
|
|
8534
|
+
$vxeMessage({
|
|
8535
|
+
content: $T("请选择数据!"),
|
|
8536
|
+
status: "info",
|
|
8537
|
+
zIndex: 3e3
|
|
8538
|
+
});
|
|
8515
8539
|
return;
|
|
8516
8540
|
}
|
|
8517
8541
|
H.length > 0 && (H = H[0]);
|
|
@@ -8605,7 +8629,13 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8605
8629
|
showStatus: !1
|
|
8606
8630
|
},
|
|
8607
8631
|
showOverflow: !0,
|
|
8608
|
-
rowConfig: {
|
|
8632
|
+
rowConfig: {
|
|
8633
|
+
useKey: !0,
|
|
8634
|
+
keyField: "id",
|
|
8635
|
+
isCurrent: !1,
|
|
8636
|
+
height: 35,
|
|
8637
|
+
isHover: !0
|
|
8638
|
+
},
|
|
8609
8639
|
type: "EDIT_GRID",
|
|
8610
8640
|
addListener: !0
|
|
8611
8641
|
}
|
|
@@ -8622,7 +8652,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8622
8652
|
const oe = await ne.validate(re).catch((ae) => ae);
|
|
8623
8653
|
} else {
|
|
8624
8654
|
if (gridData.value.params.parentRowId && !gridData.value.params.parentRowIdValue) {
|
|
8625
|
-
$vxeMessage({
|
|
8655
|
+
$vxeMessage({
|
|
8656
|
+
content: $T("请选创建父窗口数据!"),
|
|
8657
|
+
status: "info",
|
|
8658
|
+
zIndex: 3e3
|
|
8659
|
+
});
|
|
8626
8660
|
return;
|
|
8627
8661
|
}
|
|
8628
8662
|
let ne = Object.assign({}, gridData.value);
|
|
@@ -8644,9 +8678,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8644
8678
|
break;
|
|
8645
8679
|
case "DELETE":
|
|
8646
8680
|
if (gridData.value.type === "EDIT_GRID")
|
|
8647
|
-
$vxeConfirm($T("你确定删除?"), void 0, { zIndex: 3e3 }).then(
|
|
8648
|
-
ne
|
|
8649
|
-
|
|
8681
|
+
$vxeConfirm($T("你确定删除?"), void 0, { zIndex: 3e3 }).then(
|
|
8682
|
+
(ne) => {
|
|
8683
|
+
ne === "confirm" && (Q.showInGrid ? getGrid().remove(H) : getGrid().removeCheckboxRow());
|
|
8684
|
+
}
|
|
8685
|
+
);
|
|
8650
8686
|
else {
|
|
8651
8687
|
let ne = H[gridData.value.rowId];
|
|
8652
8688
|
const re = getCheckedData();
|
|
@@ -8657,17 +8693,34 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8657
8693
|
_button_id: gridData.value.params.delete_button_id
|
|
8658
8694
|
};
|
|
8659
8695
|
let ae = "/window/delete";
|
|
8660
|
-
Q.requestPath && (ae = Q.requestPath), $vxeConfirm($T("你确定删除?"), void 0, { zIndex: 3e3 }).then(
|
|
8661
|
-
le
|
|
8662
|
-
|
|
8663
|
-
|
|
8664
|
-
|
|
8665
|
-
|
|
8666
|
-
|
|
8696
|
+
Q.requestPath && (ae = Q.requestPath), $vxeConfirm($T("你确定删除?"), void 0, { zIndex: 3e3 }).then(
|
|
8697
|
+
(le) => {
|
|
8698
|
+
le === "confirm" && axios.post(ae, oe).then((se) => {
|
|
8699
|
+
se.status === 200 && se.data.result ? (reload(), $vxeMessage({
|
|
8700
|
+
content: se.data.msg,
|
|
8701
|
+
status: "info",
|
|
8702
|
+
zIndex: 3e3
|
|
8703
|
+
})) : $vxeMessage({
|
|
8704
|
+
content: se.data.msg,
|
|
8705
|
+
status: "error",
|
|
8706
|
+
zIndex: 3e3
|
|
8707
|
+
});
|
|
8708
|
+
}).catch((se) => {
|
|
8709
|
+
$vxeMessage({
|
|
8710
|
+
content: se.msg,
|
|
8711
|
+
status: "error",
|
|
8712
|
+
zIndex: 3e3
|
|
8713
|
+
});
|
|
8714
|
+
});
|
|
8715
|
+
}
|
|
8716
|
+
);
|
|
8667
8717
|
}
|
|
8668
8718
|
break;
|
|
8669
8719
|
case "TRANSLATE":
|
|
8670
|
-
showPreView("11", $T("翻译"), {
|
|
8720
|
+
showPreView("11", $T("翻译"), {
|
|
8721
|
+
dataId: H[gridData.value.rowId],
|
|
8722
|
+
dsId: gridData.value.params.dsId
|
|
8723
|
+
});
|
|
8671
8724
|
break;
|
|
8672
8725
|
case "PIC_UPLOAD":
|
|
8673
8726
|
uploadConfig.value.show = !uploadConfig.value.show, uploadConfig.value.dataId = H[gridData.value.rowId];
|
|
@@ -8694,7 +8747,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8694
8747
|
$vxeReadFile({ types: ["xml"] }).then(({ file: ne }) => {
|
|
8695
8748
|
const re = new FormData();
|
|
8696
8749
|
re.append("file", ne), axios.upload("windowButton/importWindow", re).then((oe) => {
|
|
8697
|
-
oe.status === 200 && ($vxeMessage({
|
|
8750
|
+
oe.status === 200 && ($vxeMessage({
|
|
8751
|
+
content: oe.data.msg || $T("导入失败!"),
|
|
8752
|
+
status: "info",
|
|
8753
|
+
zIndex: 3e3
|
|
8754
|
+
}), oe.data.result && reload()), Q.loading = !1;
|
|
8698
8755
|
});
|
|
8699
8756
|
}).catch((ne) => {
|
|
8700
8757
|
console.error(ne), Q.loading = !1;
|
|
@@ -8704,20 +8761,30 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8704
8761
|
}
|
|
8705
8762
|
else if (te === "EXPORT" && gridData.value.params.code == "Window") {
|
|
8706
8763
|
if (!H || H.length === 0) {
|
|
8707
|
-
$vxeMessage({
|
|
8764
|
+
$vxeMessage({
|
|
8765
|
+
content: $T("请选择需要导出的窗口!"),
|
|
8766
|
+
status: "info",
|
|
8767
|
+
zIndex: 3e3
|
|
8768
|
+
}), Q.loading = !1;
|
|
8708
8769
|
return;
|
|
8709
8770
|
}
|
|
8710
|
-
H.length > 0 && (H = H[0]), await axios.download("/windowButton/exportWindow", {
|
|
8771
|
+
H.length > 0 && (H = H[0]), await axios.download("/windowButton/exportWindow", {
|
|
8772
|
+
windowId: H.SYS_WINDOW_ID
|
|
8773
|
+
}), Q.loading = !1;
|
|
8711
8774
|
} else if (te === "CREATE_COLUMN")
|
|
8712
|
-
$vxeConfirm($T("确定生成字段?"), void 0, { zIndex: 3e3 }).then(
|
|
8713
|
-
ne
|
|
8714
|
-
|
|
8715
|
-
|
|
8716
|
-
|
|
8717
|
-
|
|
8718
|
-
|
|
8719
|
-
|
|
8720
|
-
|
|
8775
|
+
$vxeConfirm($T("确定生成字段?"), void 0, { zIndex: 3e3 }).then(
|
|
8776
|
+
(ne) => {
|
|
8777
|
+
ne === "confirm" && axios.post("windowButton/generateColumn", {
|
|
8778
|
+
datasourceId: H.SYS_DATASOURCE_ID
|
|
8779
|
+
}).then((re) => {
|
|
8780
|
+
$vxeMessage({
|
|
8781
|
+
content: re.data.msg,
|
|
8782
|
+
status: re.data.result ? "success" : "error",
|
|
8783
|
+
zIndex: 3e3
|
|
8784
|
+
}), re.data.result && reload(), Q.loading = !1;
|
|
8785
|
+
});
|
|
8786
|
+
}
|
|
8787
|
+
);
|
|
8721
8788
|
else if (te === "DATA_VIEW")
|
|
8722
8789
|
axios.post("datasource/" + H.URL).then((ne) => {
|
|
8723
8790
|
$vxeOpen({
|
|
@@ -8728,25 +8795,33 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8728
8795
|
}), Q.loading = !1;
|
|
8729
8796
|
});
|
|
8730
8797
|
else if (te === "GENERATETABLE")
|
|
8731
|
-
$vxeConfirm($T("确定生成表结构?"), void 0, { zIndex: 3e3 }).then(
|
|
8732
|
-
ne
|
|
8733
|
-
|
|
8734
|
-
|
|
8735
|
-
|
|
8736
|
-
|
|
8737
|
-
|
|
8738
|
-
|
|
8739
|
-
|
|
8798
|
+
$vxeConfirm($T("确定生成表结构?"), void 0, { zIndex: 3e3 }).then(
|
|
8799
|
+
(ne) => {
|
|
8800
|
+
ne === "confirm" && axios.post("windowButton/generateTableStructure", {
|
|
8801
|
+
dataSourceId: H.SYS_DATASOURCE_ID
|
|
8802
|
+
}).then((re) => {
|
|
8803
|
+
$vxeMessage({
|
|
8804
|
+
content: re.data.msg,
|
|
8805
|
+
status: re.data.result ? "success" : "error",
|
|
8806
|
+
zIndex: 3e3
|
|
8807
|
+
}), re.data.result && reload(), Q.loading = !1;
|
|
8808
|
+
});
|
|
8809
|
+
}
|
|
8810
|
+
);
|
|
8740
8811
|
else if (te === "GENERATE_FIELD")
|
|
8741
|
-
$vxeConfirm($T("确定生成字段?"), void 0, { zIndex: 3e3 }).then(
|
|
8742
|
-
ne
|
|
8743
|
-
|
|
8744
|
-
|
|
8745
|
-
|
|
8746
|
-
|
|
8747
|
-
|
|
8748
|
-
|
|
8749
|
-
|
|
8812
|
+
$vxeConfirm($T("确定生成字段?"), void 0, { zIndex: 3e3 }).then(
|
|
8813
|
+
(ne) => {
|
|
8814
|
+
ne === "confirm" && axios.post("windowButton/generateField", {
|
|
8815
|
+
regionId: H.SYS_WINDOW_REGION_ID
|
|
8816
|
+
}).then((re) => {
|
|
8817
|
+
$vxeMessage({
|
|
8818
|
+
content: re.data.msg,
|
|
8819
|
+
status: re.data.result ? "success" : "error",
|
|
8820
|
+
zIndex: 3e3
|
|
8821
|
+
}), re.data.result && reload(), Q.loading = !1;
|
|
8822
|
+
});
|
|
8823
|
+
}
|
|
8824
|
+
);
|
|
8750
8825
|
else if (Q.windowId)
|
|
8751
8826
|
showPreView(Q.windowId, Q.name, H, {
|
|
8752
8827
|
width: Q.openWidth,
|
|
@@ -8754,7 +8829,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8754
8829
|
});
|
|
8755
8830
|
else
|
|
8756
8831
|
try {
|
|
8757
|
-
Q.clickFunction && await evalEvent(
|
|
8832
|
+
Q.clickFunction && await evalEvent(
|
|
8833
|
+
"async " + Q.clickFunction,
|
|
8834
|
+
(X == null ? void 0 : X.length) > 1 ? X : H,
|
|
8835
|
+
Q
|
|
8836
|
+
) !== !1 && (Q.loading = !1);
|
|
8758
8837
|
} catch (ne) {
|
|
8759
8838
|
console.error(ne), Q.loading = !1;
|
|
8760
8839
|
}
|
|
@@ -8799,14 +8878,20 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8799
8878
|
if (G.length > 0)
|
|
8800
8879
|
gridData.value.toolbarConfig.buttons.forEach((X) => {
|
|
8801
8880
|
X.displayLogic && !X.showInGrid && G.some((Z) => {
|
|
8802
|
-
if (X.visible = X.displayLogic ? displayLogic(X.displayLogic, {
|
|
8881
|
+
if (X.visible = X.displayLogic ? displayLogic(X.displayLogic, {
|
|
8882
|
+
...Z,
|
|
8883
|
+
...assembleParentData(gridData.value.params.parentData)
|
|
8884
|
+
}) : !0, !X.visible)
|
|
8803
8885
|
return !0;
|
|
8804
8886
|
});
|
|
8805
8887
|
});
|
|
8806
8888
|
else {
|
|
8807
8889
|
const X = getSelectRecord();
|
|
8808
8890
|
gridData.value.toolbarConfig.buttons.forEach((Z) => {
|
|
8809
|
-
Z.displayLogic && !Z.showInGrid && (Z.visible = displayLogic(Z.displayLogic, {
|
|
8891
|
+
Z.displayLogic && !Z.showInGrid && (Z.visible = displayLogic(Z.displayLogic, {
|
|
8892
|
+
...X,
|
|
8893
|
+
...assembleParentData(gridData.value.params.parentData)
|
|
8894
|
+
}));
|
|
8810
8895
|
});
|
|
8811
8896
|
}
|
|
8812
8897
|
}, getSelectRecord = () => {
|
|
@@ -8836,27 +8921,47 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8836
8921
|
}, removeRow = (Q) => {
|
|
8837
8922
|
getCurRegion().remove(Q);
|
|
8838
8923
|
}, exportCurrentData = async () => {
|
|
8839
|
-
exportButton.value ? getCurRegion().exportData() : $vxeMessage({
|
|
8924
|
+
exportButton.value ? getCurRegion().exportData() : $vxeMessage({
|
|
8925
|
+
content: $T("您没有导出数据权限!"),
|
|
8926
|
+
status: "error",
|
|
8927
|
+
zIndex: 3e3
|
|
8928
|
+
});
|
|
8840
8929
|
}, exportData = async () => {
|
|
8841
8930
|
var Q;
|
|
8842
8931
|
if (exportButton.value) {
|
|
8843
|
-
const H = Object.assign(
|
|
8844
|
-
|
|
8845
|
-
|
|
8846
|
-
|
|
8847
|
-
|
|
8932
|
+
const H = Object.assign(
|
|
8933
|
+
{
|
|
8934
|
+
_button_id: exportButton.value._button_id,
|
|
8935
|
+
_region_id: gridData.value.params._region_id
|
|
8936
|
+
},
|
|
8937
|
+
(Q = gridData.value.params.queryParams) == null ? void 0 : Q.data
|
|
8938
|
+
);
|
|
8939
|
+
await axios.export(
|
|
8940
|
+
"/window/export?data=" + base64Encode(JSON.stringify(H)),
|
|
8941
|
+
{}
|
|
8942
|
+
), exportButton.value.loading = !1;
|
|
8848
8943
|
} else
|
|
8849
|
-
$vxeMessage({
|
|
8944
|
+
$vxeMessage({
|
|
8945
|
+
content: $T("您没有导出数据权限!"),
|
|
8946
|
+
status: "error",
|
|
8947
|
+
zIndex: 3e3
|
|
8948
|
+
});
|
|
8850
8949
|
}, search = (Q) => {
|
|
8851
8950
|
clearTimeout(queryTimeout.value), Q && (gridData.value.params.queryParams = Q), queryTimeout.value = setTimeout(function() {
|
|
8852
8951
|
getCurRegion().commitProxy("query");
|
|
8853
8952
|
}, 500);
|
|
8854
8953
|
}, importFormatError = (Q) => {
|
|
8855
|
-
$vxeMessage({
|
|
8954
|
+
$vxeMessage({
|
|
8955
|
+
content: $T("导入文件格式错误"),
|
|
8956
|
+
status: "error",
|
|
8957
|
+
zIndex: 3e3
|
|
8958
|
+
});
|
|
8856
8959
|
}, importSuccess = (Q, H) => {
|
|
8857
8960
|
Q.result && (isImport.value = !1, reload()), $vxeMessage({ content: Q.msg, status: "info", zIndex: 3e3 });
|
|
8858
8961
|
}, downTemplate = () => {
|
|
8859
|
-
axios.download("/window/downloadTemplate", {
|
|
8962
|
+
axios.download("/window/downloadTemplate", {
|
|
8963
|
+
_region_id: gridData.value.params._region_id
|
|
8964
|
+
});
|
|
8860
8965
|
}, confirm = (Q, H) => {
|
|
8861
8966
|
$vxeConfirm(Q, void 0, { zIndex: 3e3 }).then((G) => {
|
|
8862
8967
|
G === "confirm" && evalEvent(H);
|
|
@@ -8877,7 +8982,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8877
8982
|
if (Z.data.result && Z.data.data)
|
|
8878
8983
|
for (const K in Z.data.data) {
|
|
8879
8984
|
const ee = Z.data.data[K];
|
|
8880
|
-
Q[K] = evalDefaultValue(ee, {
|
|
8985
|
+
Q[K] = evalDefaultValue(ee, {
|
|
8986
|
+
...Q,
|
|
8987
|
+
...G,
|
|
8988
|
+
...X
|
|
8989
|
+
});
|
|
8881
8990
|
}
|
|
8882
8991
|
});
|
|
8883
8992
|
}, editGridInitData = async (Q) => {
|
|
@@ -8885,29 +8994,46 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8885
8994
|
for (const H of Object.keys(formSelectMap.value)) {
|
|
8886
8995
|
const G = formSelectMap.value[H];
|
|
8887
8996
|
if (G.dataType === "TREE")
|
|
8888
|
-
await axios.post(
|
|
8889
|
-
|
|
8890
|
-
|
|
8891
|
-
|
|
8892
|
-
|
|
8997
|
+
await axios.post(
|
|
8998
|
+
"/window/selector",
|
|
8999
|
+
$qs.stringify({
|
|
9000
|
+
...Q,
|
|
9001
|
+
_field_id: G.id,
|
|
9002
|
+
_select_id: G.selectorId
|
|
9003
|
+
})
|
|
9004
|
+
).then((X) => {
|
|
8893
9005
|
X.data.result && X.data.data && (G.editRender.props.treeData = X.data.data);
|
|
8894
9006
|
});
|
|
8895
9007
|
else if (G.remoteSearch) {
|
|
8896
9008
|
G.editRender.props.remoteMethod = async (Z) => {
|
|
8897
|
-
Z && (G.editRender.props.loading = !0, G.editRender.options = await remoteMethod(
|
|
9009
|
+
Z && (G.editRender.props.loading = !0, G.editRender.options = await remoteMethod(
|
|
9010
|
+
Z,
|
|
9011
|
+
G.id,
|
|
9012
|
+
G.selectorId
|
|
9013
|
+
), G.editRender.props.loading = !1);
|
|
8898
9014
|
};
|
|
8899
9015
|
let X = Q["_" + G.field + "_NAME"];
|
|
8900
|
-
Q[G.field] && X && (G.editRender.options = await remoteMethod(
|
|
9016
|
+
Q[G.field] && X && (G.editRender.options = await remoteMethod(
|
|
9017
|
+
X,
|
|
9018
|
+
G.id,
|
|
9019
|
+
G.selectorId
|
|
9020
|
+
));
|
|
8901
9021
|
} else
|
|
8902
|
-
typeof G.selectorId < "u" && await axios.post(
|
|
8903
|
-
|
|
8904
|
-
|
|
8905
|
-
|
|
8906
|
-
|
|
8907
|
-
|
|
8908
|
-
|
|
8909
|
-
|
|
8910
|
-
|
|
9022
|
+
typeof G.selectorId < "u" && await axios.post(
|
|
9023
|
+
"/window/selector",
|
|
9024
|
+
$qs.stringify({
|
|
9025
|
+
...Q,
|
|
9026
|
+
_field_id: G.id,
|
|
9027
|
+
_select_id: G.selectorId
|
|
9028
|
+
})
|
|
9029
|
+
).then((X) => {
|
|
9030
|
+
X.data.result && X.data.data && (G.editRender.options = X.data.data.map((Z) => Object.assign(
|
|
9031
|
+
{
|
|
9032
|
+
value: Z.VALUE,
|
|
9033
|
+
label: Z.NAME
|
|
9034
|
+
},
|
|
9035
|
+
Z
|
|
9036
|
+
)));
|
|
8911
9037
|
});
|
|
8912
9038
|
}
|
|
8913
9039
|
isEditGridInitData.value = !0;
|
|
@@ -8924,9 +9050,18 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8924
9050
|
break;
|
|
8925
9051
|
}
|
|
8926
9052
|
}
|
|
8927
|
-
evalEvent(
|
|
9053
|
+
evalEvent(
|
|
9054
|
+
Q.column.editRender.props.changeFunction,
|
|
9055
|
+
H,
|
|
9056
|
+
K
|
|
9057
|
+
);
|
|
8928
9058
|
} else
|
|
8929
|
-
evalEvent(
|
|
9059
|
+
evalEvent(
|
|
9060
|
+
Q.column.editRender.props.changeFunction,
|
|
9061
|
+
H,
|
|
9062
|
+
X,
|
|
9063
|
+
Z
|
|
9064
|
+
);
|
|
8930
9065
|
}, success = (Q, H) => {
|
|
8931
9066
|
$vxeMessage({
|
|
8932
9067
|
content: Q,
|
|
@@ -8964,20 +9099,31 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8964
9099
|
}, onFieldEnter = (Q, H) => {
|
|
8965
9100
|
if (H.key === "Enter" && Q.column.editRender.props.enterFunction) {
|
|
8966
9101
|
let G = Q.row[Q.column.field];
|
|
8967
|
-
evalEvent(
|
|
9102
|
+
evalEvent(
|
|
9103
|
+
Q.column.editRender.props.enterFunction,
|
|
9104
|
+
G,
|
|
9105
|
+
Q.column.field,
|
|
9106
|
+
Q.row
|
|
9107
|
+
);
|
|
8968
9108
|
}
|
|
8969
9109
|
}, remoteMethod = async (Q, H, G) => {
|
|
8970
|
-
let X = [], Z = await axios.post(
|
|
8971
|
-
|
|
8972
|
-
|
|
8973
|
-
|
|
8974
|
-
|
|
8975
|
-
|
|
9110
|
+
let X = [], Z = await axios.post(
|
|
9111
|
+
"/window/selector",
|
|
9112
|
+
$qs.stringify({
|
|
9113
|
+
$_f_value: Q,
|
|
9114
|
+
_region_id: gridData.value.params._region_id,
|
|
9115
|
+
_field_id: H,
|
|
9116
|
+
_select_id: G
|
|
9117
|
+
})
|
|
9118
|
+
);
|
|
8976
9119
|
if (Z.data.result && Z.data.data)
|
|
8977
|
-
return X = Z.data.data.map((K) => Object.assign(
|
|
8978
|
-
|
|
8979
|
-
|
|
8980
|
-
|
|
9120
|
+
return X = Z.data.data.map((K) => Object.assign(
|
|
9121
|
+
{
|
|
9122
|
+
value: K.VALUE,
|
|
9123
|
+
label: K.NAME
|
|
9124
|
+
},
|
|
9125
|
+
K
|
|
9126
|
+
)), X;
|
|
8981
9127
|
}, handleAddChildTableData = async () => {
|
|
8982
9128
|
let Q = {}, H = "";
|
|
8983
9129
|
for (let Z in gridData.value.columns)
|
|
@@ -8988,7 +9134,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
8988
9134
|
const H = getGrid();
|
|
8989
9135
|
let G = H.getCheckboxRecords();
|
|
8990
9136
|
if (G.length <= 0) {
|
|
8991
|
-
$vxeMessage({
|
|
9137
|
+
$vxeMessage({
|
|
9138
|
+
content: $T("请勾选需要复制的行数据!"),
|
|
9139
|
+
status: "warning",
|
|
9140
|
+
zIndex: 3e3
|
|
9141
|
+
});
|
|
8992
9142
|
return;
|
|
8993
9143
|
}
|
|
8994
9144
|
let X = H.getRowSeq(G[G.length - 1]);
|
|
@@ -9004,13 +9154,24 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9004
9154
|
}, handleDeleteChildTableData = async () => {
|
|
9005
9155
|
const Q = getGrid();
|
|
9006
9156
|
if (Q.getCheckboxRecords().length <= 0) {
|
|
9007
|
-
$vxeMessage({
|
|
9157
|
+
$vxeMessage({
|
|
9158
|
+
content: $T("请勾选需要删除的行数据!"),
|
|
9159
|
+
status: "warning",
|
|
9160
|
+
zIndex: 3e3
|
|
9161
|
+
});
|
|
9008
9162
|
return;
|
|
9009
9163
|
}
|
|
9010
9164
|
await $vxeConfirm($T("您确定要删除吗?")) === "confirm" && Q.removeCheckboxRow();
|
|
9011
9165
|
};
|
|
9012
9166
|
let editActivedRow = null, editActivedRowIndex = 0;
|
|
9013
|
-
const editActived = ({
|
|
9167
|
+
const editActived = ({
|
|
9168
|
+
row: Q,
|
|
9169
|
+
rowIndex: H,
|
|
9170
|
+
$rowIndex: G,
|
|
9171
|
+
column: X,
|
|
9172
|
+
columnIndex: Z,
|
|
9173
|
+
$columnIndex: K
|
|
9174
|
+
}) => {
|
|
9014
9175
|
editActivedRow = Q, editActivedRowIndex = H, destroyCopyAreaBox(), destroyCellAreaBox();
|
|
9015
9176
|
};
|
|
9016
9177
|
let isSelecting = ref(!1), selectionStart = ref({ rowIndex: -1, cellIndex: -1 }), selectionEnd = ref({ rowIndex: -1, cellIndex: -1 }), cellarea = ref(), outevent = null, tbodyMousedownTimeout = null, cellAreaData = null, isCut = !1, cutSelectionStart = ref({ rowIndex: -1, cellIndex: -1 }), cutSelectionEnd = ref({ rowIndex: -1, cellIndex: -1 });
|
|
@@ -9060,7 +9221,9 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9060
9221
|
ee[le][se.field] = G[le] ? G[le][ce] : "";
|
|
9061
9222
|
});
|
|
9062
9223
|
});
|
|
9063
|
-
let te = K.map((ae) => ae.field), ne = gridData.value.columns.filter(
|
|
9224
|
+
let te = K.map((ae) => ae.field), ne = gridData.value.columns.filter(
|
|
9225
|
+
(ae) => te.includes(ae.field)
|
|
9226
|
+
);
|
|
9064
9227
|
ee = verifyPasteData(ne, ee), X.remove(Z);
|
|
9065
9228
|
let re = selectionStart.value.rowIndex <= selectionEnd.value.rowIndex ? selectionStart.value.rowIndex : selectionEnd.value.rowIndex;
|
|
9066
9229
|
(await X.getTableData().tableData).length == re && (re = -1), X.insertAt(ee, re);
|
|
@@ -9072,7 +9235,9 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9072
9235
|
if (G.dataType == "LIST") {
|
|
9073
9236
|
for (let X of H)
|
|
9074
9237
|
if (G.editRender.options && G.editRender.options.length > 0 && X[G.field]) {
|
|
9075
|
-
let Z = X[G.field].replace(/(\r\n|\n|\r)/g, ""), K = G.editRender.options.findIndex(
|
|
9238
|
+
let Z = X[G.field].replace(/(\r\n|\n|\r)/g, ""), K = G.editRender.options.findIndex(
|
|
9239
|
+
(ee) => ee.label == Z || ee.value == Z
|
|
9240
|
+
);
|
|
9076
9241
|
K != -1 ? X[G.field] = G.editRender.options[K].value : X[G.field] = "";
|
|
9077
9242
|
}
|
|
9078
9243
|
} else if (G.dataType == "LONG" || G.dataType == "PLONG" || G.dataType == "DOUBLE") {
|
|
@@ -9110,16 +9275,21 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9110
9275
|
K[te.field] && K[te.field].trim() ? ee = ee + K[te.field] + " " : ee = ee + " " + K[te.field];
|
|
9111
9276
|
}), Z = Z ? Z + `
|
|
9112
9277
|
` + ee : ee;
|
|
9113
|
-
}), navigator.clipboard.writeText(Z).then(
|
|
9114
|
-
|
|
9115
|
-
|
|
9116
|
-
|
|
9117
|
-
|
|
9278
|
+
}), navigator.clipboard.writeText(Z).then(
|
|
9279
|
+
function() {
|
|
9280
|
+
let K = getCurRegion().$el.querySelector(
|
|
9281
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-copy-area"
|
|
9282
|
+
);
|
|
9283
|
+
if (cellAreaData && K) {
|
|
9284
|
+
const { width: ee, height: te, left: ne, top: re, right: oe } = cellAreaData;
|
|
9285
|
+
K.style.width = `${ee}px`, K.style.height = `${te}px`, K.style.top = `${re}px`, K.style.display = "block", K.style.left = `${ne}px`;
|
|
9286
|
+
}
|
|
9287
|
+
$message.success(H);
|
|
9288
|
+
},
|
|
9289
|
+
function(K) {
|
|
9290
|
+
console.log(K);
|
|
9118
9291
|
}
|
|
9119
|
-
|
|
9120
|
-
}, function(K) {
|
|
9121
|
-
console.log(K);
|
|
9122
|
-
});
|
|
9292
|
+
);
|
|
9123
9293
|
}, getSelectData = (Q = selectionStart.value, H = selectionEnd.value) => {
|
|
9124
9294
|
const G = getGrid();
|
|
9125
9295
|
let X = G.getTableData().visibleData, Z = Q.rowIndex, K = H.rowIndex, ee = X.filter((ae, le) => Z <= K ? Z <= le && K >= le : Z >= le && K <= le), te = Q.cellIndex, ne = H.cellIndex, oe = G.getTableColumn().visibleColumn.filter((ae, le) => te <= ne ? te <= le && ne >= le : te >= le && ne <= le);
|
|
@@ -9127,8 +9297,16 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9127
9297
|
}, addListener = () => {
|
|
9128
9298
|
nextTick(() => {
|
|
9129
9299
|
document.addEventListener("mousedown", tableOutDestroyAreaBox), document.addEventListener("mouseup", tbodymouseup), document.addEventListener("paste", ctrlVPaste), document.addEventListener("copy", ctrlCopyAndCut), document.addEventListener("cut", ctrlCopyAndCut);
|
|
9130
|
-
let Q = getCurRegion().$el.querySelector(
|
|
9131
|
-
|
|
9300
|
+
let Q = getCurRegion().$el.querySelector(
|
|
9301
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper table"
|
|
9302
|
+
);
|
|
9303
|
+
Q && (Q.addEventListener("mousedown", tbodymousedown), Q.addEventListener(
|
|
9304
|
+
"mousemove",
|
|
9305
|
+
XEUtils$1.throttle(tbodymousemove, 100)
|
|
9306
|
+
), Q.addEventListener(
|
|
9307
|
+
"mouseout",
|
|
9308
|
+
XEUtils$1.throttle(tbodymouseout, 100)
|
|
9309
|
+
), Q.appendChild(cellarea.value));
|
|
9132
9310
|
});
|
|
9133
9311
|
}, tbodymousedown = (Q) => {
|
|
9134
9312
|
tbodyMousedownTimeout = setTimeout(() => {
|
|
@@ -9144,14 +9322,20 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9144
9322
|
Q.button === 0 && (isSelecting.value = !1, clearTimeout(tbodyMousedownTimeout));
|
|
9145
9323
|
}, tableOutDestroyAreaBox = (Q) => {
|
|
9146
9324
|
if (getCurRegion()) {
|
|
9147
|
-
let H = getCurRegion().$el.querySelector(
|
|
9325
|
+
let H = getCurRegion().$el.querySelector(
|
|
9326
|
+
".vxe-table--render-wrapper"
|
|
9327
|
+
);
|
|
9148
9328
|
H && (Q.clientX < H.getBoundingClientRect().left || Q.clientX > H.getBoundingClientRect().right || Q.clientY < H.getBoundingClientRect().top || Q.clientY > H.getBoundingClientRect().bottom) && destroyCellAreaBox();
|
|
9149
9329
|
}
|
|
9150
9330
|
}, destroyCellAreaBox = () => {
|
|
9151
|
-
let Q = getCurRegion().$el.querySelector(
|
|
9331
|
+
let Q = getCurRegion().$el.querySelector(
|
|
9332
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-area"
|
|
9333
|
+
);
|
|
9152
9334
|
Q && (Q.style.display = "none", selectionStart.value = { rowIndex: -1, cellIndex: -1 }, selectionEnd.value = { rowIndex: -1, cellIndex: -1 }, cellAreaData = null);
|
|
9153
9335
|
}, destroyCopyAreaBox = () => {
|
|
9154
|
-
let Q = getCurRegion().$el.querySelector(
|
|
9336
|
+
let Q = getCurRegion().$el.querySelector(
|
|
9337
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-copy-area"
|
|
9338
|
+
);
|
|
9155
9339
|
Q && (Q.style.display = "none", Q.style.width = "0px", Q.style.height = "0px", Q.style.top = "0px", Q.style.left = "0px");
|
|
9156
9340
|
}, getCellPosition = (Q) => {
|
|
9157
9341
|
for (; Q && Q.tagName !== "TD"; )
|
|
@@ -9161,7 +9345,11 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9161
9345
|
const G = getCurRegion().getTableColumn().visibleColumn.findIndex((K) => K.id == Q.getAttribute("colid"));
|
|
9162
9346
|
return { rowIndex: getCurRegion().getTableData().visibleData.findIndex((K) => K.id == Q.parentElement.getAttribute("rowid")), cellIndex: G };
|
|
9163
9347
|
}, setselectedCellArea = () => {
|
|
9164
|
-
let Q = getCurRegion().$el.querySelector(
|
|
9348
|
+
let Q = getCurRegion().$el.querySelector(
|
|
9349
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-active-area"
|
|
9350
|
+
), H = getCurRegion().$el.querySelector(
|
|
9351
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-main-area"
|
|
9352
|
+
), G = [Q, H];
|
|
9165
9353
|
if (cellAreaData = getAreaBoxPosition(), cellAreaData)
|
|
9166
9354
|
var { width: X, height: Z, left: K, top: ee, right: te } = cellAreaData;
|
|
9167
9355
|
else
|
|
@@ -9180,13 +9368,17 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9180
9368
|
G <= X ? (ce < G && (oe += se.renderWidth), ce > X && (le += se.renderWidth), G <= ce && ce <= X && (ne += se.renderWidth)) : (ce < X && (oe += se.renderWidth), ce > G && (le += se.renderWidth), G >= ce && ce >= X && (ne += se.renderWidth));
|
|
9181
9369
|
}), Q <= H ? (re = (H - Q + 1) * gridData.value.rowConfig.height, ae = Q * gridData.value.rowConfig.height) : (re = (Q - H + 1) * gridData.value.rowConfig.height, ae = H * gridData.value.rowConfig.height), { width: ne, height: re, left: oe, top: ae, right: le };
|
|
9182
9370
|
}, openAreaBox = () => {
|
|
9183
|
-
let Q = getCurRegion().$el.querySelector(
|
|
9371
|
+
let Q = getCurRegion().$el.querySelector(
|
|
9372
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-area"
|
|
9373
|
+
);
|
|
9184
9374
|
Q && (Q.style.display = "block");
|
|
9185
9375
|
}, tbodymouseout = (Q) => {
|
|
9186
9376
|
if (outevent = Q, isSelecting.value) {
|
|
9187
9377
|
const H = setInterval(() => {
|
|
9188
9378
|
if (isSelecting.value) {
|
|
9189
|
-
let G = getCurRegion().$el.querySelector(
|
|
9379
|
+
let G = getCurRegion().$el.querySelector(
|
|
9380
|
+
".vxe-table--body-wrapper table"
|
|
9381
|
+
), X = G.parentElement.getBoundingClientRect();
|
|
9190
9382
|
if (outevent.clientX > X.right - 30) {
|
|
9191
9383
|
let Z = G.parentElement.scrollWidth - G.parentElement.clientWidth;
|
|
9192
9384
|
G.parentElement.scrollLeft < Z && (G.parentElement.scrollLeft += 10);
|
|
@@ -9204,7 +9396,13 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9204
9396
|
}, resizableChange = ({ column: Q, $columnIndex: H }) => {
|
|
9205
9397
|
if (selectionStart.value.rowIndex == -1 && selectionEnd.value.rowIndex == -1)
|
|
9206
9398
|
return;
|
|
9207
|
-
let { width: G, left: X } = getAreaBoxPosition(), Z = getCurRegion().$el.querySelector(
|
|
9399
|
+
let { width: G, left: X } = getAreaBoxPosition(), Z = getCurRegion().$el.querySelector(
|
|
9400
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-active-area"
|
|
9401
|
+
), K = getCurRegion().$el.querySelector(
|
|
9402
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-main-area"
|
|
9403
|
+
), ee = getCurRegion().$el.querySelector(
|
|
9404
|
+
".vxe-table--main-wrapper .vxe-table--body-wrapper .vxe-table--cell-copy-area"
|
|
9405
|
+
);
|
|
9208
9406
|
[Z, K, ee].forEach((ne) => {
|
|
9209
9407
|
ne && ne.style.display == "block" && cellAreaData && (ne.style.width = `${G}px`, cellAreaData.width = G, ne.style.left = `${X}px`, cellAreaData.left = X);
|
|
9210
9408
|
});
|
|
@@ -9219,7 +9417,15 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9219
9417
|
rowIndex: X,
|
|
9220
9418
|
cellIndex: Q
|
|
9221
9419
|
}, setselectedCellArea();
|
|
9222
|
-
}, headerSeqCellDbClick = ({
|
|
9420
|
+
}, headerSeqCellDbClick = ({
|
|
9421
|
+
row: Q,
|
|
9422
|
+
rowIndex: H,
|
|
9423
|
+
$rowIndex: G,
|
|
9424
|
+
column: X,
|
|
9425
|
+
columnIndex: Z,
|
|
9426
|
+
$columnIndex: K,
|
|
9427
|
+
$event: ee
|
|
9428
|
+
}) => {
|
|
9223
9429
|
var ne = getCurRegion().getTableColumn().visibleColumn.length - 1;
|
|
9224
9430
|
selectionStart.value = {
|
|
9225
9431
|
rowIndex: G,
|
|
@@ -9246,22 +9452,38 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9246
9452
|
}), gridData.value.formConfig.items.forEach((Q) => {
|
|
9247
9453
|
var H;
|
|
9248
9454
|
if (Q.itemRender && Q.itemRender.events && Q.itemRender.events.hasOwnProperty("change") && (Q.itemRender.events.change = search), Q.remoteSearch ? (Q.itemRender.props.remoteMethod = async (G) => {
|
|
9249
|
-
G && (Q.itemRender.props.loading = !0, Q.itemRender.options = await remoteMethod(
|
|
9250
|
-
|
|
9455
|
+
G && (Q.itemRender.props.loading = !0, Q.itemRender.options = await remoteMethod(
|
|
9456
|
+
G,
|
|
9457
|
+
Q.querys.id,
|
|
9458
|
+
Q.querys.selectorId
|
|
9459
|
+
), Q.itemRender.props.loading = !1);
|
|
9460
|
+
}, Q.itemRender.defaultValue && remoteMethod(
|
|
9461
|
+
Q.itemRender.defaultValue,
|
|
9462
|
+
Q.querys.id,
|
|
9463
|
+
Q.querys.selectorId
|
|
9464
|
+
).then((G) => {
|
|
9251
9465
|
Q.itemRender.options = G;
|
|
9252
|
-
})) : Q.querys && axios.post(
|
|
9253
|
-
|
|
9254
|
-
|
|
9255
|
-
|
|
9256
|
-
|
|
9466
|
+
})) : Q.querys && axios.post(
|
|
9467
|
+
"/window/selector",
|
|
9468
|
+
$qs.stringify({
|
|
9469
|
+
_region_id: gridData.value.params._region_id,
|
|
9470
|
+
_field_id: Q.querys.id,
|
|
9471
|
+
_select_id: Q.querys.selectorId
|
|
9472
|
+
})
|
|
9473
|
+
).then((G) => {
|
|
9257
9474
|
if (G.data.result && G.data.data) {
|
|
9258
|
-
const X = G.data.data.map((Z) => Object.assign(
|
|
9259
|
-
|
|
9260
|
-
|
|
9261
|
-
|
|
9475
|
+
const X = G.data.data.map((Z) => Object.assign(
|
|
9476
|
+
{
|
|
9477
|
+
value: Z.VALUE,
|
|
9478
|
+
label: Z.NAME
|
|
9479
|
+
},
|
|
9480
|
+
Z
|
|
9481
|
+
));
|
|
9262
9482
|
Q.itemRender.options = X;
|
|
9263
9483
|
}
|
|
9264
|
-
}), ["ElDateRangePicker", "ElDateTimeRangePicker"].includes(
|
|
9484
|
+
}), ["ElDateRangePicker", "ElDateTimeRangePicker"].includes(
|
|
9485
|
+
(H = Q == null ? void 0 : Q.itemRender) == null ? void 0 : H.name
|
|
9486
|
+
)) {
|
|
9265
9487
|
let G = Q.itemRender.props;
|
|
9266
9488
|
G.unlinkPanels = !0, G.disabledDate = (X) => {
|
|
9267
9489
|
let Z = /* @__PURE__ */ new Date();
|
|
@@ -9270,7 +9492,10 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9270
9492
|
}
|
|
9271
9493
|
}), gridData.value.columns.forEach((Q) => {
|
|
9272
9494
|
Q.hasOwnProperty("field") && !Q.hasOwnProperty("treeNode") && (Q.events.change = onFieldChange, Q.events["on-change"] = onFieldChange, Q.events.keyup = onFieldEnter, Q.editRender.events = Q.events, Q.itemRender.events = Q.events), Q.itemRender && Q.itemRender.props._select_id && (formSelectMap.value[Q.id] = Q);
|
|
9273
|
-
}), gridData.value.type === "TREE_STRUCTURE" && (gridData.value.menuConfig = {
|
|
9495
|
+
}), gridData.value.type === "TREE_STRUCTURE" && (gridData.value.menuConfig = {
|
|
9496
|
+
body: { options: bodyMenus.value },
|
|
9497
|
+
visibleMethod
|
|
9498
|
+
}), searchData(), regionMap.value[gridData.value.params.code + "-" + preTag.value] = curRegion.value, regionMap.value[gridData.value.params.code] = curRegion.value, evalEvent(gridData.value.params.formEvents.regionInit), gridData.value.params.parentRegionId && addGridClickEvent(rowClickEmitFun), curRegion.value.closeModal = () => {
|
|
9274
9499
|
closeModal && closeModal();
|
|
9275
9500
|
}, curRegion.value.closePreModal = () => {
|
|
9276
9501
|
closePreModal && closePreModal();
|
|
@@ -9314,15 +9539,15 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9314
9539
|
(openBlock(!0), createElementBlock(Fragment, null, renderList(showButtons(ae), (le) => (openBlock(), createBlock(Z, {
|
|
9315
9540
|
key: le._button_id,
|
|
9316
9541
|
iconComponent: le.iconComponent,
|
|
9317
|
-
"auto-insert-space":
|
|
9542
|
+
"auto-insert-space": "",
|
|
9318
9543
|
size: "small",
|
|
9319
9544
|
style: normalizeStyle({ ...le.css, marginLeft: "0px", padding: "5px" }),
|
|
9320
9545
|
type: "primary",
|
|
9321
|
-
text:
|
|
9546
|
+
text: "",
|
|
9322
9547
|
onClick: (se) => toolBarButtonClick(le, oe, ae)
|
|
9323
9548
|
}, createSlots({
|
|
9324
9549
|
default: withCtx(() => [
|
|
9325
|
-
!le.iconComponent || typeof le.iconComponent > "u" ? (openBlock(), createElementBlock("span", _hoisted_6$1_, toDisplayString(le.name), 1)) : createCommentVNode("", !0)
|
|
9550
|
+
!le.iconComponent || typeof le.iconComponent > "u" ? (openBlock(), createElementBlock("span", _hoisted_6$1_, toDisplayString(unref($T)(le.name)), 1)) : createCommentVNode("", !0)
|
|
9326
9551
|
]),
|
|
9327
9552
|
_: 2
|
|
9328
9553
|
}, [
|
|
@@ -9330,7 +9555,7 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9330
9555
|
name: "icon",
|
|
9331
9556
|
fn: withCtx(() => [
|
|
9332
9557
|
createVNode(X, {
|
|
9333
|
-
content: le.name,
|
|
9558
|
+
content: unref($T)(le.name),
|
|
9334
9559
|
placement: "top"
|
|
9335
9560
|
}, {
|
|
9336
9561
|
default: withCtx(() => [
|
|
@@ -9440,7 +9665,7 @@ const XEUtils$1 = /* @__PURE__ */ getDefaultExportFromCjs(xeUtils), windowGrid_v
|
|
|
9440
9665
|
]);
|
|
9441
9666
|
};
|
|
9442
9667
|
}
|
|
9443
|
-
}, WindowGrid = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-
|
|
9668
|
+
}, WindowGrid = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-3c299fd2"]]);
|
|
9444
9669
|
WindowGrid.name = "slw-window-grid";
|
|
9445
9670
|
WindowGrid.install = (Q) => {
|
|
9446
9671
|
Q.component(WindowGrid.name, WindowGrid);
|
|
@@ -36484,7 +36709,11 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36484
36709
|
type: Object
|
|
36485
36710
|
}
|
|
36486
36711
|
},
|
|
36487
|
-
emits: [
|
|
36712
|
+
emits: [
|
|
36713
|
+
"saveLoadingChange",
|
|
36714
|
+
"gridReload",
|
|
36715
|
+
"update:formConfig"
|
|
36716
|
+
],
|
|
36488
36717
|
setup(__props, { expose: __expose, emit: emits }) {
|
|
36489
36718
|
const props = __props, componentMapping = inject("$componentMapping");
|
|
36490
36719
|
let formConfig = useVModel(props, "formConfig", emits);
|
|
@@ -36535,8 +36764,13 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36535
36764
|
let data = Object.assign({}, datax), result = !1;
|
|
36536
36765
|
try {
|
|
36537
36766
|
for (let Q in data)
|
|
36538
|
-
displayStr = displayStr.replace(
|
|
36539
|
-
|
|
36767
|
+
displayStr = displayStr.replace(
|
|
36768
|
+
new RegExp("@" + Q + "@", "gi"),
|
|
36769
|
+
typeof data[Q] == "string" ? "'" + data[Q] + "'" : data[Q]
|
|
36770
|
+
);
|
|
36771
|
+
result = eval(
|
|
36772
|
+
displayStr.replaceAll("this.$data.", "").replaceAll("this.", "")
|
|
36773
|
+
);
|
|
36540
36774
|
} catch (Q) {
|
|
36541
36775
|
result = !1;
|
|
36542
36776
|
}
|
|
@@ -36619,17 +36853,35 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36619
36853
|
});
|
|
36620
36854
|
}, rowClickEmitFun = (Q, H) => {
|
|
36621
36855
|
formConfig.value.params.parentRegionId === H && (Q ? preTag.value === Q.preTag && (formConfig.value.params.parentRowId = Q.rowId, formConfig.value.params.parentRowIdValue = Q.rowIdValue) : (formConfig.value.params.parentRowId = null, formConfig.value.params.parentRowIdValue = null), searchData());
|
|
36622
|
-
}, displayLogicEvent = (Q) => displayLogic(Q.item.itemRender.props.displayLogic, {
|
|
36856
|
+
}, displayLogicEvent = (Q) => displayLogic(Q.item.itemRender.props.displayLogic, {
|
|
36857
|
+
...Q.data,
|
|
36858
|
+
...assembleParentData()
|
|
36859
|
+
}), form = ref(), submitData = (Q) => {
|
|
36623
36860
|
form.value.validate(async (H) => {
|
|
36624
36861
|
if (typeof H > "u") {
|
|
36625
|
-
let G = await evalEvent(
|
|
36862
|
+
let G = await evalEvent(
|
|
36863
|
+
formConfig.value.params.formEvents.beginSubmit,
|
|
36864
|
+
formData.value
|
|
36865
|
+
);
|
|
36626
36866
|
if (typeof G < "u" && G === !1) {
|
|
36627
36867
|
emits("saveLoadingChange");
|
|
36628
36868
|
return;
|
|
36629
36869
|
}
|
|
36630
36870
|
let X = "/window/submit";
|
|
36631
36871
|
formConfig.value.openType === "new" && formConfig.value.params.newRequestPath && (X = formConfig.value.params.newRequestPath), formConfig.value.openType === "edit" && formConfig.value.params.editRequestPath && (X = formConfig.value.params.editRequestPath), formConfig.value.openType === "submit" && formConfig.value.params.submitRequestPath && (X = formConfig.value.params.submitRequestPath), axios.post(X, formData.value).then((Z) => {
|
|
36632
|
-
emits("saveLoadingChange"), typeof Q < "u" && Q instanceof Object && (formConfig.value.showEdit = !Z.data.result, showPreViewClose()), $vxeMessage({
|
|
36872
|
+
emits("saveLoadingChange"), typeof Q < "u" && Q instanceof Object && (formConfig.value.showEdit = !Z.data.result, showPreViewClose()), $vxeMessage({
|
|
36873
|
+
content: Z.data.msg,
|
|
36874
|
+
status: Z.data.result ? "success" : "error",
|
|
36875
|
+
zIndex: 3e3
|
|
36876
|
+
}), Z.data.result && (evalEvent(
|
|
36877
|
+
formConfig.value.params.formEvents.afterSubmit,
|
|
36878
|
+
formData.value,
|
|
36879
|
+
Z.data
|
|
36880
|
+
), typeof Q < "u" && (Q instanceof Object || Q === !0) && emits(
|
|
36881
|
+
"gridReload",
|
|
36882
|
+
formData.value._region_id,
|
|
36883
|
+
formConfig.value.openType === "new" ? 0 : null
|
|
36884
|
+
)), nextTick(() => {
|
|
36633
36885
|
formDataClone.value = XEUtils$1.clone(toRaw(formData.value), !0);
|
|
36634
36886
|
});
|
|
36635
36887
|
}).catch((Z) => {
|
|
@@ -36702,7 +36954,11 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36702
36954
|
if (K.data.result && K.data.data)
|
|
36703
36955
|
for (let ee in K.data.data) {
|
|
36704
36956
|
let te = K.data.data[ee];
|
|
36705
|
-
Q[ee] = evalDefaultValue(te, {
|
|
36957
|
+
Q[ee] = evalDefaultValue(te, {
|
|
36958
|
+
...Q,
|
|
36959
|
+
...X,
|
|
36960
|
+
...Z
|
|
36961
|
+
});
|
|
36706
36962
|
}
|
|
36707
36963
|
});
|
|
36708
36964
|
}
|
|
@@ -36710,45 +36966,70 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36710
36966
|
let Z = formSelectMap.value[X];
|
|
36711
36967
|
if (Z.displayForm) {
|
|
36712
36968
|
if (Z.dataType === "TREE")
|
|
36713
|
-
await axios.post(
|
|
36714
|
-
|
|
36715
|
-
|
|
36716
|
-
|
|
36717
|
-
|
|
36969
|
+
await axios.post(
|
|
36970
|
+
"/window/selector",
|
|
36971
|
+
$qs.stringify({
|
|
36972
|
+
...Q,
|
|
36973
|
+
_field_id: Z.id,
|
|
36974
|
+
_select_id: Z.selectorId
|
|
36975
|
+
})
|
|
36976
|
+
).then((K) => {
|
|
36718
36977
|
K.data.result && K.data.data && (Z.itemRender.props.treeData = K.data.data);
|
|
36719
36978
|
});
|
|
36720
36979
|
else if (Z.remoteSearch) {
|
|
36721
36980
|
Z.itemRender.options = [], Z.itemRender.props.remoteMethod = async (ee) => {
|
|
36722
|
-
ee && (Z.itemRender.props.loading = !0, Z.itemRender.options = await remoteMethod(
|
|
36981
|
+
ee && (Z.itemRender.props.loading = !0, Z.itemRender.options = await remoteMethod(
|
|
36982
|
+
ee,
|
|
36983
|
+
Z.id,
|
|
36984
|
+
Z.selectorId
|
|
36985
|
+
), Z.itemRender.props.loading = !1);
|
|
36723
36986
|
};
|
|
36724
36987
|
let K = Q["_" + Z.field + "_NAME"];
|
|
36725
36988
|
if (Q[Z.field] && K) {
|
|
36726
|
-
Z.itemRender.options = await remoteMethod(
|
|
36989
|
+
Z.itemRender.options = await remoteMethod(
|
|
36990
|
+
K,
|
|
36991
|
+
Z.id,
|
|
36992
|
+
Z.selectorId
|
|
36993
|
+
);
|
|
36727
36994
|
let ee = Z.itemRender.options;
|
|
36728
36995
|
formConfig.value.openType === "new" && Z.visible && !Q[Z.field] && ee.length > 0 && (Q[Z.field] = ee[0].VALUE);
|
|
36729
36996
|
} else
|
|
36730
|
-
Q[Z.field] && !K && await axios.post(
|
|
36731
|
-
|
|
36732
|
-
|
|
36733
|
-
|
|
36734
|
-
|
|
36735
|
-
|
|
36736
|
-
|
|
36737
|
-
|
|
36738
|
-
|
|
36739
|
-
|
|
36997
|
+
Q[Z.field] && !K && await axios.post(
|
|
36998
|
+
"/window/selector",
|
|
36999
|
+
$qs.stringify({
|
|
37000
|
+
$_value: Q[Z.field],
|
|
37001
|
+
_region_id: formConfig.value.params._region_id,
|
|
37002
|
+
_field_id: Z.id,
|
|
37003
|
+
_select_id: Z.selectorId
|
|
37004
|
+
})
|
|
37005
|
+
).then((ee) => {
|
|
37006
|
+
ee.data.result && ee.data.data && (Z.itemRender.options = ee.data.data.map(
|
|
37007
|
+
(te) => Object.assign(
|
|
37008
|
+
{
|
|
37009
|
+
value: te.VALUE,
|
|
37010
|
+
label: te.NAME
|
|
37011
|
+
},
|
|
37012
|
+
te
|
|
37013
|
+
)
|
|
37014
|
+
));
|
|
36740
37015
|
});
|
|
36741
37016
|
} else if (typeof Z.selectorId < "u")
|
|
36742
|
-
Z.itemRender.props.loading = !0, await axios.post(
|
|
36743
|
-
|
|
36744
|
-
|
|
36745
|
-
|
|
36746
|
-
|
|
37017
|
+
Z.itemRender.props.loading = !0, await axios.post(
|
|
37018
|
+
"/window/selector",
|
|
37019
|
+
$qs.stringify({
|
|
37020
|
+
...Q,
|
|
37021
|
+
_field_id: Z.id,
|
|
37022
|
+
_select_id: Z.selectorId
|
|
37023
|
+
})
|
|
37024
|
+
).then((K) => {
|
|
36747
37025
|
if (K.data.result && K.data.data) {
|
|
36748
|
-
if (Z.itemRender.options = K.data.data.map((ee) => Object.assign(
|
|
36749
|
-
|
|
36750
|
-
|
|
36751
|
-
|
|
37026
|
+
if (Z.itemRender.options = K.data.data.map((ee) => Object.assign(
|
|
37027
|
+
{
|
|
37028
|
+
value: ee.VALUE,
|
|
37029
|
+
label: ee.NAME
|
|
37030
|
+
},
|
|
37031
|
+
ee
|
|
37032
|
+
)), formConfig.value.openType === "new" && Z.visible && !Q[Z.field] && K.data.data.length > 0) {
|
|
36752
37033
|
Q[Z.field] = K.data.data[0].VALUE;
|
|
36753
37034
|
let ee = {
|
|
36754
37035
|
data: Q,
|
|
@@ -36773,22 +37054,31 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36773
37054
|
}
|
|
36774
37055
|
readonlyLogic();
|
|
36775
37056
|
}, remoteMethod = async (Q, H, G) => {
|
|
36776
|
-
let X = [], Z = await axios.post(
|
|
36777
|
-
|
|
36778
|
-
|
|
36779
|
-
|
|
36780
|
-
|
|
36781
|
-
|
|
37057
|
+
let X = [], Z = await axios.post(
|
|
37058
|
+
"/window/selector",
|
|
37059
|
+
$qs.stringify({
|
|
37060
|
+
$_f_value: Q,
|
|
37061
|
+
_region_id: formConfig.value.params._region_id,
|
|
37062
|
+
_field_id: H,
|
|
37063
|
+
_select_id: G
|
|
37064
|
+
})
|
|
37065
|
+
);
|
|
36782
37066
|
if (Z.data.result && Z.data.data)
|
|
36783
|
-
return X = Z.data.data.map((K) => Object.assign(
|
|
36784
|
-
|
|
36785
|
-
|
|
36786
|
-
|
|
37067
|
+
return X = Z.data.data.map((K) => Object.assign(
|
|
37068
|
+
{
|
|
37069
|
+
value: K.VALUE,
|
|
37070
|
+
label: K.NAME
|
|
37071
|
+
},
|
|
37072
|
+
K
|
|
37073
|
+
)), X;
|
|
36787
37074
|
}, readonlyLogic = () => {
|
|
36788
37075
|
if (Object.keys(readOnlyColumnMap.value).length > 0) {
|
|
36789
37076
|
let Q = Object.keys(readOnlyColumnMap.value);
|
|
36790
37077
|
for (let H = 0; H < Q.length; H++) {
|
|
36791
|
-
let G = readOnlyColumnMap.value[Q[H]], X = Object.assign({}, formData.value), Z = displayLogic(G.itemRender.props.readonlyLogic, {
|
|
37078
|
+
let G = readOnlyColumnMap.value[Q[H]], X = Object.assign({}, formData.value), Z = displayLogic(G.itemRender.props.readonlyLogic, {
|
|
37079
|
+
...X,
|
|
37080
|
+
...assembleParentData()
|
|
37081
|
+
});
|
|
36792
37082
|
G.itemRender.props.readonly = Z, (G.dataType === "LIST" || G.dataType === "TABLE" || G.dataType === "TREE" || G.dataType === "BOOL") && (G.itemRender.props.disabled = Z);
|
|
36793
37083
|
}
|
|
36794
37084
|
}
|
|
@@ -36798,7 +37088,10 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36798
37088
|
if (Q.item.itemRender.props.dataType === "TREE" && Q.item.itemRender.name === "ATreeSelect") {
|
|
36799
37089
|
if (Q.item.itemRender.props.treeData) {
|
|
36800
37090
|
let Z = Q.item.itemRender.props.treeData;
|
|
36801
|
-
G = Object.assign(
|
|
37091
|
+
G = Object.assign(
|
|
37092
|
+
{},
|
|
37093
|
+
getSelectedTreeDataOptionByValue(Z, H)
|
|
37094
|
+
), G.label = G.title;
|
|
36802
37095
|
}
|
|
36803
37096
|
} else if (formSelectMap.value[Q.item.itemRender.props._field_id].itemRender.options) {
|
|
36804
37097
|
let Z = formSelectMap.value[Q.item.itemRender.props._field_id].itemRender.options;
|
|
@@ -36814,15 +37107,21 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36814
37107
|
evalEvent(Q.item.itemRender.props.changeFunction, H, G), readonlyLogic();
|
|
36815
37108
|
let X = formConfig.value;
|
|
36816
37109
|
X.params.selectTableField[Q.property] && X.params.selectTableField[Q.property].forEach((K) => {
|
|
36817
|
-
axios.post(
|
|
36818
|
-
|
|
36819
|
-
|
|
36820
|
-
|
|
36821
|
-
|
|
36822
|
-
|
|
36823
|
-
|
|
36824
|
-
|
|
36825
|
-
|
|
37110
|
+
axios.post(
|
|
37111
|
+
"/window/selector",
|
|
37112
|
+
$qs.stringify({
|
|
37113
|
+
...formData.value,
|
|
37114
|
+
_field_id: K._field_id,
|
|
37115
|
+
_select_id: K._select_id
|
|
37116
|
+
})
|
|
37117
|
+
).then((ee) => {
|
|
37118
|
+
ee.data.result && ee.data.data && (formSelectMap.value[K._field_id].dataType === "TREE" ? formSelectMap.value[K._field_id].itemRender.props.treeData = ee.data.data : (formSelectMap.value[K._field_id].itemRender.options = ee.data.data.map((te) => Object.assign(
|
|
37119
|
+
{
|
|
37120
|
+
value: te.VALUE,
|
|
37121
|
+
label: te.NAME
|
|
37122
|
+
},
|
|
37123
|
+
te
|
|
37124
|
+
)), formData.value[formSelectMap.value[K._field_id].field] = null));
|
|
36826
37125
|
});
|
|
36827
37126
|
}), subQueryFields.value.forEach((Z) => {
|
|
36828
37127
|
getSubQueryData(Q.data._region_id, Z.id, Z.field);
|
|
@@ -36843,20 +37142,28 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36843
37142
|
let G = Object.assign({}, formData.value);
|
|
36844
37143
|
G.$_f_value = H;
|
|
36845
37144
|
let X = Q.item.itemRender.props._field_id, Z = Q.item.itemRender.props._select_id;
|
|
36846
|
-
axios.post(
|
|
36847
|
-
|
|
36848
|
-
|
|
36849
|
-
|
|
36850
|
-
|
|
37145
|
+
axios.post(
|
|
37146
|
+
"/window/selector",
|
|
37147
|
+
$qs.stringify({
|
|
37148
|
+
...G,
|
|
37149
|
+
_field_id: X,
|
|
37150
|
+
_select_id: Z
|
|
37151
|
+
})
|
|
37152
|
+
).then((K) => {
|
|
36851
37153
|
if (K.data.result && K.data.data) {
|
|
36852
|
-
let ee = Object.assign(
|
|
37154
|
+
let ee = Object.assign(
|
|
37155
|
+
[],
|
|
37156
|
+
formSelectMap.value[X].itemRender.options
|
|
37157
|
+
), te = {};
|
|
36853
37158
|
ee.forEach((ne) => {
|
|
36854
37159
|
te[ne.value] = ne;
|
|
36855
37160
|
}), K.data.data.map((ne) => {
|
|
36856
|
-
te[ne.VALUE] || ee.push(
|
|
36857
|
-
|
|
36858
|
-
|
|
36859
|
-
|
|
37161
|
+
te[ne.VALUE] || ee.push(
|
|
37162
|
+
Object.assign({
|
|
37163
|
+
value: ne.VALUE,
|
|
37164
|
+
label: ne.NAME
|
|
37165
|
+
})
|
|
37166
|
+
);
|
|
36860
37167
|
}), formSelectMap.value[X].itemRender.options = ee;
|
|
36861
37168
|
}
|
|
36862
37169
|
});
|
|
@@ -36900,7 +37207,9 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36900
37207
|
}
|
|
36901
37208
|
return G;
|
|
36902
37209
|
}, computeNewLine = (Q) => {
|
|
36903
|
-
let H = Q.columns.filter(
|
|
37210
|
+
let H = Q.columns.filter(
|
|
37211
|
+
(G) => G.type !== "seq" && G.type !== "checkbox" && G.fixed !== "left"
|
|
37212
|
+
);
|
|
36904
37213
|
for (let [G, X] of H.entries())
|
|
36905
37214
|
if (X.visible && X.displayForm) {
|
|
36906
37215
|
X.width = X.width ? X.width : 12;
|
|
@@ -36913,7 +37222,7 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36913
37222
|
return __expose({ submitData, validateDataChg, getValue, getRegion, getData }), (Q, H) => {
|
|
36914
37223
|
const G = resolveComponent("vxe-form-item"), X = resolveComponent("el-icon"), Z = resolveComponent("el-button"), K = resolveComponent("vxe-form");
|
|
36915
37224
|
return openBlock(), createElementBlock("div", _hoisted_1$kV, [
|
|
36916
|
-
unref(formConfig).params.showTitle && unref(formConfig).type === "FORM" ? (openBlock(), createElementBlock("div", _hoisted_2$kR, toDisplayString(unref(formConfig).params.windowTitle), 1)) : createCommentVNode("", !0),
|
|
37225
|
+
unref(formConfig).params.showTitle && unref(formConfig).type === "FORM" ? (openBlock(), createElementBlock("div", _hoisted_2$kR, toDisplayString(unref($T)(unref(formConfig).params.windowTitle)), 1)) : createCommentVNode("", !0),
|
|
36917
37226
|
createVNode(K, {
|
|
36918
37227
|
ref_key: "form",
|
|
36919
37228
|
ref: form,
|
|
@@ -36931,7 +37240,7 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36931
37240
|
ee.colType !== "showInGrid" ? (openBlock(), createBlock(G, {
|
|
36932
37241
|
key: 0,
|
|
36933
37242
|
field: ee.field,
|
|
36934
|
-
title: ee.title,
|
|
37243
|
+
title: unref($T)(ee.title),
|
|
36935
37244
|
"title-overflow": "tooltip",
|
|
36936
37245
|
span: computeSpan.value(ee),
|
|
36937
37246
|
"item-render": ee.itemRender,
|
|
@@ -36949,7 +37258,10 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36949
37258
|
ref: localEditor,
|
|
36950
37259
|
modelValue: unref(formData)[ee.field],
|
|
36951
37260
|
"onUpdate:modelValue": (te) => unref(formData)[ee.field] = te,
|
|
36952
|
-
extensions: [
|
|
37261
|
+
extensions: [
|
|
37262
|
+
getCodeLanguagePlugin(ee.language),
|
|
37263
|
+
unref(EditorView$1).lineWrapping
|
|
37264
|
+
],
|
|
36953
37265
|
"auto-destroy": ""
|
|
36954
37266
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "extensions"])
|
|
36955
37267
|
]),
|
|
@@ -36959,9 +37271,12 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36959
37271
|
name: "title",
|
|
36960
37272
|
fn: withCtx(() => [
|
|
36961
37273
|
createElementVNode("a", {
|
|
36962
|
-
onClick: (te) => linkToMenu({
|
|
37274
|
+
onClick: (te) => linkToMenu({
|
|
37275
|
+
type: ee.title === unref($T)("数据源") ? "dataSource" : "selector",
|
|
37276
|
+
params: { name: unref(formData)["_" + ee.field + "_NAME"] }
|
|
37277
|
+
}),
|
|
36963
37278
|
href: "javascript: void(0)"
|
|
36964
|
-
}, toDisplayString(ee.title), 9, _hoisted_3$hS)
|
|
37279
|
+
}, toDisplayString(unref($T)(ee.title)), 9, _hoisted_3$hS)
|
|
36965
37280
|
]),
|
|
36966
37281
|
key: "1"
|
|
36967
37282
|
} : void 0
|
|
@@ -36975,14 +37290,14 @@ const windowForm_vue_vue_type_style_index_0_lang = "", _hoisted_1$kV = { class:
|
|
|
36975
37290
|
default: withCtx(() => [
|
|
36976
37291
|
(openBlock(!0), createElementBlock(Fragment, null, renderList(buttons.value, (ee) => (openBlock(), createBlock(Z, {
|
|
36977
37292
|
key: ee.id,
|
|
36978
|
-
"auto-insert-space":
|
|
37293
|
+
"auto-insert-space": "",
|
|
36979
37294
|
style: normalizeStyle("margin: 2px 2px 2px 2px;" + ee.css),
|
|
36980
37295
|
type: "primary",
|
|
36981
37296
|
loading: ee.loading,
|
|
36982
37297
|
onClick: (te) => btnClickFun(ee)
|
|
36983
37298
|
}, createSlots({
|
|
36984
37299
|
default: withCtx(() => [
|
|
36985
|
-
createTextVNode(" " + toDisplayString(ee.name), 1)
|
|
37300
|
+
createTextVNode(" " + toDisplayString(unref($T)(ee.name)), 1)
|
|
36986
37301
|
]),
|
|
36987
37302
|
_: 2
|
|
36988
37303
|
}, [
|
|
@@ -37352,7 +37667,7 @@ function P$1(Q, H, G, X, Z, K) {
|
|
|
37352
37667
|
renderSlot(Q.$slots, "default")
|
|
37353
37668
|
], 4);
|
|
37354
37669
|
}
|
|
37355
|
-
const g$1 = /* @__PURE__ */ S$1(x$1, [["render", P$1]]), splitpanes = "",
|
|
37670
|
+
const g$1 = /* @__PURE__ */ S$1(x$1, [["render", P$1]]), splitpanes = "", windowLayout_vue_vue_type_style_index_0_scoped_9ab267f0_lang = "", _withScopeId$1 = (Q) => (pushScopeId("data-v-9ab267f0"), Q = Q(), popScopeId(), Q), _hoisted_1$kU = { class: "slw-window-layout-container" }, _sfc_main$4 = {
|
|
37356
37671
|
__name: "window-layout",
|
|
37357
37672
|
props: {
|
|
37358
37673
|
layoutData: {
|
|
@@ -37362,68 +37677,68 @@ const g$1 = /* @__PURE__ */ S$1(x$1, [["render", P$1]]), splitpanes = "", window
|
|
|
37362
37677
|
},
|
|
37363
37678
|
emits: ["update:layoutData"],
|
|
37364
37679
|
setup(Q, { expose: H, emit: G }) {
|
|
37365
|
-
const X = Q, Z = inject("$componentMapping");
|
|
37366
|
-
let
|
|
37367
|
-
const
|
|
37368
|
-
|
|
37369
|
-
}, 100),
|
|
37370
|
-
if (
|
|
37371
|
-
if (
|
|
37372
|
-
let
|
|
37373
|
-
|
|
37680
|
+
const X = Q, Z = inject("$componentMapping"), K = inject("$t");
|
|
37681
|
+
let ee = useVModel(X, "layoutData", G), te = ref(0);
|
|
37682
|
+
const ne = useDebounceFn((ce) => {
|
|
37683
|
+
re(ce);
|
|
37684
|
+
}, 100), re = (ce) => {
|
|
37685
|
+
if (ce) {
|
|
37686
|
+
if (ee.value.child[0].splitRate = ce[0].size / 100, ee.value.mode === "vertical" && ee.value.child && ee.value.child.length === 2 && ee.value.child[0].gridData) {
|
|
37687
|
+
let de = ee.value.child[0].gridData.params.curHeight - ee.value.height * ee.value.splitRate;
|
|
37688
|
+
ee.value.child[0].gridData.params.curHeight = ee.value.height * ee.value.splitRate, ee.value.child[0].height = ee.value.child[0].gridData.params.curHeight, Number(ee.value.child[0].gridData.params.curHeight) !== Number(te.value) && oe(ee.value.child[1], de), te.value = Number(ee.value.child[0].gridData.params.curHeight);
|
|
37374
37689
|
}
|
|
37375
|
-
|
|
37376
|
-
|
|
37690
|
+
ee.value.mode === "horizontal" && ee.value.child.forEach((de, he) => {
|
|
37691
|
+
de.gridData && (de.gridData.params.singleRow = !1, de.gridData.type == "FORM" && ce[he].size <= ce[he].min + 5 && (de.gridData.params.singleRow = !0));
|
|
37377
37692
|
});
|
|
37378
37693
|
}
|
|
37379
|
-
},
|
|
37380
|
-
if (
|
|
37381
|
-
|
|
37694
|
+
}, oe = (ce, de) => {
|
|
37695
|
+
if (ce.gridData)
|
|
37696
|
+
ce.gridData.params.curHeight += de, ce.height += de;
|
|
37382
37697
|
else {
|
|
37383
|
-
|
|
37384
|
-
for (let
|
|
37385
|
-
|
|
37698
|
+
ce.height += de;
|
|
37699
|
+
for (let he = 0; he < ce.child.length; he++)
|
|
37700
|
+
oe(ce.child[he], de);
|
|
37386
37701
|
}
|
|
37387
|
-
},
|
|
37388
|
-
var
|
|
37389
|
-
(
|
|
37702
|
+
}, ae = ref(), le = (ce, de) => {
|
|
37703
|
+
var he;
|
|
37704
|
+
(he = ae.value) == null || he.gridReload(ce, de);
|
|
37390
37705
|
};
|
|
37391
37706
|
onMounted(() => {
|
|
37392
37707
|
});
|
|
37393
|
-
const
|
|
37394
|
-
return H({ gridReload:
|
|
37395
|
-
const
|
|
37708
|
+
const se = ref();
|
|
37709
|
+
return H({ gridReload: le }), (ce, de) => {
|
|
37710
|
+
const he = resolveComponent("window-layout", !0), ue = resolveComponent("el-tab-pane"), pe = resolveComponent("el-tabs");
|
|
37396
37711
|
return openBlock(), createElementBlock("div", _hoisted_1$kU, [
|
|
37397
|
-
unref(
|
|
37712
|
+
unref(ee).child && unref(ee).child.length > 0 && unref(ee).mode !== "tab" ? (openBlock(), createBlock(unref(M$1), {
|
|
37398
37713
|
key: 0,
|
|
37399
37714
|
class: "default-theme",
|
|
37400
|
-
horizontal: unref(
|
|
37715
|
+
horizontal: unref(ee).mode !== "horizontal",
|
|
37401
37716
|
"push-other-panes": !1,
|
|
37402
37717
|
style: { backgroundColor: "#fff" },
|
|
37403
|
-
onResize: unref(
|
|
37718
|
+
onResize: unref(ne)
|
|
37404
37719
|
}, {
|
|
37405
37720
|
default: withCtx(() => [
|
|
37406
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(
|
|
37407
|
-
key:
|
|
37408
|
-
size:
|
|
37409
|
-
"min-size":
|
|
37721
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(ee).child, (fe, me) => (openBlock(), createBlock(unref(g$1), {
|
|
37722
|
+
key: fe.id,
|
|
37723
|
+
size: fe.splitRate * 100,
|
|
37724
|
+
"min-size": fe.gridData && fe.gridData.type === "FORM" ? 20 : 0
|
|
37410
37725
|
}, {
|
|
37411
37726
|
default: withCtx(() => [
|
|
37412
|
-
|
|
37413
|
-
key:
|
|
37727
|
+
fe.mode === "tab" ? (openBlock(), createBlock(pe, {
|
|
37728
|
+
key: fe.id
|
|
37414
37729
|
}, {
|
|
37415
37730
|
default: withCtx(() => [
|
|
37416
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(
|
|
37417
|
-
key:
|
|
37418
|
-
tab:
|
|
37419
|
-
label:
|
|
37420
|
-
title:
|
|
37731
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(fe.child, (ve, ge) => (openBlock(), createBlock(ue, {
|
|
37732
|
+
key: ve.id,
|
|
37733
|
+
tab: unref(K)(ve.name),
|
|
37734
|
+
label: unref(K)(ve.name),
|
|
37735
|
+
title: unref(K)(ve.name),
|
|
37421
37736
|
forceRender: !0
|
|
37422
37737
|
}, {
|
|
37423
37738
|
default: withCtx(() => [
|
|
37424
|
-
createVNode(
|
|
37425
|
-
"layout-data":
|
|
37426
|
-
"onUpdate:layoutData": (
|
|
37739
|
+
createVNode(he, {
|
|
37740
|
+
"layout-data": fe.child[ge],
|
|
37741
|
+
"onUpdate:layoutData": (_e) => fe.child[ge] = _e
|
|
37427
37742
|
}, null, 8, ["layout-data", "onUpdate:layoutData"])
|
|
37428
37743
|
]),
|
|
37429
37744
|
_: 2
|
|
@@ -37431,32 +37746,32 @@ const g$1 = /* @__PURE__ */ S$1(x$1, [["render", P$1]]), splitpanes = "", window
|
|
|
37431
37746
|
]),
|
|
37432
37747
|
_: 2
|
|
37433
37748
|
}, 1024)) : createCommentVNode("", !0),
|
|
37434
|
-
|
|
37749
|
+
fe.mode !== "tab" ? (openBlock(), createBlock(he, mergeProps$1({
|
|
37435
37750
|
key: 1,
|
|
37436
|
-
"layout-data": unref(
|
|
37437
|
-
"onUpdate:layoutData": (
|
|
37438
|
-
},
|
|
37751
|
+
"layout-data": unref(ee).child[me],
|
|
37752
|
+
"onUpdate:layoutData": (ve) => unref(ee).child[me] = ve
|
|
37753
|
+
}, ce.$attrs), null, 16, ["layout-data", "onUpdate:layoutData"])) : createCommentVNode("", !0)
|
|
37439
37754
|
]),
|
|
37440
37755
|
_: 2
|
|
37441
37756
|
}, 1032, ["size", "min-size"]))), 128))
|
|
37442
37757
|
]),
|
|
37443
37758
|
_: 1
|
|
37444
37759
|
}, 8, ["horizontal", "onResize"])) : createCommentVNode("", !0),
|
|
37445
|
-
unref(
|
|
37446
|
-
key: unref(
|
|
37760
|
+
unref(ee).child && unref(ee).child.length > 0 && unref(ee).mode === "tab" ? (openBlock(), createBlock(pe, {
|
|
37761
|
+
key: unref(ee).id
|
|
37447
37762
|
}, {
|
|
37448
37763
|
default: withCtx(() => [
|
|
37449
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(
|
|
37764
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(ee).child, (fe, me) => (openBlock(), createBlock(ue, {
|
|
37450
37765
|
forceRender: !0,
|
|
37451
|
-
key:
|
|
37452
|
-
tab:
|
|
37453
|
-
label:
|
|
37454
|
-
title:
|
|
37766
|
+
key: fe.id,
|
|
37767
|
+
tab: unref(K)(fe.name),
|
|
37768
|
+
label: unref(K)(fe.name),
|
|
37769
|
+
title: unref(K)(fe.name)
|
|
37455
37770
|
}, {
|
|
37456
37771
|
default: withCtx(() => [
|
|
37457
|
-
createVNode(
|
|
37458
|
-
"layout-data": unref(
|
|
37459
|
-
"onUpdate:layoutData": (
|
|
37772
|
+
createVNode(he, {
|
|
37773
|
+
"layout-data": unref(ee).child[me],
|
|
37774
|
+
"onUpdate:layoutData": (ve) => unref(ee).child[me] = ve
|
|
37460
37775
|
}, null, 8, ["layout-data", "onUpdate:layoutData"])
|
|
37461
37776
|
]),
|
|
37462
37777
|
_: 2
|
|
@@ -37464,31 +37779,31 @@ const g$1 = /* @__PURE__ */ S$1(x$1, [["render", P$1]]), splitpanes = "", window
|
|
|
37464
37779
|
]),
|
|
37465
37780
|
_: 1
|
|
37466
37781
|
})) : createCommentVNode("", !0),
|
|
37467
|
-
unref(
|
|
37468
|
-
unref(
|
|
37782
|
+
unref(ee).gridData && (!unref(ee).child || unref(ee).child.length === 0) ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
37783
|
+
unref(ee).gridData.type === "GRID" || unref(ee).gridData.type === "EDIT_GRID" || unref(ee).gridData.type === "TREE" || unref(ee).gridData.type === "TREE_STRUCTURE" ? (openBlock(), createBlock(unref(WindowGrid), mergeProps$1({
|
|
37469
37784
|
key: 0,
|
|
37470
37785
|
ref_key: "xGrid",
|
|
37471
|
-
ref:
|
|
37472
|
-
gridData: unref(
|
|
37473
|
-
"onUpdate:gridData":
|
|
37474
|
-
},
|
|
37475
|
-
unref(
|
|
37786
|
+
ref: ae,
|
|
37787
|
+
gridData: unref(ee).gridData,
|
|
37788
|
+
"onUpdate:gridData": de[0] || (de[0] = (fe) => unref(ee).gridData = fe)
|
|
37789
|
+
}, ce.$attrs), null, 16, ["gridData"])) : createCommentVNode("", !0),
|
|
37790
|
+
unref(ee).gridData.type === "FORM" ? (openBlock(), createBlock(unref(_sfc_main$5), {
|
|
37476
37791
|
key: 1,
|
|
37477
37792
|
ref_key: "xForm",
|
|
37478
|
-
ref:
|
|
37479
|
-
"form-config": unref(
|
|
37480
|
-
"onUpdate:formConfig":
|
|
37481
|
-
onGridReload:
|
|
37793
|
+
ref: se,
|
|
37794
|
+
"form-config": unref(ee).gridData,
|
|
37795
|
+
"onUpdate:formConfig": de[1] || (de[1] = (fe) => unref(ee).gridData = fe),
|
|
37796
|
+
onGridReload: le
|
|
37482
37797
|
}, null, 8, ["form-config"])) : createCommentVNode("", !0),
|
|
37483
|
-
unref(
|
|
37798
|
+
unref(ee).gridData.type == "LINK" ? (openBlock(), createBlock(resolveDynamicComponent(unref(ee).gridData.params.linkComponentView), {
|
|
37484
37799
|
key: 2,
|
|
37485
|
-
componentData: unref(
|
|
37800
|
+
componentData: unref(ee).gridData.params
|
|
37486
37801
|
}, null, 8, ["componentData"])) : createCommentVNode("", !0)
|
|
37487
37802
|
], 64)) : createCommentVNode("", !0)
|
|
37488
37803
|
]);
|
|
37489
37804
|
};
|
|
37490
37805
|
}
|
|
37491
|
-
}, WindowLayout = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-
|
|
37806
|
+
}, WindowLayout = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-9ab267f0"]]);
|
|
37492
37807
|
WindowLayout.name = "slw-window-layout";
|
|
37493
37808
|
WindowLayout.install = (Q) => {
|
|
37494
37809
|
Q.component(WindowLayout.name, WindowLayout);
|
|
@@ -37507,30 +37822,34 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
|
|
|
37507
37822
|
},
|
|
37508
37823
|
emits: ["close"],
|
|
37509
37824
|
setup(Q, { emit: H }) {
|
|
37510
|
-
const G = Q, X = inject("$componentMapping"), Z = inject("$base64Encode"), K = inject("$base64Decode");
|
|
37511
|
-
let
|
|
37512
|
-
const
|
|
37513
|
-
|
|
37825
|
+
const G = Q, X = inject("$componentMapping"), Z = inject("$base64Encode"), K = inject("$base64Decode"), ee = inject("$t");
|
|
37826
|
+
let te = ref(!1), ne = shallowRef(), re = ref(!1), oe = ref(1e3), ae = ref({}), le = ref(500), se = ref(400), ce = ref();
|
|
37827
|
+
const de = inject("$components"), he = inject("$componentsPath"), ue = () => {
|
|
37828
|
+
te.value = !1;
|
|
37514
37829
|
};
|
|
37515
|
-
watch(
|
|
37516
|
-
|
|
37517
|
-
|
|
37518
|
-
|
|
37830
|
+
watch(
|
|
37831
|
+
() => G.actionData,
|
|
37832
|
+
async (fe) => {
|
|
37833
|
+
fe.type === "show" ? (te.value = !0, fe.params && typeof fe.params.width < "u" && (le.value = fe.params.width), fe.params && typeof fe.params.height < "u" && (se.value = fe.params.height), fe.params && typeof fe.params.fullscreen < "u" && (re.value = fe.params.fullscreen), fe.params && typeof fe.params.zIndex < "u" && (oe.value = fe.params.zIndex), ae.value = XEUtils$1.clone(toRaw(fe.params), !0), fe.showComponent && (ne.value = (await de[`${he}/${fe.showComponent}`]()).default)) : te.value = !1;
|
|
37834
|
+
},
|
|
37835
|
+
{ deep: !0 }
|
|
37836
|
+
);
|
|
37837
|
+
function pe() {
|
|
37519
37838
|
H("close");
|
|
37520
37839
|
}
|
|
37521
|
-
return (
|
|
37522
|
-
const
|
|
37523
|
-
return openBlock(), createBlock(
|
|
37840
|
+
return (fe, me) => {
|
|
37841
|
+
const ve = resolveComponent("el-dialog");
|
|
37842
|
+
return openBlock(), createBlock(ve, {
|
|
37524
37843
|
ref_key: "selfModal",
|
|
37525
|
-
ref:
|
|
37526
|
-
width: unref(
|
|
37527
|
-
height: unref(
|
|
37528
|
-
modelValue: unref(
|
|
37529
|
-
"onUpdate:modelValue":
|
|
37530
|
-
visible: unref(
|
|
37531
|
-
"onUpdate:visible":
|
|
37532
|
-
fullscreen: unref(
|
|
37533
|
-
"z-index": unref(
|
|
37844
|
+
ref: ce,
|
|
37845
|
+
width: unref(le),
|
|
37846
|
+
height: unref(se),
|
|
37847
|
+
modelValue: unref(te),
|
|
37848
|
+
"onUpdate:modelValue": me[0] || (me[0] = (ge) => isRef(te) ? te.value = ge : te = ge),
|
|
37849
|
+
visible: unref(te),
|
|
37850
|
+
"onUpdate:visible": me[1] || (me[1] = (ge) => isRef(te) ? te.value = ge : te = ge),
|
|
37851
|
+
fullscreen: unref(re),
|
|
37852
|
+
"z-index": unref(oe),
|
|
37534
37853
|
draggable: "",
|
|
37535
37854
|
footer: null,
|
|
37536
37855
|
"append-to-body": "",
|
|
@@ -37538,9 +37857,9 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
|
|
|
37538
37857
|
resize: "",
|
|
37539
37858
|
"close-on-press-escape": "",
|
|
37540
37859
|
"destroy-on-close": "",
|
|
37541
|
-
onShow:
|
|
37542
|
-
title: Q.title,
|
|
37543
|
-
onClosed:
|
|
37860
|
+
onShow: me[2] || (me[2] = (ge) => unref(re) ? unref(ce).maximize() : null),
|
|
37861
|
+
title: unref(ee)(Q.title),
|
|
37862
|
+
onClosed: pe
|
|
37544
37863
|
}, {
|
|
37545
37864
|
default: withCtx(() => [
|
|
37546
37865
|
Q.actionData.showComponent && Q.actionData.showComponent.indexOf("http") !== -1 ? (openBlock(), createElementBlock("iframe", {
|
|
@@ -37551,10 +37870,10 @@ const _hoisted_1$kT = ["src"], _sfc_main$3 = {
|
|
|
37551
37870
|
height: "100%",
|
|
37552
37871
|
scrolling: "auto",
|
|
37553
37872
|
style: { "background-color": "#fff" }
|
|
37554
|
-
}, null, 8, _hoisted_1$kT)) : (openBlock(), createBlock(resolveDynamicComponent(unref(
|
|
37873
|
+
}, null, 8, _hoisted_1$kT)) : (openBlock(), createBlock(resolveDynamicComponent(unref(ne)), {
|
|
37555
37874
|
key: 1,
|
|
37556
|
-
componentData: unref(
|
|
37557
|
-
onClose:
|
|
37875
|
+
componentData: unref(ae),
|
|
37876
|
+
onClose: ue
|
|
37558
37877
|
}, null, 40, ["componentData"]))
|
|
37559
37878
|
]),
|
|
37560
37879
|
_: 1
|
|
@@ -37579,23 +37898,27 @@ const _hoisted_1$kS = ["src"], _sfc_main$2 = {
|
|
|
37579
37898
|
}
|
|
37580
37899
|
},
|
|
37581
37900
|
setup(Q) {
|
|
37582
|
-
const H = Q, G = inject("$componentMapping"), X = inject("$components"), Z = inject("$componentsPath");
|
|
37583
|
-
let
|
|
37584
|
-
const
|
|
37585
|
-
return watch(
|
|
37586
|
-
|
|
37587
|
-
|
|
37588
|
-
|
|
37589
|
-
|
|
37901
|
+
const H = Q, G = inject("$componentMapping"), X = inject("$components"), Z = inject("$componentsPath"), K = inject("$t");
|
|
37902
|
+
let ee = ref(!1), te = ref(""), ne = ref(!1), re = ref({}), oe = ref(500), ae = ref(400);
|
|
37903
|
+
const le = ref();
|
|
37904
|
+
return watch(
|
|
37905
|
+
() => H.actionData,
|
|
37906
|
+
async (se) => {
|
|
37907
|
+
se.type === "show" ? (ee.value = !0, se.params && typeof se.params.width < "u" && (oe.value = se.params.width), se.params && typeof se.params.height < "u" && (ae.value = se.params.height), se.params && typeof se.params.fullscreen < "u" && (ne.value = se.params.fullscreen), re.value = XEUtils$1.clone(toRaw(se.params), !0), se.showComponent && (te.value = (await X[`${Z}/${se.showComponent}`]()).default)) : ee.value = !1;
|
|
37908
|
+
},
|
|
37909
|
+
{ deep: !0 }
|
|
37910
|
+
), (se, ce) => {
|
|
37911
|
+
const de = resolveComponent("el-dialog");
|
|
37912
|
+
return openBlock(), createBlock(de, {
|
|
37590
37913
|
ref_key: "selfModal",
|
|
37591
|
-
ref:
|
|
37592
|
-
width: unref(
|
|
37593
|
-
height: unref(
|
|
37594
|
-
modelValue: unref(
|
|
37595
|
-
"onUpdate:modelValue":
|
|
37596
|
-
visible: unref(
|
|
37597
|
-
"onUpdate:visible":
|
|
37598
|
-
fullscreen: unref(
|
|
37914
|
+
ref: le,
|
|
37915
|
+
width: unref(oe),
|
|
37916
|
+
height: unref(ae),
|
|
37917
|
+
modelValue: unref(ee),
|
|
37918
|
+
"onUpdate:modelValue": ce[0] || (ce[0] = (he) => isRef(ee) ? ee.value = he : ee = he),
|
|
37919
|
+
visible: unref(ee),
|
|
37920
|
+
"onUpdate:visible": ce[1] || (ce[1] = (he) => isRef(ee) ? ee.value = he : ee = he),
|
|
37921
|
+
fullscreen: unref(ne),
|
|
37599
37922
|
zIndex: 1e3,
|
|
37600
37923
|
draggable: "",
|
|
37601
37924
|
footer: null,
|
|
@@ -37605,8 +37928,8 @@ const _hoisted_1$kS = ["src"], _sfc_main$2 = {
|
|
|
37605
37928
|
"esc-closable": "",
|
|
37606
37929
|
"destroy-on-close": "",
|
|
37607
37930
|
destroyOnClose: "",
|
|
37608
|
-
onShow:
|
|
37609
|
-
title: Q.title
|
|
37931
|
+
onShow: ce[2] || (ce[2] = (he) => unref(ne) ? le.value.maximize() : null),
|
|
37932
|
+
title: unref(K)(Q.title)
|
|
37610
37933
|
}, {
|
|
37611
37934
|
default: withCtx(() => [
|
|
37612
37935
|
Q.actionData.showComponent && Q.actionData.showComponent.indexOf("http") !== -1 ? (openBlock(), createElementBlock("iframe", {
|
|
@@ -37617,9 +37940,9 @@ const _hoisted_1$kS = ["src"], _sfc_main$2 = {
|
|
|
37617
37940
|
height: "100%",
|
|
37618
37941
|
scrolling: "auto",
|
|
37619
37942
|
style: { "background-color": "#fff" }
|
|
37620
|
-
}, null, 8, _hoisted_1$kS)) : (openBlock(), createBlock(resolveDynamicComponent(unref(
|
|
37943
|
+
}, null, 8, _hoisted_1$kS)) : (openBlock(), createBlock(resolveDynamicComponent(unref(te)), {
|
|
37621
37944
|
key: 1,
|
|
37622
|
-
componentData: unref(
|
|
37945
|
+
componentData: unref(re)
|
|
37623
37946
|
}, null, 8, ["componentData"]))
|
|
37624
37947
|
]),
|
|
37625
37948
|
_: 1
|
|
@@ -37631,7 +37954,7 @@ _sfc_main$2.name = "slw-preview-modal";
|
|
|
37631
37954
|
_sfc_main$2.install = (Q) => {
|
|
37632
37955
|
Q.component(_sfc_main$2.name, _sfc_main$2);
|
|
37633
37956
|
};
|
|
37634
|
-
const
|
|
37957
|
+
const windowIndex_vue_vue_type_style_index_0_scoped_0132f153_lang = "", _withScopeId = (Q) => (pushScopeId("data-v-0132f153"), Q = Q(), popScopeId(), Q), _hoisted_1$kR = { class: "slw-config-window-container" }, _hoisted_2$kQ = { class: "child-table-p" }, _sfc_main$1 = {
|
|
37635
37958
|
__name: "window-index",
|
|
37636
37959
|
props: {
|
|
37637
37960
|
windowId: {
|
|
@@ -37645,11 +37968,7 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
37645
37968
|
type: Object
|
|
37646
37969
|
}
|
|
37647
37970
|
},
|
|
37648
|
-
emits: [
|
|
37649
|
-
"update:queryParams",
|
|
37650
|
-
"on-load-success",
|
|
37651
|
-
"close"
|
|
37652
|
-
],
|
|
37971
|
+
emits: ["update:queryParams", "on-load-success", "close"],
|
|
37653
37972
|
setup(__props, { emit }) {
|
|
37654
37973
|
const props = __props, componentMapping = inject("$componentMapping");
|
|
37655
37974
|
let queryParams = useVModel(props, "queryParams", emit);
|
|
@@ -37940,7 +38259,10 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
37940
38259
|
childRegionCode: Z.childRegionCode
|
|
37941
38260
|
}, Z.linkUrl && $components && $componentsPath) {
|
|
37942
38261
|
let ae = `${$componentsPath}/${Z.linkUrl}`, le = await $components[ae]();
|
|
37943
|
-
X.params.linkComponentView = le.default, console.info(
|
|
38262
|
+
X.params.linkComponentView = le.default, console.info(
|
|
38263
|
+
X.params.linkComponentView,
|
|
38264
|
+
"gridData.params.linkComponentView"
|
|
38265
|
+
);
|
|
37944
38266
|
}
|
|
37945
38267
|
queryParams.value && (X.params.queryParams = Object.assign({}, queryParams.value), X.params.parentData = Object.assign({}, queryParams.value)), [void 0, null].includes(Z.pageSize) || (Z.pageSize === 0 && (X.pagerConfig.enabled = !1), X.pagerConfig.pageSize = Z.pageSize), X.type === "EDIT_GRID" && (X.editConfig.trigger = "click", X.editConfig.mode = "cell", X.editConfig.enabled = !0, X.toolbarConfig.refresh = !1);
|
|
37946
38268
|
let K = Z.querys;
|
|
@@ -38483,14 +38805,14 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
38483
38805
|
header: withCtx(() => [
|
|
38484
38806
|
createVNode(ne, null, {
|
|
38485
38807
|
default: withCtx(() => [
|
|
38486
|
-
createElementVNode("span", null, toDisplayString(unref(formConfig).windowTitle), 1),
|
|
38808
|
+
createElementVNode("span", null, toDisplayString(unref($T)(unref(formConfig).windowTitle)), 1),
|
|
38487
38809
|
unref(formConfig).openType === "edit" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
38488
38810
|
createVNode(G, {
|
|
38489
38811
|
modelValue: unref(isAutoSave),
|
|
38490
38812
|
"onUpdate:modelValue": H[1] || (H[1] = (he) => isRef(isAutoSave) ? isAutoSave.value = he : isAutoSave = he),
|
|
38491
38813
|
style: { "margin-left": "30px" },
|
|
38492
|
-
label: "自动保存"
|
|
38493
|
-
}, null, 8, ["modelValue"]),
|
|
38814
|
+
label: unref($T)("自动保存")
|
|
38815
|
+
}, null, 8, ["modelValue", "label"]),
|
|
38494
38816
|
createVNode(te, null, {
|
|
38495
38817
|
default: withCtx(() => [
|
|
38496
38818
|
createVNode(K, {
|
|
@@ -38562,15 +38884,15 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
38562
38884
|
onGridReload: H[5] || (H[5] = () => unref(formConfig)._reload())
|
|
38563
38885
|
}, null, 8, ["form-config"])),
|
|
38564
38886
|
unref(formConfig).params.addChildData && unref(formConfig).childForm ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
38565
|
-
_hoisted_2$kQ,
|
|
38887
|
+
createElementVNode("p", _hoisted_2$kQ, toDisplayString(unref($T)("[新增] 关联子表数据")), 1),
|
|
38566
38888
|
createVNode(oe, { class: "child-tab" }, {
|
|
38567
38889
|
default: withCtx(() => [
|
|
38568
38890
|
(openBlock(!0), createElementBlock(Fragment, null, renderList(Object.values(unref(formConfig).childForm), (he, ue) => (openBlock(), createBlock(re, {
|
|
38569
38891
|
class: "child-tab-pane",
|
|
38570
38892
|
key: he.id,
|
|
38571
|
-
tab: he.name,
|
|
38572
|
-
label: he.name,
|
|
38573
|
-
title: he.name,
|
|
38893
|
+
tab: unref($T)(he.name),
|
|
38894
|
+
label: unref($T)(he.name),
|
|
38895
|
+
title: unref($T)(he.name),
|
|
38574
38896
|
forceRender: !0
|
|
38575
38897
|
}, {
|
|
38576
38898
|
default: withCtx(() => [
|
|
@@ -38615,7 +38937,7 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
38615
38937
|
})
|
|
38616
38938
|
]),
|
|
38617
38939
|
default: withCtx(() => [
|
|
38618
|
-
createTextVNode("
|
|
38940
|
+
createTextVNode(toDisplayString(unref($T)("保存")) + " ", 1)
|
|
38619
38941
|
]),
|
|
38620
38942
|
_: 1
|
|
38621
38943
|
}, 8, ["loading"]),
|
|
@@ -38635,7 +38957,7 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
38635
38957
|
})
|
|
38636
38958
|
]),
|
|
38637
38959
|
default: withCtx(() => [
|
|
38638
|
-
createTextVNode("
|
|
38960
|
+
createTextVNode(toDisplayString(unref($T)("取消")) + " ", 1)
|
|
38639
38961
|
]),
|
|
38640
38962
|
_: 1
|
|
38641
38963
|
})
|
|
@@ -38693,13 +39015,13 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
38693
39015
|
onClick: preViewSubmit
|
|
38694
39016
|
}, {
|
|
38695
39017
|
default: withCtx(() => [
|
|
38696
|
-
createTextVNode("
|
|
39018
|
+
createTextVNode(toDisplayString(unref($T)("提交")), 1)
|
|
38697
39019
|
]),
|
|
38698
39020
|
_: 1
|
|
38699
39021
|
}),
|
|
38700
39022
|
createVNode(K, { onClick: closePreModal }, {
|
|
38701
39023
|
default: withCtx(() => [
|
|
38702
|
-
createTextVNode("
|
|
39024
|
+
createTextVNode(toDisplayString(unref($T)("取消")), 1)
|
|
38703
39025
|
]),
|
|
38704
39026
|
_: 1
|
|
38705
39027
|
})
|
|
@@ -38719,7 +39041,7 @@ const windowIndex_vue_vue_type_style_index_0_scoped_405f4826_lang = "", _withSco
|
|
|
38719
39041
|
]);
|
|
38720
39042
|
};
|
|
38721
39043
|
}
|
|
38722
|
-
}, WindowIndex = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-
|
|
39044
|
+
}, WindowIndex = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-0132f153"]]);
|
|
38723
39045
|
WindowIndex.name = "slw-window-index";
|
|
38724
39046
|
WindowIndex.install = (Q) => {
|
|
38725
39047
|
Q.component(WindowIndex.name, WindowIndex);
|