@wx-design/components 1.4.0-alpha.1 → 1.4.0-alpha.2
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/es/index.mjs +837 -829
- package/lib/index.js +5 -5
- package/package.json +1 -1
package/es/index.mjs
CHANGED
|
@@ -4228,7 +4228,7 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4228
4228
|
}
|
|
4229
4229
|
},
|
|
4230
4230
|
setup(e) {
|
|
4231
|
-
const t = mt("$xeTable", {}), n = mt("xesize", null), { xID: o, props: r, context: s, reactData: a, internalData: c } = t, { refTableBody: f, refTableHeader: u, refTableFooter: d, refTableLeftBody: p, refTableRightBody: g, refScrollXHandleElem: h, refScrollYHandleElem: w } = t.getRefMaps(), { computeEditOpts: S, computeMouseOpts: E, computeAreaOpts: v, computeSYOpts: D, computeEmptyOpts: y, computeTooltipOpts: b, computeRadioOpts: x, computeExpandOpts: C, computeTreeOpts: M, computeCheckboxOpts: F, computeCellOpts: H, computeValidOpts: U, computeRowOpts: ne, computeColumnOpts: j, computeRowDragOpts: L, computeColumnDragOpts: B } = t.getComputeMaps(), ue = Te(), Q = Te(), P = Te(), z = Te(),
|
|
4231
|
+
const t = mt("$xeTable", {}), n = mt("xesize", null), { xID: o, props: r, context: s, reactData: a, internalData: c } = t, { refTableBody: f, refTableHeader: u, refTableFooter: d, refTableLeftBody: p, refTableRightBody: g, refScrollXHandleElem: h, refScrollYHandleElem: w } = t.getRefMaps(), { computeEditOpts: S, computeMouseOpts: E, computeAreaOpts: v, computeSYOpts: D, computeEmptyOpts: y, computeTooltipOpts: b, computeRadioOpts: x, computeExpandOpts: C, computeTreeOpts: M, computeCheckboxOpts: F, computeCellOpts: H, computeValidOpts: U, computeRowOpts: ne, computeColumnOpts: j, computeRowDragOpts: L, computeColumnDragOpts: B } = t.getComputeMaps(), ue = Te(), Q = Te(), P = Te(), z = Te(), V = Te(), I = Te(), Z = Te(), ie = () => {
|
|
4232
4232
|
if (n) {
|
|
4233
4233
|
const He = n.value;
|
|
4234
4234
|
if (He)
|
|
@@ -4503,7 +4503,7 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4503
4503
|
return Dn(() => {
|
|
4504
4504
|
pe(() => {
|
|
4505
4505
|
const { fixedType: He } = e, { elemStore: Ge } = c, at = `${He || "main"}-body-`;
|
|
4506
|
-
Ge[`${at}wrapper`] = ue, Ge[`${at}table`] = Q, Ge[`${at}colgroup`] = P, Ge[`${at}list`] = z, Ge[`${at}xSpace`] =
|
|
4506
|
+
Ge[`${at}wrapper`] = ue, Ge[`${at}table`] = Q, Ge[`${at}colgroup`] = P, Ge[`${at}list`] = z, Ge[`${at}xSpace`] = V, Ge[`${at}ySpace`] = I, Ge[`${at}emptyBlock`] = Z;
|
|
4507
4507
|
});
|
|
4508
4508
|
}), cr(() => {
|
|
4509
4509
|
clearTimeout(oe);
|
|
@@ -4527,7 +4527,7 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4527
4527
|
};
|
|
4528
4528
|
return A.mode === "wheel" && (Le.onWheel = Ye), l("div", Object.assign({ ref: ue, class: ["vxe-table--body-wrapper", Ge ? `fixed-${Ge}--wrapper` : "body--wrapper"], xid: o }, Le), [
|
|
4529
4529
|
Ge ? nf(t) : l("div", {
|
|
4530
|
-
ref:
|
|
4530
|
+
ref: V,
|
|
4531
4531
|
class: "vxe-body--x-space"
|
|
4532
4532
|
}),
|
|
4533
4533
|
l("div", {
|
|
@@ -4621,7 +4621,7 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4621
4621
|
const { isGroup: ne } = r;
|
|
4622
4622
|
S.value = ne ? m_(e.tableGroupColumn) : [];
|
|
4623
4623
|
}, M = (ne, j) => {
|
|
4624
|
-
const { column: L } = j, { fixedType: B } = e, { visibleColumn: ue } = s, Q = w.value, P = c.value, z = a.value,
|
|
4624
|
+
const { column: L } = j, { fixedType: B } = e, { visibleColumn: ue } = s, Q = w.value, P = c.value, z = a.value, V = f.value, I = u.value, Z = d.value, ie = p.value, { clientX: G } = ne, re = E.value, ge = ne.target, De = j.cell = ge.parentNode;
|
|
4625
4625
|
let ae = 0;
|
|
4626
4626
|
const _ = P.$el, Y = d_(ge, re), oe = ge.clientWidth, we = Math.floor(oe / 2), ve = h_(j) - we;
|
|
4627
4627
|
let de = Y.left - De.clientWidth + oe + ve, Ce = Y.left + we;
|
|
@@ -4639,7 +4639,7 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4639
4639
|
const dt = bt.clientX - G;
|
|
4640
4640
|
let gt = Ce + dt;
|
|
4641
4641
|
const pt = B ? 0 : _.scrollLeft;
|
|
4642
|
-
lt ? gt = Math.min(gt, (I ? I.offsetLeft : _.clientWidth) - Ge - ve) : He ? (de = (
|
|
4642
|
+
lt ? gt = Math.min(gt, (I ? I.offsetLeft : _.clientWidth) - Ge - ve) : He ? (de = (V ? V.clientWidth : 0) + Ge + ve, gt = Math.min(gt, Ce + De.clientWidth - ve)) : de = Math.max(_.scrollLeft, de), ae = Math.max(gt, de);
|
|
4643
4643
|
const ke = ae - pt;
|
|
4644
4644
|
if (Z.style.left = `${ke}px`, Q.showDragTip && ie) {
|
|
4645
4645
|
const xe = z.clientWidth, Be = re.getBoundingClientRect(), Oe = Z.clientWidth, Me = ie.clientWidth, $ = ie.clientHeight;
|
|
@@ -4657,9 +4657,9 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4657
4657
|
}), Dr(z, "drag--resize");
|
|
4658
4658
|
}, at(ne), t.closeMenu && t.closeMenu();
|
|
4659
4659
|
}, F = (ne, j) => {
|
|
4660
|
-
const { fixedType: L } = e, { resizable: B, border: ue, columnKey: Q, headerCellClassName: P, headerCellStyle: z, showHeaderOverflow:
|
|
4660
|
+
const { fixedType: L } = e, { resizable: B, border: ue, columnKey: Q, headerCellClassName: P, headerCellStyle: z, showHeaderOverflow: V, headerAlign: I, align: Z, mouseConfig: ie } = o, { currentColumn: G, scrollXLoad: re, scrollYLoad: ge, overflowX: De, scrollbarWidth: ae } = r, _ = g.value, Y = h.value, { disabledMethod: oe } = Y;
|
|
4661
4661
|
return ne.map((we, ve) => {
|
|
4662
|
-
const { type: de, showHeaderOverflow: Ce, headerAlign: je, align: Ye, headerClassName: lt, editRender: He, cellRender: Ge } = we, at = we.id, bt = He || Ge, dt = bt ? O_.get(bt.name) : null, gt = we.children && we.children.length, pt = L ? we.fixed !== L && !gt : !!we.fixed && De, ke = i.eqNull(Ce) ?
|
|
4662
|
+
const { type: de, showHeaderOverflow: Ce, headerAlign: je, align: Ye, headerClassName: lt, editRender: He, cellRender: Ge } = we, at = we.id, bt = He || Ge, dt = bt ? O_.get(bt.name) : null, gt = we.children && we.children.length, pt = L ? we.fixed !== L && !gt : !!we.fixed && De, ke = i.eqNull(Ce) ? V : Ce, xe = je || (dt ? dt.tableHeaderCellAlign : "") || I || Ye || (dt ? dt.tableCellAlign : "") || Z;
|
|
4663
4663
|
let Be = ke === "ellipsis";
|
|
4664
4664
|
const Oe = ke === "title", Me = ke === !0 || ke === "tooltip";
|
|
4665
4665
|
let $ = Oe || Me || Be;
|
|
@@ -4722,10 +4722,10 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4722
4722
|
] : []);
|
|
4723
4723
|
}, H = (ne) => {
|
|
4724
4724
|
const { fixedType: j } = e, { headerRowClassName: L, headerRowStyle: B } = o, { isDragColMove: ue } = r, Q = g.value, P = h.value;
|
|
4725
|
-
return ne.map((z,
|
|
4726
|
-
const I = { $table: t, $rowIndex:
|
|
4725
|
+
return ne.map((z, V) => {
|
|
4726
|
+
const I = { $table: t, $rowIndex: V, fixed: j, type: oh };
|
|
4727
4727
|
return Q.drag && P.animation ? l(is, {
|
|
4728
|
-
key:
|
|
4728
|
+
key: V,
|
|
4729
4729
|
name: `vxe-header--col-list${ue ? "" : "-disabled"}`,
|
|
4730
4730
|
tag: "tr",
|
|
4731
4731
|
class: [
|
|
@@ -4734,20 +4734,20 @@ const S_ = nd, { getI18n: D_, renderer: th, renderEmptyElement: nf } = ye, Us =
|
|
|
4734
4734
|
],
|
|
4735
4735
|
style: B ? i.isFunction(B) ? B(I) : B : null
|
|
4736
4736
|
}, {
|
|
4737
|
-
default: () => F(z,
|
|
4737
|
+
default: () => F(z, V)
|
|
4738
4738
|
}) : l("tr", {
|
|
4739
|
-
key:
|
|
4739
|
+
key: V,
|
|
4740
4740
|
class: [
|
|
4741
4741
|
"vxe-header--row",
|
|
4742
4742
|
L ? i.isFunction(L) ? L(I) : L : ""
|
|
4743
4743
|
],
|
|
4744
4744
|
style: B ? i.isFunction(B) ? B(I) : B : null
|
|
4745
|
-
}, F(z,
|
|
4745
|
+
}, F(z, V));
|
|
4746
4746
|
});
|
|
4747
4747
|
}, U = () => {
|
|
4748
|
-
const { fixedType: ne, fixedColumn: j, tableColumn: L } = e, { showHeaderOverflow: B, spanMethod: ue, footerSpanMethod: Q } = o, { isGroup: P, scrollbarWidth: z } = r, { visibleColumn:
|
|
4748
|
+
const { fixedType: ne, fixedColumn: j, tableColumn: L } = e, { showHeaderOverflow: B, spanMethod: ue, footerSpanMethod: Q } = o, { isGroup: P, scrollbarWidth: z } = r, { visibleColumn: V } = s;
|
|
4749
4749
|
let I = S.value, Z = L;
|
|
4750
|
-
return P ? Z =
|
|
4750
|
+
return P ? Z = V : (ne && (Z = V, B && (ue || Q ? Z = V : Z = j || [])), I = [Z]), l("div", {
|
|
4751
4751
|
ref: E,
|
|
4752
4752
|
class: ["vxe-table--header-wrapper", ne ? `fixed-${ne}--wrapper` : "body--wrapper"],
|
|
4753
4753
|
xid: n
|
|
@@ -4852,7 +4852,7 @@ const lh = rt({
|
|
|
4852
4852
|
fixed: F
|
|
4853
4853
|
});
|
|
4854
4854
|
}, D = (x, C, M, F, H) => {
|
|
4855
|
-
const { fixedType: U } = e, { footerCellClassName: ne, footerCellStyle: j, footerAlign: L, footerSpanMethod: B, align: ue, columnKey: Q, showFooterOverflow: P } = o, { scrollXLoad: z, scrollYLoad:
|
|
4855
|
+
const { fixedType: U } = e, { footerCellClassName: ne, footerCellStyle: j, footerAlign: L, footerSpanMethod: B, align: ue, columnKey: Q, showFooterOverflow: P } = o, { scrollXLoad: z, scrollYLoad: V, overflowX: I, scrollbarWidth: Z, currentColumn: ie, mergeFooterList: G } = r, re = u.value, ge = d.value;
|
|
4856
4856
|
return x.map((De, ae) => {
|
|
4857
4857
|
const { type: _, showFooterOverflow: Y, footerAlign: oe, align: we, footerClassName: ve, editRender: de, cellRender: Ce } = De, je = de || Ce, Ye = je ? $_.get(je.name) : null, lt = re.showAll, He = De.children && De.children.length, Ge = U ? De.fixed !== U && !He : De.fixed && I, at = i.eqNull(Y) ? P : Y, bt = oe || (Ye ? Ye.tableFooterCellAlign : "") || L || we || (Ye ? Ye.tableCellAlign : "") || ue;
|
|
4858
4858
|
let dt = at === "ellipsis";
|
|
@@ -4906,7 +4906,7 @@ const lh = rt({
|
|
|
4906
4906
|
"fixed--hidden": Ge,
|
|
4907
4907
|
"col--ellipsis": ke,
|
|
4908
4908
|
"col--current": ie === De
|
|
4909
|
-
}, ns(ve, te), ns(ne, te)] }, xe), { style: j ? i.isFunction(j) ? j(te) : j : null }), Be), { key: Q || z ||
|
|
4909
|
+
}, ns(ve, te), ns(ne, te)] }, xe), { style: j ? i.isFunction(j) ? j(te) : j : null }), Be), { key: Q || z || V || ge.useKey || ge.drag ? De.id : ae }), [
|
|
4910
4910
|
l("div", {
|
|
4911
4911
|
class: ["vxe-cell", {
|
|
4912
4912
|
"c--title": gt,
|
|
@@ -5392,7 +5392,7 @@ const lh = rt({
|
|
|
5392
5392
|
});
|
|
5393
5393
|
}, z = () => {
|
|
5394
5394
|
a.toggleCustomAllCheckbox();
|
|
5395
|
-
},
|
|
5395
|
+
}, V = (oe, we, ve, de) => {
|
|
5396
5396
|
const Ce = E.value;
|
|
5397
5397
|
if (!Ce)
|
|
5398
5398
|
return;
|
|
@@ -5512,10 +5512,10 @@ const lh = rt({
|
|
|
5512
5512
|
oe.preventDefault();
|
|
5513
5513
|
const dt = oe.clientY - Ye.getBoundingClientRect().y < Ye.clientHeight / 2 ? "top" : "bottom";
|
|
5514
5514
|
if (at && at.id === Ge.id || !Ce && Ge.level > 1 || !ve && Ge.level > 1 || Ge.renderFixed) {
|
|
5515
|
-
|
|
5515
|
+
V(oe, Ye, !1, dt);
|
|
5516
5516
|
return;
|
|
5517
5517
|
}
|
|
5518
|
-
x = !!(je && lt && ve), b = Ge, C = dt,
|
|
5518
|
+
x = !!(je && lt && ve), b = Ge, C = dt, V(oe, Ye, !0, dt);
|
|
5519
5519
|
}
|
|
5520
5520
|
}, De = () => {
|
|
5521
5521
|
const oe = y.value;
|
|
@@ -6335,7 +6335,7 @@ const lh = rt({
|
|
|
6335
6335
|
ue && ue.focus();
|
|
6336
6336
|
}), D();
|
|
6337
6337
|
}, C = () => {
|
|
6338
|
-
const { storeData: j, defaultOptions: L } = e, { hasMerge: B, columns: ue } = j, Q = h.value, P = S.value, z = i.searchTree(ue, (
|
|
6338
|
+
const { storeData: j, defaultOptions: L } = e, { hasMerge: B, columns: ue } = j, Q = h.value, P = S.value, z = i.searchTree(ue, (V) => V.checked, { children: "children", mapChildren: "childNodes", original: !0 });
|
|
6339
6339
|
return Object.assign({}, L, {
|
|
6340
6340
|
columns: z,
|
|
6341
6341
|
isMerge: B && P && Q ? L.isMerge : !1
|
|
@@ -6357,7 +6357,7 @@ const lh = rt({
|
|
|
6357
6357
|
const { storeData: j } = e;
|
|
6358
6358
|
j.isPrint ? M() : F();
|
|
6359
6359
|
}, ne = () => {
|
|
6360
|
-
const { defaultOptions: j, storeData: L } = e, { isAll: B, isIndeterminate: ue } = u, { hasTree: Q, hasMerge: P, isPrint: z, hasColgroup:
|
|
6360
|
+
const { defaultOptions: j, storeData: L } = e, { isAll: B, isIndeterminate: ue } = u, { hasTree: Q, hasMerge: P, isPrint: z, hasColgroup: V, columns: I } = L, { isHeader: Z } = j, ie = [], G = h.value, re = w.value, ge = S.value, De = E.value, ae = j.slots || {}, _ = ae.top, Y = ae.bottom, oe = ae.default, we = ae.footer, ve = ae.parameter;
|
|
6361
6361
|
return i.eachTree(I, (de) => {
|
|
6362
6362
|
const Ce = Do(de.getTitle(), 1), je = de.children && de.children.length, Ye = de.checked, lt = de.halfChecked, He = de.type === "html";
|
|
6363
6363
|
ie.push(l("li", {
|
|
@@ -6559,9 +6559,9 @@ const lh = rt({
|
|
|
6559
6559
|
class: "vxe-table-export--panel-option-row"
|
|
6560
6560
|
}, [
|
|
6561
6561
|
s ? l(s, {
|
|
6562
|
-
modelValue: Z &&
|
|
6562
|
+
modelValue: Z && V && ge ? j.isColgroup : !1,
|
|
6563
6563
|
title: Xn("vxe.export.expColgroupTitle"),
|
|
6564
|
-
disabled: !Z || !
|
|
6564
|
+
disabled: !Z || !V || !ge,
|
|
6565
6565
|
content: Xn("vxe.export.expOptColgroup"),
|
|
6566
6566
|
"onUpdate:modelValue"(Ce) {
|
|
6567
6567
|
j.isColgroup = Ce;
|
|
@@ -7066,7 +7066,7 @@ const lh = rt({
|
|
|
7066
7066
|
isActivated: !1
|
|
7067
7067
|
};
|
|
7068
7068
|
let p = {}, g = {};
|
|
7069
|
-
const h = Te(), w = Te(), S = Te(), E = Te(), v = Te(), D = Te(), y = Te(), b = Te(), x = Te(), C = Te(), M = Te(), F = Te(), H = Te(), U = Te(), ne = Te(), j = Te(), L = Te(), B = Te(), ue = Te(), Q = Te(), P = Te(), z = Te(),
|
|
7069
|
+
const h = Te(), w = Te(), S = Te(), E = Te(), v = Te(), D = Te(), y = Te(), b = Te(), x = Te(), C = Te(), M = Te(), F = Te(), H = Te(), U = Te(), ne = Te(), j = Te(), L = Te(), B = Te(), ue = Te(), Q = Te(), P = Te(), z = Te(), V = Te(), I = Te(), Z = Te(), ie = Te(), G = Te(), re = Te(), ge = Te(), De = Te(), ae = mt("$xeGrid", null);
|
|
7070
7070
|
let _;
|
|
7071
7071
|
const Y = N(() => {
|
|
7072
7072
|
const { id: m } = e;
|
|
@@ -7101,13 +7101,13 @@ const lh = rt({
|
|
|
7101
7101
|
const T = J.value.footer;
|
|
7102
7102
|
return T && T.options ? T.options : [];
|
|
7103
7103
|
}), Le = N(() => {
|
|
7104
|
-
const m = J.value, T = be.value, O = Ee.value,
|
|
7105
|
-
return !!(e.menuConfig && mn(m) && (T.length || O.length ||
|
|
7104
|
+
const m = J.value, T = be.value, O = Ee.value, k = $e.value;
|
|
7105
|
+
return !!(e.menuConfig && mn(m) && (T.length || O.length || k.length));
|
|
7106
7106
|
}), Qe = N(() => {
|
|
7107
7107
|
const { ctxMenuStore: m } = u, T = [];
|
|
7108
7108
|
return m.list.forEach((O) => {
|
|
7109
|
-
O.forEach((
|
|
7110
|
-
T.push(
|
|
7109
|
+
O.forEach((k) => {
|
|
7110
|
+
T.push(k);
|
|
7111
7111
|
});
|
|
7112
7112
|
}), T;
|
|
7113
7113
|
}), tt = N(() => Object.assign({}, An().table.exportConfig, e.exportConfig)), et = N(() => Object.assign({}, An().table.importConfig, e.importConfig)), yt = N(() => Object.assign({}, An().table.printConfig, e.printConfig)), ut = N(() => Object.assign({}, An().table.expandConfig, e.expandConfig)), Et = N(() => Object.assign({}, An().table.treeConfig, e.treeConfig)), jt = N(() => Object.assign({}, An().table.emptyRender, e.emptyRender)), yn = N(() => Object.assign({}, An().table.loadingConfig, e.loadingConfig)), en = N(() => e.border ? Math.max(2, Math.ceil(u.scrollbarWidth / u.tableColumn.length)) : 1), Bt = N(() => Object.assign({}, An().table.customConfig, e.customConfig)), Ie = N(() => {
|
|
@@ -7116,8 +7116,8 @@ const lh = rt({
|
|
|
7116
7116
|
}), ze = N(() => {
|
|
7117
7117
|
const { tableColumn: m } = u, { collectColumn: T } = d;
|
|
7118
7118
|
let O = 0;
|
|
7119
|
-
return m.length && T.length && T.forEach((
|
|
7120
|
-
|
|
7119
|
+
return m.length && T.length && T.forEach((k) => {
|
|
7120
|
+
k.renderFixed && O++;
|
|
7121
7121
|
}), O;
|
|
7122
7122
|
}), it = N(() => {
|
|
7123
7123
|
const m = ze.value, T = Ye.value, { maxFixedSize: O } = T;
|
|
@@ -7126,13 +7126,13 @@ const lh = rt({
|
|
|
7126
7126
|
const { border: m } = e;
|
|
7127
7127
|
return m === !0 ? "full" : m || "default";
|
|
7128
7128
|
}), At = N(() => {
|
|
7129
|
-
const { tableData: m } = u, { tableFullData: T } = d, O = ke.value, { strict:
|
|
7130
|
-
return
|
|
7129
|
+
const { tableData: m } = u, { tableFullData: T } = d, O = ke.value, { strict: k, checkMethod: W } = O;
|
|
7130
|
+
return k ? m.length || T.length ? W ? T.every((ce) => !W({ row: ce })) : !1 : !0 : !1;
|
|
7131
7131
|
}), Qt = N(() => {
|
|
7132
|
-
const { overflowX: m, scrollXLoad: T, overflowY: O, scrollYLoad:
|
|
7132
|
+
const { overflowX: m, scrollXLoad: T, overflowY: O, scrollYLoad: k } = u;
|
|
7133
7133
|
return {
|
|
7134
7134
|
x: m && T,
|
|
7135
|
-
y: O &&
|
|
7135
|
+
y: O && k
|
|
7136
7136
|
};
|
|
7137
7137
|
}), Pt = N(() => {
|
|
7138
7138
|
const { tableData: m } = u, T = Ye.value, O = {};
|
|
@@ -7215,48 +7215,48 @@ const lh = rt({
|
|
|
7215
7215
|
getComputeMaps: () => _t,
|
|
7216
7216
|
xegrid: ae
|
|
7217
7217
|
}, on = (m, T, O) => {
|
|
7218
|
-
const
|
|
7219
|
-
return dl(
|
|
7218
|
+
const k = i.get(m, O), W = i.get(T, O);
|
|
7219
|
+
return dl(k) && dl(W) ? !0 : i.isString(k) || i.isNumber(k) ? "" + k == "" + W : i.isEqual(k, W);
|
|
7220
7220
|
}, rn = (m) => {
|
|
7221
|
-
const T = $.value, { orders: O } = T,
|
|
7221
|
+
const T = $.value, { orders: O } = T, k = m.order || null, W = O.indexOf(k) + 1;
|
|
7222
7222
|
return O[W < O.length ? W : 0];
|
|
7223
7223
|
}, Mn = (m) => {
|
|
7224
|
-
const T = An().version, O = i.toStringJSON(localStorage.getItem(uh) || ""),
|
|
7225
|
-
return (m ?
|
|
7224
|
+
const T = An().version, O = i.toStringJSON(localStorage.getItem(uh) || ""), k = O && O._v === T ? O : { _v: T };
|
|
7225
|
+
return (m ? k[m] : k) || {};
|
|
7226
7226
|
}, In = (m, T) => {
|
|
7227
|
-
const O = An().version,
|
|
7228
|
-
|
|
7227
|
+
const O = An().version, k = Mn();
|
|
7228
|
+
k[m] = T || void 0, k._v = O, localStorage.setItem(uh, i.toJSONString(k));
|
|
7229
7229
|
}, Pn = (m) => {
|
|
7230
7230
|
const { fullAllDataRowIdData: T } = d, O = {};
|
|
7231
|
-
return i.each(m, (
|
|
7232
|
-
T[W] && (O[W] =
|
|
7231
|
+
return i.each(m, (k, W) => {
|
|
7232
|
+
T[W] && (O[W] = k);
|
|
7233
7233
|
}), O;
|
|
7234
7234
|
}, pn = (m) => {
|
|
7235
7235
|
const { fullDataRowIdData: T } = d, O = [];
|
|
7236
|
-
return i.each(m, (
|
|
7236
|
+
return i.each(m, (k, W) => {
|
|
7237
7237
|
T[W] && q.findRowIndexOf(O, T[W].row) === -1 && O.push(T[W].row);
|
|
7238
7238
|
}), O;
|
|
7239
7239
|
}, bn = () => {
|
|
7240
7240
|
const { visibleColumn: m } = d, T = x.value, O = T ? T.$el : null;
|
|
7241
7241
|
if (O) {
|
|
7242
|
-
const { scrollLeft:
|
|
7242
|
+
const { scrollLeft: k, clientWidth: W } = O, ce = k + W;
|
|
7243
7243
|
let le = -1, me = 0, he = 0;
|
|
7244
|
-
for (let Pe = 0, Ve = m.length; Pe < Ve && (me += m[Pe].renderWidth, le === -1 &&
|
|
7244
|
+
for (let Pe = 0, Ve = m.length; Pe < Ve && (me += m[Pe].renderWidth, le === -1 && k < me && (le = Pe), !(le >= 0 && (he++, me > ce))); Pe++)
|
|
7245
7245
|
;
|
|
7246
7246
|
return { toVisibleIndex: Math.max(0, le), visibleSize: Math.max(6, he) };
|
|
7247
7247
|
}
|
|
7248
7248
|
return { toVisibleIndex: 0, visibleSize: 6 };
|
|
7249
7249
|
}, Fn = () => {
|
|
7250
|
-
const { showOverflow: m } = e, T = b.value, O = x.value,
|
|
7250
|
+
const { showOverflow: m } = e, T = b.value, O = x.value, k = O ? O.$el : null, W = f.value, ce = je.value;
|
|
7251
7251
|
let le = 24;
|
|
7252
|
-
if (m &&
|
|
7252
|
+
if (m && k) {
|
|
7253
7253
|
const me = T ? T.$el : null;
|
|
7254
7254
|
let he;
|
|
7255
|
-
he =
|
|
7255
|
+
he = k.querySelector("tr"), !he && me && (he = me.querySelector("tr")), he && (le = he.clientHeight), le || (le = ce[W || "default"]);
|
|
7256
7256
|
}
|
|
7257
7257
|
return le;
|
|
7258
7258
|
}, vo = () => {
|
|
7259
|
-
const { scrollYStore: m, afterFullData: T, fullAllDataRowIdData: O } = d,
|
|
7259
|
+
const { scrollYStore: m, afterFullData: T, fullAllDataRowIdData: O } = d, k = x.value, W = k ? k.$el : null, { rowHeight: ce } = m;
|
|
7260
7260
|
if (W) {
|
|
7261
7261
|
const { scrollTop: le, clientHeight: me } = W, he = le + me;
|
|
7262
7262
|
let Pe = -1, Ve = 0, _e = 0;
|
|
@@ -7269,14 +7269,14 @@ const lh = rt({
|
|
|
7269
7269
|
}
|
|
7270
7270
|
return { toVisibleIndex: 0, visibleSize: 8 };
|
|
7271
7271
|
}, Ro = (m, T, O) => {
|
|
7272
|
-
for (let
|
|
7273
|
-
const ce = m[
|
|
7274
|
-
he < le && le < Ve && (T.startIndex = he), he < me && me < Ve && (T.endIndex = Ve), (T.startIndex !== le || T.endIndex !== me) && (
|
|
7272
|
+
for (let k = 0, W = m.length; k < W; k++) {
|
|
7273
|
+
const ce = m[k], { startIndex: le, endIndex: me } = T, he = ce[O], Pe = ce[O + "span"], Ve = he + Pe;
|
|
7274
|
+
he < le && le < Ve && (T.startIndex = he), he < me && me < Ve && (T.endIndex = Ve), (T.startIndex !== le || T.endIndex !== me) && (k = -1);
|
|
7275
7275
|
}
|
|
7276
7276
|
}, ho = (m, T, O) => {
|
|
7277
7277
|
if (m) {
|
|
7278
|
-
const { treeConfig:
|
|
7279
|
-
i.isArray(m) || (m = [m]),
|
|
7278
|
+
const { treeConfig: k } = e, { visibleColumn: W } = d;
|
|
7279
|
+
i.isArray(m) || (m = [m]), k && m.length && Gt("vxe.error.noTree", ["merge-cells | merge-footer-items"]), m.forEach((ce) => {
|
|
7280
7280
|
let { row: le, col: me, rowspan: he, colspan: Pe } = ce;
|
|
7281
7281
|
if (O && i.isNumber(le) && (le = O[le]), i.isNumber(me) && (me = W[me]), (O ? le : i.isNumber(le)) && me && (he || Pe) && (he = i.toNumber(he) || 1, Pe = i.toNumber(Pe) || 1, he > 1 || Pe > 1)) {
|
|
7282
7282
|
const Ve = i.findIndexOf(T, (Ne) => (Ne._row === le || St(q, Ne._row) === St(q, le)) && (Ne._col.id === me || Ne._col.id === me.id)), _e = T[Ve];
|
|
@@ -7299,7 +7299,7 @@ const lh = rt({
|
|
|
7299
7299
|
});
|
|
7300
7300
|
}
|
|
7301
7301
|
}, Xo = (m, T, O) => {
|
|
7302
|
-
const
|
|
7302
|
+
const k = [];
|
|
7303
7303
|
if (m) {
|
|
7304
7304
|
const { treeConfig: W } = e, { visibleColumn: ce } = d;
|
|
7305
7305
|
i.isArray(m) || (m = [m]), W && m.length && Gt("vxe.error.noTree", ["merge-cells | merge-footer-items"]), m.forEach((le) => {
|
|
@@ -7308,11 +7308,11 @@ const lh = rt({
|
|
|
7308
7308
|
const Pe = i.findIndexOf(T, (Ve) => (Ve._row === me || St(q, Ve._row) === St(q, me)) && (Ve._col.id === he || Ve._col.id === he.id));
|
|
7309
7309
|
if (Pe > -1) {
|
|
7310
7310
|
const Ve = T.splice(Pe, 1);
|
|
7311
|
-
|
|
7311
|
+
k.push(Ve[0]);
|
|
7312
7312
|
}
|
|
7313
7313
|
});
|
|
7314
7314
|
}
|
|
7315
|
-
return
|
|
7315
|
+
return k;
|
|
7316
7316
|
}, Wo = () => {
|
|
7317
7317
|
const { tableFullColumn: m } = d;
|
|
7318
7318
|
m.forEach((T) => {
|
|
@@ -7320,25 +7320,25 @@ const lh = rt({
|
|
|
7320
7320
|
});
|
|
7321
7321
|
}, bo = (m) => {
|
|
7322
7322
|
const { parentHeight: T } = u, O = e[m];
|
|
7323
|
-
let
|
|
7323
|
+
let k = 0;
|
|
7324
7324
|
if (O)
|
|
7325
7325
|
if (O === "100%" || O === "auto")
|
|
7326
|
-
|
|
7326
|
+
k = T;
|
|
7327
7327
|
else {
|
|
7328
7328
|
const W = q.getExcludeHeight();
|
|
7329
|
-
di(O) ?
|
|
7329
|
+
di(O) ? k = Math.floor((i.toInteger(O) || 1) / 100 * T) : k = i.toNumber(O), k = Math.max(40, k - W);
|
|
7330
7330
|
}
|
|
7331
|
-
return
|
|
7331
|
+
return k;
|
|
7332
7332
|
}, Zo = (m) => {
|
|
7333
7333
|
let { collectColumn: T } = d;
|
|
7334
|
-
const { resizableData: O, sortData:
|
|
7334
|
+
const { resizableData: O, sortData: k, visibleData: W, fixedData: ce } = m;
|
|
7335
7335
|
let le = !1;
|
|
7336
|
-
O ||
|
|
7336
|
+
O || k || W || ce ? (i.eachTree(T, (me, he, Pe, Ve, _e) => {
|
|
7337
7337
|
const Ne = me.getKey();
|
|
7338
|
-
_e || (ce && ce[Ne] && (me.fixed = ce[Ne]),
|
|
7338
|
+
_e || (ce && ce[Ne] && (me.fixed = ce[Ne]), k && i.isNumber(k[Ne]) && (le = !0, me.renderSortNumber = k[Ne])), O && i.isNumber(O[Ne]) && (me.resizeWidth = O[Ne]), W && i.isBoolean(W[Ne]) && (me.visible = W[Ne]);
|
|
7339
7339
|
}), le && (T = i.orderBy(T, "renderSortNumber"), d.collectColumn = T, d.tableFullColumn = hs(T)), u.isCustomStatus = !0) : u.isCustomStatus = !1;
|
|
7340
7340
|
}, Br = () => {
|
|
7341
|
-
const { customConfig: m } = e, T = Y.value, O = Bt.value, { storage:
|
|
7341
|
+
const { customConfig: m } = e, T = Y.value, O = Bt.value, { storage: k, restoreStore: W } = O, ce = k === !0, le = ce ? {} : Object.assign({}, k || {}), me = ce || le.resizable, he = ce || le.visible, Pe = ce || le.fixed, Ve = ce || le.sort;
|
|
7342
7342
|
if ((m ? mn(O) : O.enabled) && (me || he || Pe || Ve)) {
|
|
7343
7343
|
if (!T) {
|
|
7344
7344
|
Gt("vxe.error.reqProp", ["id"]);
|
|
@@ -7351,11 +7351,11 @@ const lh = rt({
|
|
|
7351
7351
|
}).catch((Ne) => Ne) : Zo(_e);
|
|
7352
7352
|
}
|
|
7353
7353
|
}, El = () => {
|
|
7354
|
-
const { tableFullColumn: m, collectColumn: T } = d, O = d.fullColumnIdData = {},
|
|
7354
|
+
const { tableFullColumn: m, collectColumn: T } = d, O = d.fullColumnIdData = {}, k = d.fullColumnFieldData = {}, W = Se.value, ce = Ye.value, le = at.value, { isCrossDrag: me, isSelfToChildDrag: he } = le, Pe = He.value, Ve = T.some(na);
|
|
7355
7355
|
let _e = !!e.showOverflow, Ne, Je, We, qe, ft;
|
|
7356
7356
|
const Dt = (Xe, Ot, zt, Kt, an) => {
|
|
7357
7357
|
const { id: tn, field: vn, fixed: hn, type: un, treeNode: On } = Xe, cn = { $index: -1, _index: -1, column: Xe, colid: tn, index: Ot, items: zt, parent: an || null, width: 0 };
|
|
7358
|
-
vn ? (
|
|
7358
|
+
vn ? (k[vn] && Gt("vxe.error.colRepet", ["field", vn]), k[vn] = cn) : (me || he) && Gt("vxe.error.emptyProp", ["column.field"]), !ft && un === "html" && (ft = Xe), On ? (process.env.NODE_ENV === "development" && Je && sn("vxe.error.colRepet", ["tree-node", On]), Je || (Je = Xe)) : un === "expand" && (process.env.NODE_ENV === "development" && Ne && sn("vxe.error.colRepet", ["type", un]), Ne || (Ne = Xe)), process.env.NODE_ENV === "development" && (un === "checkbox" ? (We && sn("vxe.error.colRepet", ["type", un]), We || (We = Xe)) : un === "radio" && (qe && sn("vxe.error.colRepet", ["type", un]), qe || (qe = Xe))), _e && Xe.showOverflow === !1 && (_e = !1), O[tn] && Gt("vxe.error.colRepet", ["colId", tn]), O[tn] = cn;
|
|
7359
7359
|
};
|
|
7360
7360
|
Ve ? i.eachTree(T, (Xe, Ot, zt, Kt, an, tn) => {
|
|
7361
7361
|
Xe.level = tn.length, Dt(Xe, Ot, zt, Kt, an);
|
|
@@ -7366,14 +7366,14 @@ const lh = rt({
|
|
|
7366
7366
|
const m = Ie.value;
|
|
7367
7367
|
return u.isCalcColumn = !0, pe().then(() => {
|
|
7368
7368
|
const { fullColumnIdData: T } = d, O = h.value;
|
|
7369
|
-
O && (m.forEach((
|
|
7370
|
-
const W =
|
|
7369
|
+
O && (m.forEach((k) => {
|
|
7370
|
+
const W = k.id, ce = T[W], le = O.querySelectorAll(`.vxe-header--column.${k.id}>.vxe-cell,.vxe-body--column.${k.id}>.vxe-cell,.vxe-footer--column.${k.id}>.vxe-cell`), me = le[0];
|
|
7371
7371
|
let he = 0;
|
|
7372
7372
|
if (me) {
|
|
7373
7373
|
const Ve = getComputedStyle(me);
|
|
7374
7374
|
he = Math.floor(i.toNumber(Ve.paddingLeft) + i.toNumber(Ve.paddingRight)) + 2;
|
|
7375
7375
|
}
|
|
7376
|
-
let Pe =
|
|
7376
|
+
let Pe = k.renderAutoWidth - he;
|
|
7377
7377
|
i.arrayEach(le, (Ve) => {
|
|
7378
7378
|
const _e = Ve, Ne = _e.parentElement;
|
|
7379
7379
|
let Je = 0;
|
|
@@ -7386,15 +7386,15 @@ const lh = rt({
|
|
|
7386
7386
|
We && (Je = We.offsetWidth);
|
|
7387
7387
|
}
|
|
7388
7388
|
Je && (Pe = Math.max(Pe, Math.ceil(Je) + 4));
|
|
7389
|
-
}), ce && (ce.width = Math.max(Pe, ce.width)),
|
|
7389
|
+
}), ce && (ce.width = Math.max(Pe, ce.width)), k.renderAutoWidth = Pe + he;
|
|
7390
7390
|
}), g.analyColumnWidth()), u.isCalcColumn = !1;
|
|
7391
7391
|
});
|
|
7392
7392
|
}, zr = () => {
|
|
7393
|
-
const m = b.value, T = x.value, O = C.value,
|
|
7394
|
-
if (!
|
|
7393
|
+
const m = b.value, T = x.value, O = C.value, k = T ? T.$el : null, W = m ? m.$el : null, ce = O ? O.$el : null;
|
|
7394
|
+
if (!k)
|
|
7395
7395
|
return;
|
|
7396
7396
|
let le = 0;
|
|
7397
|
-
const me = 40, he =
|
|
7397
|
+
const me = 40, he = k.clientWidth - 1;
|
|
7398
7398
|
let Pe = he, Ve = Pe / 100;
|
|
7399
7399
|
const { fit: _e } = e, { columnStore: Ne } = u, { resizeList: Je, pxMinList: We, autoMinList: qe, pxList: ft, scaleList: Dt, scaleMinList: Xe, autoList: Ot, remainList: zt } = Ne;
|
|
7400
7400
|
if (We.forEach((cn) => {
|
|
@@ -7435,18 +7435,18 @@ const lh = rt({
|
|
|
7435
7435
|
}
|
|
7436
7436
|
}
|
|
7437
7437
|
}
|
|
7438
|
-
const Kt =
|
|
7438
|
+
const Kt = k.offsetHeight, an = k.scrollHeight > k.clientHeight;
|
|
7439
7439
|
let tn = 0;
|
|
7440
|
-
an && (tn = Math.max(
|
|
7440
|
+
an && (tn = Math.max(k.offsetWidth - k.clientWidth, 0)), u.scrollbarWidth = tn, u.overflowY = an, d.tableWidth = le, d.tableHeight = Kt;
|
|
7441
7441
|
let vn = 0;
|
|
7442
7442
|
W && (vn = W.clientHeight, pe(() => {
|
|
7443
|
-
W &&
|
|
7443
|
+
W && k && W.scrollLeft !== k.scrollLeft && (W.scrollLeft = k.scrollLeft);
|
|
7444
7444
|
})), d.headerHeight = vn;
|
|
7445
7445
|
let hn = !1, un = 0, On = 0;
|
|
7446
|
-
ce ? (un = ce.offsetHeight, hn = le > ce.clientWidth, On = Math.max(un - ce.clientHeight, 0)) : (hn = le > he, On = Math.max(Kt -
|
|
7446
|
+
ce ? (un = ce.offsetHeight, hn = le > ce.clientWidth, On = Math.max(un - ce.clientHeight, 0)) : (hn = le > he, On = Math.max(Kt - k.clientHeight, 0)), d.footerHeight = un, u.overflowX = hn, u.scrollbarHeight = On, Ho(), u.parentHeight = Math.max(d.headerHeight + un + 20, g.getParentHeight()), hn && g.checkScrolling();
|
|
7447
7447
|
}, Jn = () => {
|
|
7448
|
-
const { showOverflow: m } = e, { tableData: T, scrollXLoad: O, scrollYLoad:
|
|
7449
|
-
if (!m && (O ||
|
|
7448
|
+
const { showOverflow: m } = e, { tableData: T, scrollXLoad: O, scrollYLoad: k } = u, { fullAllDataRowIdData: W } = d, ce = h.value;
|
|
7449
|
+
if (!m && (O || k) && ce) {
|
|
7450
7450
|
let le = 0, me = 0, he = !1;
|
|
7451
7451
|
T.forEach((Pe) => {
|
|
7452
7452
|
const Ve = St(q, Pe), _e = W[Ve], Ne = ce.querySelectorAll(`.vxe-body--row[rowid="${Ve}"]`);
|
|
@@ -7467,45 +7467,45 @@ const lh = rt({
|
|
|
7467
7467
|
}
|
|
7468
7468
|
}, Sl = (m) => {
|
|
7469
7469
|
const { sortBy: T, sortType: O } = m;
|
|
7470
|
-
return (
|
|
7470
|
+
return (k) => {
|
|
7471
7471
|
let W;
|
|
7472
|
-
return T ? W = i.isFunction(T) ? T({ row:
|
|
7472
|
+
return T ? W = i.isFunction(T) ? T({ row: k, column: m }) : i.get(k, T) : W = p.getCellLabel(k, m), !O || O === "auto" ? isNaN(W) ? W : i.toNumber(W) : O === "number" ? i.toNumber(W) : O === "string" ? i.toValueString(W) : W;
|
|
7473
7473
|
};
|
|
7474
7474
|
}, lr = () => {
|
|
7475
|
-
const { treeConfig: m } = e, { afterFullData: T, fullDataRowIdData: O, fullAllDataRowIdData:
|
|
7475
|
+
const { treeConfig: m } = e, { afterFullData: T, fullDataRowIdData: O, fullAllDataRowIdData: k } = d, W = Et.value;
|
|
7476
7476
|
m && W.transform && T.forEach((ce, le) => {
|
|
7477
|
-
const me = St(q, ce), he =
|
|
7477
|
+
const me = St(q, ce), he = k[me];
|
|
7478
7478
|
if (he)
|
|
7479
7479
|
he._index = le;
|
|
7480
7480
|
else {
|
|
7481
7481
|
const Pe = { row: ce, rowid: me, seq: "-1", index: -1, $index: -1, _index: le, items: [], parent: null, level: 0, height: 0 };
|
|
7482
|
-
|
|
7482
|
+
k[me] = Pe, O[me] = Pe;
|
|
7483
7483
|
}
|
|
7484
7484
|
});
|
|
7485
7485
|
}, Wr = () => {
|
|
7486
|
-
const { treeConfig: m } = e, { afterFullData: T, fullDataRowIdData: O, fullAllDataRowIdData:
|
|
7486
|
+
const { treeConfig: m } = e, { afterFullData: T, fullDataRowIdData: O, fullAllDataRowIdData: k, afterTreeFullData: W } = d, ce = Et.value, le = ce.children || ce.childrenField, me = {};
|
|
7487
7487
|
m ? (i.eachTree(W, (he, Pe, Ve, _e) => {
|
|
7488
|
-
const Ne = St(q, he), Je =
|
|
7488
|
+
const Ne = St(q, he), Je = k[Ne], We = _e.map((qe, ft) => ft % 2 === 0 ? Number(qe) + 1 : ".").join("");
|
|
7489
7489
|
if (Je)
|
|
7490
7490
|
Je.seq = We;
|
|
7491
7491
|
else {
|
|
7492
7492
|
const qe = { row: he, rowid: Ne, seq: We, index: -1, $index: -1, _index: -1, items: [], parent: null, level: 0, height: 0 };
|
|
7493
|
-
|
|
7493
|
+
k[Ne] = qe, O[Ne] = qe;
|
|
7494
7494
|
}
|
|
7495
7495
|
me[Ne] = he;
|
|
7496
7496
|
}, { children: ce.transform ? ce.mapChildrenField : le }), lr()) : T.forEach((he, Pe) => {
|
|
7497
|
-
const Ve = St(q, he), _e =
|
|
7497
|
+
const Ve = St(q, he), _e = k[Ve], Ne = Pe + 1;
|
|
7498
7498
|
if (_e)
|
|
7499
7499
|
_e.seq = Ne, _e._index = Pe;
|
|
7500
7500
|
else {
|
|
7501
7501
|
const Je = { row: he, rowid: Ve, seq: Ne, index: -1, $index: -1, _index: Pe, items: [], parent: null, level: 0, height: 0 };
|
|
7502
|
-
|
|
7502
|
+
k[Ve] = Je, O[Ve] = Je;
|
|
7503
7503
|
}
|
|
7504
7504
|
me[Ve] = he;
|
|
7505
7505
|
}), d.afterFullRowMaps = me;
|
|
7506
7506
|
}, No = () => {
|
|
7507
|
-
const { treeConfig: m } = e, { treeExpandedMaps: T } = u, { fullAllDataRowIdData: O } = d,
|
|
7508
|
-
if (m &&
|
|
7507
|
+
const { treeConfig: m } = e, { treeExpandedMaps: T } = u, { fullAllDataRowIdData: O } = d, k = Et.value, W = k.children || k.childrenField;
|
|
7508
|
+
if (m && k.transform) {
|
|
7509
7509
|
const ce = [], le = {};
|
|
7510
7510
|
return i.eachTree(d.afterTreeFullData, (me, he, Pe, Ve, _e) => {
|
|
7511
7511
|
const Ne = St(q, me), Je = St(q, _e);
|
|
@@ -7517,7 +7517,7 @@ const lh = rt({
|
|
|
7517
7517
|
}
|
|
7518
7518
|
return d.afterFullData;
|
|
7519
7519
|
}, Hr = () => {
|
|
7520
|
-
const { treeConfig: m } = e, { tableFullColumn: T, tableFullData: O, tableFullTreeData:
|
|
7520
|
+
const { treeConfig: m } = e, { tableFullColumn: T, tableFullData: O, tableFullTreeData: k } = d, W = te.value, ce = $.value, le = Et.value, me = le.children || le.childrenField, { transform: he } = le, { remote: Pe, filterMethod: Ve } = W, { remote: _e, sortMethod: Ne, multiple: Je, chronological: We } = ce;
|
|
7521
7521
|
let qe = [], ft = [];
|
|
7522
7522
|
if (!Pe || !_e) {
|
|
7523
7523
|
const Dt = [];
|
|
@@ -7536,19 +7536,19 @@ const lh = rt({
|
|
|
7536
7536
|
const { filterMethod: vn, filterRender: hn } = Kt, un = mn(hn) ? ah.get(hn.name) : null, On = un ? un.tableFilterMethod || un.filterMethod : null, cn = un ? un.tableFilterDefaultMethod || un.defaultTableFilterMethod || un.defaultFilterMethod : null, xn = Mo(zt, Kt);
|
|
7537
7537
|
return vn ? tn.some((Qn) => vn({ value: Qn.value, option: Qn, cellValue: xn, row: zt, column: Kt, $table: q })) : On ? tn.some((Qn) => On({ value: Qn.value, option: Qn, cellValue: xn, row: zt, column: Kt, $table: q })) : Ve ? Ve({ options: tn, values: an, cellValue: xn, row: zt, column: Kt }) : cn ? tn.some((Qn) => cn({ value: Qn.value, option: Qn, cellValue: xn, row: zt, column: Kt, $table: q })) : an.indexOf(i.get(zt, Kt.field)) > -1;
|
|
7538
7538
|
});
|
|
7539
|
-
m && he ? (ft = i.searchTree(
|
|
7539
|
+
m && he ? (ft = i.searchTree(k, Ot, {
|
|
7540
7540
|
original: !0,
|
|
7541
7541
|
isEvery: !0,
|
|
7542
7542
|
children: le.mapChildrenField,
|
|
7543
7543
|
mapChildren: me
|
|
7544
|
-
}), qe = ft) : (qe = m ?
|
|
7544
|
+
}), qe = ft) : (qe = m ? k.filter(Ot) : O.filter(Ot), ft = qe);
|
|
7545
7545
|
} else
|
|
7546
|
-
m && he ? (ft = i.searchTree(
|
|
7546
|
+
m && he ? (ft = i.searchTree(k, () => !0, {
|
|
7547
7547
|
original: !0,
|
|
7548
7548
|
isEvery: !0,
|
|
7549
7549
|
children: le.mapChildrenField,
|
|
7550
7550
|
mapChildren: me
|
|
7551
|
-
}), qe = ft) : (qe = m ?
|
|
7551
|
+
}), qe = ft) : (qe = m ? k.slice(0) : O.slice(0), ft = qe);
|
|
7552
7552
|
if (!_e && Xe.length)
|
|
7553
7553
|
if (m && he) {
|
|
7554
7554
|
if (Ne) {
|
|
@@ -7566,15 +7566,15 @@ const lh = rt({
|
|
|
7566
7566
|
ft = qe;
|
|
7567
7567
|
}
|
|
7568
7568
|
} else
|
|
7569
|
-
m && he ? (ft = i.searchTree(
|
|
7569
|
+
m && he ? (ft = i.searchTree(k, () => !0, {
|
|
7570
7570
|
original: !0,
|
|
7571
7571
|
isEvery: !0,
|
|
7572
7572
|
children: le.mapChildrenField,
|
|
7573
7573
|
mapChildren: me
|
|
7574
|
-
}), qe = ft) : (qe = m ?
|
|
7574
|
+
}), qe = ft) : (qe = m ? k.slice(0) : O.slice(0), ft = qe);
|
|
7575
7575
|
d.afterFullData = qe, d.afterTreeFullData = ft, Wr();
|
|
7576
7576
|
}, mo = () => {
|
|
7577
|
-
const { border: m, showFooter: T, showOverflow: O, showHeaderOverflow:
|
|
7577
|
+
const { border: m, showFooter: T, showOverflow: O, showHeaderOverflow: k, showFooterOverflow: W, mouseConfig: ce, spanMethod: le, footerSpanMethod: me } = e, { isGroup: he, currentRow: Pe, tableColumn: Ve, scrollXLoad: _e, scrollYLoad: Ne, overflowX: Je, scrollbarWidth: We, scrollbarHeight: qe, columnStore: ft, editStore: Dt, isAllOverflow: Xe, expandColumn: Ot } = u;
|
|
7578
7578
|
let { visibleColumn: zt, fullColumnIdData: Kt, tableHeight: an, tableWidth: tn, headerHeight: vn, footerHeight: hn, elemStore: un, customHeight: On, customMinHeight: cn, customMaxHeight: xn } = d;
|
|
7579
7579
|
const Qn = ["main", "left", "right"], jr = P.value, hr = en.value, qr = Se.value, Ol = tr(un["main-body-wrapper"]);
|
|
7580
7580
|
jr && (jr.style.top = `${vn}px`, jr.style.height = Ol ? `${Ol.offsetHeight - qe}px` : ""), On > 0 && T && (On += qe);
|
|
@@ -7593,14 +7593,14 @@ const lh = rt({
|
|
|
7593
7593
|
const to = tr(un[`${co}-${fo}-wrapper`]), Io = tr(un[`${co}-${fo}-table`]);
|
|
7594
7594
|
if (fo === "header") {
|
|
7595
7595
|
let Po = tn, oo = Ve;
|
|
7596
|
-
he ? oo = zt : Uo && (oo = zt,
|
|
7596
|
+
he ? oo = zt : Uo && (oo = zt, k && (le || me ? oo = zt : oo = eo || [])), Po = oo.reduce((Go, br) => Go + br.renderWidth, 0), Io && (Io.style.width = Po ? `${Po + We}px` : "");
|
|
7597
7597
|
const vr = tr(un[`${co}-${fo}-repair`]);
|
|
7598
7598
|
vr && (vr.style.width = `${tn}px`);
|
|
7599
7599
|
const xo = tr(un[`${co}-${fo}-list`]);
|
|
7600
7600
|
he && xo && i.arrayEach(xo.querySelectorAll(".col--group"), (Go) => {
|
|
7601
7601
|
const br = p.getColumnNode(Go);
|
|
7602
7602
|
if (br) {
|
|
7603
|
-
const bs = br.item, { showHeaderOverflow: rl } = bs, Ka = i.isBoolean(rl) ? rl :
|
|
7603
|
+
const bs = br.item, { showHeaderOverflow: rl } = bs, Ka = i.isBoolean(rl) ? rl : k, Ya = Ka === "title" || (Ka === !0 || Ka === "tooltip") || Ka === "ellipsis";
|
|
7604
7604
|
let Xa = 0, Ws = 0;
|
|
7605
7605
|
Ya && i.eachTree(bs.children, (Za) => {
|
|
7606
7606
|
(!Za.children || !bs.children.length) && Ws++, Xa += Za.renderWidth;
|
|
@@ -7632,7 +7632,7 @@ const lh = rt({
|
|
|
7632
7632
|
if (oo === "col_gutter" && (Po.style.width = `${We}px`), Kt[oo]) {
|
|
7633
7633
|
const xo = Kt[oo].column, { showHeaderOverflow: Go, showFooterOverflow: br, showOverflow: bs } = xo;
|
|
7634
7634
|
let rl;
|
|
7635
|
-
Po.style.width = `${xo.renderWidth}px`, fo === "header" ? rl = i.isUndefined(Go) || i.isNull(Go) ?
|
|
7635
|
+
Po.style.width = `${xo.renderWidth}px`, fo === "header" ? rl = i.isUndefined(Go) || i.isNull(Go) ? k : Go : fo === "footer" ? rl = i.isUndefined(br) || i.isNull(br) ? W : br : rl = i.isUndefined(bs) || i.isNull(bs) ? O : bs;
|
|
7636
7636
|
let nc = rl === "title" || (rl === !0 || rl === "tooltip") || rl === "ellipsis";
|
|
7637
7637
|
const Ya = tr(un[`${co}-${fo}-list`]);
|
|
7638
7638
|
Ne && !nc && (nc = !0), Ya && i.arrayEach(Ya.querySelectorAll(`.${xo.id}`), (Xa) => {
|
|
@@ -7662,8 +7662,8 @@ const lh = rt({
|
|
|
7662
7662
|
if (m) {
|
|
7663
7663
|
const T = $.value;
|
|
7664
7664
|
let { defaultSort: O } = T;
|
|
7665
|
-
O && (i.isArray(O) || (O = [O]), O.length && ((m.multiple ? O : O.slice(0, 1)).forEach((
|
|
7666
|
-
const { field: ce, order: le } =
|
|
7665
|
+
O && (i.isArray(O) || (O = [O]), O.length && ((m.multiple ? O : O.slice(0, 1)).forEach((k, W) => {
|
|
7666
|
+
const { field: ce, order: le } = k;
|
|
7667
7667
|
if (ce && le) {
|
|
7668
7668
|
const me = p.getColumnByField(ce);
|
|
7669
7669
|
me && me.sortable && (me.order = le, me.sortTime = Date.now() + W);
|
|
@@ -7673,8 +7673,8 @@ const lh = rt({
|
|
|
7673
7673
|
}, ql = () => {
|
|
7674
7674
|
const { checkboxConfig: m } = e;
|
|
7675
7675
|
if (m) {
|
|
7676
|
-
const { fullDataRowIdData: T } = d, O = ke.value, { checkAll:
|
|
7677
|
-
if (
|
|
7676
|
+
const { fullDataRowIdData: T } = d, O = ke.value, { checkAll: k, checkRowKeys: W } = O;
|
|
7677
|
+
if (k)
|
|
7678
7678
|
vt(!0, !0);
|
|
7679
7679
|
else if (W) {
|
|
7680
7680
|
const ce = [];
|
|
@@ -7686,17 +7686,17 @@ const lh = rt({
|
|
|
7686
7686
|
}, mr = () => {
|
|
7687
7687
|
const { radioConfig: m } = e;
|
|
7688
7688
|
if (m) {
|
|
7689
|
-
const { fullDataRowIdData: T } = d, O = pt.value, { checkRowKey:
|
|
7690
|
-
if (
|
|
7689
|
+
const { fullDataRowIdData: T } = d, O = pt.value, { checkRowKey: k, reserve: W } = O;
|
|
7690
|
+
if (k && (T[k] && Ue(T[k].row, !0), W)) {
|
|
7691
7691
|
const ce = Rl(q);
|
|
7692
|
-
d.radioReserveRow = { [ce]:
|
|
7692
|
+
d.radioReserveRow = { [ce]: k };
|
|
7693
7693
|
}
|
|
7694
7694
|
}
|
|
7695
7695
|
}, gs = () => {
|
|
7696
7696
|
const { expandConfig: m } = e;
|
|
7697
7697
|
if (m) {
|
|
7698
|
-
const { fullDataRowIdData: T } = d, O = ut.value, { expandAll:
|
|
7699
|
-
if (
|
|
7698
|
+
const { fullDataRowIdData: T } = d, O = ut.value, { expandAll: k, expandRowKeys: W } = O;
|
|
7699
|
+
if (k)
|
|
7700
7700
|
p.setAllRowExpand(!0);
|
|
7701
7701
|
else if (W) {
|
|
7702
7702
|
const ce = [];
|
|
@@ -7714,10 +7714,10 @@ const lh = rt({
|
|
|
7714
7714
|
T ? O[W] = m : O[W] && delete O[W];
|
|
7715
7715
|
}
|
|
7716
7716
|
}, Ue = (m, T) => {
|
|
7717
|
-
const O = pt.value, { checkMethod:
|
|
7718
|
-
return m && (T || !
|
|
7717
|
+
const O = pt.value, { checkMethod: k } = O;
|
|
7718
|
+
return m && (T || !k || k({ row: m })) && (u.selectRadioRow = m, Ul(m)), pe();
|
|
7719
7719
|
}, Ze = (m, T, O) => (m && !i.isArray(m) && (m = [m]), q.handleBatchSelectRows(m, !!T, O), q.checkSelectionStatus(), pe()), vt = (m, T) => {
|
|
7720
|
-
const { treeConfig: O } = e, { selectCheckboxMaps:
|
|
7720
|
+
const { treeConfig: O } = e, { selectCheckboxMaps: k } = u, { afterFullData: W, checkboxReserveRowMap: ce } = d, le = Et.value, me = le.children || le.childrenField, he = ke.value, { checkField: Pe, reserve: Ve, checkMethod: _e } = he, Ne = he.indeterminateField || he.halfField, Je = {};
|
|
7721
7721
|
if (Pe) {
|
|
7722
7722
|
const We = (qe) => {
|
|
7723
7723
|
(T || !_e || _e({ row: qe })) && (m && (Je[St(q, qe)] = qe), i.set(qe, Pe, m)), O && Ne && i.set(qe, Ne, !1);
|
|
@@ -7728,31 +7728,31 @@ const lh = rt({
|
|
|
7728
7728
|
(T || !_e || _e({ row: We })) && (Je[St(q, We)] = We);
|
|
7729
7729
|
}, { children: me }) : !T && _e && i.eachTree(W, (We) => {
|
|
7730
7730
|
const qe = St(q, We);
|
|
7731
|
-
!_e({ row: We }) &&
|
|
7731
|
+
!_e({ row: We }) && k[qe] && (Je[qe] = We);
|
|
7732
7732
|
}, { children: me }) : m ? !T && _e ? W.forEach((We) => {
|
|
7733
7733
|
const qe = St(q, We);
|
|
7734
|
-
(
|
|
7734
|
+
(k[qe] || _e({ row: We })) && (Je[qe] = We);
|
|
7735
7735
|
}) : W.forEach((We) => {
|
|
7736
7736
|
Je[St(q, We)] = We;
|
|
7737
7737
|
}) : !T && _e && W.forEach((We) => {
|
|
7738
7738
|
const qe = St(q, We);
|
|
7739
|
-
!_e({ row: We }) &&
|
|
7739
|
+
!_e({ row: We }) && k[qe] && (Je[qe] = We);
|
|
7740
7740
|
});
|
|
7741
7741
|
return Ve && (m ? i.each(Je, (We, qe) => {
|
|
7742
7742
|
ce[qe] = We;
|
|
7743
7743
|
}) : W.forEach((We) => fe(We, !1))), u.selectCheckboxMaps = Pe ? {} : Je, u.isAllSelected = m, u.isIndeterminate = !1, u.treeIndeterminateMaps = {}, d.treeIndeterminateRowMaps = {}, g.checkSelectionStatus(), pe();
|
|
7744
7744
|
}, Lt = () => {
|
|
7745
|
-
const { treeConfig: m } = e, { expandColumn: T, currentRow: O, selectCheckboxMaps:
|
|
7745
|
+
const { treeConfig: m } = e, { expandColumn: T, currentRow: O, selectCheckboxMaps: k, selectRadioRow: W, rowExpandedMaps: ce, treeExpandedMaps: le } = u, { fullDataRowIdData: me, fullAllDataRowIdData: he, radioReserveRow: Pe } = d, Ve = ut.value, _e = Et.value, Ne = pt.value, Je = ke.value;
|
|
7746
7746
|
if (W && !he[St(q, W)] && (u.selectRadioRow = null), Ne.reserve && Pe) {
|
|
7747
7747
|
const We = St(q, Pe);
|
|
7748
7748
|
me[We] && Ue(me[We].row, !0);
|
|
7749
7749
|
}
|
|
7750
|
-
u.selectCheckboxMaps = Pn(
|
|
7750
|
+
u.selectCheckboxMaps = Pn(k), Je.reserve && Ze(pn(d.checkboxReserveRowMap), !0, !0), O && !he[St(q, O)] && (u.currentRow = null), u.rowExpandedMaps = T ? Pn(ce) : {}, T && Ve.reserve && p.setRowExpand(pn(d.rowExpandedReserveRowMap), !0), u.treeExpandedMaps = m ? Pn(le) : {}, m && _e.reserve && p.setTreeExpand(pn(d.treeExpandedReserveRowMap), !0);
|
|
7751
7751
|
}, $t = () => {
|
|
7752
7752
|
const { treeConfig: m } = e;
|
|
7753
7753
|
if (m) {
|
|
7754
|
-
const { tableFullData: T } = d, O = Et.value, { expandAll:
|
|
7755
|
-
if (
|
|
7754
|
+
const { tableFullData: T } = d, O = Et.value, { expandAll: k, expandRowKeys: W } = O, ce = O.children || O.childrenField;
|
|
7755
|
+
if (k)
|
|
7756
7756
|
p.setAllTreeExpand(!0);
|
|
7757
7757
|
else if (W) {
|
|
7758
7758
|
const le = [], me = Rl(q);
|
|
@@ -7763,7 +7763,7 @@ const lh = rt({
|
|
|
7763
7763
|
}
|
|
7764
7764
|
}
|
|
7765
7765
|
}, Wt = (m) => {
|
|
7766
|
-
const T = Et.value, O = ke.value, { transform:
|
|
7766
|
+
const T = Et.value, O = ke.value, { transform: k, loadMethod: W } = T, { checkStrictly: ce } = O;
|
|
7767
7767
|
return new Promise((le) => {
|
|
7768
7768
|
if (W) {
|
|
7769
7769
|
const { treeExpandLazyLoadedMaps: me } = u, { fullAllDataRowIdData: he } = d, Pe = St(q, m), Ve = he[Pe];
|
|
@@ -7772,7 +7772,7 @@ const lh = rt({
|
|
|
7772
7772
|
return p.loadTreeChildren(m, _e).then((Ne) => {
|
|
7773
7773
|
const { treeExpandedMaps: Je } = u;
|
|
7774
7774
|
return Ne.length && !Je[Pe] && (Je[Pe] = m), !ce && p.isCheckedByCheckboxRow(m) && Ze(Ne, !0), pe().then(() => {
|
|
7775
|
-
if (
|
|
7775
|
+
if (k)
|
|
7776
7776
|
return g.handleTableData(), lr(), pe();
|
|
7777
7777
|
});
|
|
7778
7778
|
});
|
|
@@ -7792,10 +7792,10 @@ const lh = rt({
|
|
|
7792
7792
|
T ? O[W] = m : O[W] && delete O[W];
|
|
7793
7793
|
}
|
|
7794
7794
|
}, st = (m) => new Promise((T) => {
|
|
7795
|
-
const O = ut.value, { loadMethod:
|
|
7796
|
-
if (
|
|
7795
|
+
const O = ut.value, { loadMethod: k } = O;
|
|
7796
|
+
if (k) {
|
|
7797
7797
|
const { fullAllDataRowIdData: W } = d, { rowExpandLazyLoadedMaps: ce } = u, le = St(q, m), me = W[le];
|
|
7798
|
-
ce[le] = m,
|
|
7798
|
+
ce[le] = m, k({ $table: q, row: m, rowIndex: p.getRowIndex(m), $rowIndex: p.getVMRowIndex(m) }).then(() => {
|
|
7799
7799
|
const { rowExpandedMaps: he } = u;
|
|
7800
7800
|
me && (me.expandLoaded = !0), he[le] = m;
|
|
7801
7801
|
}).catch(() => {
|
|
@@ -7819,7 +7819,7 @@ const lh = rt({
|
|
|
7819
7819
|
const { mergeFooterItems: m } = e;
|
|
7820
7820
|
m && p.setMergeFooterItems(m);
|
|
7821
7821
|
}, zn = () => pe().then(() => {
|
|
7822
|
-
const { scrollXLoad: m, scrollYLoad: T } = u, { scrollXStore: O, scrollYStore:
|
|
7822
|
+
const { scrollXLoad: m, scrollYLoad: T } = u, { scrollXStore: O, scrollYStore: k } = d, W = de.value, ce = we.value;
|
|
7823
7823
|
if (m) {
|
|
7824
7824
|
const { visibleSize: he } = bn(), Pe = Math.max(0, ce.oSize ? i.toNumber(ce.oSize) : oa.edge ? 5 : 0);
|
|
7825
7825
|
O.offsetSize = Pe, O.visibleSize = he, O.endIndex = Math.max(O.startIndex + O.visibleSize + Pe, O.endIndex), g.updateScrollXData();
|
|
@@ -7827,11 +7827,11 @@ const lh = rt({
|
|
|
7827
7827
|
g.updateScrollXSpace();
|
|
7828
7828
|
Jn();
|
|
7829
7829
|
const le = Fn();
|
|
7830
|
-
|
|
7830
|
+
k.rowHeight = le, u.rowHeight = le;
|
|
7831
7831
|
const { visibleSize: me } = vo();
|
|
7832
7832
|
if (T) {
|
|
7833
7833
|
const he = Math.max(0, W.oSize ? i.toNumber(W.oSize) : oa.edge ? 10 : 0);
|
|
7834
|
-
|
|
7834
|
+
k.offsetSize = he, k.visibleSize = me, k.endIndex = Math.max(k.startIndex + me + he, k.endIndex), g.updateScrollYData();
|
|
7835
7835
|
} else
|
|
7836
7836
|
g.updateScrollYSpace();
|
|
7837
7837
|
pe(mo);
|
|
@@ -7842,7 +7842,7 @@ const lh = rt({
|
|
|
7842
7842
|
return Jn(), jl(), zr(), zn();
|
|
7843
7843
|
}));
|
|
7844
7844
|
}, $o = (m) => {
|
|
7845
|
-
const { keepSource: T, treeConfig: O, showOverflow:
|
|
7845
|
+
const { keepSource: T, treeConfig: O, showOverflow: k } = e, { editStore: W, scrollYLoad: ce } = u, { scrollYStore: le, scrollXStore: me, lastScrollLeft: he, lastScrollTop: Pe } = d, Ve = Et.value, _e = He.value, { transform: Ne } = Ve, Je = Ve.children || Ve.childrenField;
|
|
7846
7846
|
let We = [], qe = kt(m ? m.slice(0) : []);
|
|
7847
7847
|
O && (Ne ? (process.env.NODE_ENV === "development" && (Ve.rowField || Gt("vxe.error.reqProp", ["tree-config.rowField"]), Ve.parentField || Gt("vxe.error.reqProp", ["tree-config.parentField"]), Je || Gt("vxe.error.reqProp", ["tree-config.childrenField"]), Ve.mapChildrenField || Gt("vxe.error.reqProp", ["tree-config.mapChildrenField"]), Je === Ve.mapChildrenField && Gt("vxe.error.errConflicts", ["tree-config.childrenField", "tree-config.mapChildrenField"])), We = i.toArrayTree(qe, {
|
|
7848
7848
|
key: Ve.rowField,
|
|
@@ -7852,7 +7852,7 @@ const lh = rt({
|
|
|
7852
7852
|
}), qe = We.slice(0)) : We = qe.slice(0)), le.startIndex = 0, le.endIndex = 1, me.startIndex = 0, me.endIndex = 1, u.scrollVMLoading = !1, W.insertMaps = {}, W.removeMaps = {};
|
|
7853
7853
|
const ft = Bs(qe);
|
|
7854
7854
|
if (u.scrollYLoad = ft, u.isDragRowMove = !1, d.tableFullData = qe, d.tableFullTreeData = We, g.cacheRowMap(!0), d.tableSynchData = m, T && g.cacheSourceMap(qe), ft) {
|
|
7855
|
-
if (
|
|
7855
|
+
if (k && !_e.height) {
|
|
7856
7856
|
const Dt = d.tableFullColumn.find((Xe) => Xe.showOverflow === !1);
|
|
7857
7857
|
Dt && Gt("vxe.error.errProp", [`column[field="${Dt.field}"].show-overflow=false`, "show-overflow=true"]);
|
|
7858
7858
|
}
|
|
@@ -7874,40 +7874,40 @@ const lh = rt({
|
|
|
7874
7874
|
}, ao = () => {
|
|
7875
7875
|
pr();
|
|
7876
7876
|
}, _o = () => {
|
|
7877
|
-
const { scrollXLoad: m } = u, { visibleColumn: T, scrollXStore: O, fullColumnIdData:
|
|
7877
|
+
const { scrollXLoad: m } = u, { visibleColumn: T, scrollXStore: O, fullColumnIdData: k } = d, W = m ? T.slice(O.startIndex, O.endIndex) : T.slice(0);
|
|
7878
7878
|
W.forEach((ce, le) => {
|
|
7879
|
-
const me = ce.id, he =
|
|
7879
|
+
const me = ce.id, he = k[me];
|
|
7880
7880
|
he && (he.$index = le);
|
|
7881
7881
|
}), u.tableColumn = W;
|
|
7882
7882
|
}, Dl = () => {
|
|
7883
|
-
const { mergeList: m, mergeFooterList: T } = u, { scrollXStore: O } = d, { startIndex:
|
|
7883
|
+
const { mergeList: m, mergeFooterList: T } = u, { scrollXStore: O } = d, { startIndex: k, endIndex: W, offsetSize: ce } = O, { toVisibleIndex: le, visibleSize: me } = bn(), he = {
|
|
7884
7884
|
startIndex: Math.max(0, le - 1 - ce),
|
|
7885
7885
|
endIndex: le + me + ce
|
|
7886
7886
|
};
|
|
7887
7887
|
Ro(m.concat(T), he, "col");
|
|
7888
7888
|
const { startIndex: Pe, endIndex: Ve } = he;
|
|
7889
|
-
(le <=
|
|
7889
|
+
(le <= k || le >= W - me - 1) && (k !== Pe || W !== Ve) && (O.startIndex = Pe, O.endIndex = Ve, g.updateScrollXData()), p.closeTooltip();
|
|
7890
7890
|
}, hs = (m) => {
|
|
7891
7891
|
const T = [];
|
|
7892
7892
|
return m.forEach((O) => {
|
|
7893
7893
|
T.push(...O.children && O.children.length ? hs(O.children) : [O]);
|
|
7894
7894
|
}), T;
|
|
7895
7895
|
}, Ha = () => {
|
|
7896
|
-
const { showOverflow: m } = e, T = He.value, O = [],
|
|
7896
|
+
const { showOverflow: m } = e, T = He.value, O = [], k = [], W = [], { isGroup: ce, columnStore: le } = u, me = we.value, { collectColumn: he, tableFullColumn: Pe, scrollXStore: Ve, fullColumnIdData: _e } = d;
|
|
7897
7897
|
if (ce) {
|
|
7898
7898
|
const We = [], qe = [], ft = [];
|
|
7899
7899
|
i.eachTree(he, (Dt, Xe, Ot, zt, Kt) => {
|
|
7900
7900
|
const an = na(Dt);
|
|
7901
|
-
Kt && Kt.fixed && (Dt.fixed = Kt.fixed), Kt && Dt.fixed !== Kt.fixed && Gt("vxe.error.groupFixed"), an ? Dt.visible = !!i.findTree(Dt.children, (tn) => na(tn) ? !1 : tn.visible) : Dt.visible && (Dt.fixed === "left" ? O.push(Dt) : Dt.fixed === "right" ? W.push(Dt) :
|
|
7901
|
+
Kt && Kt.fixed && (Dt.fixed = Kt.fixed), Kt && Dt.fixed !== Kt.fixed && Gt("vxe.error.groupFixed"), an ? Dt.visible = !!i.findTree(Dt.children, (tn) => na(tn) ? !1 : tn.visible) : Dt.visible && (Dt.fixed === "left" ? O.push(Dt) : Dt.fixed === "right" ? W.push(Dt) : k.push(Dt));
|
|
7902
7902
|
}), he.forEach((Dt) => {
|
|
7903
7903
|
Dt.visible && (Dt.fixed === "left" ? We.push(Dt) : Dt.fixed === "right" ? ft.push(Dt) : qe.push(Dt));
|
|
7904
7904
|
}), u.tableGroupColumn = We.concat(qe).concat(ft);
|
|
7905
7905
|
} else
|
|
7906
7906
|
Pe.forEach((We) => {
|
|
7907
|
-
We.visible && (We.fixed === "left" ? O.push(We) : We.fixed === "right" ? W.push(We) :
|
|
7907
|
+
We.visible && (We.fixed === "left" ? O.push(We) : We.fixed === "right" ? W.push(We) : k.push(We));
|
|
7908
7908
|
});
|
|
7909
|
-
const Ne = O.concat(
|
|
7910
|
-
if (u.hasFixedColumn = O.length > 0 || W.length > 0, Object.assign(le, { leftList: O, centerList:
|
|
7909
|
+
const Ne = O.concat(k).concat(W), Je = !!me.enabled && me.gt > -1 && (me.gt === 0 || me.gt < Pe.length);
|
|
7910
|
+
if (u.hasFixedColumn = O.length > 0 || W.length > 0, Object.assign(le, { leftList: O, centerList: k, rightList: W }), Je) {
|
|
7911
7911
|
if (m && !T.height) {
|
|
7912
7912
|
const qe = d.tableFullColumn.find((ft) => ft.showOverflow === !1);
|
|
7913
7913
|
qe && Gt("vxe.error.errProp", [`column[field="${qe.field}"].show-overflow=false`, "show-overflow=true"]);
|
|
@@ -7923,8 +7923,8 @@ const lh = rt({
|
|
|
7923
7923
|
}, Cd = () => {
|
|
7924
7924
|
const { collectColumn: m } = d;
|
|
7925
7925
|
m.forEach((T, O) => {
|
|
7926
|
-
const
|
|
7927
|
-
T.sortNumber =
|
|
7926
|
+
const k = O + 1;
|
|
7927
|
+
T.sortNumber = k, T.renderSortNumber = k;
|
|
7928
7928
|
});
|
|
7929
7929
|
}, Zi = (m) => {
|
|
7930
7930
|
d.collectColumn = m;
|
|
@@ -7936,10 +7936,10 @@ const lh = rt({
|
|
|
7936
7936
|
$table: q
|
|
7937
7937
|
}), q.handleUpdateCustomColumn && q.handleUpdateCustomColumn(), p.recalculate()))));
|
|
7938
7938
|
}, Bs = (m) => {
|
|
7939
|
-
const { treeConfig: T } = e, O = de.value,
|
|
7939
|
+
const { treeConfig: T } = e, O = de.value, k = Et.value, { transform: W } = k, ce = m || d.tableFullData, le = (W || !T) && !!O.enabled && O.gt > -1 && (O.gt === 0 || O.gt < ce.length);
|
|
7940
7940
|
return u.scrollYLoad = le, le;
|
|
7941
7941
|
}, Ji = (m, T) => {
|
|
7942
|
-
const { treeExpandedMaps: O, treeExpandLazyLoadedMaps:
|
|
7942
|
+
const { treeExpandedMaps: O, treeExpandLazyLoadedMaps: k, treeNodeColumn: W } = u, ce = Object.assign({}, O), { fullAllDataRowIdData: le, tableFullData: me } = d, he = Et.value, { reserve: Pe, lazy: Ve, accordion: _e, toggleMethod: Ne } = he, Je = he.children || he.childrenField, We = he.hasChild || he.hasChildField, qe = [], ft = p.getColumnIndex(W), Dt = p.getVMColumnIndex(W);
|
|
7943
7943
|
let Xe = Ne ? m.filter((Ot) => Ne({ $table: q, expanded: T, column: W, columnIndex: ft, $columnIndex: Dt, row: Ot })) : m;
|
|
7944
7944
|
if (_e) {
|
|
7945
7945
|
Xe = Xe.length ? [Xe[Xe.length - 1]] : [];
|
|
@@ -7953,7 +7953,7 @@ const lh = rt({
|
|
|
7953
7953
|
const zt = St(q, Ot);
|
|
7954
7954
|
if (!ce[zt]) {
|
|
7955
7955
|
const Kt = le[zt];
|
|
7956
|
-
Kt && (Ve && Ot[We] && !Kt.treeLoaded && !
|
|
7956
|
+
Kt && (Ve && Ot[We] && !Kt.treeLoaded && !k[zt] ? qe.push(Wt(Ot)) : Ot[Je] && Ot[Je].length && (ce[zt] = Ot));
|
|
7957
7957
|
}
|
|
7958
7958
|
}) : Xe.forEach((Ot) => {
|
|
7959
7959
|
const zt = St(q, Ot);
|
|
@@ -7973,17 +7973,17 @@ const lh = rt({
|
|
|
7973
7973
|
checked: T
|
|
7974
7974
|
}, m);
|
|
7975
7975
|
}, ja = () => {
|
|
7976
|
-
const { showOverflow: m } = e, { mergeList: T } = u, { tableHeight: O, scrollYStore:
|
|
7976
|
+
const { showOverflow: m } = e, { mergeList: T } = u, { tableHeight: O, scrollYStore: k } = d, { startIndex: W, endIndex: ce, offsetSize: le } = k, me = m ? le : le + Math.min(8, Math.ceil(O / 200)), { toVisibleIndex: he, visibleSize: Pe } = vo(), Ve = {
|
|
7977
7977
|
startIndex: Math.max(0, he - 1 - me),
|
|
7978
7978
|
endIndex: he + Pe + me
|
|
7979
7979
|
};
|
|
7980
7980
|
Ro(T, Ve, "row");
|
|
7981
7981
|
const { startIndex: _e, endIndex: Ne } = Ve;
|
|
7982
|
-
(he <= W || he >= ce - Pe - 1) && (W !== _e || ce !== Ne) && (
|
|
7982
|
+
(he <= W || he >= ce - Pe - 1) && (W !== _e || ce !== Ne) && (k.startIndex = _e, k.endIndex = Ne, g.updateScrollYData());
|
|
7983
7983
|
}, zs = (m) => function(T) {
|
|
7984
7984
|
const { fullAllDataRowIdData: O } = d;
|
|
7985
7985
|
if (T) {
|
|
7986
|
-
const
|
|
7986
|
+
const k = St(q, T), W = O[k];
|
|
7987
7987
|
if (W)
|
|
7988
7988
|
return W[m];
|
|
7989
7989
|
}
|
|
@@ -7991,57 +7991,57 @@ const lh = rt({
|
|
|
7991
7991
|
}, ec = (m) => function(T) {
|
|
7992
7992
|
const { fullColumnIdData: O } = d;
|
|
7993
7993
|
if (T) {
|
|
7994
|
-
const
|
|
7995
|
-
if (
|
|
7996
|
-
return
|
|
7994
|
+
const k = O[T.id];
|
|
7995
|
+
if (k)
|
|
7996
|
+
return k[m];
|
|
7997
7997
|
}
|
|
7998
7998
|
return -1;
|
|
7999
7999
|
}, Ed = () => {
|
|
8000
|
-
const { lxTimeout: m, lxRunTime: T, scrollXStore: O } = d, { visibleSize:
|
|
8000
|
+
const { lxTimeout: m, lxRunTime: T, scrollXStore: O } = d, { visibleSize: k } = O, W = Math.min(80, Math.floor(k * 3));
|
|
8001
8001
|
m && clearTimeout(m), (!T || T + W < Date.now()) && (d.lxRunTime = Date.now(), Dl()), d.lxTimeout = setTimeout(() => {
|
|
8002
8002
|
d.lxRunTime = void 0, d.lxRunTime = void 0, Dl();
|
|
8003
8003
|
}, W);
|
|
8004
8004
|
}, X = () => {
|
|
8005
|
-
const { lyTimeout: m, lyRunTime: T, scrollYStore: O } = d, { visibleSize:
|
|
8005
|
+
const { lyTimeout: m, lyRunTime: T, scrollYStore: O } = d, { visibleSize: k } = O, W = Math.min(80, Math.floor(k));
|
|
8006
8006
|
m && clearTimeout(m), (!T || T + W < Date.now()) && (d.lyRunTime = Date.now(), ja()), d.lyTimeout = setTimeout(() => {
|
|
8007
8007
|
d.lyTimeout = void 0, d.lyRunTime = void 0, ja();
|
|
8008
8008
|
}, W);
|
|
8009
8009
|
}, Ae = (m) => {
|
|
8010
|
-
const { inFooterScroll: T, inBodyScroll: O, lastScrollTop:
|
|
8010
|
+
const { inFooterScroll: T, inBodyScroll: O, lastScrollTop: k } = d;
|
|
8011
8011
|
if (T || O)
|
|
8012
8012
|
return;
|
|
8013
8013
|
const W = b.value, ce = x.value, le = C.value, me = ce.$el, he = W ? W.$el : null, Pe = le ? le.$el : null, Ve = re.value, _e = m.currentTarget, { scrollLeft: Ne } = _e, Je = Ve || me;
|
|
8014
8014
|
let We = 0;
|
|
8015
8015
|
Je && (We = Je.scrollTop);
|
|
8016
|
-
const qe = !0, ft = We !==
|
|
8016
|
+
const qe = !0, ft = We !== k;
|
|
8017
8017
|
d.inVirtualScroll = !0, So(me, Ne), So(he, Ne), So(Pe, Ne), q.triggerScrollXEvent(m), q.handleScrollEvent(m, ft, qe, We, Ne, {
|
|
8018
8018
|
type: "table",
|
|
8019
8019
|
fixed: ""
|
|
8020
8020
|
});
|
|
8021
8021
|
}, Ke = (m) => {
|
|
8022
|
-
const { inFooterScroll: T, inBodyScroll: O, lastScrollLeft:
|
|
8022
|
+
const { inFooterScroll: T, inBodyScroll: O, lastScrollLeft: k } = d;
|
|
8023
8023
|
if (T || O)
|
|
8024
8024
|
return;
|
|
8025
8025
|
const W = x.value, ce = F.value, le = ne.value, me = W.$el, he = ce ? ce.$el : null, Pe = le ? le.$el : null, Ve = G.value, _e = m.currentTarget, { scrollTop: Ne } = _e, Je = Ve || me;
|
|
8026
8026
|
let We = 0;
|
|
8027
8027
|
Je && (We = Je.scrollLeft);
|
|
8028
|
-
const qe = We !==
|
|
8028
|
+
const qe = We !== k, ft = !0;
|
|
8029
8029
|
d.inVirtualScroll = !0, go(me, Ne), go(he, Ne), go(Pe, Ne), q.triggerScrollYEvent(m), q.handleScrollEvent(m, ft, qe, Ne, We, {
|
|
8030
8030
|
type: "table",
|
|
8031
8031
|
fixed: ""
|
|
8032
8032
|
});
|
|
8033
8033
|
}, ht = (m, T) => {
|
|
8034
|
-
const { scrollXLoad: O, scrollYLoad:
|
|
8034
|
+
const { scrollXLoad: O, scrollYLoad: k } = u, { lcsTimeout: W } = d;
|
|
8035
8035
|
W && clearTimeout(W), d.lcsTimeout = setTimeout(() => {
|
|
8036
|
-
d.lcsTimeout = void 0, d.inVirtualScroll = !1, d.inBodyScroll = !1, d.bodyScrollType = "", d.inFooterScroll = !1, m && O && g.updateScrollXData(), T &&
|
|
8036
|
+
d.lcsTimeout = void 0, d.inVirtualScroll = !1, d.inBodyScroll = !1, d.bodyScrollType = "", d.inFooterScroll = !1, m && O && g.updateScrollXData(), T && k && g.updateScrollYData(), p.updateCellAreas();
|
|
8037
8037
|
}, 200);
|
|
8038
8038
|
};
|
|
8039
8039
|
let It;
|
|
8040
8040
|
const Ct = (m, T, O) => {
|
|
8041
8041
|
o(m, __(O, { $table: q, $grid: ae }, T));
|
|
8042
8042
|
}, Yt = (m, T) => {
|
|
8043
|
-
const { fullColumnIdData: O } = d,
|
|
8044
|
-
return
|
|
8043
|
+
const { fullColumnIdData: O } = d, k = yo(q, m);
|
|
8044
|
+
return k && O[k.id] ? Xg(q, k, T) : pe();
|
|
8045
8045
|
};
|
|
8046
8046
|
p = {
|
|
8047
8047
|
dispatchEvent: Ct,
|
|
@@ -8094,10 +8094,10 @@ const lh = rt({
|
|
|
8094
8094
|
if (m && T) {
|
|
8095
8095
|
let O = m;
|
|
8096
8096
|
i.isArray(m) || (O = [m]);
|
|
8097
|
-
const
|
|
8097
|
+
const k = Rl(q);
|
|
8098
8098
|
O.forEach((W) => {
|
|
8099
8099
|
const ce = St(q, W), le = i.clone(Object.assign({}, T), !0);
|
|
8100
|
-
i.set(le,
|
|
8100
|
+
i.set(le, k, ce), Object.assign(W, le);
|
|
8101
8101
|
});
|
|
8102
8102
|
}
|
|
8103
8103
|
return pe();
|
|
@@ -8110,8 +8110,8 @@ const lh = rt({
|
|
|
8110
8110
|
* @param {String} field 字段名
|
|
8111
8111
|
*/
|
|
8112
8112
|
reloadRow(m, T, O) {
|
|
8113
|
-
const { keepSource:
|
|
8114
|
-
if (
|
|
8113
|
+
const { keepSource: k } = e, { tableData: W } = u, { tableSourceData: ce } = d;
|
|
8114
|
+
if (k) {
|
|
8115
8115
|
const le = p.getRowIndex(m), me = ce[le];
|
|
8116
8116
|
if (me && m)
|
|
8117
8117
|
if (O) {
|
|
@@ -8133,10 +8133,10 @@ const lh = rt({
|
|
|
8133
8133
|
* 用于树结构,给行数据加载子节点
|
|
8134
8134
|
*/
|
|
8135
8135
|
loadTreeChildren(m, T) {
|
|
8136
|
-
const { keepSource: O } = e, { tableSourceData:
|
|
8136
|
+
const { keepSource: O } = e, { tableSourceData: k, fullDataRowIdData: W, fullAllDataRowIdData: ce, sourceDataRowIdData: le } = d, me = Et.value, { transform: he, mapChildrenField: Pe } = me, Ve = me.children || me.childrenField, _e = ce[St(q, m)], Ne = _e ? _e.level : 0;
|
|
8137
8137
|
return p.createData(T).then((Je) => {
|
|
8138
8138
|
if (O) {
|
|
8139
|
-
const We = St(q, m), qe = i.findTree(
|
|
8139
|
+
const We = St(q, m), qe = i.findTree(k, (ft) => We === St(q, ft), { children: Ve });
|
|
8140
8140
|
qe && (qe.item[Ve] = i.clone(Je, !0)), Je.forEach((ft) => {
|
|
8141
8141
|
const Dt = St(q, ft);
|
|
8142
8142
|
le[Dt] = i.clone(ft, !0);
|
|
@@ -8173,14 +8173,14 @@ const lh = rt({
|
|
|
8173
8173
|
if (m) {
|
|
8174
8174
|
const { fullAllDataRowIdData: T } = d, O = m.getAttribute("rowid");
|
|
8175
8175
|
if (O) {
|
|
8176
|
-
const
|
|
8177
|
-
if (
|
|
8176
|
+
const k = T[O];
|
|
8177
|
+
if (k)
|
|
8178
8178
|
return {
|
|
8179
|
-
rowid:
|
|
8180
|
-
item:
|
|
8181
|
-
index:
|
|
8182
|
-
items:
|
|
8183
|
-
parent:
|
|
8179
|
+
rowid: k.rowid,
|
|
8180
|
+
item: k.row,
|
|
8181
|
+
index: k.index,
|
|
8182
|
+
items: k.items,
|
|
8183
|
+
parent: k.parent
|
|
8184
8184
|
};
|
|
8185
8185
|
}
|
|
8186
8186
|
}
|
|
@@ -8194,14 +8194,14 @@ const lh = rt({
|
|
|
8194
8194
|
if (m) {
|
|
8195
8195
|
const { fullColumnIdData: T } = d, O = m.getAttribute("colid");
|
|
8196
8196
|
if (O) {
|
|
8197
|
-
const
|
|
8198
|
-
if (
|
|
8197
|
+
const k = T[O];
|
|
8198
|
+
if (k)
|
|
8199
8199
|
return {
|
|
8200
|
-
colid:
|
|
8201
|
-
item:
|
|
8202
|
-
index:
|
|
8203
|
-
items:
|
|
8204
|
-
parent:
|
|
8200
|
+
colid: k.colid,
|
|
8201
|
+
item: k.column,
|
|
8202
|
+
index: k.index,
|
|
8203
|
+
items: k.items,
|
|
8204
|
+
parent: k.parent
|
|
8205
8205
|
};
|
|
8206
8206
|
}
|
|
8207
8207
|
}
|
|
@@ -8284,7 +8284,7 @@ const lh = rt({
|
|
|
8284
8284
|
* 如果还额外传了 field 则还原指定的单元格数据
|
|
8285
8285
|
*/
|
|
8286
8286
|
revertData(m, T) {
|
|
8287
|
-
const { keepSource: O } = e, { tableSourceData:
|
|
8287
|
+
const { keepSource: O } = e, { tableSourceData: k, sourceDataRowIdData: W } = d;
|
|
8288
8288
|
if (!O)
|
|
8289
8289
|
return process.env.NODE_ENV === "development" && sn("vxe.error.reqProp", ["keep-source"]), pe();
|
|
8290
8290
|
let ce = m;
|
|
@@ -8293,7 +8293,7 @@ const lh = rt({
|
|
|
8293
8293
|
const me = St(q, le), he = W[me];
|
|
8294
8294
|
he && le && (T ? i.set(le, T, i.clone(i.get(he, T), !0)) : i.destructuring(le, i.clone(he, !0)));
|
|
8295
8295
|
}
|
|
8296
|
-
}), m ? pe() : p.reloadData(
|
|
8296
|
+
}), m ? pe() : p.reloadData(k);
|
|
8297
8297
|
},
|
|
8298
8298
|
/**
|
|
8299
8299
|
* 清空单元格内容
|
|
@@ -8305,9 +8305,9 @@ const lh = rt({
|
|
|
8305
8305
|
* @param {String} field 字段名
|
|
8306
8306
|
*/
|
|
8307
8307
|
clearData(m, T) {
|
|
8308
|
-
const { tableFullData: O, visibleColumn:
|
|
8308
|
+
const { tableFullData: O, visibleColumn: k } = d;
|
|
8309
8309
|
return arguments.length ? m && !i.isArray(m) && (m = [m]) : m = O, T ? m.forEach((W) => i.set(W, T, null)) : m.forEach((W) => {
|
|
8310
|
-
|
|
8310
|
+
k.forEach((ce) => {
|
|
8311
8311
|
ce.field && pl(W, ce, null);
|
|
8312
8312
|
});
|
|
8313
8313
|
}), pe();
|
|
@@ -8316,30 +8316,30 @@ const lh = rt({
|
|
|
8316
8316
|
const O = yo(q, T);
|
|
8317
8317
|
if (!O)
|
|
8318
8318
|
return null;
|
|
8319
|
-
const
|
|
8319
|
+
const k = St(q, m), W = x.value, ce = F.value, le = ne.value;
|
|
8320
8320
|
let me;
|
|
8321
|
-
return O && (O.fixed && (O.fixed === "left" ? ce && (me = ce.$el) : le && (me = le.$el)), me || (me = W.$el), me) ? me.querySelector(`.vxe-body--row[rowid="${
|
|
8321
|
+
return O && (O.fixed && (O.fixed === "left" ? ce && (me = ce.$el) : le && (me = le.$el)), me || (me = W.$el), me) ? me.querySelector(`.vxe-body--row[rowid="${k}"] .${O.id}`) : null;
|
|
8322
8322
|
},
|
|
8323
8323
|
getCellLabel(m, T) {
|
|
8324
8324
|
const O = yo(q, T);
|
|
8325
8325
|
if (!O)
|
|
8326
8326
|
return null;
|
|
8327
|
-
const
|
|
8327
|
+
const k = O.formatter, W = Mo(m, O);
|
|
8328
8328
|
let ce = W;
|
|
8329
|
-
if (
|
|
8329
|
+
if (k) {
|
|
8330
8330
|
let le;
|
|
8331
8331
|
const { fullAllDataRowIdData: me } = d, he = St(q, m), Pe = O.id, Ve = me[he];
|
|
8332
8332
|
if (Ve && (le = Ve.formatData, le || (le = me[he].formatData = {}), Ve && le[Pe] && le[Pe].value === W))
|
|
8333
8333
|
return le[Pe].label;
|
|
8334
8334
|
const _e = { cellValue: W, row: m, rowIndex: p.getRowIndex(m), column: O, columnIndex: p.getColumnIndex(O) };
|
|
8335
|
-
if (i.isString(
|
|
8336
|
-
const Ne = ih.get(
|
|
8335
|
+
if (i.isString(k)) {
|
|
8336
|
+
const Ne = ih.get(k), Je = Ne ? Ne.tableCellFormatMethod || Ne.cellFormatMethod : null;
|
|
8337
8337
|
ce = Je ? Je(_e) : "";
|
|
8338
|
-
} else if (i.isArray(
|
|
8339
|
-
const Ne = ih.get(
|
|
8340
|
-
ce = Je ? Je(_e, ...
|
|
8338
|
+
} else if (i.isArray(k)) {
|
|
8339
|
+
const Ne = ih.get(k[0]), Je = Ne ? Ne.tableCellFormatMethod || Ne.cellFormatMethod : null;
|
|
8340
|
+
ce = Je ? Je(_e, ...k.slice(1)) : "";
|
|
8341
8341
|
} else
|
|
8342
|
-
ce =
|
|
8342
|
+
ce = k(_e);
|
|
8343
8343
|
le && (le[Pe] = { value: W, label: ce });
|
|
8344
8344
|
}
|
|
8345
8345
|
return ce;
|
|
@@ -8366,7 +8366,7 @@ const lh = rt({
|
|
|
8366
8366
|
* @param {String} field 字段名
|
|
8367
8367
|
*/
|
|
8368
8368
|
isUpdateByRow(m, T) {
|
|
8369
|
-
const { keepSource: O } = e, { tableFullColumn:
|
|
8369
|
+
const { keepSource: O } = e, { tableFullColumn: k, fullDataRowIdData: W, sourceDataRowIdData: ce } = d;
|
|
8370
8370
|
if (O) {
|
|
8371
8371
|
const le = St(q, m);
|
|
8372
8372
|
if (!W[le])
|
|
@@ -8375,8 +8375,8 @@ const lh = rt({
|
|
|
8375
8375
|
if (me) {
|
|
8376
8376
|
if (arguments.length > 1)
|
|
8377
8377
|
return !on(me, m, T);
|
|
8378
|
-
for (let he = 0, Pe =
|
|
8379
|
-
const Ve =
|
|
8378
|
+
for (let he = 0, Pe = k.length; he < Pe; he++) {
|
|
8379
|
+
const Ve = k[he].field;
|
|
8380
8380
|
if (Ve && !on(me, m, Ve))
|
|
8381
8381
|
return !0;
|
|
8382
8382
|
}
|
|
@@ -8449,9 +8449,9 @@ const lh = rt({
|
|
|
8449
8449
|
* 用于多选行,获取已选中的数据
|
|
8450
8450
|
*/
|
|
8451
8451
|
getCheckboxRecords(m) {
|
|
8452
|
-
const { treeConfig: T } = e, { tableFullData: O, afterFullData:
|
|
8452
|
+
const { treeConfig: T } = e, { tableFullData: O, afterFullData: k, afterTreeFullData: W, tableFullTreeData: ce, fullDataRowIdData: le, afterFullRowMaps: me } = d, he = Et.value, Pe = ke.value, { transform: Ve, mapChildrenField: _e } = he, { checkField: Ne } = Pe, Je = he.children || he.childrenField;
|
|
8453
8453
|
let We = [];
|
|
8454
|
-
const qe = m ? Ve ? ce : O : Ve ? W :
|
|
8454
|
+
const qe = m ? Ve ? ce : O : Ve ? W : k;
|
|
8455
8455
|
if (Ne)
|
|
8456
8456
|
T ? We = i.filterTree(qe, (ft) => i.get(ft, Ne), { children: Ve ? _e : Je }) : We = qe.filter((ft) => i.get(ft, Ne));
|
|
8457
8457
|
else {
|
|
@@ -8466,7 +8466,7 @@ const lh = rt({
|
|
|
8466
8466
|
* 只对 tree-config 有效,获取行的子级
|
|
8467
8467
|
*/
|
|
8468
8468
|
getTreeRowChildren(m) {
|
|
8469
|
-
const { treeConfig: T } = e, { fullDataRowIdData: O } = d,
|
|
8469
|
+
const { treeConfig: T } = e, { fullDataRowIdData: O } = d, k = Et.value, { transform: W, mapChildrenField: ce } = k, le = k.children || k.childrenField;
|
|
8470
8470
|
if (m && T) {
|
|
8471
8471
|
let me;
|
|
8472
8472
|
if (i.isString(m) ? me = m : me = St(q, m), me) {
|
|
@@ -8483,9 +8483,9 @@ const lh = rt({
|
|
|
8483
8483
|
getTreeParentRow(m) {
|
|
8484
8484
|
const { treeConfig: T } = e, { fullDataRowIdData: O } = d;
|
|
8485
8485
|
if (m && T) {
|
|
8486
|
-
let
|
|
8487
|
-
if (i.isString(m) ?
|
|
8488
|
-
const W = O[
|
|
8486
|
+
let k;
|
|
8487
|
+
if (i.isString(m) ? k = m : k = St(q, m), k) {
|
|
8488
|
+
const W = O[k];
|
|
8489
8489
|
return W ? W.parent : null;
|
|
8490
8490
|
}
|
|
8491
8491
|
}
|
|
@@ -8515,10 +8515,10 @@ const lh = rt({
|
|
|
8515
8515
|
* 如果存在排序,继续处理
|
|
8516
8516
|
*/
|
|
8517
8517
|
getTableData() {
|
|
8518
|
-
const { tableData: m, footerTableData: T } = u, { tableFullData: O, afterFullData:
|
|
8518
|
+
const { tableData: m, footerTableData: T } = u, { tableFullData: O, afterFullData: k, tableFullTreeData: W } = d;
|
|
8519
8519
|
return {
|
|
8520
8520
|
fullData: e.treeConfig ? W.slice(0) : O.slice(0),
|
|
8521
|
-
visibleData:
|
|
8521
|
+
visibleData: k.slice(0),
|
|
8522
8522
|
tableData: m.slice(0),
|
|
8523
8523
|
footerData: T.slice(0)
|
|
8524
8524
|
};
|
|
@@ -8529,7 +8529,7 @@ const lh = rt({
|
|
|
8529
8529
|
getFullData() {
|
|
8530
8530
|
const { treeConfig: m } = e, { tableFullData: T, tableFullTreeData: O } = d;
|
|
8531
8531
|
if (m) {
|
|
8532
|
-
const
|
|
8532
|
+
const k = Et.value, { transform: W, mapChildrenField: ce } = k, le = k.children || k.childrenField;
|
|
8533
8533
|
return W ? i.toArrayTree(i.toTreeArray(O, {
|
|
8534
8534
|
children: ce
|
|
8535
8535
|
}), { children: le }) : O.slice(0);
|
|
@@ -8541,9 +8541,9 @@ const lh = rt({
|
|
|
8541
8541
|
*/
|
|
8542
8542
|
setColumnFixed(m, T) {
|
|
8543
8543
|
let O = !1;
|
|
8544
|
-
const
|
|
8545
|
-
for (let le = 0; le <
|
|
8546
|
-
const me =
|
|
8544
|
+
const k = i.isArray(m) ? m : [m], W = Ye.value, ce = it.value;
|
|
8545
|
+
for (let le = 0; le < k.length; le++) {
|
|
8546
|
+
const me = k[le], he = yo(q, me), Pe = Kg(q, he);
|
|
8547
8547
|
if (Pe && Pe.fixed !== T) {
|
|
8548
8548
|
if (!Pe.fixed && ce)
|
|
8549
8549
|
return ye.modal && ye.modal.message({
|
|
@@ -8562,8 +8562,8 @@ const lh = rt({
|
|
|
8562
8562
|
*/
|
|
8563
8563
|
clearColumnFixed(m) {
|
|
8564
8564
|
let T = !1;
|
|
8565
|
-
return (i.isArray(m) ? m : [m]).forEach((
|
|
8566
|
-
const W = yo(q,
|
|
8565
|
+
return (i.isArray(m) ? m : [m]).forEach((k) => {
|
|
8566
|
+
const W = yo(q, k), ce = Kg(q, W);
|
|
8567
8567
|
ce && ce.fixed && (i.eachTree([ce], (le) => {
|
|
8568
8568
|
le.fixed = null;
|
|
8569
8569
|
}), g.saveCustomStore("update:fixed"), T || (T = !0));
|
|
@@ -8574,8 +8574,8 @@ const lh = rt({
|
|
|
8574
8574
|
*/
|
|
8575
8575
|
hideColumn(m) {
|
|
8576
8576
|
let T = !1;
|
|
8577
|
-
return (i.isArray(m) ? m : [m]).forEach((
|
|
8578
|
-
const W = yo(q,
|
|
8577
|
+
return (i.isArray(m) ? m : [m]).forEach((k) => {
|
|
8578
|
+
const W = yo(q, k);
|
|
8579
8579
|
W && W.visible && (W.visible = !1, T || (T = !0));
|
|
8580
8580
|
}), T ? g.handleCustom() : pe();
|
|
8581
8581
|
},
|
|
@@ -8584,8 +8584,8 @@ const lh = rt({
|
|
|
8584
8584
|
*/
|
|
8585
8585
|
showColumn(m) {
|
|
8586
8586
|
let T = !1;
|
|
8587
|
-
return (i.isArray(m) ? m : [m]).forEach((
|
|
8588
|
-
const W = yo(q,
|
|
8587
|
+
return (i.isArray(m) ? m : [m]).forEach((k) => {
|
|
8588
|
+
const W = yo(q, k);
|
|
8589
8589
|
W && !W.visible && (W.visible = !0, T || (T = !0));
|
|
8590
8590
|
}), T ? g.handleCustom() : pe();
|
|
8591
8591
|
},
|
|
@@ -8634,7 +8634,7 @@ const lh = rt({
|
|
|
8634
8634
|
* 刷新滚动操作,手动同步滚动相关位置(对于某些特殊的操作,比如滚动条错位、固定列不同步)
|
|
8635
8635
|
*/
|
|
8636
8636
|
refreshScroll() {
|
|
8637
|
-
const { lastScrollLeft: m, lastScrollTop: T } = d, O = x.value,
|
|
8637
|
+
const { lastScrollLeft: m, lastScrollTop: T } = d, O = x.value, k = C.value, W = F.value, ce = ne.value, le = O ? O.$el : null, me = W ? W.$el : null, he = ce ? ce.$el : null, Pe = k ? k.$el : null;
|
|
8638
8638
|
return new Promise((Ve) => {
|
|
8639
8639
|
if (m || T)
|
|
8640
8640
|
return ef(q, m, T).then().then(() => {
|
|
@@ -8649,8 +8649,8 @@ const lh = rt({
|
|
|
8649
8649
|
*/
|
|
8650
8650
|
recalculate(m) {
|
|
8651
8651
|
return new Promise((T) => {
|
|
8652
|
-
const { rceTimeout: O } = d,
|
|
8653
|
-
|
|
8652
|
+
const { rceTimeout: O } = d, k = h.value;
|
|
8653
|
+
k && k.clientWidth && zr(), O ? (clearTimeout(O), pe(() => {
|
|
8654
8654
|
T();
|
|
8655
8655
|
})) : T(Jo(!!m)), d.rceTimeout = setTimeout(() => {
|
|
8656
8656
|
d.rceTimeout = void 0, Jo(!!m);
|
|
@@ -8690,10 +8690,10 @@ const lh = rt({
|
|
|
8690
8690
|
* 获取复选框半选状态的行数据
|
|
8691
8691
|
*/
|
|
8692
8692
|
getCheckboxIndeterminateRecords(m) {
|
|
8693
|
-
const { treeConfig: T } = e, { fullDataRowIdData: O } = d, { treeIndeterminateMaps:
|
|
8693
|
+
const { treeConfig: T } = e, { fullDataRowIdData: O } = d, { treeIndeterminateMaps: k } = u;
|
|
8694
8694
|
if (T) {
|
|
8695
8695
|
const W = [], ce = [];
|
|
8696
|
-
return i.each(
|
|
8696
|
+
return i.each(k, (le, me) => {
|
|
8697
8697
|
le && (W.push(le), O[me] && ce.push(le));
|
|
8698
8698
|
}), m ? W : ce;
|
|
8699
8699
|
}
|
|
@@ -8710,18 +8710,18 @@ const lh = rt({
|
|
|
8710
8710
|
setCheckboxRowKey(m, T) {
|
|
8711
8711
|
const { fullAllDataRowIdData: O } = d;
|
|
8712
8712
|
i.isArray(m) || (m = [m]);
|
|
8713
|
-
const
|
|
8713
|
+
const k = [];
|
|
8714
8714
|
return m.forEach((W) => {
|
|
8715
8715
|
const ce = O[W];
|
|
8716
|
-
ce &&
|
|
8717
|
-
}), Ze(
|
|
8716
|
+
ce && k.push(ce.row);
|
|
8717
|
+
}), Ze(k, T, !0);
|
|
8718
8718
|
},
|
|
8719
8719
|
isCheckedByCheckboxRow(m) {
|
|
8720
|
-
const { selectCheckboxMaps: T } = u, O = ke.value, { checkField:
|
|
8721
|
-
return
|
|
8720
|
+
const { selectCheckboxMaps: T } = u, O = ke.value, { checkField: k } = O;
|
|
8721
|
+
return k ? i.get(m, k) : !!T[St(q, m)];
|
|
8722
8722
|
},
|
|
8723
8723
|
isCheckedByCheckboxRowKey(m) {
|
|
8724
|
-
const { selectCheckboxMaps: T } = u, { fullAllDataRowIdData: O } = d,
|
|
8724
|
+
const { selectCheckboxMaps: T } = u, { fullAllDataRowIdData: O } = d, k = ke.value, { checkField: W } = k;
|
|
8725
8725
|
if (W) {
|
|
8726
8726
|
const ce = O[m];
|
|
8727
8727
|
return ce ? i.get(ce.row, W) : !1;
|
|
@@ -8740,7 +8740,7 @@ const lh = rt({
|
|
|
8740
8740
|
* 多选,切换某一行的选中状态
|
|
8741
8741
|
*/
|
|
8742
8742
|
toggleCheckboxRow(m) {
|
|
8743
|
-
const { selectCheckboxMaps: T } = u, O = ke.value, { checkField:
|
|
8743
|
+
const { selectCheckboxMaps: T } = u, O = ke.value, { checkField: k } = O, W = k ? !i.get(m, k) : !T[St(q, m)];
|
|
8744
8744
|
return g.handleBatchSelectRows([m], W, !0), g.checkSelectionStatus(), pe();
|
|
8745
8745
|
},
|
|
8746
8746
|
/**
|
|
@@ -8754,19 +8754,19 @@ const lh = rt({
|
|
|
8754
8754
|
* 获取单选框保留选中的行
|
|
8755
8755
|
*/
|
|
8756
8756
|
getRadioReserveRecord(m) {
|
|
8757
|
-
const { treeConfig: T } = e, { fullDataRowIdData: O, radioReserveRow:
|
|
8758
|
-
if (ce.reserve &&
|
|
8759
|
-
const he = St(q,
|
|
8757
|
+
const { treeConfig: T } = e, { fullDataRowIdData: O, radioReserveRow: k, afterFullData: W } = d, ce = pt.value, le = Et.value, me = le.children || le.childrenField;
|
|
8758
|
+
if (ce.reserve && k) {
|
|
8759
|
+
const he = St(q, k);
|
|
8760
8760
|
if (m) {
|
|
8761
8761
|
if (!O[he])
|
|
8762
|
-
return
|
|
8762
|
+
return k;
|
|
8763
8763
|
} else {
|
|
8764
8764
|
const Pe = Rl(q);
|
|
8765
8765
|
if (T) {
|
|
8766
8766
|
if (i.findTree(W, (_e) => he === i.get(_e, Pe), { children: me }))
|
|
8767
|
-
return
|
|
8767
|
+
return k;
|
|
8768
8768
|
} else if (!W.some((Ve) => he === i.get(Ve, Pe)))
|
|
8769
|
-
return
|
|
8769
|
+
return k;
|
|
8770
8770
|
}
|
|
8771
8771
|
}
|
|
8772
8772
|
return null;
|
|
@@ -8778,7 +8778,7 @@ const lh = rt({
|
|
|
8778
8778
|
* 获取复选框保留选中的行
|
|
8779
8779
|
*/
|
|
8780
8780
|
getCheckboxReserveRecords(m) {
|
|
8781
|
-
const { treeConfig: T } = e, { afterFullData: O, fullDataRowIdData:
|
|
8781
|
+
const { treeConfig: T } = e, { afterFullData: O, fullDataRowIdData: k, checkboxReserveRowMap: W } = d, ce = ke.value, le = Et.value, me = le.children || le.childrenField, he = [];
|
|
8782
8782
|
if (ce.reserve) {
|
|
8783
8783
|
const Pe = {};
|
|
8784
8784
|
T ? i.eachTree(O, (Ve) => {
|
|
@@ -8786,7 +8786,7 @@ const lh = rt({
|
|
|
8786
8786
|
}, { children: me }) : O.forEach((Ve) => {
|
|
8787
8787
|
Pe[St(q, Ve)] = 1;
|
|
8788
8788
|
}), i.each(W, (Ve, _e) => {
|
|
8789
|
-
Ve && (m ?
|
|
8789
|
+
Ve && (m ? k[_e] || he.push(Ve) : Pe[_e] || he.push(Ve));
|
|
8790
8790
|
});
|
|
8791
8791
|
}
|
|
8792
8792
|
return he;
|
|
@@ -8805,12 +8805,12 @@ const lh = rt({
|
|
|
8805
8805
|
* 清空行为不管是否被禁用还是保留记录,都将彻底清空选中状态
|
|
8806
8806
|
*/
|
|
8807
8807
|
clearCheckboxRow() {
|
|
8808
|
-
const { treeConfig: m } = e, { tableFullData: T } = d, O = Et.value,
|
|
8808
|
+
const { treeConfig: m } = e, { tableFullData: T } = d, O = Et.value, k = O.children || O.childrenField, W = ke.value, { checkField: ce, reserve: le } = W, me = W.indeterminateField || W.halfField;
|
|
8809
8809
|
if (ce) {
|
|
8810
8810
|
const he = (Pe) => {
|
|
8811
8811
|
m && me && i.set(Pe, me, !1), i.set(Pe, ce, !1);
|
|
8812
8812
|
};
|
|
8813
|
-
m ? i.eachTree(T, he, { children:
|
|
8813
|
+
m ? i.eachTree(T, he, { children: k }) : T.forEach(he);
|
|
8814
8814
|
}
|
|
8815
8815
|
return le && T.forEach((he) => fe(he, !1)), u.isAllSelected = !1, u.isIndeterminate = !1, u.selectCheckboxMaps = {}, u.treeIndeterminateMaps = {}, pe();
|
|
8816
8816
|
},
|
|
@@ -8820,7 +8820,7 @@ const lh = rt({
|
|
|
8820
8820
|
*/
|
|
8821
8821
|
setCurrentRow(m) {
|
|
8822
8822
|
const T = He.value, O = h.value;
|
|
8823
|
-
return p.clearCurrentRow(), u.currentRow = m, (T.isCurrent || e.highlightCurrentRow) && O && i.arrayEach(O.querySelectorAll(`[rowid="${St(q, m)}"]`), (
|
|
8823
|
+
return p.clearCurrentRow(), u.currentRow = m, (T.isCurrent || e.highlightCurrentRow) && O && i.arrayEach(O.querySelectorAll(`[rowid="${St(q, m)}"]`), (k) => fl(k, "row--current")), pe();
|
|
8824
8824
|
},
|
|
8825
8825
|
isCheckedByRadioRow(m) {
|
|
8826
8826
|
const { selectRadioRow: T } = u;
|
|
@@ -8868,14 +8868,14 @@ const lh = rt({
|
|
|
8868
8868
|
* 用于单选行,获取当已选中的数据
|
|
8869
8869
|
*/
|
|
8870
8870
|
getRadioRecord(m) {
|
|
8871
|
-
const { fullDataRowIdData: T, afterFullRowMaps: O } = d, { selectRadioRow:
|
|
8872
|
-
if (
|
|
8873
|
-
const W = St(q,
|
|
8871
|
+
const { fullDataRowIdData: T, afterFullRowMaps: O } = d, { selectRadioRow: k } = u;
|
|
8872
|
+
if (k) {
|
|
8873
|
+
const W = St(q, k);
|
|
8874
8874
|
if (m) {
|
|
8875
8875
|
if (T[W])
|
|
8876
|
-
return
|
|
8876
|
+
return k;
|
|
8877
8877
|
} else if (O[W])
|
|
8878
|
-
return
|
|
8878
|
+
return k;
|
|
8879
8879
|
}
|
|
8880
8880
|
return null;
|
|
8881
8881
|
},
|
|
@@ -8897,19 +8897,19 @@ const lh = rt({
|
|
|
8897
8897
|
},
|
|
8898
8898
|
setPendingRow(m, T) {
|
|
8899
8899
|
const O = Object.assign({}, u.pendingRowMaps);
|
|
8900
|
-
return m && !i.isArray(m) && (m = [m]), T ? m.forEach((
|
|
8901
|
-
const W = St(q,
|
|
8902
|
-
W && !O[W] && (O[W] =
|
|
8903
|
-
}) : m.forEach((
|
|
8904
|
-
const W = St(q,
|
|
8900
|
+
return m && !i.isArray(m) && (m = [m]), T ? m.forEach((k) => {
|
|
8901
|
+
const W = St(q, k);
|
|
8902
|
+
W && !O[W] && (O[W] = k);
|
|
8903
|
+
}) : m.forEach((k) => {
|
|
8904
|
+
const W = St(q, k);
|
|
8905
8905
|
W && O[W] && delete O[W];
|
|
8906
8906
|
}), u.pendingRowMaps = O, pe();
|
|
8907
8907
|
},
|
|
8908
8908
|
togglePendingRow(m) {
|
|
8909
8909
|
const T = Object.assign({}, u.pendingRowMaps);
|
|
8910
8910
|
return m && !i.isArray(m) && (m = [m]), m.forEach((O) => {
|
|
8911
|
-
const
|
|
8912
|
-
|
|
8911
|
+
const k = St(q, O);
|
|
8912
|
+
k && (T[k] ? delete T[k] : T[k] = O);
|
|
8913
8913
|
}), u.pendingRowMaps = T, pe();
|
|
8914
8914
|
},
|
|
8915
8915
|
hasPendingByRow(m) {
|
|
@@ -8921,26 +8921,26 @@ const lh = rt({
|
|
|
8921
8921
|
},
|
|
8922
8922
|
getPendingRecords() {
|
|
8923
8923
|
const { pendingRowMaps: m } = u, { fullAllDataRowIdData: T } = d, O = [];
|
|
8924
|
-
return i.each(m, (
|
|
8925
|
-
T[W] && O.push(
|
|
8924
|
+
return i.each(m, (k, W) => {
|
|
8925
|
+
T[W] && O.push(k);
|
|
8926
8926
|
}), O;
|
|
8927
8927
|
},
|
|
8928
8928
|
clearPendingRow() {
|
|
8929
8929
|
return u.pendingRowMaps = {}, pe();
|
|
8930
8930
|
},
|
|
8931
8931
|
sort(m, T) {
|
|
8932
|
-
const O = $.value, { multiple:
|
|
8932
|
+
const O = $.value, { multiple: k, remote: W, orders: ce } = O;
|
|
8933
8933
|
return m && i.isString(m) && (m = [
|
|
8934
8934
|
{ field: m, order: T }
|
|
8935
|
-
]), i.isArray(m) || (m = [m]), m.length ? (
|
|
8935
|
+
]), i.isArray(m) || (m = [m]), m.length ? (k || Wo(), (k ? m : [m[0]]).forEach((le, me) => {
|
|
8936
8936
|
let { field: he, order: Pe } = le, Ve = he;
|
|
8937
8937
|
i.isString(he) && (Ve = p.getColumnByField(he)), Ve && Ve.sortable && (ce.indexOf(Pe) === -1 && (Pe = rn(Ve)), Ve.order !== Pe && (Ve.order = Pe), Ve.sortTime = Date.now() + me);
|
|
8938
8938
|
}), W || g.handleTableData(!0), pe().then(() => (p.updateCellAreas(), mo()))) : pe();
|
|
8939
8939
|
},
|
|
8940
8940
|
setSort(m, T) {
|
|
8941
|
-
const O = $.value, { multiple:
|
|
8941
|
+
const O = $.value, { multiple: k, remote: W, orders: ce } = O;
|
|
8942
8942
|
if (i.isArray(m) || (m = [m]), m && m.length) {
|
|
8943
|
-
|
|
8943
|
+
k || (m = [m[0]], Wo());
|
|
8944
8944
|
let le = null;
|
|
8945
8945
|
return m.forEach((me, he) => {
|
|
8946
8946
|
let { field: Pe, order: Ve } = me, _e = Pe;
|
|
@@ -8971,11 +8971,11 @@ const lh = rt({
|
|
|
8971
8971
|
return p.getSortColumns().length > 0;
|
|
8972
8972
|
},
|
|
8973
8973
|
getSortColumns() {
|
|
8974
|
-
const m = $.value, { multiple: T, chronological: O } = m,
|
|
8974
|
+
const m = $.value, { multiple: T, chronological: O } = m, k = [], { tableFullColumn: W } = d;
|
|
8975
8975
|
return W.forEach((ce) => {
|
|
8976
8976
|
const { field: le, order: me } = ce;
|
|
8977
|
-
ce.sortable && me &&
|
|
8978
|
-
}), T && O &&
|
|
8977
|
+
ce.sortable && me && k.push({ column: ce, field: le, property: le, order: me, sortTime: ce.sortTime });
|
|
8978
|
+
}), T && O && k.length > 1 ? i.orderBy(k, "sortTime") : k;
|
|
8979
8979
|
},
|
|
8980
8980
|
/**
|
|
8981
8981
|
* 关闭筛选
|
|
@@ -9010,7 +9010,7 @@ const lh = rt({
|
|
|
9010
9010
|
return O && !!O.expandLoaded;
|
|
9011
9011
|
},
|
|
9012
9012
|
clearRowExpandLoaded(m) {
|
|
9013
|
-
const { rowExpandLazyLoadedMaps: T } = u, { fullAllDataRowIdData: O } = d,
|
|
9013
|
+
const { rowExpandLazyLoadedMaps: T } = u, { fullAllDataRowIdData: O } = d, k = ut.value, { lazy: W } = k, ce = St(q, m), le = O[ce];
|
|
9014
9014
|
return W && le && (le.expandLoaded = !1, delete T[ce]), pe();
|
|
9015
9015
|
},
|
|
9016
9016
|
/**
|
|
@@ -9018,8 +9018,8 @@ const lh = rt({
|
|
|
9018
9018
|
* @param {Row} row 行对象
|
|
9019
9019
|
*/
|
|
9020
9020
|
reloadRowExpand(m) {
|
|
9021
|
-
const { rowExpandLazyLoadedMaps: T } = u, O = ut.value, { lazy:
|
|
9022
|
-
return
|
|
9021
|
+
const { rowExpandLazyLoadedMaps: T } = u, O = ut.value, { lazy: k } = O, W = St(q, m);
|
|
9022
|
+
return k && !T[W] && p.clearRowExpandLoaded(m).then(() => st(m)), pe();
|
|
9023
9023
|
},
|
|
9024
9024
|
reloadExpandContent(m) {
|
|
9025
9025
|
return process.env.NODE_ENV === "development" && sn("vxe.error.delFunc", ["reloadExpandContent", "reloadRowExpand"]), p.reloadRowExpand(m);
|
|
@@ -9035,9 +9035,9 @@ const lh = rt({
|
|
|
9035
9035
|
* @param {Boolean} expanded 是否展开
|
|
9036
9036
|
*/
|
|
9037
9037
|
setAllRowExpand(m) {
|
|
9038
|
-
const T = Et.value, { tableFullData: O, tableFullTreeData:
|
|
9038
|
+
const T = Et.value, { tableFullData: O, tableFullTreeData: k } = d, W = T.children || T.childrenField;
|
|
9039
9039
|
let ce = [];
|
|
9040
|
-
return e.treeConfig ? i.eachTree(
|
|
9040
|
+
return e.treeConfig ? i.eachTree(k, (le) => {
|
|
9041
9041
|
ce.push(le);
|
|
9042
9042
|
}, { children: W }) : ce = O, p.setRowExpand(ce, m);
|
|
9043
9043
|
},
|
|
@@ -9049,7 +9049,7 @@ const lh = rt({
|
|
|
9049
9049
|
* @param {Boolean} expanded 是否展开
|
|
9050
9050
|
*/
|
|
9051
9051
|
setRowExpand(m, T) {
|
|
9052
|
-
const { rowExpandedMaps: O, rowExpandLazyLoadedMaps:
|
|
9052
|
+
const { rowExpandedMaps: O, rowExpandLazyLoadedMaps: k, expandColumn: W } = u, { fullAllDataRowIdData: ce } = d;
|
|
9053
9053
|
let le = Object.assign({}, O);
|
|
9054
9054
|
const me = ut.value, { reserve: he, lazy: Pe, accordion: Ve, toggleMethod: _e } = me, Ne = [], Je = p.getColumnIndex(W), We = p.getVMColumnIndex(W);
|
|
9055
9055
|
if (m) {
|
|
@@ -9059,7 +9059,7 @@ const lh = rt({
|
|
|
9059
9059
|
const Dt = St(q, ft);
|
|
9060
9060
|
if (!le[Dt]) {
|
|
9061
9061
|
const Xe = ce[Dt];
|
|
9062
|
-
Pe && !Xe.expandLoaded && !
|
|
9062
|
+
Pe && !Xe.expandLoaded && !k[Dt] ? Ne.push(st(ft)) : le[Dt] = ft;
|
|
9063
9063
|
}
|
|
9064
9064
|
}) : qe.forEach((ft) => {
|
|
9065
9065
|
const Dt = St(q, ft);
|
|
@@ -9083,9 +9083,9 @@ const lh = rt({
|
|
|
9083
9083
|
* 手动清空展开行状态,数据会恢复成未展开的状态
|
|
9084
9084
|
*/
|
|
9085
9085
|
clearRowExpand() {
|
|
9086
|
-
const { tableFullData: m } = d, T = ut.value, { reserve: O } = T,
|
|
9086
|
+
const { tableFullData: m } = d, T = ut.value, { reserve: O } = T, k = p.getRowExpandRecords();
|
|
9087
9087
|
return u.rowExpandedMaps = {}, O && m.forEach((W) => Tt(W, !1)), pe().then(() => {
|
|
9088
|
-
|
|
9088
|
+
k.length && p.recalculate();
|
|
9089
9089
|
});
|
|
9090
9090
|
},
|
|
9091
9091
|
clearRowExpandReserve() {
|
|
@@ -9112,7 +9112,7 @@ const lh = rt({
|
|
|
9112
9112
|
return O && !!O.treeLoaded;
|
|
9113
9113
|
},
|
|
9114
9114
|
clearTreeExpandLoaded(m) {
|
|
9115
|
-
const { treeExpandedMaps: T } = u, { fullAllDataRowIdData: O } = d,
|
|
9115
|
+
const { treeExpandedMaps: T } = u, { fullAllDataRowIdData: O } = d, k = Et.value, { transform: W } = k;
|
|
9116
9116
|
return m && (i.isArray(m) || (m = [m]), m.forEach((ce) => {
|
|
9117
9117
|
const le = St(q, ce), me = O[le];
|
|
9118
9118
|
me && (me.treeLoaded = !1, T[le] && delete T[le]);
|
|
@@ -9123,8 +9123,8 @@ const lh = rt({
|
|
|
9123
9123
|
* @param {Row} row 行对象
|
|
9124
9124
|
*/
|
|
9125
9125
|
reloadTreeExpand(m) {
|
|
9126
|
-
const { treeExpandLazyLoadedMaps: T } = u, O = Et.value,
|
|
9127
|
-
return ce && m[
|
|
9126
|
+
const { treeExpandLazyLoadedMaps: T } = u, O = Et.value, k = O.hasChild || O.hasChildField, { transform: W, lazy: ce } = O, le = St(q, m);
|
|
9127
|
+
return ce && m[k] && !T[le] ? p.clearTreeExpandLoaded(m).then(() => Wt(m)).then(() => {
|
|
9128
9128
|
if (W)
|
|
9129
9129
|
return No(), g.handleTableData();
|
|
9130
9130
|
}).then(() => p.recalculate()) : pe();
|
|
@@ -9143,12 +9143,12 @@ const lh = rt({
|
|
|
9143
9143
|
* @param {Boolean} expanded 是否展开
|
|
9144
9144
|
*/
|
|
9145
9145
|
setAllTreeExpand(m) {
|
|
9146
|
-
const { tableFullData: T } = d, O = Et.value, { transform:
|
|
9146
|
+
const { tableFullData: T } = d, O = Et.value, { transform: k, lazy: W } = O, ce = O.children || O.childrenField, le = [];
|
|
9147
9147
|
return i.eachTree(T, (me) => {
|
|
9148
9148
|
const he = me[ce];
|
|
9149
9149
|
(W || he && he.length) && le.push(me);
|
|
9150
9150
|
}, { children: ce }), p.setTreeExpand(le, m).then(() => {
|
|
9151
|
-
if (
|
|
9151
|
+
if (k)
|
|
9152
9152
|
return No(), p.recalculate();
|
|
9153
9153
|
});
|
|
9154
9154
|
},
|
|
@@ -9160,8 +9160,8 @@ const lh = rt({
|
|
|
9160
9160
|
* @param {Boolean} expanded 是否展开
|
|
9161
9161
|
*/
|
|
9162
9162
|
setTreeExpand(m, T) {
|
|
9163
|
-
const O = Et.value, { transform:
|
|
9164
|
-
return m && (i.isArray(m) || (m = [m]), m.length) ?
|
|
9163
|
+
const O = Et.value, { transform: k } = O;
|
|
9164
|
+
return m && (i.isArray(m) || (m = [m]), m.length) ? k ? wd(m, T) : Ji(m, T) : pe();
|
|
9165
9165
|
},
|
|
9166
9166
|
/**
|
|
9167
9167
|
* 判断行是否为树形节点展开状态
|
|
@@ -9175,9 +9175,9 @@ const lh = rt({
|
|
|
9175
9175
|
* 手动清空树形节点的展开状态,数据会恢复成未展开的状态
|
|
9176
9176
|
*/
|
|
9177
9177
|
clearTreeExpand() {
|
|
9178
|
-
const { tableFullTreeData: m } = d, T = Et.value, O = T.children || T.childrenField, { transform:
|
|
9178
|
+
const { tableFullTreeData: m } = d, T = Et.value, O = T.children || T.childrenField, { transform: k, reserve: W } = T, ce = p.getTreeExpandRecords();
|
|
9179
9179
|
return u.treeExpandedMaps = {}, W && i.eachTree(m, (le) => Ht(le, !1), { children: O }), g.handleTableData().then(() => {
|
|
9180
|
-
if (
|
|
9180
|
+
if (k)
|
|
9181
9181
|
return No(), g.handleTableData();
|
|
9182
9182
|
}).then(() => {
|
|
9183
9183
|
if (ce.length)
|
|
@@ -9191,12 +9191,12 @@ const lh = rt({
|
|
|
9191
9191
|
* 获取表格的滚动状态
|
|
9192
9192
|
*/
|
|
9193
9193
|
getScroll() {
|
|
9194
|
-
const { scrollXLoad: m, scrollYLoad: T } = u,
|
|
9194
|
+
const { scrollXLoad: m, scrollYLoad: T } = u, k = x.value.$el;
|
|
9195
9195
|
return {
|
|
9196
9196
|
virtualX: m,
|
|
9197
9197
|
virtualY: T,
|
|
9198
|
-
scrollTop:
|
|
9199
|
-
scrollLeft:
|
|
9198
|
+
scrollTop: k.scrollTop,
|
|
9199
|
+
scrollLeft: k.scrollLeft
|
|
9200
9200
|
};
|
|
9201
9201
|
},
|
|
9202
9202
|
/**
|
|
@@ -9205,7 +9205,7 @@ const lh = rt({
|
|
|
9205
9205
|
* @param {Number} scrollTop 上距离
|
|
9206
9206
|
*/
|
|
9207
9207
|
scrollTo(m, T) {
|
|
9208
|
-
const O = x.value,
|
|
9208
|
+
const O = x.value, k = b.value, W = C.value, ce = F.value, le = ne.value, me = O ? O.$el : null, he = ce ? ce.$el : null, Pe = le ? le.$el : null, Ve = k ? k.$el : null, _e = W ? W.$el : null;
|
|
9209
9209
|
if (i.isNumber(m)) {
|
|
9210
9210
|
const Ne = G.value;
|
|
9211
9211
|
Ne ? So(Ne, m) : (So(me, m), So(Ve, m), So(_e, m));
|
|
@@ -9242,7 +9242,7 @@ const lh = rt({
|
|
|
9242
9242
|
* 手动清除滚动相关信息,还原到初始状态
|
|
9243
9243
|
*/
|
|
9244
9244
|
clearScroll() {
|
|
9245
|
-
const { scrollXStore: m, scrollYStore: T } = d, O = x.value,
|
|
9245
|
+
const { scrollXStore: m, scrollYStore: T } = d, O = x.value, k = b.value, W = C.value, ce = F.value, le = ne.value, me = ce ? ce.$el : null, he = O ? O.$el : null, Pe = le ? le.$el : null, Ve = k ? k.$el : null, _e = W ? W.$el : null, Ne = G.value;
|
|
9246
9246
|
Ne ? So(Ne, 0) : (So(he, 0), So(Ve, 0), So(_e, 0));
|
|
9247
9247
|
const Je = re.value;
|
|
9248
9248
|
return Je ? go(Je, 0) : (go(he, 0), go(me, 0), go(Pe, 0)), m.startIndex = 0, m.endIndex = m.visibleSize, T.startIndex = 0, T.endIndex = T.visibleSize, pe().then(() => {
|
|
@@ -9253,9 +9253,9 @@ const lh = rt({
|
|
|
9253
9253
|
* 更新表尾合计
|
|
9254
9254
|
*/
|
|
9255
9255
|
updateFooter() {
|
|
9256
|
-
const { showFooter: m, footerData: T, footerMethod: O } = e, { visibleColumn:
|
|
9256
|
+
const { showFooter: m, footerData: T, footerMethod: O } = e, { visibleColumn: k, afterFullData: W } = d;
|
|
9257
9257
|
let ce = [];
|
|
9258
|
-
return m && T && T.length ? ce = T.slice(0) : m && O && (ce =
|
|
9258
|
+
return m && T && T.length ? ce = T.slice(0) : m && O && (ce = k.length ? O({ columns: k, data: W, $table: q, $grid: ae }) : []), u.footerTableData = ce, pe();
|
|
9259
9259
|
},
|
|
9260
9260
|
/**
|
|
9261
9261
|
* 更新列状态 updateStatus({ row, column }, cellValue)
|
|
@@ -9265,8 +9265,8 @@ const lh = rt({
|
|
|
9265
9265
|
updateStatus(m, T) {
|
|
9266
9266
|
const O = !i.isUndefined(T);
|
|
9267
9267
|
return pe().then(() => {
|
|
9268
|
-
const { editRules:
|
|
9269
|
-
if (m && ce &&
|
|
9268
|
+
const { editRules: k } = e, { validStore: W } = u, ce = x.value;
|
|
9269
|
+
if (m && ce && k) {
|
|
9270
9270
|
const { row: le, column: me } = m, he = "change";
|
|
9271
9271
|
if (q.hasCellRules && q.hasCellRules(he, le, me)) {
|
|
9272
9272
|
const Pe = p.getCellElement(le, me);
|
|
@@ -9333,7 +9333,7 @@ const lh = rt({
|
|
|
9333
9333
|
return m && T.area && q.handleRecalculateCellAreas ? q.handleRecalculateCellAreas() : pe();
|
|
9334
9334
|
},
|
|
9335
9335
|
getCustomStoreData() {
|
|
9336
|
-
const { id: m } = e, T = Bt.value, { collectColumn: O } = d, { checkMethod:
|
|
9336
|
+
const { id: m } = e, T = Bt.value, { collectColumn: O } = d, { checkMethod: k } = T, W = {}, ce = {}, le = {}, me = {}, he = {
|
|
9337
9337
|
resizableData: void 0,
|
|
9338
9338
|
sortData: void 0,
|
|
9339
9339
|
visibleData: void 0,
|
|
@@ -9354,7 +9354,7 @@ const lh = rt({
|
|
|
9354
9354
|
const Xe = Je.getKey();
|
|
9355
9355
|
Xe && (Pe = 1, W[Xe] = Je.renderWidth);
|
|
9356
9356
|
}
|
|
9357
|
-
if (!
|
|
9357
|
+
if (!k || k({ column: Je })) {
|
|
9358
9358
|
if (!Je.visible && Je.defaultVisible) {
|
|
9359
9359
|
const Xe = Je.getKey();
|
|
9360
9360
|
Xe && (Ne = 1, le[Xe] = !1);
|
|
@@ -9380,8 +9380,8 @@ const lh = rt({
|
|
|
9380
9380
|
}
|
|
9381
9381
|
};
|
|
9382
9382
|
const Nt = (m) => {
|
|
9383
|
-
const { editStore: T, ctxMenuStore: O, filterStore:
|
|
9384
|
-
if (Je && (Rn(m, me, "vxe-cell--filter").flag || Rn(m, Je.$el).flag || Rn(m, document.body, "vxe-table--ignore-clear").flag || g.preventEvent(m, "event.clearFilter",
|
|
9383
|
+
const { editStore: T, ctxMenuStore: O, filterStore: k, customStore: W } = u, { mouseConfig: ce, editRules: le } = e, me = h.value, he = Me.value, Pe = oe.value, Ve = K.value, { actived: _e } = T, Ne = E.value, Je = D.value, We = y.value, qe = v.value;
|
|
9384
|
+
if (Je && (Rn(m, me, "vxe-cell--filter").flag || Rn(m, Je.$el).flag || Rn(m, document.body, "vxe-table--ignore-clear").flag || g.preventEvent(m, "event.clearFilter", k.args, p.closeFilter)), We && (W.btnEl === m.target || Rn(m, document.body, "vxe-toolbar-custom-target").flag || Rn(m, We.$el).flag || Rn(m, document.body, "vxe-table--ignore-clear").flag || g.preventEvent(m, "event.clearCustom", {}, () => {
|
|
9385
9385
|
q.closeCustom && q.closeCustom();
|
|
9386
9386
|
})), _e.row) {
|
|
9387
9387
|
if (he.autoClear !== !1) {
|
|
@@ -9419,11 +9419,11 @@ const lh = rt({
|
|
|
9419
9419
|
}, Ft = () => {
|
|
9420
9420
|
p.closeTooltip(), q.closeMenu && q.closeMenu();
|
|
9421
9421
|
}, fn = (m) => {
|
|
9422
|
-
const { mouseConfig: T, keyboardConfig: O } = e, { filterStore:
|
|
9422
|
+
const { mouseConfig: T, keyboardConfig: O } = e, { filterStore: k, ctxMenuStore: W, editStore: ce } = u, le = Se.value, me = A.value, { actived: he } = ce;
|
|
9423
9423
|
qn.hasKey(m, xr.ESCAPE) && g.preventEvent(m, "event.keydown", null, () => {
|
|
9424
9424
|
if (Ct("keydown-start", {}, m), O && T && le.area && q.handleKeyboardCellAreaEvent)
|
|
9425
9425
|
q.handleKeyboardCellAreaEvent(m);
|
|
9426
|
-
else if ((he.row ||
|
|
9426
|
+
else if ((he.row || k.visible || W.visible) && (m.stopPropagation(), q.closeMenu && q.closeMenu(), p.closeFilter(), O && me.isEsc && he.row)) {
|
|
9427
9427
|
const Ve = he.args;
|
|
9428
9428
|
q.handleClearEdit(m), le.selected && pe(() => q.handleSelected(Ve, m));
|
|
9429
9429
|
}
|
|
@@ -9431,7 +9431,7 @@ const lh = rt({
|
|
|
9431
9431
|
});
|
|
9432
9432
|
}, Tn = (m) => {
|
|
9433
9433
|
d.isActivated && g.preventEvent(m, "event.keydown", null, () => {
|
|
9434
|
-
const { mouseConfig: T, keyboardConfig: O, treeConfig:
|
|
9434
|
+
const { mouseConfig: T, keyboardConfig: O, treeConfig: k, editConfig: W, highlightCurrentRow: ce } = e, { ctxMenuStore: le, editStore: me, currentRow: he } = u, { afterFullData: Pe } = d, Ve = Le.value, _e = Ee.value, Ne = A.value, Je = Se.value, We = Me.value, qe = Et.value, ft = Qe.value, Dt = He.value, { selected: Xe, actived: Ot } = me, zt = qe.children || qe.childrenField, Kt = m.keyCode, an = qn.hasKey(m, xr.ESCAPE), tn = qn.hasKey(m, xr.BACKSPACE), vn = qn.hasKey(m, xr.TAB), hn = qn.hasKey(m, xr.ENTER), un = qn.hasKey(m, xr.SPACEBAR), On = qn.hasKey(m, xr.ARROW_LEFT), cn = qn.hasKey(m, xr.ARROW_UP), xn = qn.hasKey(m, xr.ARROW_RIGHT), Qn = qn.hasKey(m, xr.ARROW_DOWN), jr = qn.hasKey(m, xr.DELETE), hr = qn.hasKey(m, xr.F2), qr = qn.hasKey(m, xr.CONTEXT_MENU), Ol = m.metaKey, Kl = m.ctrlKey, er = m.shiftKey, co = m.altKey, Ir = On || cn || xn || Qn, Uo = Ve && le.visible && (hn || un || Ir), Ml = mn(W) && Ot.column && Ot.row, ol = We.beforeEditMethod || We.activeMethod;
|
|
9435
9435
|
if (Uo)
|
|
9436
9436
|
m.preventDefault(), le.showChild && na(le.selected) ? q.moveCtxMenu(m, le, "selectChild", On, !1, le.selected.children) : q.moveCtxMenu(m, le, "selected", xn, !0, ft);
|
|
9437
9437
|
else if (O && T && Je.area && q.handleKeyboardCellAreaEvent)
|
|
@@ -9449,7 +9449,7 @@ const lh = rt({
|
|
|
9449
9449
|
d._keyCtx = Xe.row && Xe.column && _e.length, clearTimeout(It), It = setTimeout(() => {
|
|
9450
9450
|
d._keyCtx = !1;
|
|
9451
9451
|
}, 1e3);
|
|
9452
|
-
else if (hn && !co && O && Ne.isEnter && (Xe.row || Ot.row ||
|
|
9452
|
+
else if (hn && !co && O && Ne.isEnter && (Xe.row || Ot.row || k && (Dt.isCurrent || ce) && he)) {
|
|
9453
9453
|
const { isLastEnterAppendRow: eo, beforeEnterMethod: uo, enterMethod: fo } = Ne;
|
|
9454
9454
|
if (Kl) {
|
|
9455
9455
|
if (Ot.row) {
|
|
@@ -9486,7 +9486,7 @@ const lh = rt({
|
|
|
9486
9486
|
q.moveSelected(to, On, !1, xn, !0, m), fo && fo(oo);
|
|
9487
9487
|
}
|
|
9488
9488
|
}
|
|
9489
|
-
} else if (
|
|
9489
|
+
} else if (k && (Dt.isCurrent || ce) && he) {
|
|
9490
9490
|
const to = he[zt];
|
|
9491
9491
|
if (to && to.length) {
|
|
9492
9492
|
m.preventDefault();
|
|
@@ -9530,7 +9530,7 @@ const lh = rt({
|
|
|
9530
9530
|
(!ol || ol(uo)) && (eo ? eo(uo) : (pl(Xe.row, Xe.column, null), q.handleEdit(Xe.args, m)), Ct("cell-backspace-value", uo, m));
|
|
9531
9531
|
}
|
|
9532
9532
|
}
|
|
9533
|
-
} else if (tn && O &&
|
|
9533
|
+
} else if (tn && O && k && Ne.isBack && (Dt.isCurrent || ce) && he) {
|
|
9534
9534
|
const { parent: eo } = i.findTree(d.afterTreeFullData, (uo) => uo === he, { children: zt });
|
|
9535
9535
|
if (eo) {
|
|
9536
9536
|
m.preventDefault();
|
|
@@ -9560,13 +9560,13 @@ const lh = rt({
|
|
|
9560
9560
|
Ct("keydown", {}, m);
|
|
9561
9561
|
});
|
|
9562
9562
|
}, Yn = (m) => {
|
|
9563
|
-
const { keyboardConfig: T, mouseConfig: O } = e, { editStore:
|
|
9563
|
+
const { keyboardConfig: T, mouseConfig: O } = e, { editStore: k, filterStore: W } = u, { isActivated: ce } = d, le = Se.value, me = A.value, { actived: he } = k;
|
|
9564
9564
|
ce && !W.visible && (he.row || he.column || T && me.isClip && O && le.area && q.handlePasteCellAreaEvent && q.handlePasteCellAreaEvent(m), Ct("paste", {}, m));
|
|
9565
9565
|
}, jo = (m) => {
|
|
9566
|
-
const { keyboardConfig: T, mouseConfig: O } = e, { editStore:
|
|
9566
|
+
const { keyboardConfig: T, mouseConfig: O } = e, { editStore: k, filterStore: W } = u, { isActivated: ce } = d, le = Se.value, me = A.value, { actived: he } = k;
|
|
9567
9567
|
ce && !W.visible && (he.row || he.column || T && me.isClip && O && le.area && q.handleCopyCellAreaEvent && q.handleCopyCellAreaEvent(m), Ct("copy", {}, m));
|
|
9568
9568
|
}, gr = (m) => {
|
|
9569
|
-
const { keyboardConfig: T, mouseConfig: O } = e, { editStore:
|
|
9569
|
+
const { keyboardConfig: T, mouseConfig: O } = e, { editStore: k, filterStore: W } = u, { isActivated: ce } = d, le = Se.value, me = A.value, { actived: he } = k;
|
|
9570
9570
|
ce && !W.visible && (he.row || he.column || T && me.isClip && O && le.area && q.handleCutCellAreaEvent && q.handleCutCellAreaEvent(m), Ct("cut", {}, m));
|
|
9571
9571
|
}, qo = () => {
|
|
9572
9572
|
q.closeMenu && q.closeMenu();
|
|
@@ -9588,13 +9588,13 @@ const lh = rt({
|
|
|
9588
9588
|
}, Gl = (m) => {
|
|
9589
9589
|
const T = h.value;
|
|
9590
9590
|
if (T) {
|
|
9591
|
-
const O = "row--drag-origin",
|
|
9592
|
-
i.arrayEach(T.querySelectorAll(`[rowid="${
|
|
9591
|
+
const O = "row--drag-origin", k = St(q, m);
|
|
9592
|
+
i.arrayEach(T.querySelectorAll(`[rowid="${k}"]`), (W) => {
|
|
9593
9593
|
fl(W, O);
|
|
9594
9594
|
});
|
|
9595
9595
|
}
|
|
9596
9596
|
}, Sd = (m) => {
|
|
9597
|
-
const { dragConfig: T } = e, { dragRow: O } = u,
|
|
9597
|
+
const { dragConfig: T } = e, { dragRow: O } = u, k = Ge.value, { tooltipMethod: W } = k, ce = W || (T ? T.rowTooltipMethod : null);
|
|
9598
9598
|
let le = "";
|
|
9599
9599
|
ce ? le = `${ce({
|
|
9600
9600
|
row: O
|
|
@@ -9606,9 +9606,9 @@ const lh = rt({
|
|
|
9606
9606
|
i.eachTree([m], (W) => {
|
|
9607
9607
|
O.push(`[colid="${W.id}"]`);
|
|
9608
9608
|
});
|
|
9609
|
-
const
|
|
9609
|
+
const k = "col--drag-origin";
|
|
9610
9610
|
i.arrayEach(T.querySelectorAll(O.join(",")), (W) => {
|
|
9611
|
-
fl(W,
|
|
9611
|
+
fl(W, k);
|
|
9612
9612
|
});
|
|
9613
9613
|
}
|
|
9614
9614
|
}, qa = () => {
|
|
@@ -9620,20 +9620,20 @@ const lh = rt({
|
|
|
9620
9620
|
});
|
|
9621
9621
|
}
|
|
9622
9622
|
}, tc = (m) => {
|
|
9623
|
-
const { dragCol: T } = u, O = at.value, { tooltipMethod:
|
|
9623
|
+
const { dragCol: T } = u, O = at.value, { tooltipMethod: k } = O;
|
|
9624
9624
|
let W = "";
|
|
9625
|
-
|
|
9625
|
+
k ? W = `${k({
|
|
9626
9626
|
column: T
|
|
9627
9627
|
}) || ""}` : W = es("vxe.table.dragTip", [m.textContent || ""]), u.dragTipText = W;
|
|
9628
|
-
}, vs = (m, T, O,
|
|
9628
|
+
}, vs = (m, T, O, k, W) => {
|
|
9629
9629
|
const ce = h.value;
|
|
9630
9630
|
if (!ce)
|
|
9631
9631
|
return;
|
|
9632
9632
|
const { scrollbarWidth: le, scrollbarHeight: me } = u, { prevDragToChild: he } = d, Pe = ce.getBoundingClientRect();
|
|
9633
9633
|
if (T) {
|
|
9634
|
-
const _e =
|
|
9634
|
+
const _e = V.value;
|
|
9635
9635
|
if (_e)
|
|
9636
|
-
if (
|
|
9636
|
+
if (k) {
|
|
9637
9637
|
const Ne = T.getBoundingClientRect();
|
|
9638
9638
|
_e.style.display = "block", _e.style.top = `${Math.max(1, Ne.y - Pe.y)}px`, _e.style.height = `${Ne.height}px`, _e.style.width = `${Pe.width - le}px`, _e.setAttribute("drag-pos", W), _e.setAttribute("drag-to-child", he ? "y" : "n");
|
|
9639
9639
|
} else
|
|
@@ -9641,18 +9641,18 @@ const lh = rt({
|
|
|
9641
9641
|
} else if (O) {
|
|
9642
9642
|
const _e = I.value;
|
|
9643
9643
|
if (_e)
|
|
9644
|
-
if (
|
|
9644
|
+
if (k) {
|
|
9645
9645
|
const Ne = O.getBoundingClientRect(), Je = Math.max(0, Ne.y - Pe.y);
|
|
9646
9646
|
_e.style.display = "block", _e.style.top = `${Je}px`, _e.style.left = `${Math.max(1, Ne.x - Pe.x)}px`, _e.style.width = `${Ne.width}px`, he ? _e.style.height = `${Ne.height}px` : _e.style.height = `${Pe.height - Je - me}px`, _e.setAttribute("drag-pos", W), _e.setAttribute("drag-to-child", he ? "y" : "n");
|
|
9647
9647
|
} else
|
|
9648
9648
|
_e.style.display = "";
|
|
9649
9649
|
}
|
|
9650
9650
|
const Ve = z.value;
|
|
9651
|
-
Ve && (Ve.style.display = "block", Ve.style.top = `${Math.min(ce.clientHeight - ce.scrollTop - Ve.clientHeight, m.clientY - Pe.y)}px`, Ve.style.left = `${Math.min(ce.clientWidth - ce.scrollLeft - Ve.clientWidth - 16, m.clientX - Pe.x)}px`, Ve.setAttribute("drag-status",
|
|
9651
|
+
Ve && (Ve.style.display = "block", Ve.style.top = `${Math.min(ce.clientHeight - ce.scrollTop - Ve.clientHeight, m.clientY - Pe.y)}px`, Ve.style.left = `${Math.min(ce.clientWidth - ce.scrollLeft - Ve.clientWidth - 16, m.clientX - Pe.x)}px`, Ve.setAttribute("drag-status", k ? he ? "sub" : "normal" : "disabled"));
|
|
9652
9652
|
}, Tl = () => {
|
|
9653
|
-
const m = z.value, T =
|
|
9653
|
+
const m = z.value, T = V.value, O = I.value;
|
|
9654
9654
|
m && (m.style.display = ""), T && (T.style.display = ""), O && (O.style.display = "");
|
|
9655
|
-
}, Td = (m, T, O,
|
|
9655
|
+
}, Td = (m, T, O, k, W) => {
|
|
9656
9656
|
W.cell = T;
|
|
9657
9657
|
const { tooltipStore: ce } = u, le = xe.value, { column: me, row: he } = W, { showAll: Pe, contentMethod: Ve } = le, _e = Ve ? Ve(W) : null, Ne = Ve && !i.eqNull(_e), Je = Ne ? _e : i.toString(me.type === "html" ? O.innerText : O.textContent).trim(), We = O.scrollWidth > O.clientWidth;
|
|
9658
9658
|
return Je && (Pe || Ne || We) && (Object.assign(ce, {
|
|
@@ -9662,7 +9662,7 @@ const lh = rt({
|
|
|
9662
9662
|
currOpts: {}
|
|
9663
9663
|
}), pe(() => {
|
|
9664
9664
|
const qe = w.value;
|
|
9665
|
-
qe && qe.open && qe.open(We ? O :
|
|
9665
|
+
qe && qe.open && qe.open(We ? O : k || O, Do(Je));
|
|
9666
9666
|
})), pe();
|
|
9667
9667
|
}, Ua = (m, T) => {
|
|
9668
9668
|
if (m) {
|
|
@@ -9696,8 +9696,8 @@ const lh = rt({
|
|
|
9696
9696
|
getParentHeight() {
|
|
9697
9697
|
const { height: m } = e, T = h.value;
|
|
9698
9698
|
if (T) {
|
|
9699
|
-
const O = T.parentNode,
|
|
9700
|
-
return Math.floor(ae ? ae.getParentHeight() : i.toNumber(getComputedStyle(O).height) -
|
|
9699
|
+
const O = T.parentNode, k = m === "100%" || m === "auto" ? Nf(O) : 0;
|
|
9700
|
+
return Math.floor(ae ? ae.getParentHeight() : i.toNumber(getComputedStyle(O).height) - k);
|
|
9701
9701
|
}
|
|
9702
9702
|
return 0;
|
|
9703
9703
|
},
|
|
@@ -9714,7 +9714,7 @@ const lh = rt({
|
|
|
9714
9714
|
* @param {Row} records 行数据
|
|
9715
9715
|
*/
|
|
9716
9716
|
defineField(m) {
|
|
9717
|
-
const { treeConfig: T } = e, O = ut.value,
|
|
9717
|
+
const { treeConfig: T } = e, O = ut.value, k = Et.value, W = pt.value, ce = ke.value, le = k.children || k.childrenField, me = Rl(q);
|
|
9718
9718
|
return i.isArray(m) || (m = [m]), m.map((he) => (d.tableFullColumn.forEach((Ve) => {
|
|
9719
9719
|
const { field: _e, editRender: Ne } = Ve;
|
|
9720
9720
|
if (_e && !i.has(he, _e) && !he[_e]) {
|
|
@@ -9727,15 +9727,15 @@ const lh = rt({
|
|
|
9727
9727
|
}
|
|
9728
9728
|
}), [W.labelField, ce.checkField, ce.labelField, O.labelField].forEach((Ve) => {
|
|
9729
9729
|
Ve && dl(i.get(he, Ve)) && i.set(he, Ve, null);
|
|
9730
|
-
}), T &&
|
|
9730
|
+
}), T && k.lazy && i.isUndefined(he[le]) && (he[le] = null), dl(i.get(he, me)) && i.set(he, me, tf()), he));
|
|
9731
9731
|
},
|
|
9732
9732
|
handleTableData(m) {
|
|
9733
|
-
const { scrollYLoad: T } = u, { scrollYStore: O, fullDataRowIdData:
|
|
9733
|
+
const { scrollYLoad: T } = u, { scrollYStore: O, fullDataRowIdData: k } = d;
|
|
9734
9734
|
let W = d.afterFullData;
|
|
9735
9735
|
m && (Hr(), W = No());
|
|
9736
9736
|
const ce = T ? W.slice(O.startIndex, O.endIndex) : W.slice(0);
|
|
9737
9737
|
return ce.forEach((le, me) => {
|
|
9738
|
-
const he = St(q, le), Pe =
|
|
9738
|
+
const he = St(q, le), Pe = k[he];
|
|
9739
9739
|
Pe && (Pe.$index = me);
|
|
9740
9740
|
}), u.tableData = ce, pe();
|
|
9741
9741
|
},
|
|
@@ -9744,23 +9744,23 @@ const lh = rt({
|
|
|
9744
9744
|
* 牺牲数据组装的耗时,用来换取使用过程中的流畅
|
|
9745
9745
|
*/
|
|
9746
9746
|
cacheRowMap(m) {
|
|
9747
|
-
const { treeConfig: T } = e, O = Et.value, { fullAllDataRowIdData:
|
|
9747
|
+
const { treeConfig: T } = e, O = Et.value, { fullAllDataRowIdData: k, tableFullData: W, tableFullTreeData: ce } = d, le = O.children || O.childrenField, me = O.hasChild || O.hasChildField, he = Rl(q), Pe = T && O.lazy, Ve = {}, _e = {}, Ne = (Je, We, qe, ft, Dt, Xe) => {
|
|
9748
9748
|
let Ot = St(q, Je);
|
|
9749
9749
|
const zt = T && ft ? g_(ft) : We + 1, Kt = Xe ? Xe.length - 1 : 0;
|
|
9750
9750
|
dl(Ot) && (Ot = tf(), i.set(Je, he, Ot)), Pe && Je[me] && i.isUndefined(Je[le]) && (Je[le] = null);
|
|
9751
|
-
let an =
|
|
9751
|
+
let an = k[Ot];
|
|
9752
9752
|
an || (an = { row: Je, rowid: Ot, seq: zt, index: -1, _index: -1, $index: -1, items: qe, parent: Dt, level: Kt, height: 0 }), an.row = Je, an.items = qe, an.parent = Dt, an.level = Kt, an.index = T && Dt ? -1 : We, m && (_e[Ot] = an), Ve[Ot] = an;
|
|
9753
9753
|
};
|
|
9754
9754
|
m && (d.fullDataRowIdData = _e), d.fullAllDataRowIdData = Ve, T ? i.eachTree(ce, Ne, { children: le }) : W.forEach(Ne);
|
|
9755
9755
|
},
|
|
9756
9756
|
cacheSourceMap(m) {
|
|
9757
9757
|
const { treeConfig: T } = e, O = Et.value;
|
|
9758
|
-
let { sourceDataRowIdData:
|
|
9758
|
+
let { sourceDataRowIdData: k } = d;
|
|
9759
9759
|
const W = i.clone(m, !0), ce = Rl(q);
|
|
9760
|
-
|
|
9760
|
+
k = d.sourceDataRowIdData = {};
|
|
9761
9761
|
const le = (me) => {
|
|
9762
9762
|
let he = St(q, me);
|
|
9763
|
-
dl(he) && (he = tf(), i.set(me, ce, he)),
|
|
9763
|
+
dl(he) && (he = tf(), i.set(me, ce, he)), k[he] = me;
|
|
9764
9764
|
};
|
|
9765
9765
|
if (T) {
|
|
9766
9766
|
const me = O.children || O.childrenField;
|
|
@@ -9773,14 +9773,14 @@ const lh = rt({
|
|
|
9773
9773
|
* 指定列宽的列进行拆分
|
|
9774
9774
|
*/
|
|
9775
9775
|
analyColumnWidth() {
|
|
9776
|
-
const { tableFullColumn: m } = d, T = Ye.value, { width: O, minWidth:
|
|
9776
|
+
const { tableFullColumn: m } = d, T = Ye.value, { width: O, minWidth: k } = T, W = [], ce = [], le = [], me = [], he = [], Pe = [], Ve = [], _e = [];
|
|
9777
9777
|
m.forEach((Ne) => {
|
|
9778
|
-
O && !Ne.width && (Ne.width = O),
|
|
9778
|
+
O && !Ne.width && (Ne.width = O), k && !Ne.minWidth && (Ne.minWidth = k), Ne.visible && (Ne.resizeWidth ? W.push(Ne) : Ne.width === "auto" ? Ve.push(Ne) : Rf(Ne.width) ? ce.push(Ne) : di(Ne.width) ? he.push(Ne) : Rf(Ne.minWidth) ? le.push(Ne) : Ne.minWidth === "auto" ? me.push(Ne) : di(Ne.minWidth) ? Pe.push(Ne) : _e.push(Ne));
|
|
9779
9779
|
}), Object.assign(u.columnStore, { resizeList: W, pxList: ce, pxMinList: le, autoMinList: me, scaleList: he, scaleMinList: Pe, autoList: Ve, remainList: _e });
|
|
9780
9780
|
},
|
|
9781
9781
|
saveCustomStore(m) {
|
|
9782
|
-
const { customConfig: T } = e, O = Y.value,
|
|
9783
|
-
if ((T ? mn(
|
|
9782
|
+
const { customConfig: T } = e, O = Y.value, k = Bt.value, { updateStore: W, storage: ce } = k, le = ce === !0, me = le ? {} : Object.assign({}, ce || {}), he = le || me.resizable, Pe = le || me.visible, Ve = le || me.fixed, _e = le || me.sort;
|
|
9783
|
+
if ((T ? mn(k) : k.enabled) && (he || Pe || Ve || _e)) {
|
|
9784
9784
|
if (!O)
|
|
9785
9785
|
return Gt("vxe.error.reqProp", ["id"]), pe();
|
|
9786
9786
|
const Ne = m === "reset" ? {
|
|
@@ -9809,14 +9809,14 @@ const lh = rt({
|
|
|
9809
9809
|
handleRefreshColumnQueue() {
|
|
9810
9810
|
u.reColumnFlag++;
|
|
9811
9811
|
},
|
|
9812
|
-
preventEvent(m, T, O,
|
|
9812
|
+
preventEvent(m, T, O, k, W) {
|
|
9813
9813
|
let ce = ch.get(T);
|
|
9814
9814
|
!ce.length && T === "event.clearEdit" && (ce = ch.get("event.clearActived"), process.env.NODE_ENV === "development" && ce.length && sn("vxe.error.delEvent", ["event.clearActived", "event.clearEdit"]));
|
|
9815
9815
|
let le;
|
|
9816
|
-
return ce.some((me) => me(Object.assign({ $grid: ae, $table: q, $event: m }, O)) === !1) ||
|
|
9816
|
+
return ce.some((me) => me(Object.assign({ $grid: ae, $table: q, $event: m }, O)) === !1) || k && (le = k()), W && W(), le;
|
|
9817
9817
|
},
|
|
9818
9818
|
updateCheckboxStatus() {
|
|
9819
|
-
const { treeConfig: m } = e, { selectCheckboxMaps: T, treeIndeterminateMaps: O } = u,
|
|
9819
|
+
const { treeConfig: m } = e, { selectCheckboxMaps: T, treeIndeterminateMaps: O } = u, k = Object.assign({}, T), W = Object.assign({}, O), ce = Et.value, { transform: le, mapChildrenField: me } = ce, he = ce.children || ce.childrenField, Pe = ke.value, { checkField: Ve, checkStrictly: _e, checkMethod: Ne } = Pe, { afterTreeFullData: Je } = d;
|
|
9820
9820
|
if (!_e) {
|
|
9821
9821
|
if (m) {
|
|
9822
9822
|
const We = {}, qe = [];
|
|
@@ -9827,21 +9827,21 @@ const lh = rt({
|
|
|
9827
9827
|
const Dt = ft[0], Xe = ft[1], Ot = ft[2];
|
|
9828
9828
|
let zt = 0, Kt = 0, an = 0;
|
|
9829
9829
|
Ot.forEach(Ne ? (hn) => {
|
|
9830
|
-
const un = St(q, hn), On = Ve ? i.get(hn, Ve) :
|
|
9830
|
+
const un = St(q, hn), On = Ve ? i.get(hn, Ve) : k[un];
|
|
9831
9831
|
Ne({ row: hn }) ? (On ? zt++ : W[un] && Kt++, an++) : On ? zt++ : W[un] && Kt++;
|
|
9832
9832
|
} : (hn) => {
|
|
9833
9833
|
const un = St(q, hn);
|
|
9834
|
-
(Ve ? i.get(hn, Ve) :
|
|
9834
|
+
(Ve ? i.get(hn, Ve) : k[un]) ? zt++ : W[un] && Kt++, an++;
|
|
9835
9835
|
});
|
|
9836
9836
|
const tn = zt >= an, vn = !tn && (zt >= 1 || Kt >= 1);
|
|
9837
|
-
Ve && i.get(Dt, Ve, tn), tn ? (Ve || (
|
|
9837
|
+
Ve && i.get(Dt, Ve, tn), tn ? (Ve || (k[Xe] = Dt), W[Xe] && delete W[Xe]) : (Ve || k[Xe] && delete k[Xe], vn ? W[Xe] = Dt : W[Xe] && delete W[Xe]);
|
|
9838
9838
|
});
|
|
9839
9839
|
}
|
|
9840
|
-
u.selectCheckboxMaps =
|
|
9840
|
+
u.selectCheckboxMaps = k, u.treeIndeterminateMaps = W;
|
|
9841
9841
|
}
|
|
9842
9842
|
},
|
|
9843
9843
|
updateAllCheckboxStatus() {
|
|
9844
|
-
const { treeConfig: m } = e, { selectCheckboxMaps: T, treeIndeterminateMaps: O } = u,
|
|
9844
|
+
const { treeConfig: m } = e, { selectCheckboxMaps: T, treeIndeterminateMaps: O } = u, k = ke.value, { checkField: W, checkMethod: ce } = k, { afterFullData: le, afterTreeFullData: me } = d;
|
|
9845
9845
|
let he = 0, Pe = 0, Ve = 0;
|
|
9846
9846
|
(m ? me : le).forEach(ce ? (We) => {
|
|
9847
9847
|
const qe = St(q, We), ft = W ? i.get(We, W) : T[qe];
|
|
@@ -9861,9 +9861,9 @@ const lh = rt({
|
|
|
9861
9861
|
* 多选,行选中事件
|
|
9862
9862
|
*/
|
|
9863
9863
|
handleBatchSelectRows(m, T, O) {
|
|
9864
|
-
const { treeConfig:
|
|
9864
|
+
const { treeConfig: k } = e, { selectCheckboxMaps: W } = u, ce = Object.assign({}, W), le = Et.value, { transform: me, mapChildrenField: he } = le, Pe = le.children || le.childrenField, Ve = ke.value, { checkField: _e, checkStrictly: Ne, checkMethod: Je } = Ve, We = Ve.indeterminateField || Ve.halfField;
|
|
9865
9865
|
if (_e) {
|
|
9866
|
-
if (
|
|
9866
|
+
if (k && !Ne) {
|
|
9867
9867
|
i.eachTree(m, (qe) => {
|
|
9868
9868
|
(O || !Je || Je({ row: qe })) && (i.set(qe, _e, T), We && i.set(qe, We, !1), fe(qe, T));
|
|
9869
9869
|
}, { children: me ? he : Pe }), u.selectCheckboxMaps = ce;
|
|
@@ -9875,7 +9875,7 @@ const lh = rt({
|
|
|
9875
9875
|
u.selectCheckboxMaps = ce;
|
|
9876
9876
|
return;
|
|
9877
9877
|
}
|
|
9878
|
-
if (
|
|
9878
|
+
if (k && !Ne) {
|
|
9879
9879
|
i.eachTree(m, (qe) => {
|
|
9880
9880
|
const ft = St(q, qe);
|
|
9881
9881
|
(O || !Je || Je({ row: qe })) && (T ? ce[ft] = qe : ce[ft] && delete ce[ft], fe(qe, T));
|
|
@@ -9895,9 +9895,9 @@ const lh = rt({
|
|
|
9895
9895
|
q.handleBatchSelectRows([m], T, O);
|
|
9896
9896
|
},
|
|
9897
9897
|
triggerHeaderTitleEvent(m, T, O) {
|
|
9898
|
-
const
|
|
9899
|
-
if (
|
|
9900
|
-
const { tooltipStore: W } = u, { column: ce } = O, le = hl(
|
|
9898
|
+
const k = T.content || T.message;
|
|
9899
|
+
if (k) {
|
|
9900
|
+
const { tooltipStore: W } = u, { column: ce } = O, le = hl(k);
|
|
9901
9901
|
io(!0), W.row = null, W.column = ce, W.visible = !0, W.currOpts = T, pe(() => {
|
|
9902
9902
|
const me = w.value;
|
|
9903
9903
|
me && me.open && me.open(m.currentTarget, le);
|
|
@@ -9908,14 +9908,14 @@ const lh = rt({
|
|
|
9908
9908
|
* 触发表头 tooltip 事件
|
|
9909
9909
|
*/
|
|
9910
9910
|
triggerHeaderTooltipEvent(m, T) {
|
|
9911
|
-
const { tooltipStore: O } = u, { column:
|
|
9912
|
-
io(!0), (O.column !==
|
|
9911
|
+
const { tooltipStore: O } = u, { column: k } = T, W = m.currentTarget;
|
|
9912
|
+
io(!0), (O.column !== k || !O.visible) && Td(m, W, W, null, T);
|
|
9913
9913
|
},
|
|
9914
9914
|
/**
|
|
9915
9915
|
* 触发单元格 tooltip 事件
|
|
9916
9916
|
*/
|
|
9917
9917
|
triggerBodyTooltipEvent(m, T) {
|
|
9918
|
-
const { editConfig: O } = e, { editStore:
|
|
9918
|
+
const { editConfig: O } = e, { editStore: k } = u, { tooltipStore: W } = u, ce = Me.value, { actived: le } = k, { row: me, column: he } = T, Pe = m.currentTarget;
|
|
9919
9919
|
if (io(W.column !== he || W.row !== me), !(he.editRender && mn(O) && (ce.mode === "row" && le.row === me || le.row === me && le.column === he)) && (W.column !== he || W.row !== me || !W.visible)) {
|
|
9920
9920
|
let Ve, _e;
|
|
9921
9921
|
he.treeNode ? (Ve = Pe.querySelector(".vxe-tree-cell"), he.type === "html" && (_e = Pe.querySelector(".vxe-cell--html"))) : _e = Pe.querySelector(he.type === "html" ? ".vxe-cell--html" : ".vxe-cell--label"), Td(m, Pe, Ve || Pe.children[0], _e, T);
|
|
@@ -9925,8 +9925,8 @@ const lh = rt({
|
|
|
9925
9925
|
* 触发表尾 tooltip 事件
|
|
9926
9926
|
*/
|
|
9927
9927
|
triggerFooterTooltipEvent(m, T) {
|
|
9928
|
-
const { column: O } = T, { tooltipStore:
|
|
9929
|
-
io(
|
|
9928
|
+
const { column: O } = T, { tooltipStore: k } = u, W = m.currentTarget;
|
|
9929
|
+
io(k.column !== O || !!k.row), (k.column !== O || !k.visible) && Td(m, W, W.querySelector(".vxe-cell--item") || W.children[0], null, T);
|
|
9930
9930
|
},
|
|
9931
9931
|
handleTargetLeaveEvent() {
|
|
9932
9932
|
const m = xe.value;
|
|
@@ -9936,8 +9936,8 @@ const lh = rt({
|
|
|
9936
9936
|
}, m.leaveDelay) : p.closeTooltip();
|
|
9937
9937
|
},
|
|
9938
9938
|
triggerHeaderCellClickEvent(m, T) {
|
|
9939
|
-
const { _lastResizeTime: O } = d,
|
|
9940
|
-
|
|
9939
|
+
const { _lastResizeTime: O } = d, k = $.value, W = Ye.value, { column: ce } = T, le = m.currentTarget, me = O && O > Date.now() - 300, he = Rn(m, le, "vxe-cell--sort").flag, Pe = Rn(m, le, "vxe-cell--filter").flag;
|
|
9940
|
+
k.trigger === "cell" && !(me || he || Pe) && g.triggerSortEvent(m, ce, rn(ce)), Ct("header-cell-click", Object.assign({ triggerResizable: me, triggerSort: he, triggerFilter: Pe, cell: le }, T), m), (W.isCurrent || e.highlightCurrentColumn) && g.triggerCurrentColumnEvent(m, T);
|
|
9941
9941
|
},
|
|
9942
9942
|
triggerHeaderCellDblclickEvent(m, T) {
|
|
9943
9943
|
Ct("header-cell-dblclick", Object.assign({ cell: m.currentTarget }, T), m);
|
|
@@ -9948,30 +9948,30 @@ const lh = rt({
|
|
|
9948
9948
|
* 如果是双击模式,则单击后选中状态
|
|
9949
9949
|
*/
|
|
9950
9950
|
triggerCellClickEvent(m, T) {
|
|
9951
|
-
const { highlightCurrentRow: O, editConfig:
|
|
9952
|
-
T = Object.assign({ cell: Kt, triggerRadio: an, triggerCheckbox: tn, triggerTreeNode: vn, triggerExpandNode: hn }, T), !tn && !an && (!hn && (ce.trigger === "row" || zt && ce.trigger === "cell") && g.triggerRowExpandEvent(m, T), (me.trigger === "row" || Dt && me.trigger === "cell") && g.triggerTreeExpandEvent(m, T)), vn || (hn || ((_e.isCurrent || O) && !tn && !an && g.triggerCurrentRowEvent(m, T), !an && (he.trigger === "row" || Xe && he.trigger === "cell") && g.triggerRadioRowEvent(m, T), !tn && (Pe.trigger === "row" || Ot && Pe.trigger === "cell") && g.handleToggleCheckRowEvent(m, T)), mn(
|
|
9951
|
+
const { highlightCurrentRow: O, editConfig: k } = e, { editStore: W } = u, ce = ut.value, le = Me.value, me = Et.value, he = pt.value, Pe = ke.value, Ve = A.value, _e = He.value, { actived: Ne, focused: Je } = W, { row: We, column: qe } = T, { type: ft, treeNode: Dt } = qe, Xe = ft === "radio", Ot = ft === "checkbox", zt = ft === "expand", Kt = m.currentTarget, an = Xe && Rn(m, Kt, "vxe-cell--radio").flag, tn = Ot && Rn(m, Kt, "vxe-cell--checkbox").flag, vn = Dt && Rn(m, Kt, "vxe-tree--btn-wrapper").flag, hn = zt && Rn(m, Kt, "vxe-table--expanded").flag;
|
|
9952
|
+
T = Object.assign({ cell: Kt, triggerRadio: an, triggerCheckbox: tn, triggerTreeNode: vn, triggerExpandNode: hn }, T), !tn && !an && (!hn && (ce.trigger === "row" || zt && ce.trigger === "cell") && g.triggerRowExpandEvent(m, T), (me.trigger === "row" || Dt && me.trigger === "cell") && g.triggerTreeExpandEvent(m, T)), vn || (hn || ((_e.isCurrent || O) && !tn && !an && g.triggerCurrentRowEvent(m, T), !an && (he.trigger === "row" || Xe && he.trigger === "cell") && g.triggerRadioRowEvent(m, T), !tn && (Pe.trigger === "row" || Ot && Pe.trigger === "cell") && g.handleToggleCheckRowEvent(m, T)), mn(k) && (Ve.arrowCursorLock && m && le.mode === "cell" && m.target && /^input|textarea$/i.test(m.target.tagName) && (Je.column = qe, Je.row = We), le.trigger === "manual" ? Ne.args && Ne.row === We && qe !== Ne.column && Lo(m, T) : (!Ne.args || We !== Ne.row || qe !== Ne.column) && (le.trigger === "click" || le.trigger === "dblclick" && le.mode === "row" && Ne.row === We) && Lo(m, T))), mn(k) && le.trigger === "dblclick" && Ne.row && Ne.column && (le.mode === "row" ? q.eqRow(Ne.row, We) || q.handleClearEdit(m) : le.mode === "cell" && (!q.eqRow(Ne.row, We) || Ne.column.id !== qe.id) && q.handleClearEdit(m)), Ct("cell-click", T, m);
|
|
9953
9953
|
},
|
|
9954
9954
|
/**
|
|
9955
9955
|
* 列双击点击事件
|
|
9956
9956
|
* 如果是双击模式,则激活为编辑状态
|
|
9957
9957
|
*/
|
|
9958
9958
|
triggerCellDblclickEvent(m, T) {
|
|
9959
|
-
const { editConfig: O } = e, { editStore:
|
|
9959
|
+
const { editConfig: O } = e, { editStore: k } = u, W = Me.value, { actived: ce } = k, le = m.currentTarget;
|
|
9960
9960
|
T = Object.assign({ cell: le }, T), mn(O) && W.trigger === "dblclick" && (!ce.args || m.currentTarget !== ce.args.cell) && (W.mode === "row" ? wo("blur").catch((me) => me).then(() => {
|
|
9961
9961
|
q.handleEdit(T, m).then(() => wo("change")).catch((me) => me);
|
|
9962
9962
|
}) : W.mode === "cell" && q.handleEdit(T, m).then(() => wo("change")).catch((me) => me)), Ct("cell-dblclick", T, m);
|
|
9963
9963
|
},
|
|
9964
9964
|
handleToggleCheckRowEvent(m, T) {
|
|
9965
|
-
const { selectCheckboxMaps: O } = u,
|
|
9965
|
+
const { selectCheckboxMaps: O } = u, k = ke.value, { checkField: W, trigger: ce } = k, { row: le } = T;
|
|
9966
9966
|
if (ce === "manual")
|
|
9967
9967
|
return;
|
|
9968
9968
|
let me = !1;
|
|
9969
9969
|
W ? me = !i.get(le, W) : me = !O[St(q, le)], m ? g.triggerCheckRowEvent(m, T, me) : (g.handleBatchSelectRows([le], me), g.checkSelectionStatus());
|
|
9970
9970
|
},
|
|
9971
9971
|
triggerCheckRowEvent(m, T, O) {
|
|
9972
|
-
const
|
|
9972
|
+
const k = ke.value, { row: W } = T, { afterFullData: ce } = d, { checkMethod: le, trigger: me } = k;
|
|
9973
9973
|
if (me !== "manual") {
|
|
9974
|
-
if (m.stopPropagation(),
|
|
9974
|
+
if (m.stopPropagation(), k.isShiftKey && m.shiftKey && !e.treeConfig) {
|
|
9975
9975
|
const he = p.getCheckboxRecords();
|
|
9976
9976
|
if (he.length) {
|
|
9977
9977
|
const Pe = he[0], Ve = p.getVTRowIndex(W), _e = p.getVTRowIndex(Pe);
|
|
@@ -9995,42 +9995,42 @@ const lh = rt({
|
|
|
9995
9995
|
* 多选,选中所有事件
|
|
9996
9996
|
*/
|
|
9997
9997
|
triggerCheckAllEvent(m, T) {
|
|
9998
|
-
const O = ke.value, { trigger:
|
|
9999
|
-
|
|
9998
|
+
const O = ke.value, { trigger: k } = O;
|
|
9999
|
+
k !== "manual" && (m && m.stopPropagation(), Qi(m, T));
|
|
10000
10000
|
},
|
|
10001
10001
|
/**
|
|
10002
10002
|
* 单选,行选中事件
|
|
10003
10003
|
*/
|
|
10004
10004
|
triggerRadioRowEvent(m, T) {
|
|
10005
|
-
const { selectRadioRow: O } = u, { row:
|
|
10005
|
+
const { selectRadioRow: O } = u, { row: k } = T, W = pt.value, { trigger: ce } = W;
|
|
10006
10006
|
if (ce === "manual")
|
|
10007
10007
|
return;
|
|
10008
10008
|
m.stopPropagation();
|
|
10009
|
-
let le =
|
|
10009
|
+
let le = k, me = O !== le;
|
|
10010
10010
|
me ? Ue(le) : W.strict || (me = O === le, me && (le = null, p.clearRadioRow())), me && Ct("radio-change", Object.assign({ oldValue: O, newValue: le }, T), m);
|
|
10011
10011
|
},
|
|
10012
10012
|
triggerCurrentColumnEvent(m, T) {
|
|
10013
|
-
const O = Ye.value, { currentMethod:
|
|
10014
|
-
(!
|
|
10013
|
+
const O = Ye.value, { currentMethod: k } = O, { column: W } = T;
|
|
10014
|
+
(!k || k({ column: W })) && p.setCurrentColumn(W);
|
|
10015
10015
|
},
|
|
10016
10016
|
triggerCurrentRowEvent(m, T) {
|
|
10017
|
-
const { currentRow: O } = u,
|
|
10017
|
+
const { currentRow: O } = u, k = He.value, { currentMethod: W } = k, { row: ce } = T, le = O !== ce;
|
|
10018
10018
|
(!W || W({ row: ce })) && (p.setCurrentRow(ce), le && Ct("current-change", Object.assign({ oldValue: O, newValue: ce }, T), m));
|
|
10019
10019
|
},
|
|
10020
10020
|
/**
|
|
10021
10021
|
* 展开行事件
|
|
10022
10022
|
*/
|
|
10023
10023
|
triggerRowExpandEvent(m, T) {
|
|
10024
|
-
const { rowExpandLazyLoadedMaps: O, expandColumn:
|
|
10024
|
+
const { rowExpandLazyLoadedMaps: O, expandColumn: k } = u, W = ut.value, { row: ce } = T, { lazy: le, trigger: me } = W;
|
|
10025
10025
|
if (me === "manual")
|
|
10026
10026
|
return;
|
|
10027
10027
|
m.stopPropagation();
|
|
10028
10028
|
const he = St(q, ce);
|
|
10029
10029
|
if (!le || !O[he]) {
|
|
10030
|
-
const Pe = !p.isRowExpandByRow(ce), Ve = p.getColumnIndex(
|
|
10030
|
+
const Pe = !p.isRowExpandByRow(ce), Ve = p.getColumnIndex(k), _e = p.getVMColumnIndex(k);
|
|
10031
10031
|
p.setRowExpand(ce, Pe), Ct("toggle-row-expand", {
|
|
10032
10032
|
expanded: Pe,
|
|
10033
|
-
column:
|
|
10033
|
+
column: k,
|
|
10034
10034
|
columnIndex: Ve,
|
|
10035
10035
|
$columnIndex: _e,
|
|
10036
10036
|
row: ce,
|
|
@@ -10043,7 +10043,7 @@ const lh = rt({
|
|
|
10043
10043
|
* 展开树节点事件
|
|
10044
10044
|
*/
|
|
10045
10045
|
triggerTreeExpandEvent(m, T) {
|
|
10046
|
-
const { treeExpandLazyLoadedMaps: O } = u,
|
|
10046
|
+
const { treeExpandLazyLoadedMaps: O } = u, k = Et.value, { row: W, column: ce } = T, { lazy: le, trigger: me } = k;
|
|
10047
10047
|
if (me === "manual")
|
|
10048
10048
|
return;
|
|
10049
10049
|
m.stopPropagation();
|
|
@@ -10054,32 +10054,32 @@ const lh = rt({
|
|
|
10054
10054
|
}
|
|
10055
10055
|
},
|
|
10056
10056
|
handleColumnSortEvent(m, T) {
|
|
10057
|
-
const { mouseConfig: O } = e,
|
|
10057
|
+
const { mouseConfig: O } = e, k = Se.value, { field: W, sortable: ce } = T;
|
|
10058
10058
|
if (ce) {
|
|
10059
10059
|
const le = { $table: q, $event: m, column: T, field: W, property: W, order: T.order, sortList: p.getSortColumns(), sortTime: T.sortTime };
|
|
10060
|
-
O &&
|
|
10060
|
+
O && k.area && q.handleSortEvent && q.handleSortEvent(m, le), Ct("sort-change", le, m);
|
|
10061
10061
|
}
|
|
10062
10062
|
},
|
|
10063
10063
|
/**
|
|
10064
10064
|
* 点击排序事件
|
|
10065
10065
|
*/
|
|
10066
10066
|
triggerSortEvent(m, T, O) {
|
|
10067
|
-
const
|
|
10068
|
-
ce && (!O || T.order === O ? p.clearSort(
|
|
10067
|
+
const k = $.value, { field: W, sortable: ce } = T;
|
|
10068
|
+
ce && (!O || T.order === O ? p.clearSort(k.multiple ? T : null) : p.sort({ field: W, order: O }), q.handleColumnSortEvent(m, T));
|
|
10069
10069
|
},
|
|
10070
10070
|
/**
|
|
10071
10071
|
* 表头单元格按下事件
|
|
10072
10072
|
*/
|
|
10073
10073
|
triggerHeaderCellMousedownEvent(m, T) {
|
|
10074
|
-
const { mouseConfig: O } = e,
|
|
10074
|
+
const { mouseConfig: O } = e, k = Se.value, W = Ye.value, ce = at.value, { trigger: le, disabledMethod: me } = ce, he = m.currentTarget, Pe = he && he.tagName && he.tagName.toLowerCase() === "input", Ve = Rn(m, he, "vxe-cell--checkbox").flag, _e = Rn(m, he, "vxe-cell--sort").flag, Ne = Rn(m, he, "vxe-cell--filter").flag;
|
|
10075
10075
|
let Je = !1;
|
|
10076
|
-
Pe || Ve || _e || Ne || W.drag && le === "cell" && !(me && me(T)) && (Je = !0, q.handleHeaderCellDragMousedownEvent(m, T)), !Je && O &&
|
|
10076
|
+
Pe || Ve || _e || Ne || W.drag && le === "cell" && !(me && me(T)) && (Je = !0, q.handleHeaderCellDragMousedownEvent(m, T)), !Je && O && k.area && q.handleHeaderCellAreaEvent && q.handleHeaderCellAreaEvent(m, Object.assign({ cell: he, triggerSort: _e, triggerFilter: Ne }, T)), q.focus(), q.closeMenu && q.closeMenu();
|
|
10077
10077
|
},
|
|
10078
10078
|
/**
|
|
10079
10079
|
* 单元格按下事件
|
|
10080
10080
|
*/
|
|
10081
10081
|
triggerCellMousedownEvent(m, T) {
|
|
10082
|
-
const { column: O } = T, { type:
|
|
10082
|
+
const { column: O } = T, { type: k, treeNode: W } = O, ce = k === "radio", le = k === "checkbox", me = k === "expand", he = He.value, Pe = Ge.value, { trigger: Ve, disabledMethod: _e } = Pe, Ne = m.currentTarget;
|
|
10083
10083
|
T.cell = Ne;
|
|
10084
10084
|
const Je = Ne && Ne.tagName && Ne.tagName.toLowerCase() === "input", We = ce && Rn(m, Ne, "vxe-cell--radio").flag, qe = le && Rn(m, Ne, "vxe-cell--checkbox").flag, ft = W && Rn(m, Ne, "vxe-tree--btn-wrapper").flag, Dt = me && Rn(m, Ne, "vxe-table--expanded").flag;
|
|
10085
10085
|
let Xe = !1;
|
|
@@ -10097,7 +10097,7 @@ const lh = rt({
|
|
|
10097
10097
|
}
|
|
10098
10098
|
},
|
|
10099
10099
|
handleRowDragDragendEvent(m) {
|
|
10100
|
-
const { treeConfig: T, dragConfig: O } = e,
|
|
10100
|
+
const { treeConfig: T, dragConfig: O } = e, k = Ge.value, { fullAllDataRowIdData: W, prevDragToChild: ce } = d, { isCrossDrag: le, isSelfToChildDrag: me, dragEndMethod: he } = k, Pe = Et.value, { transform: Ve, rowField: _e, mapChildrenField: Ne, parentField: Je } = Pe, We = Pe.children || Pe.childrenField, { dragRow: qe } = u, { afterFullData: ft, tableFullData: Dt, prevDragRow: Xe, prevDragPos: Ot } = d, zt = he || (O ? O.dragEndMethod : null), Kt = Ot === "bottom" ? 1 : 0;
|
|
10101
10101
|
Xe && qe && Xe !== qe && Promise.resolve(zt ? zt({
|
|
10102
10102
|
oldRow: qe,
|
|
10103
10103
|
newRow: Xe,
|
|
@@ -10180,8 +10180,8 @@ const lh = rt({
|
|
|
10180
10180
|
}, 500);
|
|
10181
10181
|
},
|
|
10182
10182
|
handleRowDragDragoverEvent(m) {
|
|
10183
|
-
const { treeConfig: T } = e, { fullAllDataRowIdData: O } = d, { dragRow:
|
|
10184
|
-
if (!
|
|
10183
|
+
const { treeConfig: T } = e, { fullAllDataRowIdData: O } = d, { dragRow: k } = u, W = Et.value, { transform: ce } = W, le = Ge.value, { isCrossDrag: me, isToChildDrag: he } = le;
|
|
10184
|
+
if (!k) {
|
|
10185
10185
|
m.preventDefault();
|
|
10186
10186
|
return;
|
|
10187
10187
|
}
|
|
@@ -10204,7 +10204,7 @@ const lh = rt({
|
|
|
10204
10204
|
handleCellDragMousedownEvent(m, T) {
|
|
10205
10205
|
var O;
|
|
10206
10206
|
m.stopPropagation();
|
|
10207
|
-
const { dragConfig:
|
|
10207
|
+
const { dragConfig: k } = e, W = Ge.value, { trigger: ce, dragStartMethod: le } = W, { row: me } = T, he = m.currentTarget, Pe = ce === "cell" || ce === "row" ? he : (O = he.parentElement) === null || O === void 0 ? void 0 : O.parentElement, Ve = Pe.parentElement, _e = le || (k ? k.dragStartMethod : null);
|
|
10208
10208
|
if (Qo(), _e && !_e(T)) {
|
|
10209
10209
|
Ve.draggable = !1, u.dragRow = null, u.dragCol = null, Tl();
|
|
10210
10210
|
return;
|
|
@@ -10223,10 +10223,10 @@ const lh = rt({
|
|
|
10223
10223
|
T.src = kf, m.dataTransfer.setDragImage(T, 0, 0);
|
|
10224
10224
|
}
|
|
10225
10225
|
},
|
|
10226
|
-
handleColDragSwapEvent(m, T, O,
|
|
10226
|
+
handleColDragSwapEvent(m, T, O, k, W, ce) {
|
|
10227
10227
|
const { mouseConfig: le } = e, me = at.value, { isCrossDrag: he, isSelfToChildDrag: Pe, isToChildDrag: Ve, dragEndMethod: _e } = me, { collectColumn: Ne } = d, Je = W === "right" ? 1 : 0;
|
|
10228
|
-
if (
|
|
10229
|
-
const We = O, qe =
|
|
10228
|
+
if (k && O && k !== O) {
|
|
10229
|
+
const We = O, qe = k;
|
|
10230
10230
|
return Promise.resolve(_e ? _e({
|
|
10231
10231
|
oldColumn: We,
|
|
10232
10232
|
newColumn: qe,
|
|
@@ -10304,13 +10304,13 @@ const lh = rt({
|
|
|
10304
10304
|
return Promise.resolve();
|
|
10305
10305
|
},
|
|
10306
10306
|
handleHeaderCellDragDragendEvent(m) {
|
|
10307
|
-
const { dragCol: T } = u, { prevDragCol: O, prevDragPos:
|
|
10308
|
-
q.handleColDragSwapEvent(m, !0, T, O,
|
|
10307
|
+
const { dragCol: T } = u, { prevDragCol: O, prevDragPos: k, prevDragToChild: W } = d;
|
|
10308
|
+
q.handleColDragSwapEvent(m, !0, T, O, k, W), Tl(), qa(), d.prevDragToChild = !1, u.dragRow = null, u.dragCol = null, setTimeout(() => {
|
|
10309
10309
|
u.isDragColMove = !1;
|
|
10310
10310
|
}, 500);
|
|
10311
10311
|
},
|
|
10312
10312
|
handleHeaderCellDragDragoverEvent(m) {
|
|
10313
|
-
const { dragCol: T } = u, O = at.value, { isToChildDrag:
|
|
10313
|
+
const { dragCol: T } = u, O = at.value, { isToChildDrag: k, isCrossDrag: W } = O;
|
|
10314
10314
|
if (!T) {
|
|
10315
10315
|
m.preventDefault();
|
|
10316
10316
|
return;
|
|
@@ -10323,7 +10323,7 @@ const lh = rt({
|
|
|
10323
10323
|
vs(m, null, le, !1, _e);
|
|
10324
10324
|
return;
|
|
10325
10325
|
}
|
|
10326
|
-
d.prevDragToChild = !!(
|
|
10326
|
+
d.prevDragToChild = !!(k && ce), d.prevDragCol = he, d.prevDragPos = _e, vs(m, null, le, !0, _e), Ct("column-dragover", {
|
|
10327
10327
|
oldColumn: Pe,
|
|
10328
10328
|
targetColumn: he,
|
|
10329
10329
|
dragPos: _e
|
|
@@ -10333,7 +10333,7 @@ const lh = rt({
|
|
|
10333
10333
|
handleHeaderCellDragMousedownEvent(m, T) {
|
|
10334
10334
|
var O;
|
|
10335
10335
|
m.stopPropagation();
|
|
10336
|
-
const
|
|
10336
|
+
const k = at.value, { trigger: W, dragStartMethod: ce } = k, { column: le } = T, me = m.currentTarget, he = W === "cell" ? me : (O = me.parentElement) === null || O === void 0 ? void 0 : O.parentElement;
|
|
10337
10337
|
if (u.isDragColMove = !1, qa(), ce && !ce(T)) {
|
|
10338
10338
|
he.draggable = !1, u.dragRow = null, u.dragCol = null, Tl();
|
|
10339
10339
|
return;
|
|
@@ -10343,7 +10343,7 @@ const lh = rt({
|
|
|
10343
10343
|
handleHeaderCellDragMouseupEvent() {
|
|
10344
10344
|
qa(), Tl(), u.dragRow = null, u.dragCol = null, u.isDragColMove = !1;
|
|
10345
10345
|
},
|
|
10346
|
-
handleScrollEvent(m, T, O,
|
|
10346
|
+
handleScrollEvent(m, T, O, k, W, ce) {
|
|
10347
10347
|
const { highlightHoverRow: le } = e, { lastScrollLeft: me, lastScrollTop: he } = d, Pe = x.value, Ve = Pe ? Pe.$el : null, _e = He.value, Ne = E.value, Je = w.value, We = Ve ? Ve.clientHeight : 0, qe = Ve ? Ve.clientWidth : 0, ft = Ve ? Ve.scrollHeight : 0, Dt = Ve ? Ve.scrollWidth : 0;
|
|
10348
10348
|
let Xe = !1, Ot = !1, zt = !1, Kt = !1, an = "", tn = !1, vn = !1, hn = !1, un = !1;
|
|
10349
10349
|
if (O) {
|
|
@@ -10352,11 +10352,11 @@ const lh = rt({
|
|
|
10352
10352
|
}
|
|
10353
10353
|
if (T) {
|
|
10354
10354
|
const cn = Ce.value;
|
|
10355
|
-
Xe =
|
|
10355
|
+
Xe = k <= 0, Xe || (Ot = k + We >= ft), k > he ? (an = "bottom", k + We >= ft - cn && (vn = !0)) : (an = "top", k <= cn && (tn = !0)), d.lastScrollTop = k;
|
|
10356
10356
|
}
|
|
10357
10357
|
u.isDragColMove = !1, u.isDragRowMove = !1, u.lastScrollTime = Date.now();
|
|
10358
10358
|
const On = Object.assign({
|
|
10359
|
-
scrollTop:
|
|
10359
|
+
scrollTop: k,
|
|
10360
10360
|
scrollLeft: W,
|
|
10361
10361
|
bodyHeight: We,
|
|
10362
10362
|
bodyWidth: qe,
|
|
@@ -10390,24 +10390,24 @@ const lh = rt({
|
|
|
10390
10390
|
* @param {Row} row 行对象
|
|
10391
10391
|
*/
|
|
10392
10392
|
scrollToTreeRow(m) {
|
|
10393
|
-
const { treeConfig: T } = e, { tableFullData: O } = d,
|
|
10393
|
+
const { treeConfig: T } = e, { tableFullData: O } = d, k = [];
|
|
10394
10394
|
if (T) {
|
|
10395
10395
|
const W = Et.value, ce = W.children || W.childrenField, le = i.findTree(O, (me) => q.eqRow(me, m), { children: ce });
|
|
10396
10396
|
if (le) {
|
|
10397
10397
|
const me = le.nodes;
|
|
10398
10398
|
me.forEach((he, Pe) => {
|
|
10399
|
-
Pe < me.length - 1 && !p.isTreeExpandByRow(he) &&
|
|
10399
|
+
Pe < me.length - 1 && !p.isTreeExpandByRow(he) && k.push(p.setTreeExpand(he, !0));
|
|
10400
10400
|
});
|
|
10401
10401
|
}
|
|
10402
10402
|
}
|
|
10403
|
-
return Promise.all(
|
|
10403
|
+
return Promise.all(k).then(() => Yg(q, m));
|
|
10404
10404
|
},
|
|
10405
10405
|
updateScrollYStatus: Bs,
|
|
10406
10406
|
// 更新横向 X 可视渲染上下剩余空间大小
|
|
10407
10407
|
updateScrollXSpace() {
|
|
10408
|
-
const { isGroup: m, scrollXLoad: T, scrollbarWidth: O } = u, { visibleColumn:
|
|
10408
|
+
const { isGroup: m, scrollXLoad: T, scrollbarWidth: O } = u, { visibleColumn: k, scrollXStore: W, elemStore: ce, tableWidth: le } = d, me = b.value, he = x.value, Pe = C.value, Ve = he ? he.$el : null;
|
|
10409
10409
|
if (Ve) {
|
|
10410
|
-
const _e = me ? me.$el : null, Ne = Pe ? Pe.$el : null, Je = _e ? _e.querySelector(".vxe-table--header") : null, We = Ve.querySelector(".vxe-table--body"), qe = Ne ? Ne.querySelector(".vxe-table--footer") : null, ft =
|
|
10410
|
+
const _e = me ? me.$el : null, Ne = Pe ? Pe.$el : null, Je = _e ? _e.querySelector(".vxe-table--header") : null, We = Ve.querySelector(".vxe-table--body"), qe = Ne ? Ne.querySelector(".vxe-table--footer") : null, ft = k.slice(0, W.startIndex).reduce((zt, Kt) => zt + Kt.renderWidth, 0);
|
|
10411
10411
|
let Dt = "";
|
|
10412
10412
|
T && (Dt = `${ft}px`), Je && (Je.style.marginLeft = m ? "" : Dt), We.style.marginLeft = Dt, qe && (qe.style.marginLeft = Dt), ["main"].forEach((zt) => {
|
|
10413
10413
|
["header", "body", "footer"].forEach((an) => {
|
|
@@ -10421,7 +10421,7 @@ const lh = rt({
|
|
|
10421
10421
|
},
|
|
10422
10422
|
// 更新纵向 Y 可视渲染上下剩余空间大小
|
|
10423
10423
|
updateScrollYSpace() {
|
|
10424
|
-
const { showOverflow: m } = e, { scrollYLoad: T } = u, { scrollYStore: O, elemStore:
|
|
10424
|
+
const { showOverflow: m } = e, { scrollYLoad: T } = u, { scrollYStore: O, elemStore: k, afterFullData: W, fullAllDataRowIdData: ce } = d, { startIndex: le, rowHeight: me } = O;
|
|
10425
10425
|
let he = 0, Pe = 0;
|
|
10426
10426
|
const Ve = ["main", "left", "right"];
|
|
10427
10427
|
let _e = "", Ne = "";
|
|
@@ -10441,9 +10441,9 @@ const lh = rt({
|
|
|
10441
10441
|
_e = `${Pe}px`, Ne = `${he}px`;
|
|
10442
10442
|
}
|
|
10443
10443
|
Ve.forEach((We) => {
|
|
10444
|
-
const qe = ["header", "body", "footer"], ft = tr(
|
|
10444
|
+
const qe = ["header", "body", "footer"], ft = tr(k[`${We}-body-table`]);
|
|
10445
10445
|
ft && (ft.style.marginTop = _e), qe.forEach((Dt) => {
|
|
10446
|
-
const Xe = tr(
|
|
10446
|
+
const Xe = tr(k[`${We}-${Dt}-ySpace`]);
|
|
10447
10447
|
Xe && (Xe.style.height = Ne);
|
|
10448
10448
|
});
|
|
10449
10449
|
});
|
|
@@ -10465,7 +10465,7 @@ const lh = rt({
|
|
|
10465
10465
|
* 处理固定列的显示状态
|
|
10466
10466
|
*/
|
|
10467
10467
|
checkScrolling() {
|
|
10468
|
-
const m = L.value, T = B.value, O = x.value,
|
|
10468
|
+
const m = L.value, T = B.value, O = x.value, k = O ? O.$el : null, ce = G.value || k;
|
|
10469
10469
|
ce && (m && (ce.scrollLeft > 0 ? fl(m, "scrolling--middle") : Dr(m, "scrolling--middle")), T && (ce.clientWidth < ce.scrollWidth - Math.ceil(ce.scrollLeft) ? fl(T, "scrolling--middle") : Dr(T, "scrolling--middle")));
|
|
10470
10470
|
},
|
|
10471
10471
|
updateZindex() {
|
|
@@ -10480,7 +10480,7 @@ const lh = rt({
|
|
|
10480
10480
|
},
|
|
10481
10481
|
setHoverRow(m) {
|
|
10482
10482
|
const T = St(q, m), O = h.value;
|
|
10483
|
-
g.clearHoverRow(), O && i.arrayEach(O.querySelectorAll(`[rowid="${T}"]`), (
|
|
10483
|
+
g.clearHoverRow(), O && i.arrayEach(O.querySelectorAll(`[rowid="${T}"]`), (k) => fl(k, "row--hover")), d.hoverRow = m;
|
|
10484
10484
|
},
|
|
10485
10485
|
clearHoverRow() {
|
|
10486
10486
|
const m = h.value;
|
|
@@ -10509,7 +10509,7 @@ const lh = rt({
|
|
|
10509
10509
|
};
|
|
10510
10510
|
})), Object.assign(q, p, g);
|
|
10511
10511
|
const om = (m) => {
|
|
10512
|
-
const { showHeader: T, showFooter: O } = e, { tableData:
|
|
10512
|
+
const { showHeader: T, showFooter: O } = e, { tableData: k, tableColumn: W, tableGroupColumn: ce, columnStore: le, footerTableData: me } = u, he = m === "left", Pe = he ? le.leftList : le.rightList;
|
|
10513
10513
|
return l("div", {
|
|
10514
10514
|
ref: he ? L : B,
|
|
10515
10515
|
class: `vxe-table--fixed-${m}-wrapper`
|
|
@@ -10517,7 +10517,7 @@ const lh = rt({
|
|
|
10517
10517
|
T ? l(rh, {
|
|
10518
10518
|
ref: he ? M : U,
|
|
10519
10519
|
fixedType: m,
|
|
10520
|
-
tableData:
|
|
10520
|
+
tableData: k,
|
|
10521
10521
|
tableColumn: W,
|
|
10522
10522
|
tableGroupColumn: ce,
|
|
10523
10523
|
fixedColumn: Pe
|
|
@@ -10525,7 +10525,7 @@ const lh = rt({
|
|
|
10525
10525
|
l(nh, {
|
|
10526
10526
|
ref: he ? F : ne,
|
|
10527
10527
|
fixedType: m,
|
|
10528
|
-
tableData:
|
|
10528
|
+
tableData: k,
|
|
10529
10529
|
tableColumn: W,
|
|
10530
10530
|
fixedColumn: Pe
|
|
10531
10531
|
}),
|
|
@@ -10542,23 +10542,23 @@ const lh = rt({
|
|
|
10542
10542
|
if (n.empty)
|
|
10543
10543
|
return n.empty(T);
|
|
10544
10544
|
{
|
|
10545
|
-
const O = m.name ? ah.get(m.name) : null,
|
|
10546
|
-
if (
|
|
10547
|
-
return Tr(
|
|
10545
|
+
const O = m.name ? ah.get(m.name) : null, k = O ? O.renderTableEmpty || O.renderTableEmptyView || O.renderEmpty : null;
|
|
10546
|
+
if (k)
|
|
10547
|
+
return Tr(k(m, T));
|
|
10548
10548
|
}
|
|
10549
10549
|
return hl(e.emptyText) || es("vxe.table.emptyText");
|
|
10550
10550
|
}, mE = () => {
|
|
10551
|
-
const { dragConfig: m } = e, { dragRow: T, dragCol: O, dragTipText:
|
|
10552
|
-
return T && me ? Ua(me, { row: T }) : O && Pe ? Ua(Pe, { column: O }) : [l("span",
|
|
10551
|
+
const { dragConfig: m } = e, { dragRow: T, dragCol: O, dragTipText: k } = u, W = at.value, me = (Ge.value.slots || {}).tip || (m && m.slots ? m.slots.rowTip : null), Pe = (W.slots || {}).tip;
|
|
10552
|
+
return T && me ? Ua(me, { row: T }) : O && Pe ? Ua(Pe, { column: O }) : [l("span", k)];
|
|
10553
10553
|
}, gE = () => {
|
|
10554
|
-
const { dragRow: m } = u, T = He.value, O = Ye.value,
|
|
10554
|
+
const { dragRow: m } = u, T = He.value, O = Ye.value, k = Ge.value, W = at.value;
|
|
10555
10555
|
return T.drag || O.drag ? l("div", {
|
|
10556
10556
|
class: "vxe-table--drag-wrapper"
|
|
10557
10557
|
}, [
|
|
10558
10558
|
l("div", {
|
|
10559
|
-
ref:
|
|
10559
|
+
ref: V,
|
|
10560
10560
|
class: ["vxe-table--drag-row-line", {
|
|
10561
|
-
"is--guides":
|
|
10561
|
+
"is--guides": k.showGuidesStatus
|
|
10562
10562
|
}]
|
|
10563
10563
|
}),
|
|
10564
10564
|
l("div", {
|
|
@@ -10599,7 +10599,7 @@ const lh = rt({
|
|
|
10599
10599
|
m && m.clientWidth && m.clientHeight && p.recalculate();
|
|
10600
10600
|
}
|
|
10601
10601
|
const hE = () => {
|
|
10602
|
-
const { loading: m, stripe: T, showHeader: O, height:
|
|
10602
|
+
const { loading: m, stripe: T, showHeader: O, height: k, treeConfig: W, mouseConfig: ce, showFooter: le, highlightCell: me, highlightHoverRow: he, highlightHoverColumn: Pe, editConfig: Ve, editRules: _e } = e, { isCalcColumn: Ne, isGroup: Je, overflowX: We, overflowY: qe, scrollXLoad: ft, scrollYLoad: Dt, scrollbarHeight: Xe, tableData: Ot, tableColumn: zt, tableGroupColumn: Kt, footerTableData: an, initStore: tn, columnStore: vn, filterStore: hn, customStore: un, tooltipStore: On } = u, { leftList: cn, rightList: xn } = vn, Qn = n.loading, jr = Be.value, hr = oe.value, qr = ke.value, Ol = Et.value, Kl = He.value, er = Ye.value, co = f.value, Ir = Mt.value, Uo = Se.value, Ml = K.value, ol = Oe.value, eo = yn.value, uo = Le.value, fo = u._isLoading || m, to = Qt.value, Io = dt.value, sr = ce && Uo.area, Po = Pt.value, oo = at.value;
|
|
10603
10603
|
return l("div", {
|
|
10604
10604
|
ref: h,
|
|
10605
10605
|
class: ["vxe-table", "vxe-table--render-default", `tid_${r}`, `border--${Ir}`, {
|
|
@@ -10833,7 +10833,7 @@ const lh = rt({
|
|
|
10833
10833
|
/**
|
|
10834
10834
|
* 校验提示
|
|
10835
10835
|
*/
|
|
10836
|
-
e.editRules && hr.showMessage && (hr.message === "default" ? !
|
|
10836
|
+
e.editRules && hr.showMessage && (hr.message === "default" ? !k : hr.message === "tooltip") ? l(a, Object.assign({ key: "vtp", ref: E, class: [{
|
|
10837
10837
|
"old-cell-valid": _e && An().cellVaildMode === "obsolete"
|
|
10838
10838
|
}, "vxe-table--valid-error"] }, hr.message === "tooltip" || Ot.length === 1 ? ol : {})) : zo(q)
|
|
10839
10839
|
]) : zo(q)
|
|
@@ -10846,8 +10846,8 @@ const lh = rt({
|
|
|
10846
10846
|
}), ot(Md, () => {
|
|
10847
10847
|
const { initStatus: m } = d;
|
|
10848
10848
|
$o(e.data || []).then(() => {
|
|
10849
|
-
const { scrollXLoad: T, scrollYLoad: O, expandColumn:
|
|
10850
|
-
d.inited = !0, d.initStatus = !0, m || To(), process.env.NODE_ENV === "development" && (T || O) &&
|
|
10849
|
+
const { scrollXLoad: T, scrollYLoad: O, expandColumn: k } = u;
|
|
10850
|
+
d.inited = !0, d.initStatus = !0, m || To(), process.env.NODE_ENV === "development" && (T || O) && k && sn("vxe.error.scrollErrProp", ["column.type=expand"]), p.recalculate();
|
|
10851
10851
|
});
|
|
10852
10852
|
});
|
|
10853
10853
|
const $d = Te(0);
|
|
@@ -10933,7 +10933,7 @@ const lh = rt({
|
|
|
10933
10933
|
d.isActivated = !1, g.preventEvent(null, "deactivated", { $table: q });
|
|
10934
10934
|
}), Dn(() => {
|
|
10935
10935
|
pe(() => {
|
|
10936
|
-
const { data: m, treeConfig: T, showOverflow: O } = e, { scrollXStore:
|
|
10936
|
+
const { data: m, treeConfig: T, showOverflow: O } = e, { scrollXStore: k, scrollYStore: W } = d, ce = de.value, le = Me.value, me = Et.value, he = pt.value, Pe = ke.value, Ve = ut.value, _e = He.value;
|
|
10937
10937
|
if (process.env.NODE_ENV === "development") {
|
|
10938
10938
|
e.rowId && sn("vxe.error.delProp", ["row-id", "row-config.keyField"]), e.rowKey && sn("vxe.error.delProp", ["row-key", "row-config.useKey"]), e.columnKey && sn("vxe.error.delProp", ["column-id", "column-config.useKey"]), !(e.rowId || _e.keyField) && (Pe.reserve || Pe.checkRowKeys || he.reserve || he.checkRowKey || Ve.expandRowKeys || me.expandRowKeys) && sn("vxe.error.reqProp", ["row-config.keyField"]), e.editConfig && (le.showStatus || le.showUpdateStatus || le.showInsertStatus) && !e.keepSource && sn("vxe.error.reqProp", ["keep-source"]), T && (me.showLine || me.line) && (!(e.rowKey || _e.useKey) || !O) && sn("vxe.error.reqProp", ["row-config.useKey | show-overflow"]), T && !me.transform && e.stripe && sn("vxe.error.noTree", ["stripe"]), e.showFooter && !(e.footerMethod || e.footerData) && sn("vxe.error.reqProp", ["footer-data | footer-method"]);
|
|
10939
10939
|
const { exportConfig: Ne, importConfig: Je } = e, We = tt.value, qe = et.value;
|
|
@@ -10952,7 +10952,7 @@ const lh = rt({
|
|
|
10952
10952
|
endIndex: 0,
|
|
10953
10953
|
visibleSize: 0,
|
|
10954
10954
|
adaptive: ce.adaptive !== !1
|
|
10955
|
-
}), Object.assign(
|
|
10955
|
+
}), Object.assign(k, {
|
|
10956
10956
|
startIndex: 0,
|
|
10957
10957
|
endIndex: 0,
|
|
10958
10958
|
visibleSize: 0
|
|
@@ -11059,14 +11059,14 @@ j_.add("tableFilterModule", {
|
|
|
11059
11059
|
const Q = a.value, P = Q ? Q.$el : null;
|
|
11060
11060
|
if (!P)
|
|
11061
11061
|
return;
|
|
11062
|
-
const z = P.offsetWidth,
|
|
11062
|
+
const z = P.offsetWidth, V = P.offsetHeight, I = P.querySelector(".vxe-table--filter-header"), Z = P.querySelector(".vxe-table--filter-footer"), ie = z / 2, G = 10, re = ue.clientWidth - z - G;
|
|
11063
11063
|
let ge, De;
|
|
11064
11064
|
const ae = {
|
|
11065
11065
|
top: `${b.offsetTop + b.offsetParent.offsetTop + b.offsetHeight}px`
|
|
11066
11066
|
};
|
|
11067
11067
|
let _ = null;
|
|
11068
11068
|
const Y = ue.clientHeight - (B ? B.clientHeight / 2 : 0);
|
|
11069
|
-
if (
|
|
11069
|
+
if (V >= Y && (_ = Math.max(40, Y - (Z ? Z.offsetHeight : 0) - (I ? I.offsetHeight : 0))), E.fixed === "left" ? ge = b.offsetLeft + b.offsetParent.offsetLeft - ie : E.fixed === "right" ? De = b.offsetParent.offsetWidth - b.offsetLeft + (b.offsetParent.offsetParent.offsetWidth - b.offsetParent.offsetLeft) - E.renderWidth - ie : ge = b.offsetLeft + b.offsetParent.offsetLeft - ie - ue.scrollLeft, ge) {
|
|
11070
11070
|
const oe = x + z - ie + G - C;
|
|
11071
11071
|
oe > 0 && (ge -= oe), ae.left = `${Math.min(re, Math.max(G, ge))}px`;
|
|
11072
11072
|
} else if (De) {
|
|
@@ -11219,15 +11219,15 @@ G_.add("tableMenuModule", {
|
|
|
11219
11219
|
left: `${L}px`
|
|
11220
11220
|
}
|
|
11221
11221
|
}), pe(() => {
|
|
11222
|
-
const
|
|
11222
|
+
const V = c.value.getRefMaps().refElem.value, I = V.clientHeight, Z = V.clientWidth, { boundingTop: ie, boundingLeft: G } = Pc(V), re = ie + I - U, ge = G + Z - ne;
|
|
11223
11223
|
re > -10 && (v.style.top = `${Math.max(F + 2, j - I - 2)}px`), ge > -10 && (v.style.left = `${Math.max(H + 2, L - Z - 2)}px`);
|
|
11224
11224
|
});
|
|
11225
11225
|
}, { keyboard: ue, row: Q, column: P } = E;
|
|
11226
11226
|
ue && Q && P ? e.scrollToRow(Q, P).then(() => {
|
|
11227
11227
|
const z = e.getCellElement(Q, P);
|
|
11228
11228
|
if (z) {
|
|
11229
|
-
const { boundingTop:
|
|
11230
|
-
j =
|
|
11229
|
+
const { boundingTop: V, boundingLeft: I } = Pc(z);
|
|
11230
|
+
j = V + F + Math.floor(z.offsetHeight / 2), L = I + H + Math.floor(z.offsetWidth / 2);
|
|
11231
11231
|
}
|
|
11232
11232
|
B();
|
|
11233
11233
|
}) : B();
|
|
@@ -11308,8 +11308,8 @@ G_.add("tableMenuModule", {
|
|
|
11308
11308
|
const I = e.getRowNode(ue.parentNode), Z = I ? I.item : null;
|
|
11309
11309
|
z = "", Z && (B.row = Z, B.rowIndex = e.getRowIndex(Z));
|
|
11310
11310
|
}
|
|
11311
|
-
const
|
|
11312
|
-
h(w, j, B), e.dispatchEvent(
|
|
11311
|
+
const V = `${z}cell-menu`;
|
|
11312
|
+
h(w, j, B), e.dispatchEvent(V, B, w);
|
|
11313
11313
|
return;
|
|
11314
11314
|
} else if (Rn(w, F, `vxe-table--${j}-wrapper`, (ue) => ue.getAttribute("xid") === t).flag) {
|
|
11315
11315
|
M.trigger === "cell" ? w.preventDefault() : h(w, j, B);
|
|
@@ -11376,9 +11376,9 @@ Z_.add("tableEditModule", {
|
|
|
11376
11376
|
function E(b, x) {
|
|
11377
11377
|
const { tableFullTreeData: C, afterFullData: M, fullDataRowIdData: F, fullAllDataRowIdData: H } = o, U = f.value, { rowField: ne, parentField: j, mapChildrenField: L } = U, B = U.children || U.childrenField, ue = x ? "push" : "unshift";
|
|
11378
11378
|
b.forEach((Q) => {
|
|
11379
|
-
const P = Q[j], z = St(e, Q),
|
|
11380
|
-
if (
|
|
11381
|
-
const { item: I } =
|
|
11379
|
+
const P = Q[j], z = St(e, Q), V = P ? i.findTree(C, (I) => P === I[ne], { children: L }) : null;
|
|
11380
|
+
if (V) {
|
|
11381
|
+
const { item: I } = V, Z = H[St(e, I)], ie = Z ? Z.level : 0;
|
|
11382
11382
|
let G = I[B], re = I[L];
|
|
11383
11383
|
i.isArray(G) || (G = I[B] = []), i.isArray(re) || (re = I[B] = []), G[ue](Q), re[ue](Q);
|
|
11384
11384
|
const ge = { row: Q, rowid: z, seq: -1, index: -1, _index: -1, $index: -1, items: G, parent: I, level: ie + 1, height: 0 };
|
|
@@ -11391,9 +11391,9 @@ Z_.add("tableEditModule", {
|
|
|
11391
11391
|
});
|
|
11392
11392
|
}
|
|
11393
11393
|
const v = (b, x, C) => {
|
|
11394
|
-
const { treeConfig: M } = t, { mergeList: F, editStore: H } = n, { tableFullTreeData: U, afterFullData: ne, tableFullData: j, fullDataRowIdData: L, fullAllDataRowIdData: B } = o, ue = f.value, { transform: Q, rowField: P, mapChildrenField: z } = ue,
|
|
11394
|
+
const { treeConfig: M } = t, { mergeList: F, editStore: H } = n, { tableFullTreeData: U, afterFullData: ne, tableFullData: j, fullDataRowIdData: L, fullAllDataRowIdData: B } = o, ue = f.value, { transform: Q, rowField: P, mapChildrenField: z } = ue, V = ue.children || ue.childrenField;
|
|
11395
11395
|
i.isArray(b) || (b = [b]);
|
|
11396
|
-
const I = kt(e.defineField(b.map((ie) => Object.assign(M && Q ? { [z]: [], [
|
|
11396
|
+
const I = kt(e.defineField(b.map((ie) => Object.assign(M && Q ? { [z]: [], [V]: [] } : {}, ie))));
|
|
11397
11397
|
if (i.eqNull(x))
|
|
11398
11398
|
M && Q ? E(I, !1) : (I.forEach((ie) => {
|
|
11399
11399
|
const G = St(e, ie), re = { row: ie, rowid: G, seq: -1, index: -1, _index: -1, $index: -1, items: ne, parent: null, level: 0, height: 0 };
|
|
@@ -11422,7 +11422,7 @@ Z_.add("tableEditModule", {
|
|
|
11422
11422
|
const we = { row: ae, rowid: Y, seq: -1, index: -1, _index: -1, $index: -1, items: re, parent: G, level: De + 1, height: 0 };
|
|
11423
11423
|
L[Y] = we, B[Y] = we;
|
|
11424
11424
|
}), G) {
|
|
11425
|
-
const ae = i.findTree(U, (_) => x[P] === _[P], { children:
|
|
11425
|
+
const ae = i.findTree(U, (_) => x[P] === _[P], { children: V });
|
|
11426
11426
|
if (ae) {
|
|
11427
11427
|
const _ = ae.items;
|
|
11428
11428
|
let Y = ae.index;
|
|
@@ -11511,7 +11511,7 @@ Z_.add("tableEditModule", {
|
|
|
11511
11511
|
* 如果为空则删除所有
|
|
11512
11512
|
*/
|
|
11513
11513
|
remove(b) {
|
|
11514
|
-
const { treeConfig: x } = t, { mergeList: C, editStore: M, selectCheckboxMaps: F } = n, { tableFullTreeData: H, afterFullData: U, tableFullData: ne } = o, j = c.value, L = f.value, { transform: B, mapChildrenField: ue } = L, Q = L.children || L.childrenField, { actived: P, removeMaps: z } = M,
|
|
11514
|
+
const { treeConfig: x } = t, { mergeList: C, editStore: M, selectCheckboxMaps: F } = n, { tableFullTreeData: H, afterFullData: U, tableFullData: ne } = o, j = c.value, L = f.value, { transform: B, mapChildrenField: ue } = L, Q = L.children || L.childrenField, { actived: P, removeMaps: z } = M, V = Object.assign({}, M.insertMaps), I = Object.assign({}, n.pendingRowMaps), { checkField: Z } = j;
|
|
11515
11515
|
let ie = [];
|
|
11516
11516
|
if (b ? i.isArray(b) || (b = [b]) : b = ne, b.forEach((G) => {
|
|
11517
11517
|
if (!e.isInsertByRow(G)) {
|
|
@@ -11548,8 +11548,8 @@ Z_.add("tableEditModule", {
|
|
|
11548
11548
|
}), U.splice(ge, 1));
|
|
11549
11549
|
}), P.row && e.findRowIndexOf(b, P.row) > -1 && d.clearEdit(), b.forEach((G) => {
|
|
11550
11550
|
const re = St(e, G);
|
|
11551
|
-
|
|
11552
|
-
}), M.insertMaps =
|
|
11551
|
+
V[re] && delete V[re], I[re] && delete I[re];
|
|
11552
|
+
}), M.insertMaps = V, n.pendingRowMaps = I, e.updateFooter(), e.cacheRowMap(), e.handleTableData(x && B), x && B || e.updateAfterDataIndex(), e.checkSelectionStatus(), n.scrollYLoad && e.updateScrollYSpace(), pe().then(() => (e.updateCellAreas(), e.recalculate())).then(() => ({ row: ie.length ? ie[ie.length - 1] : null, rows: ie }));
|
|
11553
11553
|
},
|
|
11554
11554
|
/**
|
|
11555
11555
|
* 删除复选框选中的数据
|
|
@@ -11710,22 +11710,22 @@ Z_.add("tableEditModule", {
|
|
|
11710
11710
|
const { editConfig: C, mouseConfig: M } = t, { editStore: F, tableColumn: H } = n, U = a.value, { mode: ne } = U, { actived: j, focused: L } = F, { row: B, column: ue } = b, { editRender: Q } = ue, P = b.cell || e.getCellElement(B, ue), z = U.beforeEditMethod || U.activeMethod;
|
|
11711
11711
|
if (b.cell = P, P && mn(C) && mn(Q) && !e.isPendingByRow(B)) {
|
|
11712
11712
|
if (j.row !== B || ne === "cell" && j.column !== ue) {
|
|
11713
|
-
let
|
|
11713
|
+
let V = "edit-disabled";
|
|
11714
11714
|
if (!z || z(Object.assign(Object.assign({}, b), { $table: e, $grid: e.xegrid }))) {
|
|
11715
|
-
M && (d.clearSelected(), e.clearCellAreas && (e.clearCellAreas(), e.clearCopyCellArea())), e.closeTooltip(), j.column && y(x),
|
|
11715
|
+
M && (d.clearSelected(), e.clearCellAreas && (e.clearCellAreas(), e.clearCopyCellArea())), e.closeTooltip(), j.column && y(x), V = "edit-activated", ue.renderHeight = P.offsetHeight, j.args = b, j.row = B, j.column = ue, ne === "row" ? H.forEach((Z) => g(B, Z)) : g(B, ue);
|
|
11716
11716
|
const I = U.afterEditMethod;
|
|
11717
11717
|
pe(() => {
|
|
11718
11718
|
p.handleFocus(b, x), I && I(Object.assign(Object.assign({}, b), { $table: e, $grid: e.xegrid }));
|
|
11719
11719
|
});
|
|
11720
11720
|
}
|
|
11721
|
-
e.dispatchEvent(
|
|
11721
|
+
e.dispatchEvent(V, {
|
|
11722
11722
|
row: B,
|
|
11723
11723
|
rowIndex: e.getRowIndex(B),
|
|
11724
11724
|
$rowIndex: e.getVMRowIndex(B),
|
|
11725
11725
|
column: ue,
|
|
11726
11726
|
columnIndex: e.getColumnIndex(ue),
|
|
11727
11727
|
$columnIndex: e.getVMColumnIndex(ue)
|
|
11728
|
-
}, x),
|
|
11728
|
+
}, x), V === "edit-activated" && e.dispatchEvent("edit-actived", {
|
|
11729
11729
|
row: B,
|
|
11730
11730
|
rowIndex: e.getRowIndex(B),
|
|
11731
11731
|
$rowIndex: e.getVMRowIndex(B),
|
|
@@ -11734,10 +11734,10 @@ Z_.add("tableEditModule", {
|
|
|
11734
11734
|
$columnIndex: e.getVMColumnIndex(ue)
|
|
11735
11735
|
}, x);
|
|
11736
11736
|
} else {
|
|
11737
|
-
const { column:
|
|
11738
|
-
if (M && (d.clearSelected(), e.clearCellAreas && (e.clearCellAreas(), e.clearCopyCellArea())),
|
|
11739
|
-
const { model: I } =
|
|
11740
|
-
I.update && pl(B,
|
|
11737
|
+
const { column: V } = j;
|
|
11738
|
+
if (M && (d.clearSelected(), e.clearCellAreas && (e.clearCellAreas(), e.clearCopyCellArea())), V !== ue) {
|
|
11739
|
+
const { model: I } = V;
|
|
11740
|
+
I.update && pl(B, V, I.value), e.clearValidate && e.clearValidate(B, ue);
|
|
11741
11741
|
}
|
|
11742
11742
|
ue.renderHeight = P.offsetHeight, j.args = b, j.column = ue, setTimeout(() => {
|
|
11743
11743
|
p.handleFocus(b, x);
|
|
@@ -11984,10 +11984,10 @@ function dB(e, t) {
|
|
|
11984
11984
|
const fB = ["exportData", "importByFile", "importData", "saveFile", "readFile", "print", "getPrintHtml", "openImport", "closeImport", "openExport", "closeExport", "openPrint", "closePrint"];
|
|
11985
11985
|
nB.add("tableExportModule", {
|
|
11986
11986
|
setupTable(e) {
|
|
11987
|
-
const { props: t, reactData: n, internalData: o } = e, { computeTreeOpts: r, computePrintOpts: s, computeExportOpts: a, computeImportOpts: c, computeCustomOpts: f, computeSeqOpts: u, computeRadioOpts: d, computeCheckboxOpts: p, computeColumnOpts: g } = e.getComputeMaps(), h = mt("$xeGrid", null), w = (
|
|
11987
|
+
const { props: t, reactData: n, internalData: o } = e, { computeTreeOpts: r, computePrintOpts: s, computeExportOpts: a, computeImportOpts: c, computeCustomOpts: f, computeSeqOpts: u, computeRadioOpts: d, computeCheckboxOpts: p, computeColumnOpts: g } = e.getComputeMaps(), h = mt("$xeGrid", null), w = (V) => {
|
|
11988
11988
|
const I = r.value, Z = I.children || I.childrenField;
|
|
11989
|
-
return
|
|
11990
|
-
}, S = (
|
|
11989
|
+
return V[Z] && V[Z].length;
|
|
11990
|
+
}, S = (V, I, Z, ie, G) => {
|
|
11991
11991
|
const ge = u.value.seqMethod || ie.seqMethod;
|
|
11992
11992
|
return ge ? ge({
|
|
11993
11993
|
row: I,
|
|
@@ -11996,14 +11996,14 @@ nB.add("tableExportModule", {
|
|
|
11996
11996
|
column: ie,
|
|
11997
11997
|
columnIndex: e.getColumnIndex(ie),
|
|
11998
11998
|
$columnIndex: G
|
|
11999
|
-
}) :
|
|
11999
|
+
}) : V;
|
|
12000
12000
|
};
|
|
12001
|
-
function E(
|
|
12001
|
+
function E(V, I) {
|
|
12002
12002
|
const Z = g.value, ie = I.headerExportMethod || Z.headerExportMethod;
|
|
12003
|
-
return ie ? ie({ column: I, options:
|
|
12003
|
+
return ie ? ie({ column: I, options: V, $table: e }) : (V.original ? I.field : I.getTitle()) || "";
|
|
12004
12004
|
}
|
|
12005
|
-
const v = (
|
|
12006
|
-
const { isAllExpand: ie, mode: G } =
|
|
12005
|
+
const v = (V) => i.isBoolean(V) ? V ? "TRUE" : "FALSE" : V, D = (V) => dl(V) ? "" : `${V}`, y = (V, I, Z) => {
|
|
12006
|
+
const { isAllExpand: ie, mode: G } = V, { treeConfig: re } = t, ge = d.value, De = p.value, ae = r.value, _ = g.value;
|
|
12007
12007
|
if (Ks || (Ks = document.createElement("div")), re) {
|
|
12008
12008
|
const Y = ae.children || ae.childrenField, oe = [], we = /* @__PURE__ */ new Map();
|
|
12009
12009
|
return i.eachTree(Z, (ve, de, Ce, je, Ye, lt) => {
|
|
@@ -12024,7 +12024,7 @@ nB.add("tableExportModule", {
|
|
|
12024
12024
|
Be && (xe = Be.tableExportMethod || Be.exportMethod);
|
|
12025
12025
|
}
|
|
12026
12026
|
if (xe || (xe = _.exportMethod), xe)
|
|
12027
|
-
pt = xe({ $table: e, row: He, column: dt, options:
|
|
12027
|
+
pt = xe({ $table: e, row: He, column: dt, options: V });
|
|
12028
12028
|
else
|
|
12029
12029
|
switch (dt.type) {
|
|
12030
12030
|
case "seq": {
|
|
@@ -12039,7 +12039,7 @@ nB.add("tableExportModule", {
|
|
|
12039
12039
|
pt = v(e.isCheckedByRadioRow(He)), bt._radioLabel = ge.labelField ? i.get(He, ge.labelField) : "", bt._radioDisabled = ge.checkMethod && !ge.checkMethod({ row: He });
|
|
12040
12040
|
break;
|
|
12041
12041
|
default:
|
|
12042
|
-
if (
|
|
12042
|
+
if (V.original)
|
|
12043
12043
|
pt = Mo(He, dt);
|
|
12044
12044
|
else if (pt = e.getCellLabel(He, dt), dt.type === "html")
|
|
12045
12045
|
Ks.innerHTML = pt, pt = Ks.innerText.trim();
|
|
@@ -12066,7 +12066,7 @@ nB.add("tableExportModule", {
|
|
|
12066
12066
|
lt && (Ye = lt.tableExportMethod || lt.exportMethod);
|
|
12067
12067
|
}
|
|
12068
12068
|
if (Ye)
|
|
12069
|
-
Ce = Ye({ $table: e, row: Y, column: ve, options:
|
|
12069
|
+
Ce = Ye({ $table: e, row: Y, column: ve, options: V });
|
|
12070
12070
|
else
|
|
12071
12071
|
switch (ve.type) {
|
|
12072
12072
|
case "seq": {
|
|
@@ -12081,7 +12081,7 @@ nB.add("tableExportModule", {
|
|
|
12081
12081
|
Ce = v(e.isCheckedByRadioRow(Y)), we._radioLabel = ge.labelField ? i.get(Y, ge.labelField) : "", we._radioDisabled = ge.checkMethod && !ge.checkMethod({ row: Y });
|
|
12082
12082
|
break;
|
|
12083
12083
|
default:
|
|
12084
|
-
if (
|
|
12084
|
+
if (V.original)
|
|
12085
12085
|
Ce = Mo(Y, ve);
|
|
12086
12086
|
else if (Ce = e.getCellLabel(Y, ve), ve.type === "html")
|
|
12087
12087
|
Ks.innerHTML = Ce, Ce = Ks.innerText.trim();
|
|
@@ -12093,11 +12093,11 @@ nB.add("tableExportModule", {
|
|
|
12093
12093
|
we[ve.id] = D(Ce);
|
|
12094
12094
|
}), we;
|
|
12095
12095
|
});
|
|
12096
|
-
}, b = (
|
|
12097
|
-
const { columns: I, dataFilterMethod: Z } =
|
|
12098
|
-
let ie =
|
|
12099
|
-
return Z && (ie = ie.filter((G, re) => Z({ row: G, $rowIndex: re }))), y(
|
|
12100
|
-
}, x = (
|
|
12096
|
+
}, b = (V) => {
|
|
12097
|
+
const { columns: I, dataFilterMethod: Z } = V;
|
|
12098
|
+
let ie = V.data;
|
|
12099
|
+
return Z && (ie = ie.filter((G, re) => Z({ row: G, $rowIndex: re }))), y(V, I, ie);
|
|
12100
|
+
}, x = (V, I, Z) => {
|
|
12101
12101
|
const ie = g.value, G = Z.editRender || Z.cellRender;
|
|
12102
12102
|
let re = Z.footerExportMethod;
|
|
12103
12103
|
if (!re && G && G.name) {
|
|
@@ -12106,36 +12106,36 @@ nB.add("tableExportModule", {
|
|
|
12106
12106
|
}
|
|
12107
12107
|
re || (re = ie.footerExportMethod);
|
|
12108
12108
|
const ge = e.getVTColumnIndex(Z);
|
|
12109
|
-
return re ? re({ $table: e, items: I, itemIndex: ge, row: I, _columnIndex: ge, column: Z, options:
|
|
12110
|
-
}, C = (
|
|
12109
|
+
return re ? re({ $table: e, items: I, itemIndex: ge, row: I, _columnIndex: ge, column: Z, options: V }) : i.isArray(I) ? i.toValueString(I[ge]) : i.get(I, Z.field);
|
|
12110
|
+
}, C = (V, I, Z) => {
|
|
12111
12111
|
let ie = oB;
|
|
12112
|
-
if (
|
|
12112
|
+
if (V.isHeader && (ie += I.map((G) => Xs(E(V, G))).join(",") + Cs), Z.forEach((G) => {
|
|
12113
12113
|
ie += I.map((re) => Xs(sB(re, G[re.id]))).join(",") + Cs;
|
|
12114
|
-
}),
|
|
12114
|
+
}), V.isFooter) {
|
|
12115
12115
|
const { footerTableData: G } = n;
|
|
12116
|
-
xc(
|
|
12117
|
-
ie += I.map((De) => Xs(x(
|
|
12116
|
+
xc(V, G).forEach((ge) => {
|
|
12117
|
+
ie += I.map((De) => Xs(x(V, ge, De))).join(",") + Cs;
|
|
12118
12118
|
});
|
|
12119
12119
|
}
|
|
12120
12120
|
return ie;
|
|
12121
|
-
}, M = (
|
|
12121
|
+
}, M = (V, I, Z) => {
|
|
12122
12122
|
let ie = "";
|
|
12123
|
-
if (
|
|
12123
|
+
if (V.isHeader && (ie += I.map((G) => Xs(E(V, G))).join(" ") + Cs), Z.forEach((G) => {
|
|
12124
12124
|
ie += I.map((re) => Xs(G[re.id])).join(" ") + Cs;
|
|
12125
|
-
}),
|
|
12125
|
+
}), V.isFooter) {
|
|
12126
12126
|
const { footerTableData: G } = n;
|
|
12127
|
-
xc(
|
|
12128
|
-
ie += I.map((De) => Xs(x(
|
|
12127
|
+
xc(V, G).forEach((ge) => {
|
|
12128
|
+
ie += I.map((De) => Xs(x(V, ge, De))).join(" ") + Cs;
|
|
12129
12129
|
});
|
|
12130
12130
|
}
|
|
12131
12131
|
return ie;
|
|
12132
|
-
}, F = (
|
|
12133
|
-
const ie =
|
|
12132
|
+
}, F = (V, I, Z) => {
|
|
12133
|
+
const ie = V[I], G = i.isUndefined(ie) || i.isNull(ie) ? Z : ie;
|
|
12134
12134
|
let ae = G === "title" || (G === !0 || G === "tooltip") || G === "ellipsis";
|
|
12135
12135
|
const { scrollXLoad: _, scrollYLoad: Y } = n;
|
|
12136
12136
|
return (_ || Y) && !ae && (ae = !0), ae;
|
|
12137
|
-
}, H = (
|
|
12138
|
-
const { id: ie, border: G, treeConfig: re, headerAlign: ge, align: De, footerAlign: ae, showOverflow: _, showHeaderOverflow: Y } = t, { isAllSelected: oe, isIndeterminate: we, mergeList: ve } = n, de = r.value, { print: Ce, isHeader: je, isFooter: Ye, isColgroup: lt, isMerge: He, colgroups: Ge, original: at } =
|
|
12137
|
+
}, H = (V, I, Z) => {
|
|
12138
|
+
const { id: ie, border: G, treeConfig: re, headerAlign: ge, align: De, footerAlign: ae, showOverflow: _, showHeaderOverflow: Y } = t, { isAllSelected: oe, isIndeterminate: we, mergeList: ve } = n, de = r.value, { print: Ce, isHeader: je, isFooter: Ye, isColgroup: lt, isMerge: He, colgroups: Ge, original: at } = V, bt = "check-all", gt = [
|
|
12139
12139
|
`<table class="${[
|
|
12140
12140
|
"vxe-table",
|
|
12141
12141
|
`border--${lB(G)}`,
|
|
@@ -12146,7 +12146,7 @@ nB.add("tableExportModule", {
|
|
|
12146
12146
|
];
|
|
12147
12147
|
if (je && (gt.push("<thead>"), lt && !at ? Ge.forEach((ke) => {
|
|
12148
12148
|
gt.push(`<tr>${ke.map((xe) => {
|
|
12149
|
-
const Be = xe.headerAlign || xe.align || ge || De, Oe = F(xe, "showHeaderOverflow", Y) ? ["col--ellipsis"] : [], Me = E(
|
|
12149
|
+
const Be = xe.headerAlign || xe.align || ge || De, Oe = F(xe, "showHeaderOverflow", Y) ? ["col--ellipsis"] : [], Me = E(V, xe);
|
|
12150
12150
|
let $ = 0, te = 0;
|
|
12151
12151
|
i.eachTree([xe], (K) => {
|
|
12152
12152
|
(!K.childNodes || !xe.childNodes.length) && te++, $ += K.renderWidth;
|
|
@@ -12155,7 +12155,7 @@ nB.add("tableExportModule", {
|
|
|
12155
12155
|
return Be && Oe.push(`col--${Be}`), xe.type === "checkbox" ? `<th class="${Oe.join(" ")}" colspan="${xe._colSpan}" rowspan="${xe._rowSpan}"><div ${Ce ? "" : `style="width: ${Se}px"`}><input type="checkbox" class="${bt}" ${oe ? "checked" : ""}><span>${Me}</span></div></th>` : `<th class="${Oe.join(" ")}" colspan="${xe._colSpan}" rowspan="${xe._rowSpan}" title="${Me}"><div ${Ce ? "" : `style="width: ${Se}px"`}><span>${Do(Me, !0)}</span></div></th>`;
|
|
12156
12156
|
}).join("")}</tr>`);
|
|
12157
12157
|
}) : gt.push(`<tr>${I.map((ke) => {
|
|
12158
|
-
const xe = ke.headerAlign || ke.align || ge || De, Be = F(ke, "showHeaderOverflow", Y) ? ["col--ellipsis"] : [], Oe = E(
|
|
12158
|
+
const xe = ke.headerAlign || ke.align || ge || De, Be = F(ke, "showHeaderOverflow", Y) ? ["col--ellipsis"] : [], Oe = E(V, ke);
|
|
12159
12159
|
return xe && Be.push(`col--${xe}`), ke.type === "checkbox" ? `<th class="${Be.join(" ")}"><div ${Ce ? "" : `style="width: ${ke.renderWidth}px"`}><input type="checkbox" class="${bt}" ${oe ? "checked" : ""}><span>${Oe}</span></div></th>` : `<th class="${Be.join(" ")}" title="${Oe}"><div ${Ce ? "" : `style="width: ${ke.renderWidth}px"`}><span>${Do(Oe, !0)}</span></div></th>`;
|
|
12160
12160
|
}).join("")}</tr>`), gt.push("</thead>")), Z.length && (gt.push("<tbody>"), re ? Z.forEach((ke) => {
|
|
12161
12161
|
gt.push("<tr>" + I.map((xe) => {
|
|
@@ -12182,17 +12182,17 @@ nB.add("tableExportModule", {
|
|
|
12182
12182
|
return Be && Oe.push(`col--${Be}`), xe.type === "radio" ? `<td class="${Oe.join(" ")}" rowspan="${$}" colspan="${te}"><div ${Ce ? "" : `style="width: ${xe.renderWidth}px"`}><input type="radio" name="radio_${ie}" ${ke._radioDisabled ? "disabled " : ""}${Ys(Me) ? "checked" : ""}><span>${ke._radioLabel}</span></div></td>` : xe.type === "checkbox" ? `<td class="${Oe.join(" ")}" rowspan="${$}" colspan="${te}"><div ${Ce ? "" : `style="width: ${xe.renderWidth}px"`}><input type="checkbox" ${ke._checkboxDisabled ? "disabled " : ""}${Ys(Me) ? "checked" : ""}><span>${ke._checkboxLabel}</span></div></td>` : `<td class="${Oe.join(" ")}" rowspan="${$}" colspan="${te}" title="${Me}"><div ${Ce ? "" : `style="width: ${xe.renderWidth}px"`}>${Do(Me, !0)}</div></td>`;
|
|
12183
12183
|
}).join("") + "</tr>");
|
|
12184
12184
|
}), gt.push("</tbody>")), Ye) {
|
|
12185
|
-
const { footerTableData: ke } = n, xe = xc(
|
|
12185
|
+
const { footerTableData: ke } = n, xe = xc(V, ke);
|
|
12186
12186
|
xe.length && (gt.push("<tfoot>"), xe.forEach((Be) => {
|
|
12187
12187
|
gt.push(`<tr>${I.map((Oe) => {
|
|
12188
|
-
const Me = Oe.footerAlign || Oe.align || ae || De, $ = F(Oe, "showOverflow", _) ? ["col--ellipsis"] : [], te = x(
|
|
12188
|
+
const Me = Oe.footerAlign || Oe.align || ae || De, $ = F(Oe, "showOverflow", _) ? ["col--ellipsis"] : [], te = x(V, Be, Oe);
|
|
12189
12189
|
return Me && $.push(`col--${Me}`), `<td class="${$.join(" ")}" title="${te}"><div ${Ce ? "" : `style="width: ${Oe.renderWidth}px"`}>${Do(te, !0)}</div></td>`;
|
|
12190
12190
|
}).join("")}</tr>`);
|
|
12191
12191
|
}), gt.push("</tfoot>"));
|
|
12192
12192
|
}
|
|
12193
12193
|
const pt = !oe && we ? `<script>(function(){var a=document.querySelector(".${bt}");if(a){a.indeterminate=true}})()<\/script>` : "";
|
|
12194
|
-
return gt.push("</table>", pt), Ce ? gt.join("") : tB(
|
|
12195
|
-
}, U = (
|
|
12194
|
+
return gt.push("</table>", pt), Ce ? gt.join("") : tB(V, gt.join(""));
|
|
12195
|
+
}, U = (V, I, Z) => {
|
|
12196
12196
|
let ie = [
|
|
12197
12197
|
'<?xml version="1.0"?>',
|
|
12198
12198
|
'<?mso-application progid="Excel.Sheet"?>',
|
|
@@ -12208,71 +12208,71 @@ nB.add("tableExportModule", {
|
|
|
12208
12208
|
"<ProtectStructure>False</ProtectStructure>",
|
|
12209
12209
|
"<ProtectWindows>False</ProtectWindows>",
|
|
12210
12210
|
"</ExcelWorkbook>",
|
|
12211
|
-
`<Worksheet ss:Name="${
|
|
12211
|
+
`<Worksheet ss:Name="${V.sheetName}">`,
|
|
12212
12212
|
"<Table>",
|
|
12213
12213
|
I.map((G) => `<Column ss:Width="${G.renderWidth}"/>`).join("")
|
|
12214
12214
|
].join("");
|
|
12215
|
-
if (
|
|
12215
|
+
if (V.isHeader && (ie += `<Row>${I.map((G) => `<Cell><Data ss:Type="String">${E(V, G)}</Data></Cell>`).join("")}</Row>`), Z.forEach((G) => {
|
|
12216
12216
|
ie += "<Row>" + I.map((re) => `<Cell><Data ss:Type="String">${G[re.id]}</Data></Cell>`).join("") + "</Row>";
|
|
12217
|
-
}),
|
|
12217
|
+
}), V.isFooter) {
|
|
12218
12218
|
const { footerTableData: G } = n;
|
|
12219
|
-
xc(
|
|
12220
|
-
ie += `<Row>${I.map((De) => `<Cell><Data ss:Type="String">${x(
|
|
12219
|
+
xc(V, G).forEach((ge) => {
|
|
12220
|
+
ie += `<Row>${I.map((De) => `<Cell><Data ss:Type="String">${x(V, ge, De)}</Data></Cell>`).join("")}</Row>`;
|
|
12221
12221
|
});
|
|
12222
12222
|
}
|
|
12223
12223
|
return `${ie}</Table></Worksheet></Workbook>`;
|
|
12224
|
-
}, ne = (
|
|
12224
|
+
}, ne = (V, I, Z) => {
|
|
12225
12225
|
if (I.length)
|
|
12226
|
-
switch (
|
|
12226
|
+
switch (V.type) {
|
|
12227
12227
|
case "csv":
|
|
12228
|
-
return C(
|
|
12228
|
+
return C(V, I, Z);
|
|
12229
12229
|
case "txt":
|
|
12230
|
-
return M(
|
|
12230
|
+
return M(V, I, Z);
|
|
12231
12231
|
case "html":
|
|
12232
|
-
return H(
|
|
12232
|
+
return H(V, I, Z);
|
|
12233
12233
|
case "xml":
|
|
12234
|
-
return U(
|
|
12234
|
+
return U(V, I, Z);
|
|
12235
12235
|
}
|
|
12236
12236
|
return "";
|
|
12237
|
-
}, j = (
|
|
12238
|
-
const { filename: Z, type: ie, download: G } =
|
|
12237
|
+
}, j = (V, I) => {
|
|
12238
|
+
const { filename: Z, type: ie, download: G } = V;
|
|
12239
12239
|
if (!G) {
|
|
12240
|
-
const re = eB(I,
|
|
12240
|
+
const re = eB(I, V);
|
|
12241
12241
|
return Promise.resolve({ type: ie, content: I, blob: re });
|
|
12242
12242
|
}
|
|
12243
12243
|
ye.saveFile && ye.saveFile({ filename: Z, type: ie, content: I }).then(() => {
|
|
12244
|
-
|
|
12244
|
+
V.message !== !1 && ye.modal && ye.modal.message({ content: al("vxe.table.expSuccess"), status: "success" });
|
|
12245
12245
|
});
|
|
12246
|
-
}, L = (
|
|
12247
|
-
const { remote: I, columns: Z, colgroups: ie, exportMethod: G, afterExportMethod: re } =
|
|
12246
|
+
}, L = (V) => {
|
|
12247
|
+
const { remote: I, columns: Z, colgroups: ie, exportMethod: G, afterExportMethod: re } = V;
|
|
12248
12248
|
return new Promise((ge) => {
|
|
12249
12249
|
if (I) {
|
|
12250
|
-
const De = { options:
|
|
12250
|
+
const De = { options: V, $table: e, $grid: h };
|
|
12251
12251
|
ge(G ? G(De) : De);
|
|
12252
12252
|
} else {
|
|
12253
|
-
const De = b(
|
|
12254
|
-
ge(e.preventEvent(null, "event.export", { options:
|
|
12253
|
+
const De = b(V);
|
|
12254
|
+
ge(e.preventEvent(null, "event.export", { options: V, columns: Z, colgroups: ie, datas: De }, () => j(V, ne(V, Z, De))));
|
|
12255
12255
|
}
|
|
12256
|
-
}).then((ge) => (hh(Z),
|
|
12257
|
-
hh(Z),
|
|
12256
|
+
}).then((ge) => (hh(Z), V.print || re && re({ status: !0, options: V, $table: e, $grid: h }), Object.assign({ status: !0 }, ge))).catch(() => {
|
|
12257
|
+
hh(Z), V.print || re && re({ status: !1, options: V, $table: e, $grid: h });
|
|
12258
12258
|
const ge = { status: !1 };
|
|
12259
12259
|
return Promise.reject(ge);
|
|
12260
12260
|
});
|
|
12261
|
-
}, B = (
|
|
12261
|
+
}, B = (V, I) => {
|
|
12262
12262
|
const { tableFullColumn: Z, _importResolve: ie, _importReject: G } = o;
|
|
12263
12263
|
let re = { fields: [], rows: [] };
|
|
12264
12264
|
switch (I.type) {
|
|
12265
12265
|
case "csv":
|
|
12266
|
-
re = aB(Z,
|
|
12266
|
+
re = aB(Z, V);
|
|
12267
12267
|
break;
|
|
12268
12268
|
case "txt":
|
|
12269
|
-
re = iB(Z,
|
|
12269
|
+
re = iB(Z, V);
|
|
12270
12270
|
break;
|
|
12271
12271
|
case "html":
|
|
12272
|
-
re = cB(Z,
|
|
12272
|
+
re = cB(Z, V);
|
|
12273
12273
|
break;
|
|
12274
12274
|
case "xml":
|
|
12275
|
-
re = uB(Z,
|
|
12275
|
+
re = uB(Z, V);
|
|
12276
12276
|
break;
|
|
12277
12277
|
}
|
|
12278
12278
|
const { fields: ge, rows: De } = re;
|
|
@@ -12282,8 +12282,8 @@ nB.add("tableExportModule", {
|
|
|
12282
12282
|
ie && ie({ status: !0 });
|
|
12283
12283
|
});
|
|
12284
12284
|
}) : I.message !== !1 && (ye.modal && ye.modal.message({ content: al("vxe.error.impFields"), status: "error" }), G && G({ status: !1 }));
|
|
12285
|
-
}, ue = (
|
|
12286
|
-
const { importMethod: Z, afterImportMethod: ie } = I, { type: G, filename: re } = by(
|
|
12285
|
+
}, ue = (V, I) => {
|
|
12286
|
+
const { importMethod: Z, afterImportMethod: ie } = I, { type: G, filename: re } = by(V), ge = c.value;
|
|
12287
12287
|
if (!Z && !i.includes(i.keys(ge._typeMaps), G)) {
|
|
12288
12288
|
I.message !== !1 && ye.modal && ye.modal.message({ content: al("vxe.error.notType", [G]), status: "error" });
|
|
12289
12289
|
const ae = { status: !1 };
|
|
@@ -12298,20 +12298,20 @@ nB.add("tableExportModule", {
|
|
|
12298
12298
|
if (o._importResolve = Y, o._importReject = oe, window.FileReader) {
|
|
12299
12299
|
const we = Object.assign({ mode: "insertTop" }, I, { type: G, filename: re });
|
|
12300
12300
|
if (we.remote)
|
|
12301
|
-
Z ? Promise.resolve(Z({ file:
|
|
12301
|
+
Z ? Promise.resolve(Z({ file: V, options: we, $table: e })).then(() => {
|
|
12302
12302
|
Y({ status: !0 });
|
|
12303
12303
|
}).catch(() => {
|
|
12304
12304
|
Y({ status: !0 });
|
|
12305
12305
|
}) : Y({ status: !0 });
|
|
12306
12306
|
else {
|
|
12307
12307
|
const { tableFullColumn: ve } = o;
|
|
12308
|
-
e.preventEvent(null, "event.import", { file:
|
|
12308
|
+
e.preventEvent(null, "event.import", { file: V, options: we, columns: ve }, () => {
|
|
12309
12309
|
const de = new FileReader();
|
|
12310
12310
|
de.onerror = () => {
|
|
12311
12311
|
Gt("vxe.error.notType", [G]), oe({ status: !1 });
|
|
12312
12312
|
}, de.onload = (Ce) => {
|
|
12313
12313
|
B(Ce.target.result, we);
|
|
12314
|
-
}, de.readAsText(
|
|
12314
|
+
}, de.readAsText(V, we.encoding || "UTF-8");
|
|
12315
12315
|
});
|
|
12316
12316
|
}
|
|
12317
12317
|
} else
|
|
@@ -12319,14 +12319,14 @@ nB.add("tableExportModule", {
|
|
|
12319
12319
|
}).then(() => {
|
|
12320
12320
|
ie && ie({ status: !0, options: I, $table: e });
|
|
12321
12321
|
}).catch((ae) => (ie && ie({ status: !1, options: I, $table: e }), Promise.reject(ae)));
|
|
12322
|
-
}, Q = (
|
|
12322
|
+
}, Q = (V, I) => {
|
|
12323
12323
|
const { treeConfig: Z, showHeader: ie, showFooter: G } = t, { initStore: re, mergeList: ge, isGroup: De, footerTableData: ae, exportStore: _, exportParams: Y } = n, { collectColumn: oe } = o, we = a.value, ve = Z, de = f.value, Ce = e.getCheckboxRecords(), je = h ? h.getComputeMaps().computeProxyOpts.value : {}, Ye = !!ae.length, lt = !ve && ge.length, He = Object.assign({
|
|
12324
12324
|
message: !0,
|
|
12325
12325
|
isHeader: ie,
|
|
12326
12326
|
isFooter: G,
|
|
12327
12327
|
current: "current",
|
|
12328
12328
|
modes: ["current", "selected"].concat(je.ajax && je.ajax.queryAll ? ["all"] : [])
|
|
12329
|
-
},
|
|
12329
|
+
}, V), Ge = He.types || i.keys(we._typeMaps), at = He.modes || [], bt = de.checkMethod, dt = oe.slice(0), { columns: gt } = He, pt = Ge.map((xe) => ({
|
|
12330
12330
|
value: xe,
|
|
12331
12331
|
label: al(`vxe.export.types.${xe}`)
|
|
12332
12332
|
})), ke = at.map((xe) => xe && xe.value ? {
|
|
@@ -12375,7 +12375,7 @@ nB.add("tableExportModule", {
|
|
|
12375
12375
|
* 如果是启用了虚拟滚动,则只能导出数据源,可以配合 dataFilterMethod 函数自行转换数据
|
|
12376
12376
|
* @param {Object} options 参数
|
|
12377
12377
|
*/
|
|
12378
|
-
exportData(
|
|
12378
|
+
exportData(V) {
|
|
12379
12379
|
const { treeConfig: I } = t, { isGroup: Z, tableGroupColumn: ie } = n, { tableFullColumn: G, afterFullData: re } = o, ge = a.value, De = r.value, ae = Object.assign({
|
|
12380
12380
|
// filename: '',
|
|
12381
12381
|
// sheetName: '',
|
|
@@ -12399,7 +12399,7 @@ nB.add("tableExportModule", {
|
|
|
12399
12399
|
// afterExportMethod: null
|
|
12400
12400
|
}, ge, {
|
|
12401
12401
|
print: !1
|
|
12402
|
-
},
|
|
12402
|
+
}, V), { type: _, mode: Y, columns: oe, original: we, beforeExportMethod: ve, includeFields: de, excludeFields: Ce } = ae;
|
|
12403
12403
|
let je = [];
|
|
12404
12404
|
const Ye = oe && oe.length ? oe : null;
|
|
12405
12405
|
let lt = ae.columnFilterMethod;
|
|
@@ -12458,32 +12458,32 @@ nB.add("tableExportModule", {
|
|
|
12458
12458
|
Y === "current" && (ae.data = re);
|
|
12459
12459
|
return L(ae);
|
|
12460
12460
|
},
|
|
12461
|
-
importByFile(
|
|
12461
|
+
importByFile(V, I) {
|
|
12462
12462
|
const Z = Object.assign({}, I), { beforeImportMethod: ie } = Z;
|
|
12463
|
-
return ie && ie({ options: Z, $table: e }), ue(
|
|
12463
|
+
return ie && ie({ options: Z, $table: e }), ue(V, Z);
|
|
12464
12464
|
},
|
|
12465
|
-
importData(
|
|
12465
|
+
importData(V) {
|
|
12466
12466
|
const I = c.value, Z = Object.assign({
|
|
12467
12467
|
types: i.keys(I._typeMaps)
|
|
12468
12468
|
// beforeImportMethod: null,
|
|
12469
12469
|
// afterImportMethod: null
|
|
12470
|
-
}, I,
|
|
12470
|
+
}, I, V), { beforeImportMethod: ie, afterImportMethod: G } = Z;
|
|
12471
12471
|
return ie && ie({ options: Z, $table: e }), ye.readFile(Z).catch((re) => (G && G({ status: !1, options: Z, $table: e }), Promise.reject(re))).then((re) => {
|
|
12472
12472
|
const { file: ge } = re;
|
|
12473
12473
|
return ue(ge, Z);
|
|
12474
12474
|
});
|
|
12475
12475
|
},
|
|
12476
|
-
saveFile(
|
|
12477
|
-
return ye.saveFile(
|
|
12476
|
+
saveFile(V) {
|
|
12477
|
+
return ye.saveFile(V);
|
|
12478
12478
|
},
|
|
12479
|
-
readFile(
|
|
12480
|
-
return ye.readFile(
|
|
12479
|
+
readFile(V) {
|
|
12480
|
+
return ye.readFile(V);
|
|
12481
12481
|
},
|
|
12482
|
-
print(
|
|
12482
|
+
print(V) {
|
|
12483
12483
|
const I = s.value, Z = Object.assign({
|
|
12484
12484
|
original: !1
|
|
12485
12485
|
// beforePrintMethod
|
|
12486
|
-
}, I,
|
|
12486
|
+
}, I, V, {
|
|
12487
12487
|
type: "html",
|
|
12488
12488
|
download: !1,
|
|
12489
12489
|
remote: !1,
|
|
@@ -12515,11 +12515,11 @@ nB.add("tableExportModule", {
|
|
|
12515
12515
|
}))) : ge({ status: !1 });
|
|
12516
12516
|
});
|
|
12517
12517
|
},
|
|
12518
|
-
getPrintHtml(
|
|
12518
|
+
getPrintHtml(V) {
|
|
12519
12519
|
const I = s.value, Z = Object.assign({
|
|
12520
12520
|
original: !1
|
|
12521
12521
|
// beforePrintMethod
|
|
12522
|
-
}, I,
|
|
12522
|
+
}, I, V, {
|
|
12523
12523
|
type: "html",
|
|
12524
12524
|
download: !1,
|
|
12525
12525
|
remote: !1,
|
|
@@ -12532,13 +12532,13 @@ nB.add("tableExportModule", {
|
|
|
12532
12532
|
closeImport() {
|
|
12533
12533
|
return ye.modal ? ye.modal.close("VXE_IMPORT_MODAL") : Promise.resolve();
|
|
12534
12534
|
},
|
|
12535
|
-
openImport(
|
|
12535
|
+
openImport(V) {
|
|
12536
12536
|
const { treeConfig: I, importConfig: Z } = t, { initStore: ie, importStore: G, importParams: re } = n, ge = c.value, De = Object.assign({
|
|
12537
12537
|
mode: "insertTop",
|
|
12538
12538
|
message: !0,
|
|
12539
12539
|
types: i.keys(ge._typeMaps),
|
|
12540
12540
|
modes: ["insertTop", "covering"]
|
|
12541
|
-
}, ge,
|
|
12541
|
+
}, ge, V), ae = De.types || [], _ = De.modes || [];
|
|
12542
12542
|
if (!!I) {
|
|
12543
12543
|
De.message && ye.modal && ye.modal.message({ content: al("vxe.error.treeNotImp"), status: "error" });
|
|
12544
12544
|
return;
|
|
@@ -12564,18 +12564,18 @@ nB.add("tableExportModule", {
|
|
|
12564
12564
|
}), Object.assign(re, De), we.some((ve) => ve.value === re.mode) || (re.mode = we[0].value), ie.import = !0;
|
|
12565
12565
|
},
|
|
12566
12566
|
closeExport: P,
|
|
12567
|
-
openExport(
|
|
12567
|
+
openExport(V) {
|
|
12568
12568
|
const I = a.value, Z = Object.assign({
|
|
12569
12569
|
message: !0,
|
|
12570
12570
|
types: i.keys(I._typeMaps)
|
|
12571
|
-
}, I,
|
|
12571
|
+
}, I, V);
|
|
12572
12572
|
process.env.NODE_ENV === "development" && (t.exportConfig || Gt("vxe.error.reqProp", ["export-config"])), Q(Z);
|
|
12573
12573
|
},
|
|
12574
12574
|
closePrint: P,
|
|
12575
|
-
openPrint(
|
|
12575
|
+
openPrint(V) {
|
|
12576
12576
|
const I = s.value, Z = Object.assign({
|
|
12577
12577
|
message: !0
|
|
12578
|
-
}, I,
|
|
12578
|
+
}, I, V);
|
|
12579
12579
|
process.env.NODE_ENV === "development" && (t.printConfig || Gt("vxe.error.reqProp", ["print-config"])), Q(Z, !0);
|
|
12580
12580
|
}
|
|
12581
12581
|
};
|
|
@@ -12628,7 +12628,7 @@ pB.add("tableKeyboardModule", {
|
|
|
12628
12628
|
return;
|
|
12629
12629
|
const C = x.querySelector(".vxe-table--checkbox-range"), M = document.onmousemove, F = document.onmouseup, H = E.parentElement, U = e.getCheckboxRecords();
|
|
12630
12630
|
let ne = [];
|
|
12631
|
-
const j = 1, L = mB(h.target, x), B = L.offsetTop + h.offsetY, ue = L.offsetLeft + h.offsetX, Q = x.scrollTop, P = H.offsetHeight, z = H.getBoundingClientRect(),
|
|
12631
|
+
const j = 1, L = mB(h.target, x), B = L.offsetTop + h.offsetY, ue = L.offsetLeft + h.offsetX, Q = x.scrollTop, P = H.offsetHeight, z = H.getBoundingClientRect(), V = b - z.y;
|
|
12632
12632
|
let I = null, Z = !1, ie = 1;
|
|
12633
12633
|
const G = (ae, _) => {
|
|
12634
12634
|
e.dispatchEvent(`checkbox-range-${ae}`, { records: e.getCheckboxRecords(), reserves: e.getCheckboxReserveRecords() }, _);
|
|
@@ -12636,7 +12636,7 @@ pB.add("tableKeyboardModule", {
|
|
|
12636
12636
|
const { clientX: _, clientY: Y } = ae, oe = _ - y, we = Y - b + (x.scrollTop - Q);
|
|
12637
12637
|
let ve = Math.abs(we), de = Math.abs(oe), Ce = B, je = ue;
|
|
12638
12638
|
we < j ? (Ce += we, Ce < j && (Ce = j, ve = B)) : ve = Math.min(ve, x.scrollHeight - B - j), oe < j ? (je += oe, de > ue && (je = j, de = ue)) : de = Math.min(de, x.clientWidth - ue - j), C.style.height = `${ve}px`, C.style.width = `${de}px`, C.style.left = `${je}px`, C.style.top = `${Ce}px`, C.style.display = "block";
|
|
12639
|
-
const Ye = u(ae, w, H, z,
|
|
12639
|
+
const Ye = u(ae, w, H, z, V, we < j ? -ve : ve);
|
|
12640
12640
|
ve > 10 && Ye.length !== ne.length && (ne = Ye, ae.ctrlKey ? Ye.forEach((lt) => {
|
|
12641
12641
|
e.handleBatchSelectRows([lt], U.indexOf(lt) === -1);
|
|
12642
12642
|
}) : (e.setAllCheckboxRow(!1), e.handleCheckedCheckboxRow(Ye, !0, !1)), G("change", ae));
|
|
@@ -12766,8 +12766,8 @@ vB.add("tableValidatorModule", {
|
|
|
12766
12766
|
if (D || !d) {
|
|
12767
12767
|
const P = [];
|
|
12768
12768
|
B.forEach((z) => {
|
|
12769
|
-
const
|
|
12770
|
-
(D || !d) && i.has(b,
|
|
12769
|
+
const V = i.isString(z) ? z : z.field;
|
|
12770
|
+
(D || !d) && i.has(b, V) && P.push(u.validCellRules("all", Q, z).catch(({ rule: I, rules: Z }) => {
|
|
12771
12771
|
const ie = {
|
|
12772
12772
|
rule: I,
|
|
12773
12773
|
rules: Z,
|
|
@@ -12775,15 +12775,15 @@ vB.add("tableValidatorModule", {
|
|
|
12775
12775
|
row: Q,
|
|
12776
12776
|
columnIndex: e.getColumnIndex(z),
|
|
12777
12777
|
column: z,
|
|
12778
|
-
field:
|
|
12778
|
+
field: V,
|
|
12779
12779
|
$table: e
|
|
12780
12780
|
};
|
|
12781
|
-
if (y[
|
|
12781
|
+
if (y[V] || (y[V] = []), L[`${St(e, Q)}:${z.id}`] = {
|
|
12782
12782
|
column: z,
|
|
12783
12783
|
row: Q,
|
|
12784
12784
|
rule: I,
|
|
12785
12785
|
content: I.content
|
|
12786
|
-
}, y[
|
|
12786
|
+
}, y[V].push(ie), !D)
|
|
12787
12787
|
return d = !0, Promise.reject(ie);
|
|
12788
12788
|
}));
|
|
12789
12789
|
}), j.push(Promise.all(P));
|
|
@@ -12797,15 +12797,15 @@ vB.add("tableValidatorModule", {
|
|
|
12797
12797
|
v && v();
|
|
12798
12798
|
});
|
|
12799
12799
|
}).catch((Q) => new Promise((P, z) => {
|
|
12800
|
-
const
|
|
12800
|
+
const V = () => {
|
|
12801
12801
|
pe(() => {
|
|
12802
12802
|
v ? (v(y), P()) : gB().validToReject === "obsolete" ? z(y) : P(y);
|
|
12803
12803
|
});
|
|
12804
12804
|
}, I = () => {
|
|
12805
|
-
Q.cell = e.getCellElement(Q.row, Q.column), f_(Q.cell), p(Q).then(
|
|
12805
|
+
Q.cell = e.getCellElement(Q.row, Q.column), f_(Q.cell), p(Q).then(V);
|
|
12806
12806
|
};
|
|
12807
12807
|
if (U.autoPos === !1)
|
|
12808
|
-
|
|
12808
|
+
V();
|
|
12809
12809
|
else {
|
|
12810
12810
|
const Z = Q.row, ie = Q.column, G = C.indexOf(Z), re = M.indexOf(ie), ge = G > 0 ? C[G - 1] : Z, De = re > 0 ? M[re - 1] : ie;
|
|
12811
12811
|
e.scrollToRow(ge, De).then(I);
|
|
@@ -13846,7 +13846,7 @@ const Zy = sd, { getConfig: Ur, getIcon: ts, getI18n: Zs, renderer: Eh, commands
|
|
|
13846
13846
|
suffixTooltip: ve.suffixTooltip,
|
|
13847
13847
|
onClick: ({ $event: Ce }) => Y ? j(Ce, ve) : L(Ce, ve)
|
|
13848
13848
|
}) : Fe()) : we;
|
|
13849
|
-
},
|
|
13849
|
+
}, V = () => {
|
|
13850
13850
|
const { buttons: _ } = e, { connectTable: Y } = f, oe = Y, we = [];
|
|
13851
13851
|
return _ && _.forEach((ve) => {
|
|
13852
13852
|
const { dropdowns: de, buttonRender: Ce } = ve;
|
|
@@ -13980,7 +13980,7 @@ const Zy = sd, { getConfig: Ur, getIcon: ts, getI18n: Zs, renderer: Eh, commands
|
|
|
13980
13980
|
}, [
|
|
13981
13981
|
l("div", {
|
|
13982
13982
|
class: "vxe-buttons--wrapper"
|
|
13983
|
-
}, lt ? lt({ $grid: h, $table: He }) :
|
|
13983
|
+
}, lt ? lt({ $grid: h, $table: He }) : V()),
|
|
13984
13984
|
l("div", {
|
|
13985
13985
|
class: "vxe-tools--wrapper"
|
|
13986
13986
|
}, Ye ? Ye({ $grid: h, $table: He }) : I()),
|
|
@@ -14090,7 +14090,7 @@ const PB = ad, { getConfig: Pl, getI18n: Js, commands: FB, hooks: VB, useFns: kB
|
|
|
14090
14090
|
refForm: g,
|
|
14091
14091
|
refToolbar: h,
|
|
14092
14092
|
refPager: w
|
|
14093
|
-
},
|
|
14093
|
+
}, V = {
|
|
14094
14094
|
computeProxyOpts: C,
|
|
14095
14095
|
computePagerOpts: H,
|
|
14096
14096
|
computeFormOpts: U,
|
|
@@ -14102,7 +14102,7 @@ const PB = ad, { getConfig: Pl, getI18n: Js, commands: FB, hooks: VB, useFns: kB
|
|
|
14102
14102
|
context: t,
|
|
14103
14103
|
reactData: u,
|
|
14104
14104
|
getRefMaps: () => z,
|
|
14105
|
-
getComputeMaps: () =>
|
|
14105
|
+
getComputeMaps: () => V
|
|
14106
14106
|
}, Z = () => {
|
|
14107
14107
|
const K = ne.value;
|
|
14108
14108
|
e.toolbarConfig && mn(K) && pe(() => {
|
|
@@ -22841,9 +22841,9 @@ const ss = rt({
|
|
|
22841
22841
|
const g = () => {
|
|
22842
22842
|
const { tipTarget: U, tipStore: ne } = a;
|
|
22843
22843
|
if (U) {
|
|
22844
|
-
const { scrollTop: j, scrollLeft: L, visibleWidth: B } = Ms(), { top: ue, left: Q } = Hl(U), P = f.value, z = 6,
|
|
22845
|
-
let Z = Q, ie = ue -
|
|
22846
|
-
Z = Math.max(z, Q + Math.floor((U.offsetWidth - I) / 2)), Z + I + z > L + B && (Z = L + B - I - z), ue -
|
|
22844
|
+
const { scrollTop: j, scrollLeft: L, visibleWidth: B } = Ms(), { top: ue, left: Q } = Hl(U), P = f.value, z = 6, V = P.offsetHeight, I = P.offsetWidth;
|
|
22845
|
+
let Z = Q, ie = ue - V - z;
|
|
22846
|
+
Z = Math.max(z, Q + Math.floor((U.offsetWidth - I) / 2)), Z + I + z > L + B && (Z = L + B - I - z), ue - V < j + z && (ne.placement = "bottom", ie = ue + U.offsetHeight + z), ne.style.top = `${ie}px`, ne.style.left = `${Z}px`, ne.arrowStyle.left = `${Q - Z + U.offsetWidth / 2}px`;
|
|
22847
22847
|
}
|
|
22848
22848
|
}, h = (U) => {
|
|
22849
22849
|
U !== a.visible && (a.visible = U, a.isUpdate = !0, o("update:modelValue", U));
|
|
@@ -22941,8 +22941,8 @@ const ss = rt({
|
|
|
22941
22941
|
}, `${ne}`);
|
|
22942
22942
|
}, H = () => {
|
|
22943
22943
|
const { popupClassName: U, theme: ne, isArrow: j, enterable: L } = e, { tipActive: B, visible: ue, tipStore: Q } = a, P = n.default, z = s.value;
|
|
22944
|
-
let
|
|
22945
|
-
return L && (
|
|
22944
|
+
let V;
|
|
22945
|
+
return L && (V = {
|
|
22946
22946
|
onMouseenter: D,
|
|
22947
22947
|
onMouseleave: y
|
|
22948
22948
|
}), l("div", Object.assign({ ref: f, class: ["vxe-table--tooltip-wrapper", `theme--${ne}`, U ? i.isFunction(U) ? U({ $tooltip: d }) : U : "", {
|
|
@@ -22952,7 +22952,7 @@ const ss = rt({
|
|
|
22952
22952
|
"is--visible": ue,
|
|
22953
22953
|
"is--arrow": j,
|
|
22954
22954
|
"is--active": B
|
|
22955
|
-
}], style: Q.style },
|
|
22955
|
+
}], style: Q.style }, V), [
|
|
22956
22956
|
F(),
|
|
22957
22957
|
l("div", {
|
|
22958
22958
|
class: "vxe-table--tooltip-arrow",
|
|
@@ -23170,7 +23170,7 @@ const ss = rt({
|
|
|
23170
23170
|
g.visiblePanel && B();
|
|
23171
23171
|
}, 50));
|
|
23172
23172
|
}, 20));
|
|
23173
|
-
},
|
|
23173
|
+
}, V = (de) => {
|
|
23174
23174
|
const { loading: Ce } = e;
|
|
23175
23175
|
x.value || Ce || (re(), Z(de));
|
|
23176
23176
|
}, I = (de) => {
|
|
@@ -23253,7 +23253,7 @@ const ss = rt({
|
|
|
23253
23253
|
return Fe();
|
|
23254
23254
|
if (ee) {
|
|
23255
23255
|
const R = {}, J = {};
|
|
23256
|
-
return Ye === "hover" && (R.onMouseenter =
|
|
23256
|
+
return Ye === "hover" && (R.onMouseenter = V, R.onMouseleave = I, J.onMouseenter = z, J.onMouseleave = De), l("div", {
|
|
23257
23257
|
ref: w,
|
|
23258
23258
|
class: ["vxe-button--dropdown", de ? i.isFunction(de) ? de({ $button: D }) : de : "", {
|
|
23259
23259
|
[`size--${A}`]: A,
|
|
@@ -23637,7 +23637,7 @@ const Hc = rt({
|
|
|
23637
23637
|
}), z = N(() => {
|
|
23638
23638
|
const R = P.value;
|
|
23639
23639
|
return i.chunk(R, 2);
|
|
23640
|
-
}),
|
|
23640
|
+
}), V = N(() => {
|
|
23641
23641
|
const { selectMonth: R, currentDate: J } = s, { monthSize: be } = a, Ee = [];
|
|
23642
23642
|
if (R && J) {
|
|
23643
23643
|
const $e = J.getFullYear(), Le = J.getMonth(), Qe = i.getWhatYear(R, 0, "first").getFullYear();
|
|
@@ -23655,7 +23655,7 @@ const Hc = rt({
|
|
|
23655
23655
|
}
|
|
23656
23656
|
return Ee;
|
|
23657
23657
|
}), I = N(() => {
|
|
23658
|
-
const R =
|
|
23658
|
+
const R = V.value;
|
|
23659
23659
|
return i.chunk(R, 4);
|
|
23660
23660
|
}), Z = N(() => {
|
|
23661
23661
|
const { selectMonth: R, currentDate: J } = s, be = [];
|
|
@@ -23758,7 +23758,7 @@ const Hc = rt({
|
|
|
23758
23758
|
}, dt = (R) => {
|
|
23759
23759
|
lt({ date: R }) || (P.value.some((be) => i.isDateSame(be.date, R, "yyyyq")) || Y(R), De(R));
|
|
23760
23760
|
}, gt = (R) => {
|
|
23761
|
-
lt({ date: R }) || (
|
|
23761
|
+
lt({ date: R }) || (V.value.some((be) => i.isDateSame(be.date, R, "yyyyMM")) || Y(R), De(R));
|
|
23762
23762
|
}, pt = (R) => {
|
|
23763
23763
|
if (!lt(R)) {
|
|
23764
23764
|
const { datePanelType: J } = s;
|
|
@@ -24278,8 +24278,8 @@ const qc = rt({
|
|
|
24278
24278
|
}, u = {
|
|
24279
24279
|
refElem: s
|
|
24280
24280
|
}, d = N(() => {
|
|
24281
|
-
const { vertical: Q, options: P } = e, { activeName: z, itemWidth:
|
|
24282
|
-
return Q ? re.transform = `translateY(-${G * I}px)` : (re.width = `${
|
|
24281
|
+
const { vertical: Q, options: P } = e, { activeName: z, itemWidth: V, itemHeight: I, staticItems: Z } = c, ie = (Z && Z.length ? Z : P) || [], G = Math.max(0, i.findIndexOf(ie, (ge) => ge.name === z)), re = {};
|
|
24282
|
+
return Q ? re.transform = `translateY(-${G * I}px)` : (re.width = `${V * ie.length}px`, re.transform = `translateX(-${G * V}px)`), re;
|
|
24283
24283
|
}), p = {}, g = {
|
|
24284
24284
|
xID: r,
|
|
24285
24285
|
props: e,
|
|
@@ -24300,15 +24300,15 @@ const qc = rt({
|
|
|
24300
24300
|
let P = null;
|
|
24301
24301
|
if (Q && Q.length) {
|
|
24302
24302
|
let z = !1;
|
|
24303
|
-
P = e.modelValue, Q.forEach((
|
|
24304
|
-
P ===
|
|
24303
|
+
P = e.modelValue, Q.forEach((V) => {
|
|
24304
|
+
P === V.name && (z = !0);
|
|
24305
24305
|
}), z || (P = Q[0].name, n("update:modelValue", P));
|
|
24306
24306
|
}
|
|
24307
24307
|
c.activeName = P;
|
|
24308
24308
|
}, E = (Q, P, z) => {
|
|
24309
24309
|
n(Q, Jt(z, { $carousel: g }, P));
|
|
24310
24310
|
}, v = (Q) => {
|
|
24311
|
-
const { options: P, loop: z } = e, { activeName:
|
|
24311
|
+
const { options: P, loop: z } = e, { activeName: V, staticItems: I } = c, Z = (I && I.length ? I : P) || [], ie = Math.max(0, i.findIndexOf(Z, (G) => G.name === V));
|
|
24312
24312
|
if (ie > -1) {
|
|
24313
24313
|
let G = null;
|
|
24314
24314
|
if (Q ? ie < Z.length - 1 ? G = Z[ie + 1] : z && (G = Z[0]) : ie > 0 ? G = Z[ie - 1] : z && (G = Z[Z.length - 1]), G) {
|
|
@@ -24350,10 +24350,10 @@ const qc = rt({
|
|
|
24350
24350
|
}, H = {}, U = (Q, P) => Q && (i.isString(Q) && (Q = o[Q] || null), i.isFunction(Q)) ? Rt(Q(P)) : [];
|
|
24351
24351
|
Object.assign(g, D, H);
|
|
24352
24352
|
const ne = (Q) => {
|
|
24353
|
-
const { height: P } = e, { activeName: z } = c,
|
|
24353
|
+
const { height: P } = e, { activeName: z } = c, V = d.value;
|
|
24354
24354
|
return l("div", {
|
|
24355
24355
|
class: "vxe-carousel--list",
|
|
24356
|
-
style:
|
|
24356
|
+
style: V
|
|
24357
24357
|
}, Q.map((I) => {
|
|
24358
24358
|
const { name: Z, url: ie, slots: G } = I, re = G ? G.default : null;
|
|
24359
24359
|
return l("div", {
|
|
@@ -24376,11 +24376,11 @@ const qc = rt({
|
|
|
24376
24376
|
return l("div", {
|
|
24377
24377
|
class: "vxe-carousel--indicators"
|
|
24378
24378
|
}, Q.map((z) => {
|
|
24379
|
-
const { name:
|
|
24379
|
+
const { name: V } = z;
|
|
24380
24380
|
return l("div", {
|
|
24381
|
-
key: `${
|
|
24381
|
+
key: `${V}`,
|
|
24382
24382
|
class: ["vxe-carousel--indicators-item", {
|
|
24383
|
-
"is--active": P ===
|
|
24383
|
+
"is--active": P === V
|
|
24384
24384
|
}],
|
|
24385
24385
|
onClick(I) {
|
|
24386
24386
|
w(I, z);
|
|
@@ -24388,7 +24388,7 @@ const qc = rt({
|
|
|
24388
24388
|
});
|
|
24389
24389
|
}));
|
|
24390
24390
|
}, L = () => {
|
|
24391
|
-
const { loading: Q, height: P, width: z, showIndicators:
|
|
24391
|
+
const { loading: Q, height: P, width: z, showIndicators: V, vertical: I, options: Z } = e, { staticItems: ie } = c, G = o.default, re = (ie && ie.length ? ie : Z) || [];
|
|
24392
24392
|
return l("div", {
|
|
24393
24393
|
ref: s,
|
|
24394
24394
|
class: ["vxe-carousel", `is--${I ? "vertical" : "horizontal"}`],
|
|
@@ -24410,7 +24410,7 @@ const qc = rt({
|
|
|
24410
24410
|
}, [
|
|
24411
24411
|
ne(re)
|
|
24412
24412
|
]),
|
|
24413
|
-
|
|
24413
|
+
V ? j(re) : Fe(),
|
|
24414
24414
|
l("div", {
|
|
24415
24415
|
class: "vxe-carousel--btn-wrapper"
|
|
24416
24416
|
}, [
|
|
@@ -24846,7 +24846,7 @@ const Gc = rt({
|
|
|
24846
24846
|
const C = (U) => {
|
|
24847
24847
|
const { activeNames: ne, initNames: j } = c, L = p.value;
|
|
24848
24848
|
return U.map((B) => {
|
|
24849
|
-
const { icon: ue, name: Q, title: P, slots: z } = B,
|
|
24849
|
+
const { icon: ue, name: Q, title: P, slots: z } = B, V = z ? z.title : null, I = z ? z.default : null, Z = Q && ne.includes(Q);
|
|
24850
24850
|
return l("div", {
|
|
24851
24851
|
class: "vxe-collapse-item"
|
|
24852
24852
|
}, [
|
|
@@ -24872,7 +24872,7 @@ const Gc = rt({
|
|
|
24872
24872
|
]) : no(),
|
|
24873
24873
|
l("span", {
|
|
24874
24874
|
class: "vxe-collapse--item-name"
|
|
24875
|
-
},
|
|
24875
|
+
}, V ? y(V, { name: Q, title: P }) : `${P}`)
|
|
24876
24876
|
]),
|
|
24877
24877
|
l("div", {
|
|
24878
24878
|
class: ["vxe-collapse--item-content", {
|
|
@@ -25212,7 +25212,7 @@ const Xr = rt({
|
|
|
25212
25212
|
}, Re(`vxe.countdown.formats.${B}`))
|
|
25213
25213
|
]));
|
|
25214
25214
|
}, H = () => {
|
|
25215
|
-
const { prefixConfig: U, suffixConfig: ne } = e, { currNum: j } = c, L = a.value, B = p.value, ue = h.value, Q = w.value, P = n.prefix, z = n.suffix,
|
|
25215
|
+
const { prefixConfig: U, suffixConfig: ne } = e, { currNum: j } = c, L = a.value, B = p.value, ue = h.value, Q = w.value, P = n.prefix, z = n.suffix, V = n.default;
|
|
25216
25216
|
return l("div", {
|
|
25217
25217
|
ref: s,
|
|
25218
25218
|
class: ["vxe-countdown", B.done ? "is--progress" : "is-end", {
|
|
@@ -25230,7 +25230,7 @@ const Xr = rt({
|
|
|
25230
25230
|
]) : Fe(),
|
|
25231
25231
|
l("div", {
|
|
25232
25232
|
class: "vxe-countdown--content"
|
|
25233
|
-
},
|
|
25233
|
+
}, V ? Rt(V({ currentValue: j, diffConf: B })) : F()),
|
|
25234
25234
|
z || ne ? l("div", {
|
|
25235
25235
|
class: "vxe-countdown--suffix"
|
|
25236
25236
|
}, z ? Rt(z({ currentValue: j, diffConf: B })) : [
|
|
@@ -25439,7 +25439,7 @@ const la = rt({
|
|
|
25439
25439
|
i.isValidDate(Lt) && (vt = Lt);
|
|
25440
25440
|
}
|
|
25441
25441
|
return vt;
|
|
25442
|
-
}),
|
|
25442
|
+
}), V = N(() => {
|
|
25443
25443
|
const fe = ne.value, { selectMonth: Ue } = p;
|
|
25444
25444
|
return Ue && fe ? Ue <= fe : !1;
|
|
25445
25445
|
}), I = N(() => {
|
|
@@ -25731,7 +25731,7 @@ const la = rt({
|
|
|
25731
25731
|
fe === "month" || fe === "quarter" ? fe = "year" : fe = "month", p.datePanelType = fe;
|
|
25732
25732
|
}, Ie = (fe) => {
|
|
25733
25733
|
const { type: Ue } = e, { datePanelType: Ze, selectMonth: vt, inputValue: Lt } = p, { yearSize: $t } = g, Wt = Lt;
|
|
25734
|
-
if (!
|
|
25734
|
+
if (!V.value) {
|
|
25735
25735
|
let st;
|
|
25736
25736
|
Ue === "year" ? st = i.getWhatYear(vt, -$t, "first") : Ue === "month" || Ue === "quarter" ? Ze === "year" ? st = i.getWhatYear(vt, -$t, "first") : st = i.getWhatYear(vt, -1, "first") : Ze === "year" ? st = i.getWhatYear(vt, -$t, "first") : Ze === "month" ? st = i.getWhatYear(vt, -1, "first") : st = i.getWhatMonth(vt, -1, "first"), p.selectMonth = st, b.dispatchEvent("date-prev", { viewType: Ze, viewDate: st, value: Wt, type: Ue }, fe);
|
|
25737
25737
|
}
|
|
@@ -26075,7 +26075,7 @@ const la = rt({
|
|
|
26075
26075
|
}
|
|
26076
26076
|
return Sl();
|
|
26077
26077
|
}, wo = () => {
|
|
26078
|
-
const { multiple: fe } = e, { datePanelType: Ue } = p, Ze =
|
|
26078
|
+
const { multiple: fe } = e, { datePanelType: Ue } = p, Ze = V.value, vt = I.value, Lt = ge.value;
|
|
26079
26079
|
return [
|
|
26080
26080
|
l("div", {
|
|
26081
26081
|
class: "vxe-date-picker--date-picker-header"
|
|
@@ -26678,7 +26678,7 @@ const Ts = [], Zc = rt({
|
|
|
26678
26678
|
return e.showFooter ? l("div", {
|
|
26679
26679
|
class: "vxe-drawer--footer"
|
|
26680
26680
|
}, Z ? Rt(Z({ $drawer: w })) : [P()]) : no();
|
|
26681
|
-
},
|
|
26681
|
+
}, V = () => {
|
|
26682
26682
|
const { slots: I = {}, className: Z, position: ie, loading: G, lockScroll: re, padding: ge, lockView: De, mask: ae, resize: _, destroyOnClose: Y } = e, { initialized: oe, contentVisible: we, visible: ve } = d, de = n.aside || I.aside, Ce = s.value, je = g.value;
|
|
26683
26683
|
return l(Jr, {
|
|
26684
26684
|
to: "body",
|
|
@@ -26738,7 +26738,7 @@ const Ts = [], Zc = rt({
|
|
|
26738
26738
|
}), e.escClosable && ct.on(w, "keydown", U);
|
|
26739
26739
|
}), Wn(() => {
|
|
26740
26740
|
ct.off(w, "keydown");
|
|
26741
|
-
}), Cn("$xeDrawer", "$xeDrawer"), w.renderVN =
|
|
26741
|
+
}), Cn("$xeDrawer", "$xeDrawer"), w.renderVN = V, w;
|
|
26742
26742
|
},
|
|
26743
26743
|
render() {
|
|
26744
26744
|
return this.renderVN();
|
|
@@ -27008,7 +27008,7 @@ function $v(e) {
|
|
|
27008
27008
|
]);
|
|
27009
27009
|
}
|
|
27010
27010
|
const Xp = (e, t, n) => {
|
|
27011
|
-
const o = e.props, r = e.reactData, { data: s, rules: a, readonly: c, disabled: f, span: u, titleBackground: d, titleBold: p, titleColon: g, titleAsterisk: h, vertical: w, padding: S } = o, { collapseAll: E } = r, { folding: v, field: D, itemRender: y, showError: b, className: x, vertical: C, padding: M, children: F, showContent: H } = t, U = Nr(y) ? $n.get(y.name) : null, ne = U ? U.formItemClassName || U.itemClassName : "", j = t.span || u, L = i.eqNull(M) ? S : M, B = i.eqNull(C) ? w : C, ue = i.eqNull(t.titleBackground) ? d : t.titleBackground, Q = i.eqNull(t.titleBold) ? p : t.titleBold, P = i.eqNull(t.titleColon) ? g : t.titleColon, z = i.eqNull(t.titleAsterisk) ? h : t.titleAsterisk,
|
|
27011
|
+
const o = e.props, r = e.reactData, { data: s, rules: a, readonly: c, disabled: f, span: u, titleBackground: d, titleBold: p, titleColon: g, titleAsterisk: h, vertical: w, padding: S } = o, { collapseAll: E } = r, { folding: v, field: D, itemRender: y, showError: b, className: x, vertical: C, padding: M, children: F, showContent: H } = t, U = Nr(y) ? $n.get(y.name) : null, ne = U ? U.formItemClassName || U.itemClassName : "", j = t.span || u, L = i.eqNull(M) ? S : M, B = i.eqNull(C) ? w : C, ue = i.eqNull(t.titleBackground) ? d : t.titleBackground, Q = i.eqNull(t.titleBold) ? p : t.titleBold, P = i.eqNull(t.titleColon) ? g : t.titleColon, z = i.eqNull(t.titleAsterisk) ? h : t.titleAsterisk, V = { data: s, disabled: f, readonly: c, field: D, property: D, item: t, $form: e, $grid: e.xegrid }, I = F && F.length > 0;
|
|
27012
27012
|
let Z = !1, ie = !1;
|
|
27013
27013
|
if (!c && a) {
|
|
27014
27014
|
const G = a[D];
|
|
@@ -27019,8 +27019,8 @@ const Xp = (e, t, n) => {
|
|
|
27019
27019
|
"vxe-form--item",
|
|
27020
27020
|
t.id,
|
|
27021
27021
|
j ? `vxe-form--item-col_${j} is--span` : "",
|
|
27022
|
-
x ? i.isFunction(x) ? x(
|
|
27023
|
-
ne ? i.isFunction(ne) ? ne(
|
|
27022
|
+
x ? i.isFunction(x) ? x(V) : x : "",
|
|
27023
|
+
ne ? i.isFunction(ne) ? ne(V) : ne : "",
|
|
27024
27024
|
{
|
|
27025
27025
|
"is--colon": P,
|
|
27026
27026
|
"is--tbg": ue,
|
|
@@ -27048,7 +27048,7 @@ const Xp = (e, t, n) => {
|
|
|
27048
27048
|
];
|
|
27049
27049
|
};
|
|
27050
27050
|
function Jp(e, t, n) {
|
|
27051
|
-
const o = e.props, { data: r, readonly: s, disabled: a, titleAlign: c, titleWidth: f, titleOverflow: u, vertical: d } = o, { slots: p, title: g, field: h, itemRender: w, titleOverflow: S, vertical: E, showTitle: v, titleClassName: D, titleStyle: y, titlePrefix: b, titleSuffix: x, children: C, showContent: M } = t, { computeTooltipOpts: F } = e.getComputeMaps(), H = F.value, U = Nr(w) ? $n.get(w.name) : null, ne = U ? U.formItemTitleClassName || U.itemTitleClassName : "", j = U ? U.formItemTitleStyle || U.itemTitleStyle : null, L = i.eqNull(E) ? d : E, B = i.eqNull(t.titleAlign) ? c : t.titleAlign, ue = L ? null : i.eqNull(t.titleWidth) ? f : t.titleWidth, Q = i.eqNull(S) ? u : S, P = Q === "ellipsis", z = Q === "title",
|
|
27051
|
+
const o = e.props, { data: r, readonly: s, disabled: a, titleAlign: c, titleWidth: f, titleOverflow: u, vertical: d } = o, { slots: p, title: g, field: h, itemRender: w, titleOverflow: S, vertical: E, showTitle: v, titleClassName: D, titleStyle: y, titlePrefix: b, titleSuffix: x, children: C, showContent: M } = t, { computeTooltipOpts: F } = e.getComputeMaps(), H = F.value, U = Nr(w) ? $n.get(w.name) : null, ne = U ? U.formItemTitleClassName || U.itemTitleClassName : "", j = U ? U.formItemTitleStyle || U.itemTitleStyle : null, L = i.eqNull(E) ? d : E, B = i.eqNull(t.titleAlign) ? c : t.titleAlign, ue = L ? null : i.eqNull(t.titleWidth) ? f : t.titleWidth, Q = i.eqNull(S) ? u : S, P = Q === "ellipsis", z = Q === "title", V = Q === !0 || Q === "tooltip", I = z || V || P, Z = { data: r, disabled: a, readonly: s, field: h, property: h, item: t, $form: e, $grid: e.xegrid }, ie = p ? p.title : null, G = p ? p.extra : null, re = v !== !1 && (g || ie), ge = C && C.length > 0, De = [];
|
|
27052
27052
|
b && De.push(b.content || b.message ? l(ss, Object.assign(Object.assign(Object.assign({}, H), b), { content: Un(b.content || b.message) }), {
|
|
27053
27053
|
default: () => Mv(b)
|
|
27054
27054
|
}) : Mv(b));
|
|
@@ -27060,7 +27060,7 @@ function Jp(e, t, n) {
|
|
|
27060
27060
|
x && _.push(x.content || x.message ? l(ss, Object.assign(Object.assign(Object.assign({}, H), x), { content: Un(x.content || x.message) }), {
|
|
27061
27061
|
default: () => $v(x)
|
|
27062
27062
|
}) : $v(x));
|
|
27063
|
-
const Y =
|
|
27063
|
+
const Y = V ? {
|
|
27064
27064
|
onMouseenter(oe) {
|
|
27065
27065
|
e.triggerTitleTipEvent(oe, Z);
|
|
27066
27066
|
},
|
|
@@ -27462,7 +27462,7 @@ const Iv = (e, t) => {
|
|
|
27462
27462
|
oe ? p.dispatchEvent("submit-invalid", { data: e.data, errMap: oe }, _) : p.dispatchEvent("submit", { data: e.data }, _);
|
|
27463
27463
|
});
|
|
27464
27464
|
}
|
|
27465
|
-
},
|
|
27465
|
+
}, V = () => {
|
|
27466
27466
|
const { tooltipStore: _ } = c, Y = d.value;
|
|
27467
27467
|
return _.visible && (Object.assign(_, {
|
|
27468
27468
|
item: null,
|
|
@@ -27470,7 +27470,7 @@ const Iv = (e, t) => {
|
|
|
27470
27470
|
}), Y && Y.close()), pe();
|
|
27471
27471
|
}, I = (_, Y) => {
|
|
27472
27472
|
const { item: oe } = Y, { tooltipStore: we } = c, ve = d.value, de = _.currentTarget.children[0], Ce = (de.textContent || "").trim(), je = de.scrollWidth > de.clientWidth;
|
|
27473
|
-
clearTimeout(c.stTimeout), we.item !== oe &&
|
|
27473
|
+
clearTimeout(c.stTimeout), we.item !== oe && V(), Ce && je && (Object.assign(we, {
|
|
27474
27474
|
item: oe,
|
|
27475
27475
|
visible: !0
|
|
27476
27476
|
}), ve && ve.open(de, Ce));
|
|
@@ -27478,8 +27478,8 @@ const Iv = (e, t) => {
|
|
|
27478
27478
|
const _ = h.value;
|
|
27479
27479
|
let Y = d.value;
|
|
27480
27480
|
Y && Y.setActived(!1), _.enterable ? c.stTimeout = setTimeout(() => {
|
|
27481
|
-
Y = d.value, Y && !Y.isActived() &&
|
|
27482
|
-
}, _.leaveDelay) :
|
|
27481
|
+
Y = d.value, Y && !Y.isActived() && V();
|
|
27482
|
+
}, _.leaveDelay) : V();
|
|
27483
27483
|
}, ie = (_, Y, oe) => Y ? B(_ ? ["blur"].includes(_.type) ? "blur" : "change" : "all", Y, oe).then(() => {
|
|
27484
27484
|
H(Y);
|
|
27485
27485
|
}).catch((we) => {
|
|
@@ -27501,7 +27501,7 @@ const Iv = (e, t) => {
|
|
|
27501
27501
|
toggleCollapse: M,
|
|
27502
27502
|
getItems: b,
|
|
27503
27503
|
getItemByField: x,
|
|
27504
|
-
closeTooltip:
|
|
27504
|
+
closeTooltip: V
|
|
27505
27505
|
}, Object.assign(v, p, {
|
|
27506
27506
|
callSlot: D,
|
|
27507
27507
|
triggerItemEvent: ie,
|
|
@@ -28513,7 +28513,7 @@ const i9 = rt({
|
|
|
28513
28513
|
class: "vxe-tabs-header--extra"
|
|
28514
28514
|
}, Rt(Ye({}))) : Fe()
|
|
28515
28515
|
]);
|
|
28516
|
-
},
|
|
28516
|
+
}, V = (re) => {
|
|
28517
28517
|
const { initNames: ge, activeName: De } = f, { name: ae, slots: _ } = re, Y = _ ? _.default : null;
|
|
28518
28518
|
return ae && ge.includes(ae) ? l("div", {
|
|
28519
28519
|
key: `${ae}`,
|
|
@@ -28524,7 +28524,7 @@ const i9 = rt({
|
|
|
28524
28524
|
}, Y ? D(Y, { name: ae }) : []) : Fe();
|
|
28525
28525
|
}, I = (re) => {
|
|
28526
28526
|
const { destroyOnClose: ge } = e, { activeName: De } = f, ae = re.find((_) => _.name === De);
|
|
28527
|
-
return ge ? [ae ?
|
|
28527
|
+
return ge ? [ae ? V(ae) : Fe()] : re.map((_) => V(_));
|
|
28528
28528
|
}, Z = () => {
|
|
28529
28529
|
const { type: re, height: ge, padding: De, trigger: ae } = e, _ = h.value, Y = w.value, oe = n.default, we = n.footer, ve = oe ? Y : _;
|
|
28530
28530
|
return l("div", {
|
|
@@ -29312,7 +29312,7 @@ const gl = rt({
|
|
|
29312
29312
|
}, z = () => {
|
|
29313
29313
|
const { type: Oe } = e, Me = Oe === "notification" ? Cf : yf;
|
|
29314
29314
|
Me.indexOf(y) === -1 && Me.push(y), H();
|
|
29315
|
-
},
|
|
29315
|
+
}, V = () => {
|
|
29316
29316
|
const { id: Oe, remember: Me, storage: $, storageKey: te } = e, { revertLocat: Se } = a;
|
|
29317
29317
|
if (Oe && Me && $) {
|
|
29318
29318
|
const K = x();
|
|
@@ -29376,7 +29376,7 @@ const gl = rt({
|
|
|
29376
29376
|
left: `${et}px`,
|
|
29377
29377
|
width: "200px",
|
|
29378
29378
|
height: `${$e.offsetHeight}px`
|
|
29379
|
-
}),
|
|
29379
|
+
}), V();
|
|
29380
29380
|
}));
|
|
29381
29381
|
}, Z = () => {
|
|
29382
29382
|
const Oe = a.zoomStatus;
|
|
@@ -29392,7 +29392,7 @@ const gl = rt({
|
|
|
29392
29392
|
left: "0",
|
|
29393
29393
|
width: "100%",
|
|
29394
29394
|
height: "100%"
|
|
29395
|
-
})),
|
|
29395
|
+
})), V();
|
|
29396
29396
|
});
|
|
29397
29397
|
}, ie = () => {
|
|
29398
29398
|
const { duration: Oe } = e;
|
|
@@ -29458,7 +29458,7 @@ const gl = rt({
|
|
|
29458
29458
|
left: `${Oe.left}px`,
|
|
29459
29459
|
width: `${Oe.width}px`,
|
|
29460
29460
|
height: `${Oe.height}px`
|
|
29461
|
-
}),
|
|
29461
|
+
}), V(), pe();
|
|
29462
29462
|
}
|
|
29463
29463
|
})), de = (Oe) => {
|
|
29464
29464
|
const { zoomStatus: Me } = a;
|
|
@@ -29515,7 +29515,7 @@ const gl = rt({
|
|
|
29515
29515
|
Et > et && (Et = et), Et < tt && (Et = tt), jt > ut && (jt = ut), jt < yt && (jt = yt), K.style.left = `${Et}px`, K.style.top = `${jt}px`, K.className = K.className.replace(/\s?is--drag/, "") + " is--drag", bt("move", { type: "move" }, $e);
|
|
29516
29516
|
}, document.onmouseup = () => {
|
|
29517
29517
|
document.onmousemove = A, document.onmouseup = ee, Me && $ && pe(() => {
|
|
29518
|
-
|
|
29518
|
+
V();
|
|
29519
29519
|
}), setTimeout(() => {
|
|
29520
29520
|
K.className = K.className.replace(/\s?is--drag/, "");
|
|
29521
29521
|
}, 50);
|
|
@@ -29553,7 +29553,7 @@ const gl = rt({
|
|
|
29553
29553
|
Ie = en.clientY - ut, it = Ie + et, Et + it + K < te && it > J && ($e.style.height = `${it < Ee ? it : Ee}px`);
|
|
29554
29554
|
break;
|
|
29555
29555
|
}
|
|
29556
|
-
$e.className = $e.className.replace(/\s?is--drag/, "") + " is--drag", Me && $ &&
|
|
29556
|
+
$e.className = $e.className.replace(/\s?is--drag/, "") + " is--drag", Me && $ && V(), bt("resize", yn, en);
|
|
29557
29557
|
}, document.onmouseup = () => {
|
|
29558
29558
|
a.revertLocat = null, document.onmousemove = Le, document.onmouseup = Qe, setTimeout(() => {
|
|
29559
29559
|
$e.className = $e.className.replace(/\s?is--drag/, "");
|
|
@@ -29867,37 +29867,37 @@ const gl = rt({
|
|
|
29867
29867
|
widgetData: []
|
|
29868
29868
|
}), w = (P) => {
|
|
29869
29869
|
if (P) {
|
|
29870
|
-
const { formConfig: z, widgetData:
|
|
29871
|
-
v(z || {}), b(
|
|
29870
|
+
const { formConfig: z, widgetData: V } = P;
|
|
29871
|
+
v(z || {}), b(V || []);
|
|
29872
29872
|
}
|
|
29873
29873
|
return pe();
|
|
29874
29874
|
}, S = (P) => {
|
|
29875
|
-
const { formConfig: z, widgetData:
|
|
29875
|
+
const { formConfig: z, widgetData: V } = P || {}, I = y(V || []);
|
|
29876
29876
|
return Object.assign(Object.assign({}, D(I)), { formConfig: E(z || {}), widgetData: I });
|
|
29877
29877
|
}, E = (P) => {
|
|
29878
|
-
const { viewRender: z, createFormConfig:
|
|
29879
|
-
if (
|
|
29880
|
-
return
|
|
29878
|
+
const { viewRender: z, createFormConfig: V, formOptions: I } = e, Z = { viewRender: z, formConfig: P };
|
|
29879
|
+
if (V)
|
|
29880
|
+
return V(Z);
|
|
29881
29881
|
const { name: ie } = z || {}, G = $n.get(ie) || {}, re = G ? G.createFormViewFormConfig : null;
|
|
29882
29882
|
return Object.assign({}, re ? re(Z) : Lw(Z), I);
|
|
29883
29883
|
}, v = (P) => (u.formConfig = E(P), pe()), D = (P) => {
|
|
29884
|
-
const z = {},
|
|
29884
|
+
const z = {}, V = {};
|
|
29885
29885
|
return i.eachTree(P, (I) => {
|
|
29886
29886
|
const { name: Z, field: ie, required: G } = I, re = $n.get(Z) || {}, ge = re.createFormDesignWidgetFieldValue, De = re.createFormDesignWidgetFieldRules;
|
|
29887
29887
|
if (z[ie] = ge ? ge({ widget: I, $formView: g }) : x(I), De) {
|
|
29888
29888
|
const ae = De({ widget: I, $formView: g });
|
|
29889
|
-
ae && ae.length && (
|
|
29889
|
+
ae && ae.length && (V[ie] = ae);
|
|
29890
29890
|
} else
|
|
29891
|
-
G && (
|
|
29891
|
+
G && (V[ie] = C());
|
|
29892
29892
|
}, { children: "children" }), {
|
|
29893
29893
|
formData: z,
|
|
29894
|
-
formRules:
|
|
29894
|
+
formRules: V
|
|
29895
29895
|
};
|
|
29896
29896
|
}, y = (P) => (P || []).map((z) => Qp(z)), b = (P) => {
|
|
29897
29897
|
const z = y(P);
|
|
29898
29898
|
u.widgetObjList = z;
|
|
29899
|
-
const { formData:
|
|
29900
|
-
return u.formRules = I, n("update:modelValue", Object.assign(
|
|
29899
|
+
const { formData: V, formRules: I } = D(z);
|
|
29900
|
+
return u.formRules = I, n("update:modelValue", Object.assign(V, e.modelValue)), pe();
|
|
29901
29901
|
}, x = (P) => {
|
|
29902
29902
|
switch (P.name) {
|
|
29903
29903
|
case "subtable":
|
|
@@ -29907,16 +29907,16 @@ const gl = rt({
|
|
|
29907
29907
|
}, C = () => [
|
|
29908
29908
|
{ required: !0, content: "该填写该字段!" }
|
|
29909
29909
|
], M = (P, z) => {
|
|
29910
|
-
const { field:
|
|
29911
|
-
return I && I.updateStatus({ field:
|
|
29910
|
+
const { field: V } = P, I = a.value;
|
|
29911
|
+
return I && I.updateStatus({ field: V }, z), pe();
|
|
29912
29912
|
}, F = (P, z) => {
|
|
29913
|
-
const { modelValue:
|
|
29914
|
-
return
|
|
29913
|
+
const { modelValue: V } = e, { field: I } = P, Z = a.value;
|
|
29914
|
+
return V && (V[I] = z), Z && Z.updateStatus({ field: I }, z), pe();
|
|
29915
29915
|
}, H = (P) => {
|
|
29916
29916
|
const { modelValue: z } = e;
|
|
29917
29917
|
return z ? z[P.field] : null;
|
|
29918
|
-
}, U = (P, z,
|
|
29919
|
-
n(P, Jt(
|
|
29918
|
+
}, U = (P, z, V) => {
|
|
29919
|
+
n(P, Jt(V, { $formView: g }, z));
|
|
29920
29920
|
}, ne = (P) => P ? i.isArray(P) ? P.map((z) => z.name) : [P.name] : null, j = {
|
|
29921
29921
|
dispatchEvent: U,
|
|
29922
29922
|
clearConfig: h,
|
|
@@ -29957,7 +29957,7 @@ const gl = rt({
|
|
|
29957
29957
|
};
|
|
29958
29958
|
Object.assign(g, j, {});
|
|
29959
29959
|
const Q = () => {
|
|
29960
|
-
const { readonly: P, disabled: z, modelValue:
|
|
29960
|
+
const { readonly: P, disabled: z, modelValue: V } = e, { formConfig: I, formRules: Z, widgetObjList: ie } = u, G = c.value, re = o.top, ge = o.bottom, De = o.header, ae = o.footer;
|
|
29961
29961
|
return l("div", {
|
|
29962
29962
|
ref: s,
|
|
29963
29963
|
class: ["vxe-form-view", {
|
|
@@ -29968,7 +29968,7 @@ const gl = rt({
|
|
|
29968
29968
|
class: "vxe-form-view--top"
|
|
29969
29969
|
}, Rt(re({ $formView: g }))) : Fe(),
|
|
29970
29970
|
l(Hn, Object.assign(Object.assign({ ref: a }, I), {
|
|
29971
|
-
data:
|
|
29971
|
+
data: V,
|
|
29972
29972
|
customLayout: !0,
|
|
29973
29973
|
readonly: P,
|
|
29974
29974
|
disabled: z,
|
|
@@ -30229,7 +30229,7 @@ const Gn = rt({
|
|
|
30229
30229
|
}), B = N(() => ["number", "integer", "float"].indexOf(e.type) > -1), ue = N(() => i.getSize(h.inputValue)), Q = N(() => {
|
|
30230
30230
|
const X = ue.value, Ae = j.value;
|
|
30231
30231
|
return Ae && X > i.toNumber(Ae);
|
|
30232
|
-
}), P = N(() => L.value || ["date", "week", "month", "quarter", "year"].indexOf(e.type) > -1), z = N(() => e.type === "password"),
|
|
30232
|
+
}), P = N(() => L.value || ["date", "week", "month", "quarter", "year"].indexOf(e.type) > -1), z = N(() => e.type === "password"), V = N(() => e.type === "search"), I = N(() => i.toInteger(e.digits) || 1), Z = N(() => {
|
|
30233
30233
|
const { type: X } = e, Ae = I.value, Ke = e.step;
|
|
30234
30234
|
return X === "integer" ? i.toInteger(Ke) || 1 : X === "float" ? i.toNumber(Ke) || 1 / Math.pow(10, Ae) : i.toNumber(Ke) || 1;
|
|
30235
30235
|
}), ie = N(() => {
|
|
@@ -31168,7 +31168,7 @@ const Gn = rt({
|
|
|
31168
31168
|
])
|
|
31169
31169
|
]) : null;
|
|
31170
31170
|
}, ja = () => {
|
|
31171
|
-
const { suffixIcon: X } = e, { inputValue: Ae } = h, Ke = n.suffix, ht = ne.value, It = B.value, Ct = P.value, Yt = z.value, Nt =
|
|
31171
|
+
const { suffixIcon: X } = e, { inputValue: Ae } = h, Ke = n.suffix, ht = ne.value, It = B.value, Ct = P.value, Yt = z.value, Nt = V.value, nt = ie.value, Ft = Yt || It || Ct || Nt;
|
|
31172
31172
|
return nt || Ke || X || Ft ? l("div", {
|
|
31173
31173
|
class: ["vxe-input--suffix", {
|
|
31174
31174
|
"is--clear": nt && !ht && !(Ae === "" || i.eqNull(Ae))
|
|
@@ -31193,7 +31193,7 @@ const Gn = rt({
|
|
|
31193
31193
|
]) : Fe()
|
|
31194
31194
|
]) : null;
|
|
31195
31195
|
}, zs = () => {
|
|
31196
|
-
const { controls: X } = e, Ae = B.value, Ke = P.value, ht = z.value, It =
|
|
31196
|
+
const { controls: X } = e, Ae = B.value, Ke = P.value, ht = z.value, It = V.value;
|
|
31197
31197
|
return ht ? wd() : Ae && X ? Zi() : Ke ? Bs() : It ? Ji() : Fe();
|
|
31198
31198
|
};
|
|
31199
31199
|
C = {
|
|
@@ -31674,7 +31674,7 @@ const Vr = rt({
|
|
|
31674
31674
|
}), H = N(() => Object.assign({}, e.optionProps)), U = N(() => Object.assign({}, e.optionGroupProps)), ne = N(() => H.value.label || "label"), j = N(() => H.value.value || "value"), L = N(() => U.value.label || "label"), B = N(() => U.value.options || "options"), ue = N(() => {
|
|
31675
31675
|
const { modelValue: Ie, multiple: ze, max: it } = e;
|
|
31676
31676
|
return ze && it ? (i.isArray(Ie) ? Ie.length : i.eqNull(Ie) ? 0 : 1) >= i.toNumber(it) : !1;
|
|
31677
|
-
}), Q = N(() => Object.assign({}, se().select.scrollY, e.scrollY)), P = N(() => Object.assign({}, se().select.optionConfig, e.optionConfig)), z = N(() => i.toNumber(e.multiCharOverflow)),
|
|
31677
|
+
}), Q = N(() => Object.assign({}, se().select.scrollY, e.scrollY)), P = N(() => Object.assign({}, se().select.optionConfig, e.optionConfig)), z = N(() => i.toNumber(e.multiCharOverflow)), V = N(() => {
|
|
31678
31678
|
const { modelValue: Ie, remote: ze, multiple: it } = e, Mt = z.value;
|
|
31679
31679
|
if (i.eqNull(Ie))
|
|
31680
31680
|
return "";
|
|
@@ -32006,7 +32006,7 @@ const Vr = rt({
|
|
|
32006
32006
|
}, e.emptyText || Re("vxe.select.emptyText"))
|
|
32007
32007
|
];
|
|
32008
32008
|
}, Bt = () => {
|
|
32009
|
-
const { className: Ie, popupClassName: ze, loading: it, filterable: Mt } = e, { initialized: At, isActivated: Qt, isAniVisible: Pt, visiblePanel: qt, bodyHeight: _t, topSpaceHeight: q } = v, on = E.value, rn = C.value, Mn =
|
|
32009
|
+
const { className: Ie, popupClassName: ze, loading: it, filterable: Mt } = e, { initialized: At, isActivated: Qt, isAniVisible: Pt, visiblePanel: qt, bodyHeight: _t, topSpaceHeight: q } = v, on = E.value, rn = C.value, Mn = V.value, In = M.value, Pn = x.value, pn = F.value, bn = n.default, Fn = n.header, vo = n.footer, Ro = n.prefix;
|
|
32010
32010
|
return Pn ? l("div", {
|
|
32011
32011
|
ref: d,
|
|
32012
32012
|
class: ["vxe-select--readonly", Ie]
|
|
@@ -32601,17 +32601,17 @@ const Vr = rt({
|
|
|
32601
32601
|
const { formConfig: I, widgetData: Z } = P;
|
|
32602
32602
|
I && D(I), Z && x(Z);
|
|
32603
32603
|
}
|
|
32604
|
-
const { activeWidget: z, widgetObjList:
|
|
32604
|
+
const { activeWidget: z, widgetObjList: V } = f;
|
|
32605
32605
|
if (z) {
|
|
32606
|
-
const I = i.findTree(
|
|
32607
|
-
I ? f.activeWidget = I.item : f.activeWidget =
|
|
32606
|
+
const I = i.findTree(V, (Z) => Z.id === z.id, { children: "children" });
|
|
32607
|
+
I ? f.activeWidget = I.item : f.activeWidget = V[0] || null;
|
|
32608
32608
|
} else
|
|
32609
|
-
f.activeWidget =
|
|
32609
|
+
f.activeWidget = V[0] || null;
|
|
32610
32610
|
return pe();
|
|
32611
32611
|
}, E = (P) => (M(), S(P)), v = () => i.clone(f.formData, !0), D = (P) => (f.formData = Object.assign({}, j(), P), pe()), y = (P) => {
|
|
32612
32612
|
const { widgetObjList: z } = f;
|
|
32613
32613
|
if (P) {
|
|
32614
|
-
const
|
|
32614
|
+
const V = i.toNumber(P), I = i.findTree(z, (Z) => Z && Z.id === V, { children: "children" });
|
|
32615
32615
|
if (I)
|
|
32616
32616
|
return I.item;
|
|
32617
32617
|
}
|
|
@@ -32625,8 +32625,8 @@ const Vr = rt({
|
|
|
32625
32625
|
const P = a.value;
|
|
32626
32626
|
return P && P.openStylePreview(), pe();
|
|
32627
32627
|
}, M = () => (f.widgetObjList = [], L(), pe()), F = {
|
|
32628
|
-
dispatchEvent(P, z,
|
|
32629
|
-
n(P, Jt(
|
|
32628
|
+
dispatchEvent(P, z, V) {
|
|
32629
|
+
n(P, Jt(V, { $xeFormDesign: g }, z));
|
|
32630
32630
|
},
|
|
32631
32631
|
createWidget: h,
|
|
32632
32632
|
createEmptyWidget: w,
|
|
@@ -32644,8 +32644,8 @@ const Vr = rt({
|
|
|
32644
32644
|
getWidgetById: y,
|
|
32645
32645
|
getFormData() {
|
|
32646
32646
|
const { widgetObjList: P } = f, z = {};
|
|
32647
|
-
return i.eachTree(P, (
|
|
32648
|
-
z[
|
|
32647
|
+
return i.eachTree(P, (V) => {
|
|
32648
|
+
z[V.field] = null;
|
|
32649
32649
|
}, { children: "children" }), z;
|
|
32650
32650
|
},
|
|
32651
32651
|
getWidgetData: b,
|
|
@@ -32656,7 +32656,7 @@ const Vr = rt({
|
|
|
32656
32656
|
},
|
|
32657
32657
|
openStyleSetting: C
|
|
32658
32658
|
}, H = () => {
|
|
32659
|
-
const { widgets: P } = e, z = [],
|
|
32659
|
+
const { widgets: P } = e, z = [], V = [], I = [], Z = [], ie = [];
|
|
32660
32660
|
$n.forEach((G, re) => {
|
|
32661
32661
|
const { createFormDesignWidgetConfig: ge } = G;
|
|
32662
32662
|
if (ge) {
|
|
@@ -32676,13 +32676,13 @@ const Vr = rt({
|
|
|
32676
32676
|
Z.push(De);
|
|
32677
32677
|
break;
|
|
32678
32678
|
default:
|
|
32679
|
-
["title"].includes(De.name) ||
|
|
32679
|
+
["title"].includes(De.name) || V.push(De);
|
|
32680
32680
|
break;
|
|
32681
32681
|
}
|
|
32682
32682
|
}
|
|
32683
|
-
}),
|
|
32683
|
+
}), V.length && z.push({
|
|
32684
32684
|
group: "base",
|
|
32685
|
-
children:
|
|
32685
|
+
children: V
|
|
32686
32686
|
}), I.length && z.push({
|
|
32687
32687
|
group: "layout",
|
|
32688
32688
|
children: I
|
|
@@ -32715,24 +32715,24 @@ const Vr = rt({
|
|
|
32715
32715
|
z && z.name && (P.stopPropagation(), f.activeWidget = z, F.dispatchEvent("click-widget", { widget: z }, P));
|
|
32716
32716
|
},
|
|
32717
32717
|
handleCopyWidget(P, z) {
|
|
32718
|
-
const { widgetObjList:
|
|
32718
|
+
const { widgetObjList: V } = f, I = i.findTree(V, (Z) => Z.id === z.id, { children: "children" });
|
|
32719
32719
|
if (I && (P.stopPropagation(), U(z.name))) {
|
|
32720
32720
|
const { path: Z } = I, ie = Number(Z[0]), G = h(z.name);
|
|
32721
|
-
G.title && (G.title = Re("vxe.formDesign.widget.copyTitle", [`${z.title}`.replace(Re("vxe.formDesign.widget.copyTitle", [""]), "")])), ie >=
|
|
32721
|
+
G.title && (G.title = Re("vxe.formDesign.widget.copyTitle", [`${z.title}`.replace(Re("vxe.formDesign.widget.copyTitle", [""]), "")])), ie >= V.length - 1 ? V.push(G) : V.splice(ie + 1, 0, G), f.activeWidget = G, f.widgetObjList = [...V], F.dispatchEvent("copy-widget", { widget: z, newWidget: G }, P);
|
|
32722
32722
|
}
|
|
32723
32723
|
},
|
|
32724
32724
|
handleRemoveWidget(P, z) {
|
|
32725
|
-
const { widgetObjList:
|
|
32725
|
+
const { widgetObjList: V } = f, I = i.findTree(V, (Z) => Z.id === z.id, { children: "children" });
|
|
32726
32726
|
if (I) {
|
|
32727
32727
|
const { index: Z, parent: ie, items: G } = I;
|
|
32728
|
-
P.stopPropagation(), Z >= G.length - 1 ? f.activeWidget = G[Z - 1] : f.activeWidget = G[Z + 1] || null, ie && ie.name === "row" ? G[Z] = w() : G.splice(Z, 1), f.widgetObjList = [...
|
|
32728
|
+
P.stopPropagation(), Z >= G.length - 1 ? f.activeWidget = G[Z - 1] : f.activeWidget = G[Z + 1] || null, ie && ie.name === "row" ? G[Z] = w() : G.splice(Z, 1), f.widgetObjList = [...V], F.dispatchEvent("remove-widget", { widget: z }, P);
|
|
32729
32729
|
}
|
|
32730
32730
|
}
|
|
32731
32731
|
}, j = () => {
|
|
32732
|
-
const { formRender: P, showPc: z, showMobile:
|
|
32732
|
+
const { formRender: P, showPc: z, showMobile: V } = e;
|
|
32733
32733
|
let I = g9({
|
|
32734
32734
|
pcVisible: z,
|
|
32735
|
-
mobileVisible:
|
|
32735
|
+
mobileVisible: V
|
|
32736
32736
|
});
|
|
32737
32737
|
if (P) {
|
|
32738
32738
|
const Z = $n.get(P.name), ie = Z ? Z.createFormDesignSettingFormConfig : null;
|
|
@@ -32776,11 +32776,11 @@ const Vr = rt({
|
|
|
32776
32776
|
])
|
|
32777
32777
|
]);
|
|
32778
32778
|
}, Q = () => {
|
|
32779
|
-
const { height: P, showHeader: z } = e,
|
|
32779
|
+
const { height: P, showHeader: z } = e, V = c.value, I = o.header, Z = o.footer;
|
|
32780
32780
|
return l("div", {
|
|
32781
32781
|
ref: s,
|
|
32782
32782
|
class: ["vxe-form-design", {
|
|
32783
|
-
[`size--${
|
|
32783
|
+
[`size--${V}`]: V
|
|
32784
32784
|
}],
|
|
32785
32785
|
style: P ? {
|
|
32786
32786
|
height: dn(P)
|
|
@@ -32995,9 +32995,9 @@ const ba = rt({
|
|
|
32995
32995
|
const L = b.value, { minRows: B, maxRows: ue } = L, Q = u.value;
|
|
32996
32996
|
if (!Q)
|
|
32997
32997
|
return;
|
|
32998
|
-
const P = Vl.clientHeight, z = getComputedStyle(Q),
|
|
32998
|
+
const P = Vl.clientHeight, z = getComputedStyle(Q), V = i.toNumber(z.lineHeight), I = i.toNumber(z.paddingTop), Z = i.toNumber(z.paddingBottom), ie = i.toNumber(z.borderTopWidth), G = i.toNumber(z.borderBottomWidth), re = I + Z + ie + G, ge = (P - re) / V, De = ge && /[0-9]/.test("" + ge) ? ge : Math.floor(ge) + 1;
|
|
32999
32999
|
let ae = De;
|
|
33000
|
-
De < B ? ae = B : De > ue && (ae = ue), Q.style.height = `${ae *
|
|
33000
|
+
De < B ? ae = B : De > ue && (ae = ue), Q.style.height = `${ae * V + re}px`;
|
|
33001
33001
|
});
|
|
33002
33002
|
}, M = (L) => {
|
|
33003
33003
|
const B = c.inputValue;
|
|
@@ -33033,7 +33033,7 @@ const ba = rt({
|
|
|
33033
33033
|
L && (x(), C());
|
|
33034
33034
|
});
|
|
33035
33035
|
const j = () => {
|
|
33036
|
-
const { className: L, resize: B, autosize: ue, showWordCount: Q, countMethod: P, rows: z, cols:
|
|
33036
|
+
const { className: L, resize: B, autosize: ue, showWordCount: Q, countMethod: P, rows: z, cols: V } = e, { inputValue: I } = c, Z = a.value, ie = w.value, G = y.value, re = D.value, ge = S.value, De = h.value, ae = E.value, _ = v.value;
|
|
33037
33037
|
return De ? l("div", {
|
|
33038
33038
|
ref: f,
|
|
33039
33039
|
class: ["vxe-textarea--readonly", L]
|
|
@@ -33045,7 +33045,7 @@ const ba = rt({
|
|
|
33045
33045
|
"is--count": Q,
|
|
33046
33046
|
"is--disabled": ie,
|
|
33047
33047
|
"is--rows": !i.eqNull(z),
|
|
33048
|
-
"is--cols": !i.eqNull(
|
|
33048
|
+
"is--cols": !i.eqNull(V)
|
|
33049
33049
|
}],
|
|
33050
33050
|
spellcheck: !1
|
|
33051
33051
|
}, [
|
|
@@ -33059,7 +33059,7 @@ const ba = rt({
|
|
|
33059
33059
|
readonly: ge,
|
|
33060
33060
|
disabled: ie,
|
|
33061
33061
|
rows: z,
|
|
33062
|
-
cols:
|
|
33062
|
+
cols: V,
|
|
33063
33063
|
style: B ? {
|
|
33064
33064
|
resize: B
|
|
33065
33065
|
} : null,
|
|
@@ -34916,7 +34916,7 @@ const E9 = (e) => Re(`vxe.formDesign.widget.component.${e}`), ko = (e) => E9(e.n
|
|
|
34916
34916
|
}, z = ($) => {
|
|
34917
34917
|
const Se = $.target.value;
|
|
34918
34918
|
P(Se, $);
|
|
34919
|
-
},
|
|
34919
|
+
}, V = ($) => {
|
|
34920
34920
|
F.value || ue($);
|
|
34921
34921
|
}, I = ($) => {
|
|
34922
34922
|
f.isActivated = !0, ue($);
|
|
@@ -35150,7 +35150,7 @@ const E9 = (e) => Re(`vxe.formDesign.widget.component.${e}`), ko = (e) => E9(e.n
|
|
|
35150
35150
|
onWheel: Ge,
|
|
35151
35151
|
onClick: at,
|
|
35152
35152
|
onInput: z,
|
|
35153
|
-
onChange:
|
|
35153
|
+
onChange: V,
|
|
35154
35154
|
onFocus: I,
|
|
35155
35155
|
onBlur: _
|
|
35156
35156
|
})
|
|
@@ -35889,7 +35889,7 @@ const wi = rt({
|
|
|
35889
35889
|
n("update:checkNodeKeys", $);
|
|
35890
35890
|
}, z = ($) => {
|
|
35891
35891
|
n("update:checkNodeKey", $);
|
|
35892
|
-
},
|
|
35892
|
+
}, V = ($) => ($ && (c.selectRadioKey = H($)), pe()), I = ($, te) => ($ && (i.isArray($) || ($ = [$]), ie($.map((Se) => H(Se)), te)), pe()), Z = ($, te) => ($ && (i.isArray($) || ($ = [$]), ie($, te)), pe()), ie = ($, te) => {
|
|
35893
35893
|
const Se = Object.assign({}, c.selectCheckboxMaps);
|
|
35894
35894
|
$.forEach((K) => {
|
|
35895
35895
|
te ? Se[K] = !0 : Se[K] && delete Se[K];
|
|
@@ -35953,7 +35953,7 @@ const wi = rt({
|
|
|
35953
35953
|
setRadioNodeId($) {
|
|
35954
35954
|
return c.selectRadioKey = $, pe();
|
|
35955
35955
|
},
|
|
35956
|
-
setRadioNode:
|
|
35956
|
+
setRadioNode: V,
|
|
35957
35957
|
setCheckboxNode: I,
|
|
35958
35958
|
setCheckboxByNodeId: Z,
|
|
35959
35959
|
getCheckboxNodeIds() {
|
|
@@ -36482,14 +36482,14 @@ const Ei = rt({
|
|
|
36482
36482
|
}), z = N(() => {
|
|
36483
36483
|
const xe = x.value, { height: Be, width: Oe } = xe, Me = {};
|
|
36484
36484
|
return Oe && (Me.width = dn(Oe)), Be && (Me.height = dn(Be), Me.maxHeight = dn(Be)), Me;
|
|
36485
|
-
}),
|
|
36485
|
+
}), V = {}, I = {
|
|
36486
36486
|
xID: u,
|
|
36487
36487
|
props: e,
|
|
36488
36488
|
context: t,
|
|
36489
36489
|
reactData: S,
|
|
36490
36490
|
internalData: E,
|
|
36491
36491
|
getRefMaps: () => v,
|
|
36492
|
-
getComputeMaps: () =>
|
|
36492
|
+
getComputeMaps: () => V
|
|
36493
36493
|
}, Z = (xe, Be, Oe) => {
|
|
36494
36494
|
n(xe, Jt(Oe, { $treeSelect: I }, Be));
|
|
36495
36495
|
}, ie = (xe) => {
|
|
@@ -37311,7 +37311,7 @@ const S7 = (e) => {
|
|
|
37311
37311
|
}, P = (A) => decodeURIComponent(`${A || ""}`).split("/").pop() || "", z = (A) => {
|
|
37312
37312
|
const ee = A ? A.indexOf(".") : -1;
|
|
37313
37313
|
return ee > -1 ? A.substring(ee + 1, A.length).toLowerCase() : "";
|
|
37314
|
-
},
|
|
37314
|
+
}, V = (A, ee, R) => {
|
|
37315
37315
|
n(A, Jt(R, { $upload: L }, ee));
|
|
37316
37316
|
}, I = (A) => {
|
|
37317
37317
|
const { singleMode: ee, urlMode: R } = e, J = D.value;
|
|
@@ -37369,10 +37369,10 @@ const S7 = (e) => {
|
|
|
37369
37369
|
}
|
|
37370
37370
|
})).then((Ee) => {
|
|
37371
37371
|
const { fileCacheMaps: $e } = u, Le = $e[J];
|
|
37372
|
-
Le && (Le.percent = 100), Object.assign(A, Ee),
|
|
37372
|
+
Le && (Le.percent = 100), Object.assign(A, Ee), V("upload-success", { option: A, data: Ee }, null);
|
|
37373
37373
|
}).catch((Ee) => {
|
|
37374
37374
|
const { fileCacheMaps: $e } = u, Le = $e[J];
|
|
37375
|
-
Le && (Le.status = "error"), R ? Object.assign(A, Ee) : u.fileList = u.fileList.filter((Qe) => ue(Qe) !== J),
|
|
37375
|
+
Le && (Le.status = "error"), R ? Object.assign(A, Ee) : u.fileList = u.fileList.filter((Qe) => ue(Qe) !== J), V("upload-error", { option: A, data: Ee }, null);
|
|
37376
37376
|
}).finally(() => {
|
|
37377
37377
|
const { fileCacheMaps: Ee } = u, $e = Ee[J];
|
|
37378
37378
|
$e && ($e.loading = !1);
|
|
@@ -37454,7 +37454,7 @@ const S7 = (e) => {
|
|
|
37454
37454
|
percent: 0
|
|
37455
37455
|
});
|
|
37456
37456
|
const At = kt(Mt);
|
|
37457
|
-
Ee && Bt.push(De(At, Ie)), en.push(At),
|
|
37457
|
+
Ee && Bt.push(De(At, Ie)), en.push(At), V("add", { option: At }, ee);
|
|
37458
37458
|
}), u.fileList = en, u.fileCacheMaps = yn, Promise.all(J ? Bt : []).then(() => {
|
|
37459
37459
|
I(en), r && s && r.triggerItemEvent(ee, s.itemConfig.field, en);
|
|
37460
37460
|
});
|
|
@@ -37473,7 +37473,7 @@ const S7 = (e) => {
|
|
|
37473
37473
|
});
|
|
37474
37474
|
}, we = (A, ee, R) => {
|
|
37475
37475
|
const { fileList: J } = u;
|
|
37476
|
-
J.splice(R, 1), I(J), r && s && r.triggerItemEvent(A, s.itemConfig.field, J),
|
|
37476
|
+
J.splice(R, 1), I(J), r && s && r.triggerItemEvent(A, s.itemConfig.field, J), V("remove", { option: ee }, A);
|
|
37477
37477
|
}, ve = (A, ee, R) => {
|
|
37478
37478
|
const J = e.beforeRemoveMethod || se().upload.beforeRemoveMethod, be = e.removeMethod || se().upload.removeMethod;
|
|
37479
37479
|
Promise.resolve(J ? J({
|
|
@@ -37485,10 +37485,10 @@ const S7 = (e) => {
|
|
|
37485
37485
|
option: ee
|
|
37486
37486
|
})).then(() => {
|
|
37487
37487
|
we(A, ee, R);
|
|
37488
|
-
}).catch(($e) => $e) : we(A, ee, R) :
|
|
37488
|
+
}).catch(($e) => $e) : we(A, ee, R) : V("remove-fail", { option: ee }, A);
|
|
37489
37489
|
});
|
|
37490
37490
|
}, de = (A, ee) => {
|
|
37491
|
-
|
|
37491
|
+
V("download", { option: ee }, A);
|
|
37492
37492
|
}, Ce = (A, ee) => {
|
|
37493
37493
|
const R = e.beforeDownloadMethod || se().upload.beforeDownloadMethod, J = e.downloadMethod || se().upload.downloadMethod;
|
|
37494
37494
|
Promise.resolve(R ? R({
|
|
@@ -37500,7 +37500,7 @@ const S7 = (e) => {
|
|
|
37500
37500
|
option: ee
|
|
37501
37501
|
})).then(() => {
|
|
37502
37502
|
de(A, ee);
|
|
37503
|
-
}).catch((Ee) => Ee) : de(A, ee) :
|
|
37503
|
+
}).catch((Ee) => Ee) : de(A, ee) : V("download-fail", { option: ee }, A);
|
|
37504
37504
|
});
|
|
37505
37505
|
}, je = (A) => {
|
|
37506
37506
|
const ee = A.currentTarget, { clientX: R, clientY: J } = A;
|
|
@@ -37610,7 +37610,7 @@ const S7 = (e) => {
|
|
|
37610
37610
|
u.isActivated = !1;
|
|
37611
37611
|
};
|
|
37612
37612
|
Object.assign(L, {
|
|
37613
|
-
dispatchEvent:
|
|
37613
|
+
dispatchEvent: V,
|
|
37614
37614
|
choose() {
|
|
37615
37615
|
return Y(null);
|
|
37616
37616
|
}
|
|
@@ -38357,33 +38357,33 @@ const S7 = (e) => {
|
|
|
38357
38357
|
getComputeMaps: () => D
|
|
38358
38358
|
}, b = (P) => {
|
|
38359
38359
|
n("update:modelValue", P);
|
|
38360
|
-
}, x = (P, z,
|
|
38361
|
-
n(P, Jt(
|
|
38360
|
+
}, x = (P, z, V) => {
|
|
38361
|
+
n(P, Jt(V, { $slider: y }, z));
|
|
38362
38362
|
}, C = {
|
|
38363
38363
|
dispatchEvent: x
|
|
38364
38364
|
}, M = (P) => {
|
|
38365
|
-
const { range: z } = e,
|
|
38366
|
-
return z ? i.floor((P - I) / i.toNumber(
|
|
38365
|
+
const { range: z } = e, V = E.value, I = v.value;
|
|
38366
|
+
return z ? i.floor((P - I) / i.toNumber(V - I) * 100) : 0;
|
|
38367
38367
|
}, F = (P, z) => {
|
|
38368
|
-
const { range:
|
|
38369
|
-
return i.floor((z - (
|
|
38368
|
+
const { range: V } = e, I = E.value, Z = v.value;
|
|
38369
|
+
return i.floor((z - (V ? P : 0) - Z) / i.toNumber(I - Z) * 100);
|
|
38370
38370
|
}, H = () => {
|
|
38371
38371
|
const { modelValue: P } = e;
|
|
38372
38372
|
if (i.isArray(P)) {
|
|
38373
|
-
const [z,
|
|
38374
|
-
g.startValue = i.floor(i.toNumber(z || 0)), g.endValue = i.floor(i.toNumber(
|
|
38373
|
+
const [z, V] = i.clone(P, !0).sort();
|
|
38374
|
+
g.startValue = i.floor(i.toNumber(z || 0)), g.endValue = i.floor(i.toNumber(V || 0));
|
|
38375
38375
|
} else
|
|
38376
38376
|
g.startValue = 0, g.endValue = i.floor(i.toNumber(P || 0));
|
|
38377
38377
|
}, U = () => {
|
|
38378
|
-
const { startValue: P, endValue: z } = g,
|
|
38378
|
+
const { startValue: P, endValue: z } = g, V = u.value, I = d.value, Z = p.value;
|
|
38379
38379
|
let ie = 0, G = 0;
|
|
38380
|
-
P > z ? (ie = M(z), G = F(z, P)) : (ie = M(P), G = F(P, z)),
|
|
38380
|
+
P > z ? (ie = M(z), G = F(z, P)) : (ie = M(P), G = F(P, z)), V && (V.style.left = `${ie}%`, V.style.width = `${G}%`), I && (I.style.left = `${ie}%`), Z && (Z.style.left = `${i.floor(ie + G)}%`);
|
|
38381
38381
|
}, ne = (P) => {
|
|
38382
|
-
const { range: z } = e, { startValue:
|
|
38382
|
+
const { range: z } = e, { startValue: V, endValue: I } = g, Z = z ? [V, I].sort() : I;
|
|
38383
38383
|
b(Z), x("change", { value: Z }, P), o && r && o.triggerItemEvent(P, r.itemConfig.field, Z);
|
|
38384
38384
|
}, j = (P, z) => {
|
|
38385
|
-
const
|
|
38386
|
-
if (!(
|
|
38385
|
+
const V = w.value, I = S.value, Z = E.value, ie = v.value;
|
|
38386
|
+
if (!(V || I)) {
|
|
38387
38387
|
P.preventDefault();
|
|
38388
38388
|
const G = document.onmousemove, re = document.onmouseup;
|
|
38389
38389
|
document.onmousemove = (ge) => {
|
|
@@ -38399,19 +38399,19 @@ const S7 = (e) => {
|
|
|
38399
38399
|
};
|
|
38400
38400
|
}
|
|
38401
38401
|
}, L = (P) => {
|
|
38402
|
-
const z = p.value,
|
|
38403
|
-
j(P, z ? z.offsetLeft <
|
|
38402
|
+
const z = p.value, V = P.currentTarget;
|
|
38403
|
+
j(P, z ? z.offsetLeft < V.offsetLeft : !1);
|
|
38404
38404
|
}, B = (P) => {
|
|
38405
|
-
const z = d.value,
|
|
38406
|
-
j(P, z ?
|
|
38405
|
+
const z = d.value, V = P.currentTarget;
|
|
38406
|
+
j(P, z ? V.offsetLeft > z.offsetLeft : !0);
|
|
38407
38407
|
};
|
|
38408
38408
|
Object.assign(y, C, {});
|
|
38409
38409
|
const Q = () => {
|
|
38410
|
-
const { vertical: P, range: z } = e,
|
|
38410
|
+
const { vertical: P, range: z } = e, V = a.value, I = w.value, Z = S.value;
|
|
38411
38411
|
return l("div", {
|
|
38412
38412
|
ref: c,
|
|
38413
38413
|
class: ["vxe-slider", {
|
|
38414
|
-
[`size--${
|
|
38414
|
+
[`size--${V}`]: V,
|
|
38415
38415
|
"is--vertical": P,
|
|
38416
38416
|
"is--readonly": I,
|
|
38417
38417
|
"is--disabled": Z
|
|
@@ -38864,7 +38864,7 @@ const tu = rt({
|
|
|
38864
38864
|
ae.preventDefault(), d.visiblePanel ? ne() : U();
|
|
38865
38865
|
}, z = (ae) => {
|
|
38866
38866
|
P(ae), v.dispatchEvent("click", {}, ae);
|
|
38867
|
-
},
|
|
38867
|
+
}, V = (ae) => {
|
|
38868
38868
|
const { visiblePanel: _ } = d;
|
|
38869
38869
|
if (!y.value && _) {
|
|
38870
38870
|
const oe = w.value;
|
|
@@ -39022,7 +39022,7 @@ const tu = rt({
|
|
|
39022
39022
|
return ot(() => e.modelValue, (ae) => {
|
|
39023
39023
|
d.selectIcon = `${ae || ""}`;
|
|
39024
39024
|
}), Dn(() => {
|
|
39025
|
-
ct.on(E, "mousewheel",
|
|
39025
|
+
ct.on(E, "mousewheel", V), ct.on(E, "mousedown", I), ct.on(E, "keydown", Z), ct.on(E, "blur", ie);
|
|
39026
39026
|
}), Wn(() => {
|
|
39027
39027
|
ct.off(E, "mousewheel"), ct.off(E, "mousedown"), ct.off(E, "keydown"), ct.off(E, "blur");
|
|
39028
39028
|
}), Cn("$xeIconPicker", E), E.renderVN = De, E;
|
|
@@ -39246,7 +39246,7 @@ const Ti = rt({
|
|
|
39246
39246
|
e.maskClosable && G.target === G.currentTarget && S("close", {}, G);
|
|
39247
39247
|
};
|
|
39248
39248
|
Object.assign(w, E, y);
|
|
39249
|
-
const
|
|
39249
|
+
const V = () => {
|
|
39250
39250
|
const { activeIndex: G } = a, re = p.value, ge = g.value;
|
|
39251
39251
|
return l("div", {
|
|
39252
39252
|
class: "vxe-image-preview--img-list",
|
|
@@ -39358,7 +39358,7 @@ const Ti = rt({
|
|
|
39358
39358
|
}],
|
|
39359
39359
|
onWheel: ue
|
|
39360
39360
|
}, [
|
|
39361
|
-
|
|
39361
|
+
V(),
|
|
39362
39362
|
Z()
|
|
39363
39363
|
]);
|
|
39364
39364
|
};
|
|
@@ -40891,7 +40891,7 @@ const Vi = (e) => Object.assign({
|
|
|
40891
40891
|
const Q = [];
|
|
40892
40892
|
L.forEach((P) => {
|
|
40893
40893
|
if (i.isObject(P) && P.default) {
|
|
40894
|
-
const z = p.find((
|
|
40894
|
+
const z = p.find((V) => V.code === P.code);
|
|
40895
40895
|
z && Q.push(Vi({
|
|
40896
40896
|
type: z.type,
|
|
40897
40897
|
code: z.code
|
|
@@ -41039,7 +41039,7 @@ const uu = rt({
|
|
|
41039
41039
|
// 默认一行合计
|
|
41040
41040
|
]
|
|
41041
41041
|
}), d = N(() => {
|
|
41042
|
-
const { gridOptions: Q } = e, { formConfig: P, tableColumns: z, searchFormData:
|
|
41042
|
+
const { gridOptions: Q } = e, { formConfig: P, tableColumns: z, searchFormData: V, searchFormItems: I, footerData: Z } = u, { showStatistics: ie } = P, G = Q || {}, re = Object.assign({
|
|
41043
41043
|
minWidth: 120
|
|
41044
41044
|
}, G.columnConfig);
|
|
41045
41045
|
let ge;
|
|
@@ -41049,15 +41049,15 @@ const uu = rt({
|
|
|
41049
41049
|
showFooter: ie,
|
|
41050
41050
|
footerData: ie ? Z : null,
|
|
41051
41051
|
formConfig: {
|
|
41052
|
-
data:
|
|
41052
|
+
data: V,
|
|
41053
41053
|
items: I
|
|
41054
41054
|
},
|
|
41055
41055
|
proxyConfig: ge
|
|
41056
41056
|
});
|
|
41057
41057
|
}), p = N(() => {
|
|
41058
41058
|
const { gridEvents: Q } = e, P = {};
|
|
41059
|
-
return i.each(Q, (z,
|
|
41060
|
-
P[i.camelCase(`on-${
|
|
41059
|
+
return i.each(Q, (z, V) => {
|
|
41060
|
+
P[i.camelCase(`on-${V}`)] = z;
|
|
41061
41061
|
}), P;
|
|
41062
41062
|
}), g = {
|
|
41063
41063
|
refElem: a,
|
|
@@ -41075,23 +41075,23 @@ const uu = rt({
|
|
|
41075
41075
|
$n.forEach((Q, P) => {
|
|
41076
41076
|
const { createListDesignSettingActionButtonConfig: z } = Q;
|
|
41077
41077
|
if (z) {
|
|
41078
|
-
const
|
|
41078
|
+
const V = { name: P }, I = Object.assign(Vi({ code: P }), z(V));
|
|
41079
41079
|
I.type === "custom" || S.push(I);
|
|
41080
41080
|
}
|
|
41081
41081
|
});
|
|
41082
41082
|
const E = (Q) => {
|
|
41083
41083
|
if (Q && Q.length) {
|
|
41084
|
-
const P = {}, z = Q.map((
|
|
41085
|
-
field:
|
|
41086
|
-
title:
|
|
41087
|
-
folding:
|
|
41088
|
-
itemRender:
|
|
41084
|
+
const P = {}, z = Q.map((V) => (P[V.field] = null, {
|
|
41085
|
+
field: V.field,
|
|
41086
|
+
title: V.title,
|
|
41087
|
+
folding: V.folding,
|
|
41088
|
+
itemRender: V.itemRender
|
|
41089
41089
|
}));
|
|
41090
41090
|
return z.push({
|
|
41091
41091
|
field: "active",
|
|
41092
41092
|
title: "",
|
|
41093
41093
|
folding: !1,
|
|
41094
|
-
collapseNode: Q.some((
|
|
41094
|
+
collapseNode: Q.some((V) => V.folding),
|
|
41095
41095
|
itemRender: {
|
|
41096
41096
|
name: "VxeButtonGroup",
|
|
41097
41097
|
options: [
|
|
@@ -41123,13 +41123,13 @@ const uu = rt({
|
|
|
41123
41123
|
]
|
|
41124
41124
|
}), pe()), y = (Q) => {
|
|
41125
41125
|
if (Q) {
|
|
41126
|
-
const { formConfig: P, searchItems: z, listColumns:
|
|
41127
|
-
u.formConfig = P || {}, ne(z || []), U(
|
|
41126
|
+
const { formConfig: P, searchItems: z, listColumns: V } = Q;
|
|
41127
|
+
u.formConfig = P || {}, ne(z || []), U(V || []);
|
|
41128
41128
|
}
|
|
41129
41129
|
return pe();
|
|
41130
41130
|
}, b = (Q) => E(Q || []), x = (Q, P) => {
|
|
41131
|
-
const z = Object.assign({}, P), { showSeq:
|
|
41132
|
-
if (
|
|
41131
|
+
const z = Object.assign({}, P), { showSeq: V, actionButtonList: I } = z, Z = [], ie = {}, G = r.cellAction, re = r.footerCell;
|
|
41132
|
+
if (V && Z.push({
|
|
41133
41133
|
type: "seq",
|
|
41134
41134
|
field: "_seq",
|
|
41135
41135
|
fixed: "left",
|
|
@@ -41186,7 +41186,7 @@ const uu = rt({
|
|
|
41186
41186
|
}
|
|
41187
41187
|
return { rowRecord: ie, columns: Z, actionButtons: I };
|
|
41188
41188
|
}, C = (Q) => {
|
|
41189
|
-
const { formConfig: P, searchItems: z, listColumns:
|
|
41189
|
+
const { formConfig: P, searchItems: z, listColumns: V } = Q || {}, { columns: I, rowRecord: Z, actionButtons: ie } = x(V || [], P || u.formConfig), { data: G, items: re } = b(z || []);
|
|
41190
41190
|
return {
|
|
41191
41191
|
formData: G,
|
|
41192
41192
|
formItems: re,
|
|
@@ -41200,12 +41200,12 @@ const uu = rt({
|
|
|
41200
41200
|
return P;
|
|
41201
41201
|
}
|
|
41202
41202
|
if (Q) {
|
|
41203
|
-
const { formConfig: P, listColumns: z } = Q, { rowRecord:
|
|
41204
|
-
return
|
|
41203
|
+
const { formConfig: P, listColumns: z } = Q, { rowRecord: V } = x(z || [], P || u.formConfig);
|
|
41204
|
+
return V;
|
|
41205
41205
|
}
|
|
41206
41206
|
return {};
|
|
41207
41207
|
}, F = () => {
|
|
41208
|
-
const { searchFormData: Q, searchFormItems: P } = u, z = [],
|
|
41208
|
+
const { searchFormData: Q, searchFormItems: P } = u, z = [], V = {
|
|
41209
41209
|
items: z,
|
|
41210
41210
|
type: "and"
|
|
41211
41211
|
};
|
|
@@ -41223,13 +41223,13 @@ const uu = rt({
|
|
|
41223
41223
|
type: "and"
|
|
41224
41224
|
});
|
|
41225
41225
|
}
|
|
41226
|
-
}),
|
|
41226
|
+
}), V;
|
|
41227
41227
|
}, H = (Q, ...P) => {
|
|
41228
41228
|
const z = c.value;
|
|
41229
41229
|
return z ? z.commitProxy(Q, ...P) : Promise.resolve();
|
|
41230
41230
|
}, U = (Q) => {
|
|
41231
|
-
const { formConfig: P } = u, z = Q || [], { columns:
|
|
41232
|
-
u.listTableColumns = z, u.tableColumns =
|
|
41231
|
+
const { formConfig: P } = u, z = Q || [], { columns: V, actionButtons: I } = x(z, P);
|
|
41232
|
+
u.listTableColumns = z, u.tableColumns = V, o("update:actionButtons", I), pe(() => {
|
|
41233
41233
|
d.value.proxyConfig && H("reload");
|
|
41234
41234
|
});
|
|
41235
41235
|
}, ne = (Q) => {
|
|
@@ -41248,7 +41248,7 @@ const uu = rt({
|
|
|
41248
41248
|
commitProxy: H
|
|
41249
41249
|
}, {});
|
|
41250
41250
|
const ue = () => {
|
|
41251
|
-
const { height: Q, loading: P } = e, z = f.value,
|
|
41251
|
+
const { height: Q, loading: P } = e, z = f.value, V = r.grid, I = d.value, Z = p.value;
|
|
41252
41252
|
return l("div", {
|
|
41253
41253
|
ref: a,
|
|
41254
41254
|
class: ["vxe-list-view", {
|
|
@@ -41262,9 +41262,9 @@ const uu = rt({
|
|
|
41262
41262
|
l("div", {
|
|
41263
41263
|
class: "vxe-list-view--body"
|
|
41264
41264
|
}, [
|
|
41265
|
-
|
|
41265
|
+
V ? l("div", {
|
|
41266
41266
|
class: "vxe-list-view--grid-wrapper"
|
|
41267
|
-
}, Rt(
|
|
41267
|
+
}, Rt(V({ $listView: w }))) : n ? l(n, Object.assign({}, I, Z, {
|
|
41268
41268
|
ref: c
|
|
41269
41269
|
}), Object.assign({}, r, {
|
|
41270
41270
|
default: void 0
|
|
@@ -41353,8 +41353,8 @@ const du = rt({
|
|
|
41353
41353
|
v(), E();
|
|
41354
41354
|
}, y = () => pe().then(() => {
|
|
41355
41355
|
const { scrollYLoad: B } = a, { scrollYStore: ue } = c, Q = d.value, P = h.value;
|
|
41356
|
-
let z = 0,
|
|
41357
|
-
if (Q && (P.sItem && (
|
|
41356
|
+
let z = 0, V;
|
|
41357
|
+
if (Q && (P.sItem && (V = Q.querySelector(P.sItem)), V || (V = Q.children[0])), V && (z = V.offsetHeight), z = Math.max(20, z), ue.rowHeight = z, B) {
|
|
41358
41358
|
const I = u.value, Z = Math.max(8, Math.ceil(I.clientHeight / z)), ie = P.oSize ? i.toNumber(P.oSize) : b5.edge ? 10 : 0;
|
|
41359
41359
|
ue.offsetSize = ie, ue.visibleSize = Z, ue.endIndex = Math.max(ue.startIndex, Z + ie, ue.endIndex), D();
|
|
41360
41360
|
} else
|
|
@@ -41381,11 +41381,11 @@ const du = rt({
|
|
|
41381
41381
|
const B = f.value;
|
|
41382
41382
|
return B.clientWidth && B.clientHeight ? y() : Promise.resolve();
|
|
41383
41383
|
}, F = (B) => {
|
|
41384
|
-
const { scrollYStore: ue } = c, { startIndex: Q, endIndex: P, visibleSize: z, offsetSize:
|
|
41384
|
+
const { scrollYStore: ue } = c, { startIndex: Q, endIndex: P, visibleSize: z, offsetSize: V, rowHeight: I } = ue, ie = B.target.scrollTop, G = Math.floor(ie / I), re = Math.max(0, G - 1 - V), ge = G + z + V;
|
|
41385
41385
|
(G <= Q || G >= P - z - 1) && (Q !== re || P !== ge) && (ue.startIndex = re, ue.endIndex = ge, D());
|
|
41386
41386
|
}, H = (B) => {
|
|
41387
|
-
const ue = B.target, Q = ue.scrollTop, P = ue.scrollLeft, z = P !== c.lastScrollLeft,
|
|
41388
|
-
c.lastScrollTop = Q, c.lastScrollLeft = P, a.scrollYLoad && F(B), S("scroll", { scrollLeft: P, scrollTop: Q, isX: z, isY:
|
|
41387
|
+
const ue = B.target, Q = ue.scrollTop, P = ue.scrollLeft, z = P !== c.lastScrollLeft, V = Q !== c.lastScrollTop;
|
|
41388
|
+
c.lastScrollTop = Q, c.lastScrollLeft = P, a.scrollYLoad && F(B), S("scroll", { scrollLeft: P, scrollTop: Q, isX: z, isY: V }, B);
|
|
41389
41389
|
}, U = (B) => {
|
|
41390
41390
|
const { scrollYStore: ue } = c, Q = h.value, P = B || [];
|
|
41391
41391
|
return Object.assign(ue, {
|
|
@@ -41435,7 +41435,7 @@ const du = rt({
|
|
|
41435
41435
|
B && B.disconnect(), ct.off(g, "resize");
|
|
41436
41436
|
});
|
|
41437
41437
|
const L = () => {
|
|
41438
|
-
const { className: B, loading: ue } = e, { bodyHeight: Q, topSpaceHeight: P, items: z } = a,
|
|
41438
|
+
const { className: B, loading: ue } = e, { bodyHeight: Q, topSpaceHeight: P, items: z } = a, V = n.default, I = s.value, Z = w.value;
|
|
41439
41439
|
return l("div", {
|
|
41440
41440
|
ref: f,
|
|
41441
41441
|
class: ["vxe-list", B ? i.isFunction(B) ? B({ $list: g }) : B : "", {
|
|
@@ -41461,7 +41461,7 @@ const du = rt({
|
|
|
41461
41461
|
style: {
|
|
41462
41462
|
marginTop: P ? `${P}px` : ""
|
|
41463
41463
|
}
|
|
41464
|
-
},
|
|
41464
|
+
}, V ? V({ items: z, $list: g }) : [])
|
|
41465
41465
|
]),
|
|
41466
41466
|
/**
|
|
41467
41467
|
* 加载中
|
|
@@ -41540,26 +41540,26 @@ const fu = rt({
|
|
|
41540
41540
|
}, S = (z) => `${z.title || z.name}`, E = () => {
|
|
41541
41541
|
f.collapseZindex < _r() && (f.collapseZindex = Mr());
|
|
41542
41542
|
}, v = (z) => {
|
|
41543
|
-
const { activeName:
|
|
41543
|
+
const { activeName: V } = f;
|
|
41544
41544
|
i.eachTree(f.menuList, (I, Z, ie, G, re, ge) => {
|
|
41545
|
-
I.itemKey ===
|
|
41545
|
+
I.itemKey === V ? (ge.forEach((De) => {
|
|
41546
41546
|
De.isActive = !0, z && (De.isExpand = !0);
|
|
41547
41547
|
}), I.isExactActive = !0) : (I.isExactActive = !1, I.isActive = !1);
|
|
41548
41548
|
}, { children: "childList" });
|
|
41549
41549
|
}, D = () => {
|
|
41550
|
-
const { options: z, expandAll:
|
|
41551
|
-
f.menuList = i.mapTree(z, (I, Z, ie, G, re) => Object.assign(Object.assign({}, I), { parentKey: re ? re.name || G.slice(0, G.length - 1).join(",") : "", level: G.length, itemKey: I.name || G.join(","), isExactActive: !1, isActive: !1, isExpand: i.isBoolean(I.expanded) ? I.expanded : !!
|
|
41550
|
+
const { options: z, expandAll: V } = e;
|
|
41551
|
+
f.menuList = i.mapTree(z, (I, Z, ie, G, re) => Object.assign(Object.assign({}, I), { parentKey: re ? re.name || G.slice(0, G.length - 1).join(",") : "", level: G.length, itemKey: I.name || G.join(","), isExactActive: !1, isActive: !1, isExpand: i.isBoolean(I.expanded) ? I.expanded : !!V, hasChild: I.children && I.children.length > 0 }), { children: "children", mapChildren: "childList" });
|
|
41552
41552
|
}, y = () => {
|
|
41553
41553
|
const { collapseFixed: z } = e;
|
|
41554
41554
|
z && pe(() => {
|
|
41555
|
-
const { isEnterCollapse:
|
|
41555
|
+
const { isEnterCollapse: V } = f, I = d.value, Z = g.value, ie = p.value, G = s.value;
|
|
41556
41556
|
if (G) {
|
|
41557
41557
|
const re = G.getBoundingClientRect(), ge = G.parentNode;
|
|
41558
41558
|
f.collapseStyle = I ? {
|
|
41559
41559
|
top: dn(re.top),
|
|
41560
41560
|
left: dn(re.left),
|
|
41561
41561
|
height: dn(ge.clientHeight),
|
|
41562
|
-
width:
|
|
41562
|
+
width: V ? Z ? dn(Z) : "" : ie ? dn(ie) : "",
|
|
41563
41563
|
zIndex: f.collapseZindex
|
|
41564
41564
|
} : {};
|
|
41565
41565
|
}
|
|
@@ -41567,44 +41567,44 @@ const fu = rt({
|
|
|
41567
41567
|
}, b = () => {
|
|
41568
41568
|
const { collapseFixed: z } = e;
|
|
41569
41569
|
if (z) {
|
|
41570
|
-
const { initialized:
|
|
41571
|
-
d.value && (
|
|
41570
|
+
const { initialized: V } = f;
|
|
41571
|
+
d.value && (V || (f.initialized = !0, pe(() => {
|
|
41572
41572
|
const Z = a.value;
|
|
41573
41573
|
Z && document.body.appendChild(Z);
|
|
41574
41574
|
}))), f.isEnterCollapse = !1, E(), y();
|
|
41575
41575
|
}
|
|
41576
|
-
}, x = (z,
|
|
41577
|
-
const { hasChild: I, isExpand: Z } =
|
|
41578
|
-
I && (z.stopPropagation(), z.preventDefault(),
|
|
41576
|
+
}, x = (z, V) => {
|
|
41577
|
+
const { hasChild: I, isExpand: Z } = V;
|
|
41578
|
+
I && (z.stopPropagation(), z.preventDefault(), V.isExpand = !Z);
|
|
41579
41579
|
}, C = (z) => {
|
|
41580
41580
|
f.activeName = z, n("update:modelValue", z);
|
|
41581
|
-
}, M = (z,
|
|
41582
|
-
const { itemKey: I, routerLink: Z, hasChild: ie } =
|
|
41583
|
-
Z ? (C(I), H()) : ie ? x(z,
|
|
41581
|
+
}, M = (z, V) => {
|
|
41582
|
+
const { itemKey: I, routerLink: Z, hasChild: ie } = V;
|
|
41583
|
+
Z ? (C(I), H()) : ie ? x(z, V) : (C(I), H()), U("click", { menu: V }, z);
|
|
41584
41584
|
}, F = () => {
|
|
41585
|
-
const { collapseStyle: z } = f,
|
|
41585
|
+
const { collapseStyle: z } = f, V = g.value;
|
|
41586
41586
|
f.collapseStyle = Object.assign({}, z, {
|
|
41587
|
-
width:
|
|
41587
|
+
width: V ? dn(V) : ""
|
|
41588
41588
|
}), f.isEnterCollapse = !0;
|
|
41589
41589
|
}, H = () => {
|
|
41590
|
-
const { collapseStyle: z } = f,
|
|
41590
|
+
const { collapseStyle: z } = f, V = s.value;
|
|
41591
41591
|
f.collapseStyle = Object.assign({}, z, {
|
|
41592
|
-
width:
|
|
41592
|
+
width: V ? dn(V.offsetWidth) : ""
|
|
41593
41593
|
}), f.isEnterCollapse = !1;
|
|
41594
|
-
}, U = (z,
|
|
41595
|
-
n(z, Jt(I, { $menu: w },
|
|
41594
|
+
}, U = (z, V, I) => {
|
|
41595
|
+
n(z, Jt(I, { $menu: w }, V));
|
|
41596
41596
|
};
|
|
41597
41597
|
Object.assign(w, {
|
|
41598
41598
|
dispatchEvent: U
|
|
41599
41599
|
}, {});
|
|
41600
41600
|
const L = (z) => {
|
|
41601
|
-
const { icon:
|
|
41601
|
+
const { icon: V, isExpand: I, hasChild: Z } = z, ie = S(z);
|
|
41602
41602
|
return [
|
|
41603
41603
|
l("span", {
|
|
41604
41604
|
class: "vxe-menu--item-link-icon"
|
|
41605
|
-
},
|
|
41605
|
+
}, V ? [
|
|
41606
41606
|
l("i", {
|
|
41607
|
-
class:
|
|
41607
|
+
class: V
|
|
41608
41608
|
})
|
|
41609
41609
|
] : []),
|
|
41610
41610
|
l("span", {
|
|
@@ -41623,9 +41623,9 @@ const fu = rt({
|
|
|
41623
41623
|
]) : Fe()
|
|
41624
41624
|
];
|
|
41625
41625
|
}, B = (z) => {
|
|
41626
|
-
const { itemKey:
|
|
41626
|
+
const { itemKey: V, level: I, hasChild: Z, isActive: ie, isExactActive: G, isExpand: re, routerLink: ge, childList: De } = z, { isEnterCollapse: ae } = f, _ = d.value;
|
|
41627
41627
|
return z.permissionCode && !Pi.checkVisible(z.permissionCode) ? Fe() : l("div", {
|
|
41628
|
-
key:
|
|
41628
|
+
key: V,
|
|
41629
41629
|
class: ["vxe-menu--item-wrapper", `vxe-menu--item-level${I}`, {
|
|
41630
41630
|
"is--exact-active": G,
|
|
41631
41631
|
"is--active": ie,
|
|
@@ -41651,9 +41651,9 @@ const fu = rt({
|
|
|
41651
41651
|
}, De.map((Y) => B(Y))) : Fe()
|
|
41652
41652
|
]);
|
|
41653
41653
|
}, ue = (z) => {
|
|
41654
|
-
const { itemKey:
|
|
41654
|
+
const { itemKey: V, level: I, hasChild: Z, isActive: ie, isExactActive: G, routerLink: re, childList: ge } = z;
|
|
41655
41655
|
return z.permissionCode && !Pi.checkVisible(z.permissionCode) ? Fe() : l("div", {
|
|
41656
|
-
key:
|
|
41656
|
+
key: V,
|
|
41657
41657
|
class: ["vxe-menu--item-wrapper", `vxe-menu--item-level${I}`, {
|
|
41658
41658
|
"is--exact-active": G,
|
|
41659
41659
|
"is--active": ie
|
|
@@ -41678,7 +41678,7 @@ const fu = rt({
|
|
|
41678
41678
|
}, ge.map((De) => B(De))) : Fe()
|
|
41679
41679
|
]);
|
|
41680
41680
|
}, Q = () => {
|
|
41681
|
-
const { loading: z } = e, { initialized:
|
|
41681
|
+
const { loading: z } = e, { initialized: V, menuList: I, collapseStyle: Z, isEnterCollapse: ie } = f, G = c.value, re = d.value;
|
|
41682
41682
|
return l("div", {
|
|
41683
41683
|
ref: s,
|
|
41684
41684
|
class: ["vxe-menu", {
|
|
@@ -41690,7 +41690,7 @@ const fu = rt({
|
|
|
41690
41690
|
l("div", {
|
|
41691
41691
|
class: "vxe-menu--item-list"
|
|
41692
41692
|
}, I.map((ge) => re ? ue(ge) : B(ge))),
|
|
41693
|
-
|
|
41693
|
+
V ? l("div", {
|
|
41694
41694
|
ref: a,
|
|
41695
41695
|
class: ["vxe-menu--collapse-wrapper", {
|
|
41696
41696
|
[`size--${G}`]: G,
|
|
@@ -41733,8 +41733,8 @@ const fu = rt({
|
|
|
41733
41733
|
ct.off(w, "resize");
|
|
41734
41734
|
const z = a.value;
|
|
41735
41735
|
if (z) {
|
|
41736
|
-
const
|
|
41737
|
-
|
|
41736
|
+
const V = z.parentNode;
|
|
41737
|
+
V && V.removeChild(z);
|
|
41738
41738
|
}
|
|
41739
41739
|
}), D(), v(!0), w.renderVN = Q, w;
|
|
41740
41740
|
},
|
|
@@ -42267,7 +42267,7 @@ const hu = rt({
|
|
|
42267
42267
|
class: ["vxe-pager--btn-icon", e.iconEndPage || xt().PAGER_END]
|
|
42268
42268
|
})
|
|
42269
42269
|
]);
|
|
42270
|
-
},
|
|
42270
|
+
}, V = (_) => {
|
|
42271
42271
|
const { currentPage: Y, pagerCount: oe } = e, we = [], ve = d.value, de = p.value, Ce = g.value, je = ve > oe, Ye = je && Y > Ce + 1, lt = je && Y < ve - Ce;
|
|
42272
42272
|
let He = 1;
|
|
42273
42273
|
return je && (Y >= ve - Ce ? He = Math.max(ve - de.length + 1, 1) : He = Math.max(Y - Ce, 1)), _ && Ye && we.push(l("button", {
|
|
@@ -42291,7 +42291,7 @@ const hu = rt({
|
|
|
42291
42291
|
}, ve)), l("span", {
|
|
42292
42292
|
class: "vxe-pager--btn-wrapper"
|
|
42293
42293
|
}, we);
|
|
42294
|
-
}, I = () =>
|
|
42294
|
+
}, I = () => V(!0), Z = () => {
|
|
42295
42295
|
const _ = h.value;
|
|
42296
42296
|
return l(Vr, {
|
|
42297
42297
|
class: "vxe-pager--sizes",
|
|
@@ -42388,7 +42388,7 @@ const hu = rt({
|
|
|
42388
42388
|
je = B;
|
|
42389
42389
|
break;
|
|
42390
42390
|
case "Number":
|
|
42391
|
-
je =
|
|
42391
|
+
je = V;
|
|
42392
42392
|
break;
|
|
42393
42393
|
case "JumpNumber":
|
|
42394
42394
|
je = I;
|
|
@@ -42514,72 +42514,72 @@ const vu = rt({
|
|
|
42514
42514
|
};
|
|
42515
42515
|
let h = {};
|
|
42516
42516
|
const w = N(() => e.clearable), S = N(() => {
|
|
42517
|
-
const { readonly:
|
|
42518
|
-
return
|
|
42517
|
+
const { readonly: V } = e;
|
|
42518
|
+
return V;
|
|
42519
42519
|
}), E = N(() => {
|
|
42520
|
-
const { placeholder:
|
|
42521
|
-
if (
|
|
42522
|
-
return Un(
|
|
42520
|
+
const { placeholder: V } = e;
|
|
42521
|
+
if (V)
|
|
42522
|
+
return Un(V);
|
|
42523
42523
|
const I = se().passwordInput.placeholder;
|
|
42524
42524
|
return I ? Un(I) : Re("vxe.base.pleaseInput");
|
|
42525
42525
|
}), v = N(() => {
|
|
42526
|
-
const { showPwd:
|
|
42527
|
-
return
|
|
42526
|
+
const { showPwd: V } = f;
|
|
42527
|
+
return V ? "text" : "password";
|
|
42528
42528
|
}), D = N(() => {
|
|
42529
|
-
const { immediate:
|
|
42530
|
-
return
|
|
42531
|
-
}), y = (
|
|
42529
|
+
const { immediate: V } = e;
|
|
42530
|
+
return V;
|
|
42531
|
+
}), y = (V) => {
|
|
42532
42532
|
const { inputValue: I } = f;
|
|
42533
|
-
h.dispatchEvent(
|
|
42534
|
-
}, b = (
|
|
42533
|
+
h.dispatchEvent(V.type, { value: I }, V);
|
|
42534
|
+
}, b = (V, I) => {
|
|
42535
42535
|
const Z = D.value;
|
|
42536
|
-
f.inputValue =
|
|
42537
|
-
}, x = (
|
|
42538
|
-
const Z =
|
|
42539
|
-
b(Z,
|
|
42540
|
-
}, C = (
|
|
42541
|
-
f.inputValue =
|
|
42542
|
-
}, M = (
|
|
42543
|
-
y(
|
|
42536
|
+
f.inputValue = V, Z ? C(V, I) : h.dispatchEvent("input", { value: V }, I);
|
|
42537
|
+
}, x = (V) => {
|
|
42538
|
+
const Z = V.target.value;
|
|
42539
|
+
b(Z, V);
|
|
42540
|
+
}, C = (V, I) => {
|
|
42541
|
+
f.inputValue = V, n("update:modelValue", V), h.dispatchEvent("input", { value: V }, I), i.toValueString(e.modelValue) !== V && (h.dispatchEvent("change", { value: V }, I), r && s && r.triggerItemEvent(I, s.itemConfig.field, V));
|
|
42542
|
+
}, M = (V) => {
|
|
42543
|
+
y(V);
|
|
42544
42544
|
const { inputValue: I } = f;
|
|
42545
|
-
r && s && r.triggerItemEvent(
|
|
42546
|
-
}, F = (
|
|
42547
|
-
f.isActivated = !0, y(
|
|
42548
|
-
}, H = (
|
|
42545
|
+
r && s && r.triggerItemEvent(V, s.itemConfig.field, I);
|
|
42546
|
+
}, F = (V) => {
|
|
42547
|
+
f.isActivated = !0, y(V);
|
|
42548
|
+
}, H = (V) => {
|
|
42549
42549
|
const { inputValue: I } = f, Z = I;
|
|
42550
|
-
h.dispatchEvent("blur", { value: Z },
|
|
42551
|
-
}, U = (
|
|
42550
|
+
h.dispatchEvent("blur", { value: Z }, V), r && s && r.triggerItemEvent(V, s.itemConfig.field, Z);
|
|
42551
|
+
}, U = (V) => {
|
|
42552
42552
|
const { readonly: I, disabled: Z } = e, { showPwd: ie } = f;
|
|
42553
|
-
!Z && !I && (f.showPwd = !ie), h.dispatchEvent("toggle-visible", { visible: f.showPwd },
|
|
42554
|
-
}, ne = (
|
|
42555
|
-
y(
|
|
42556
|
-
}, j = (
|
|
42557
|
-
focus(), C("",
|
|
42558
|
-
}, L = (
|
|
42553
|
+
!Z && !I && (f.showPwd = !ie), h.dispatchEvent("toggle-visible", { visible: f.showPwd }, V);
|
|
42554
|
+
}, ne = (V) => {
|
|
42555
|
+
y(V);
|
|
42556
|
+
}, j = (V, I) => {
|
|
42557
|
+
focus(), C("", V), h.dispatchEvent("clear", { value: I }, V);
|
|
42558
|
+
}, L = (V) => {
|
|
42559
42559
|
const { disabled: I } = e;
|
|
42560
42560
|
if (!I) {
|
|
42561
42561
|
const { inputValue: Z } = f;
|
|
42562
|
-
h.dispatchEvent("suffix-click", { value: Z },
|
|
42562
|
+
h.dispatchEvent("suffix-click", { value: Z }, V);
|
|
42563
42563
|
}
|
|
42564
|
-
}, B = (
|
|
42564
|
+
}, B = (V) => {
|
|
42565
42565
|
const { disabled: I } = e;
|
|
42566
42566
|
if (!I) {
|
|
42567
42567
|
const { inputValue: Z } = f;
|
|
42568
|
-
h.dispatchEvent("prefix-click", { value: Z },
|
|
42568
|
+
h.dispatchEvent("prefix-click", { value: Z }, V);
|
|
42569
42569
|
}
|
|
42570
42570
|
}, ue = () => {
|
|
42571
|
-
const { showPwd:
|
|
42571
|
+
const { showPwd: V } = f;
|
|
42572
42572
|
return l("div", {
|
|
42573
42573
|
class: "vxe-password-input--control-icon",
|
|
42574
42574
|
onClick: U
|
|
42575
42575
|
}, [
|
|
42576
42576
|
l("i", {
|
|
42577
|
-
class: ["vxe-password-input--password-icon",
|
|
42577
|
+
class: ["vxe-password-input--password-icon", V ? xt().PASSWORD_INPUT_SHOW_PWD : xt().PASSWORD_INPUT_HIDE_PWD]
|
|
42578
42578
|
})
|
|
42579
42579
|
]);
|
|
42580
42580
|
}, Q = () => {
|
|
42581
|
-
const { prefixIcon:
|
|
42582
|
-
return I ||
|
|
42581
|
+
const { prefixIcon: V } = e, I = o.prefix;
|
|
42582
|
+
return I || V ? l("div", {
|
|
42583
42583
|
class: "vxe-password-input--prefix",
|
|
42584
42584
|
onClick: B
|
|
42585
42585
|
}, [
|
|
@@ -42587,15 +42587,15 @@ const vu = rt({
|
|
|
42587
42587
|
class: "vxe-password-input--prefix-icon"
|
|
42588
42588
|
}, I ? Rt(I({})) : [
|
|
42589
42589
|
l("i", {
|
|
42590
|
-
class:
|
|
42590
|
+
class: V
|
|
42591
42591
|
})
|
|
42592
42592
|
])
|
|
42593
42593
|
]) : null;
|
|
42594
42594
|
}, P = () => {
|
|
42595
|
-
const { disabled:
|
|
42595
|
+
const { disabled: V, suffixIcon: I, controls: Z } = e, { inputValue: ie } = f, G = o.suffix, re = w.value;
|
|
42596
42596
|
return re || Z || G || I ? l("div", {
|
|
42597
42597
|
class: ["vxe-password-input--suffix", {
|
|
42598
|
-
"is--clear": re && !
|
|
42598
|
+
"is--clear": re && !V && !(ie === "" || i.eqNull(ie))
|
|
42599
42599
|
}]
|
|
42600
42600
|
}, [
|
|
42601
42601
|
re ? l("div", {
|
|
@@ -42618,12 +42618,12 @@ const vu = rt({
|
|
|
42618
42618
|
]) : null;
|
|
42619
42619
|
};
|
|
42620
42620
|
h = {
|
|
42621
|
-
dispatchEvent(
|
|
42622
|
-
n(
|
|
42621
|
+
dispatchEvent(V, I, Z) {
|
|
42622
|
+
n(V, Jt(Z, { $passwordInput: g }, I));
|
|
42623
42623
|
},
|
|
42624
42624
|
focus() {
|
|
42625
|
-
const
|
|
42626
|
-
return f.isActivated = !0,
|
|
42625
|
+
const V = d.value;
|
|
42626
|
+
return f.isActivated = !0, V.focus(), pe();
|
|
42627
42627
|
},
|
|
42628
42628
|
blur() {
|
|
42629
42629
|
return d.value.blur(), f.isActivated = !1, pe();
|
|
@@ -42631,14 +42631,14 @@ const vu = rt({
|
|
|
42631
42631
|
select() {
|
|
42632
42632
|
return d.value.select(), f.isActivated = !1, pe();
|
|
42633
42633
|
}
|
|
42634
|
-
}, Object.assign(g, h), ot(() => e.modelValue, (
|
|
42635
|
-
f.inputValue =
|
|
42634
|
+
}, Object.assign(g, h), ot(() => e.modelValue, (V) => {
|
|
42635
|
+
f.inputValue = V;
|
|
42636
42636
|
});
|
|
42637
42637
|
const z = () => {
|
|
42638
|
-
const { className:
|
|
42638
|
+
const { className: V, name: I, disabled: Z, readonly: ie, autocomplete: G, autoComplete: re, maxLength: ge } = e, { inputValue: De, isActivated: ae } = f, _ = c.value, Y = S.value, oe = v.value, we = E.value, ve = w.value, de = Q(), Ce = P();
|
|
42639
42639
|
return l("div", {
|
|
42640
42640
|
ref: u,
|
|
42641
|
-
class: ["vxe-password-input",
|
|
42641
|
+
class: ["vxe-password-input", V, {
|
|
42642
42642
|
[`size--${_}`]: _,
|
|
42643
42643
|
"is--prefix": !!de,
|
|
42644
42644
|
"is--suffix": !!Ce,
|
|
@@ -43071,8 +43071,8 @@ const yu = rt({
|
|
|
43071
43071
|
const y = () => {
|
|
43072
43072
|
d.panelIndex < _r() && (d.panelIndex = Mr());
|
|
43073
43073
|
}, b = () => d.visiblePanel, x = () => pe().then(() => {
|
|
43074
|
-
const { placement: P } = e, { panelIndex: z, visiblePanel:
|
|
43075
|
-
if (
|
|
43074
|
+
const { placement: P } = e, { panelIndex: z, visiblePanel: V } = d, I = S.value;
|
|
43075
|
+
if (V) {
|
|
43076
43076
|
const Z = h.value, ie = w.value;
|
|
43077
43077
|
if (ie && Z) {
|
|
43078
43078
|
const G = Z.offsetHeight, re = Z.offsetWidth, ge = ie.offsetHeight, De = ie.offsetWidth, ae = 5, _ = {
|
|
@@ -43114,15 +43114,15 @@ const yu = rt({
|
|
|
43114
43114
|
const { trigger: z } = e;
|
|
43115
43115
|
z === "click" && (d.visiblePanel ? (M(), B("hide-panel", {}, P)) : (C(), B("show-panel", {}, P))), B("click", { $pulldown: v }, P);
|
|
43116
43116
|
}, ne = (P) => {
|
|
43117
|
-
const { disabled: z } = e, { visiblePanel:
|
|
43118
|
-
z ||
|
|
43117
|
+
const { disabled: z } = e, { visiblePanel: V } = d, I = w.value;
|
|
43118
|
+
z || V && (Kn(P, I).flag ? x() : (M(), B("hide-panel", {}, P)));
|
|
43119
43119
|
}, j = (P) => {
|
|
43120
|
-
const { disabled: z } = e, { visiblePanel:
|
|
43121
|
-
z || (d.isActivated = Kn(P, I).flag || Kn(P, Z).flag,
|
|
43120
|
+
const { disabled: z } = e, { visiblePanel: V } = d, I = g.value, Z = w.value;
|
|
43121
|
+
z || (d.isActivated = Kn(P, I).flag || Kn(P, Z).flag, V && !d.isActivated && (M(), B("hide-panel", {}, P)));
|
|
43122
43122
|
}, L = (P) => {
|
|
43123
43123
|
d.visiblePanel && (d.isActivated = !1, M(), B("hide-panel", {}, P));
|
|
43124
|
-
}, B = (P, z,
|
|
43125
|
-
o(P, Jt(
|
|
43124
|
+
}, B = (P, z, V) => {
|
|
43125
|
+
o(P, Jt(V, { $pulldown: v }, z));
|
|
43126
43126
|
};
|
|
43127
43127
|
D = {
|
|
43128
43128
|
dispatchEvent: B,
|
|
@@ -43141,14 +43141,14 @@ const yu = rt({
|
|
|
43141
43141
|
const z = n.option;
|
|
43142
43142
|
return l("div", {
|
|
43143
43143
|
class: "vxe-pulldown--panel-list"
|
|
43144
|
-
}, P ? P.map((
|
|
43144
|
+
}, P ? P.map((V) => l("div", {
|
|
43145
43145
|
class: "vxe-pulldown--panel-item",
|
|
43146
43146
|
onClick(I) {
|
|
43147
|
-
H(I,
|
|
43147
|
+
H(I, V);
|
|
43148
43148
|
}
|
|
43149
|
-
}, z ? z({ $pulldown: v, option:
|
|
43149
|
+
}, z ? z({ $pulldown: v, option: V }) : `${V.label || ""}`)) : []);
|
|
43150
43150
|
}, Q = () => {
|
|
43151
|
-
const { className: P, options: z, popupClassName:
|
|
43151
|
+
const { className: P, options: z, popupClassName: V, showPopupShadow: I, destroyOnClose: Z, disabled: ie } = e, { initialized: G, isActivated: re, isAniVisible: ge, visiblePanel: De, panelStyle: ae, panelPlacement: _ } = d, Y = S.value, oe = u.value, we = n.default, ve = n.header, de = n.footer, Ce = n.dropdown;
|
|
43152
43152
|
return l("div", {
|
|
43153
43153
|
ref: g,
|
|
43154
43154
|
class: ["vxe-pulldown", P ? i.isFunction(P) ? P({ $pulldown: v }) : P : "", {
|
|
@@ -43169,7 +43169,7 @@ const yu = rt({
|
|
|
43169
43169
|
}, [
|
|
43170
43170
|
l("div", {
|
|
43171
43171
|
ref: w,
|
|
43172
|
-
class: ["vxe-table--ignore-clear vxe-pulldown--panel",
|
|
43172
|
+
class: ["vxe-table--ignore-clear vxe-pulldown--panel", V ? i.isFunction(V) ? V({ $pulldown: v }) : V : "", {
|
|
43173
43173
|
[`size--${oe}`]: oe,
|
|
43174
43174
|
"is--shadow": I,
|
|
43175
43175
|
"is--transfer": Y,
|
|
@@ -43490,7 +43490,7 @@ const Eu = rt({
|
|
|
43490
43490
|
getComputeMaps: () => Q
|
|
43491
43491
|
}, z = (ke, xe, Be) => {
|
|
43492
43492
|
n(ke, Jt(Be, { $tableSelect: P }, xe));
|
|
43493
|
-
},
|
|
43493
|
+
}, V = (ke) => {
|
|
43494
43494
|
n("update:modelValue", ke);
|
|
43495
43495
|
}, I = {
|
|
43496
43496
|
dispatchEvent: z
|
|
@@ -43560,7 +43560,7 @@ const Eu = rt({
|
|
|
43560
43560
|
}, 350);
|
|
43561
43561
|
}, we = (ke, xe) => {
|
|
43562
43562
|
const { fullRowMaps: Be } = v;
|
|
43563
|
-
if (
|
|
43563
|
+
if (V(xe), xe !== e.modelValue) {
|
|
43564
43564
|
const Oe = Be[xe];
|
|
43565
43565
|
z("change", { value: xe, row: Oe ? Oe.item : null }, ke), f && u && f.triggerItemEvent(ke, u.itemConfig.field, xe);
|
|
43566
43566
|
}
|
|
@@ -44628,8 +44628,16 @@ const uJ = (e) => {
|
|
|
44628
44628
|
controls: !1,
|
|
44629
44629
|
onBlur() {
|
|
44630
44630
|
Math.round(ue.__table__seq - 1e-3) != Q && (ue.__table__seq = ue.__table__seq - 1e-3, t.tableRef.reactData.customColumnList.sort((P, z) => {
|
|
44631
|
-
if (
|
|
44632
|
-
return
|
|
44631
|
+
if (P.field === "sab-table-seq")
|
|
44632
|
+
return -1;
|
|
44633
|
+
if (z.field === "sab-table-seq")
|
|
44634
|
+
return 1;
|
|
44635
|
+
if (P.field === "sab-table-checkbox")
|
|
44636
|
+
return -1;
|
|
44637
|
+
if (z.field === "sab-table-checkbox")
|
|
44638
|
+
return 1;
|
|
44639
|
+
const V = P.__table__seq ?? -1 / 0, I = z.__table__seq ?? -1 / 0;
|
|
44640
|
+
return V - I;
|
|
44633
44641
|
}));
|
|
44634
44642
|
}
|
|
44635
44643
|
})
|
|
@@ -44679,10 +44687,10 @@ const uJ = (e) => {
|
|
|
44679
44687
|
offsetIndex: z
|
|
44680
44688
|
} = ue;
|
|
44681
44689
|
t.tableRef.reactData.isCustomStatus = !0;
|
|
44682
|
-
const
|
|
44683
|
-
|
|
44684
|
-
const Z =
|
|
44685
|
-
|
|
44690
|
+
const V = t.tableRef.reactData.customColumnList || [], I = V.findIndex((ie) => ie.id === P.id);
|
|
44691
|
+
V.splice(I, 1);
|
|
44692
|
+
const Z = V.findIndex((ie) => ie.id === Q.id);
|
|
44693
|
+
V.splice(Z + z, 0, P);
|
|
44686
44694
|
};
|
|
44687
44695
|
return (ue, Q) => (_n(), Vo(Fs, null, [Zt(Ps, {
|
|
44688
44696
|
height: "auto",
|
|
@@ -44739,9 +44747,9 @@ const uJ = (e) => {
|
|
|
44739
44747
|
}
|
|
44740
44748
|
}, {
|
|
44741
44749
|
default: Ln(() => {
|
|
44742
|
-
var z,
|
|
44750
|
+
var z, V, I, Z, ie, G, re, ge, De, ae, _, Y;
|
|
44743
44751
|
return [Zt(nn(Nd), {
|
|
44744
|
-
label: (Z = (I = (
|
|
44752
|
+
label: (Z = (I = (V = (z = nn(n)) == null ? void 0 : z.sabDesign) == null ? void 0 : V.table) == null ? void 0 : I.set) == null ? void 0 : Z.fixedLeft,
|
|
44745
44753
|
value: "left"
|
|
44746
44754
|
}, null, 8, ["label"]), Zt(nn(Nd), {
|
|
44747
44755
|
label: (ge = (re = (G = (ie = nn(n)) == null ? void 0 : ie.sabDesign) == null ? void 0 : G.table) == null ? void 0 : re.set) == null ? void 0 : ge.fixedNone,
|