zhihao-ui 1.2.71 → 1.2.72
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/{BaseItem-CEFYU-vZ.js → BaseItem-CcDWBfoz.js} +1 -1
- package/dist/es/{CascaderLoadMore-1ENwzKY8.js → CascaderLoadMore-Cs9tSDmi.js} +93 -93
- package/dist/es/{DatePicker-DvSoaSq9.js → DatePicker-OFa_X3SK.js} +1 -1
- package/dist/es/{DetailHeader-70m7dEou.js → DetailHeader-CqZEznN3.js} +1 -1
- package/dist/es/{DetailSubTitle-CqcoW7Qc.js → DetailSubTitle-CMZHFO7G.js} +1 -1
- package/dist/es/{DiyDataTable-bO--1zPQ.js → DiyDataTable-xIPNp8SM.js} +1 -1
- package/dist/es/{EditInfoPair-CIN0LGcX.js → EditInfoPair-D4OdVVv0.js} +1 -1
- package/dist/es/{FileWrapper-kRc7s3wS.js → FileWrapper-CaI9Two-.js} +1 -1
- package/dist/es/{Grid-YHrIHuuu.js → Grid-gC33_S4r.js} +1 -1
- package/dist/es/{InfoPair-Dg0qbY3Z.js → InfoPair-DqDXekp4.js} +1 -1
- package/dist/es/{Map-BURr7_36.js → Map-C1pKJIU2.js} +1 -1
- package/dist/es/{MoneyInput-n52E-q_5.js → MoneyInput-CyuL9f-x.js} +1 -1
- package/dist/es/{Table-Cr4k_o89.js → Table-HzWLO4s5.js} +411 -401
- package/dist/es/index.js +15 -15
- package/dist/index.css +1 -1
- package/dist/types/components/CascaderLoadMore/CascaderLoadMore.vue.d.ts +2 -0
- package/dist/types/components/CascaderLoadMore/index.d.ts +5 -0
- package/dist/types/components/Dialog/Dialog.vue.d.ts +6 -6
- package/dist/types/components/Dialog/index.d.ts +9 -9
- package/dist/types/components/Map/function/drawLine.d.ts +1 -1
- package/dist/types/components/Table/utils.d.ts +4 -0
- package/dist/umd/index.css +1 -1
- package/dist/umd/index.umd.cjs +16 -2
- package/package.json +1 -1
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
import { reactive as te, computed as
|
|
2
|
-
import { a3 as
|
|
3
|
-
import { D as ae, C as jt } from "./BaseItem-
|
|
4
|
-
import { Z as
|
|
1
|
+
import { reactive as te, computed as D, toRefs as Ae, ref as I, defineComponent as le, useCssVars as dt, inject as Ue, openBlock as y, createElementBlock as M, createBlock as L, resolveDynamicComponent as fe, mergeProps as Y, withKeys as pt, unref as i, createSlots as me, withCtx as S, Fragment as J, renderList as ge, renderSlot as K, createElementVNode as $, toDisplayString as X, createCommentVNode as z, createVNode as w, withModifiers as ht, normalizeClass as Ze, createTextVNode as Q, useSlots as Ke, isVNode as ft, normalizeProps as We, guardReactiveProps as je, nextTick as ve, onMounted as mt, onActivated as gt, onDeactivated as vt, onUnmounted as bt, watch as Ct, provide as yt, resolveDirective as St, withDirectives as we, vShow as wt, toHandlers as kt } from "vue";
|
|
2
|
+
import { a3 as Ne, a4 as _t, a5 as Pt, a6 as qe, a7 as Tt, n as Et, a8 as $t, q as Bt, a9 as zt, a2 as be, b as Te, a as Ce, aa as Mt, ab as Ft, p as re, ac as It, ad as Lt, ae as Vt, af as xe, ag as He, e as G, o as Je, ah as Le, ai as Dt, aj as Ye, ak as Rt, al as Ot, am as At, an as Ut, E as ke, ao as Zt, m as Kt, ap as Wt, aq as Ve, ar as De } from "./vendor-9390iK3y.js";
|
|
3
|
+
import { D as ae, C as jt } from "./BaseItem-CcDWBfoz.js";
|
|
4
|
+
import { Z as Nt } from "./CascaderLoadMore-Cs9tSDmi.js";
|
|
5
5
|
import { _ as se, Z as _e } from "./Button-BdGo3Kfv.js";
|
|
6
|
-
import { _ as
|
|
7
|
-
import { w as
|
|
8
|
-
const
|
|
9
|
-
function
|
|
10
|
-
return g.reduce((m,
|
|
6
|
+
import { _ as qt } from "./Dialog-Cib_m5sM.js";
|
|
7
|
+
import { w as xt } from "./utils-UjENBVnX.js";
|
|
8
|
+
const Ht = 12;
|
|
9
|
+
function Ee(g, p, a, f) {
|
|
10
|
+
return g.reduce((m, C) => {
|
|
11
11
|
if (m) return m;
|
|
12
|
-
if (
|
|
13
|
-
if (
|
|
12
|
+
if (C[a] === p) return C;
|
|
13
|
+
if (C[f]) return Ee(C[f], p, a, f);
|
|
14
14
|
}, null);
|
|
15
15
|
}
|
|
16
|
-
function
|
|
17
|
-
const f = Pt(a) ? ae : a, m =
|
|
16
|
+
function Jt(g, p, a) {
|
|
17
|
+
const f = Pt(a) ? ae : a, m = Ne(g, p);
|
|
18
18
|
return _t(m) || m === "" ? f : m;
|
|
19
19
|
}
|
|
20
|
-
const
|
|
21
|
-
function
|
|
22
|
-
const
|
|
23
|
-
return
|
|
20
|
+
const Re = Jt;
|
|
21
|
+
function R(g) {
|
|
22
|
+
const p = g.split(".");
|
|
23
|
+
return p.length == 1 ? g : p[p.length - 1];
|
|
24
24
|
}
|
|
25
|
-
function Oe(g,
|
|
26
|
-
const m = (a == null ? void 0 : a.value) ?? "value",
|
|
25
|
+
function Oe(g, p, a, f) {
|
|
26
|
+
const m = (a == null ? void 0 : a.value) ?? "value", C = (a == null ? void 0 : a.label) ?? "label", t = (a == null ? void 0 : a.children) ?? "children";
|
|
27
27
|
let b = {};
|
|
28
|
-
return Array.isArray(
|
|
28
|
+
return Array.isArray(p) && (b = Ee(p, g, m, t)), f == "tag" ? b != null && b.tagType ? b.tagType : "" : b ? b[C] : ae;
|
|
29
29
|
}
|
|
30
|
-
function
|
|
30
|
+
function Yt(g, p, a) {
|
|
31
31
|
const f = "value", m = "children";
|
|
32
|
-
let
|
|
33
|
-
return Array.isArray(
|
|
32
|
+
let C = {};
|
|
33
|
+
return Array.isArray(p) && (C = Ee(p, g, f, m)), C;
|
|
34
34
|
}
|
|
35
|
-
function
|
|
36
|
-
return
|
|
35
|
+
function Gt(g) {
|
|
36
|
+
return qe(g) ? g.length ? g.join(" / ") : ae : g ?? ae;
|
|
37
37
|
}
|
|
38
|
-
function he(g,
|
|
39
|
-
return
|
|
38
|
+
function he(g, p) {
|
|
39
|
+
return p.includes(".") ? (p.split(".").forEach((a) => g = g[a] ?? ae), g) : g[p] ?? ae;
|
|
40
40
|
}
|
|
41
|
-
const oe = (g,
|
|
42
|
-
const a =
|
|
41
|
+
const oe = (g, p) => {
|
|
42
|
+
const a = p || Ht, m = document.createElement("canvas").getContext("2d");
|
|
43
43
|
return m.font = `${a}px Microsoft YaHei`, m.measureText(g).width;
|
|
44
|
-
},
|
|
45
|
-
const
|
|
46
|
-
const b = localStorage.getItem(
|
|
44
|
+
}, Qt = (g) => {
|
|
45
|
+
const p = g || "zhihao-col-setting", a = () => {
|
|
46
|
+
const b = localStorage.getItem(p);
|
|
47
47
|
return b ? JSON.parse(b) : {};
|
|
48
48
|
}, f = (b) => {
|
|
49
|
-
localStorage.setItem(
|
|
49
|
+
localStorage.setItem(p, JSON.stringify(b));
|
|
50
50
|
};
|
|
51
51
|
return {
|
|
52
52
|
getMap: a,
|
|
@@ -61,7 +61,21 @@ const oe = (g, d) => {
|
|
|
61
61
|
delete n[b], f(n);
|
|
62
62
|
}
|
|
63
63
|
};
|
|
64
|
-
}, Xt =
|
|
64
|
+
}, Xt = `<g clip-path="url(#clip0_94_5585)">
|
|
65
|
+
<path d="M9.48792 55.1851C11.0631 55.1851 12.3401 53.9081 12.3401 52.3329C12.3401 50.7577 11.0631 49.4807 9.48792 49.4807C7.91271 49.4807 6.63574 50.7577 6.63574 52.3329C6.63574 53.9081 7.91271 55.1851 9.48792 55.1851Z" fill="#9CBEFC"/>
|
|
66
|
+
<path d="M2.44202 35.4087C4.01723 35.4087 5.2942 34.1317 5.2942 32.5565C5.2942 30.9813 4.01723 29.7043 2.44202 29.7043C0.866808 29.7043 -0.410156 30.9813 -0.410156 32.5565C-0.410156 34.1317 0.866808 35.4087 2.44202 35.4087Z" fill="#9CBEFC"/>
|
|
67
|
+
<path d="M9.48799 16.7354C11.859 16.7354 13.7812 14.8133 13.7812 12.4422C13.7812 10.0712 11.859 8.14907 9.48799 8.14907C7.11694 8.14907 5.19482 10.0712 5.19482 12.4422C5.19482 14.8133 7.11694 16.7354 9.48799 16.7354Z" fill="#9CBEFC"/>
|
|
68
|
+
<path d="M29.2644 63.7615C31.6354 63.7615 33.5575 61.8394 33.5575 59.4683C33.5575 57.0973 31.6354 55.1752 29.2644 55.1752C26.8933 55.1752 24.9712 57.0973 24.9712 59.4683C24.9712 61.8394 26.8933 63.7615 29.2644 63.7615Z" fill="#9CBEFC"/>
|
|
69
|
+
<path d="M49.5177 57.7491C52.509 57.7491 54.9339 55.3242 54.9339 52.3329C54.9339 49.3417 52.509 46.9168 49.5177 46.9168C46.5265 46.9168 44.1016 49.3417 44.1016 52.3329C44.1016 55.3242 46.5265 57.7491 49.5177 57.7491Z" fill="#9CBEFC"/>
|
|
70
|
+
<path d="M29.2643 10.8323C32.2555 10.8323 34.6804 8.40741 34.6804 5.41615C34.6804 2.4249 32.2555 0 29.2643 0C26.273 0 23.8481 2.4249 23.8481 5.41615C23.8481 8.40741 26.273 10.8323 29.2643 10.8323Z" fill="#9CBEFC"/>
|
|
71
|
+
<path d="M48.9613 20.4422C53.1106 20.4422 56.4743 17.0785 56.4743 12.9292C56.4743 8.77985 53.1106 5.41615 48.9613 5.41615C44.8119 5.41615 41.4482 8.77985 41.4482 12.9292C41.4482 17.0785 44.8119 20.4422 48.9613 20.4422Z" fill="#9CBEFC"/>
|
|
72
|
+
<path d="M56.4744 39.672C60.4042 39.672 63.5899 36.4863 63.5899 32.5565C63.5899 28.6267 60.4042 25.441 56.4744 25.441C52.5446 25.441 49.3589 28.6267 49.3589 32.5565C49.3589 36.4863 52.5446 39.672 56.4744 39.672Z" fill="#9CBEFC"/>
|
|
73
|
+
</g>
|
|
74
|
+
<defs>
|
|
75
|
+
<clipPath id="clip0_94_5585">
|
|
76
|
+
<rect width="64" height="64" fill="white"/>
|
|
77
|
+
</clipPath>
|
|
78
|
+
</defs>`, ea = (g, p = {}, a = !0, f, m, C = (t) => t) => {
|
|
65
79
|
const t = te({
|
|
66
80
|
// 表格数据
|
|
67
81
|
tableData: [],
|
|
@@ -82,7 +96,7 @@ const oe = (g, d) => {
|
|
|
82
96
|
totalParam: {},
|
|
83
97
|
// 是否在加载中
|
|
84
98
|
loading: !1
|
|
85
|
-
}), b =
|
|
99
|
+
}), b = D({
|
|
86
100
|
get: () => ({
|
|
87
101
|
page: t.pageable.page,
|
|
88
102
|
size: t.pageable.size
|
|
@@ -96,19 +110,13 @@ const oe = (g, d) => {
|
|
|
96
110
|
return;
|
|
97
111
|
}
|
|
98
112
|
try {
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
for (const u in t.searchParam)
|
|
107
|
-
t.searchParam[u] === "" && delete t.searchParam[u];
|
|
108
|
-
let e = await g(y({ ...t.searchInitParam, ...t.totalParam }));
|
|
109
|
-
if (f && (e = await f(e)), t.tableData = a ? e.list : e, a) {
|
|
110
|
-
const { currentPage: u, pageSize: s, total: l } = e;
|
|
111
|
-
W({ page: u, size: s, total: l });
|
|
113
|
+
Object.assign(t.totalParam, p, a ? b.value : {});
|
|
114
|
+
for (const e in t.searchParam)
|
|
115
|
+
t.searchParam[e] === "" && delete t.searchParam[e];
|
|
116
|
+
let T = await g(C({ ...t.searchInitParam, ...t.totalParam }));
|
|
117
|
+
if (f && (T = await f(T)), t.tableData = a ? T.list : T, a) {
|
|
118
|
+
const { currentPage: e, pageSize: c, total: s } = T;
|
|
119
|
+
W({ page: e, size: c, total: s });
|
|
112
120
|
}
|
|
113
121
|
} catch (T) {
|
|
114
122
|
m && m(T);
|
|
@@ -116,7 +124,7 @@ const oe = (g, d) => {
|
|
|
116
124
|
t.loading = !1;
|
|
117
125
|
}
|
|
118
126
|
}, h = () => {
|
|
119
|
-
t.totalParam = {}, t.searchInitParam = {},
|
|
127
|
+
t.totalParam = {}, t.searchInitParam = {}, p = {};
|
|
120
128
|
const T = {};
|
|
121
129
|
for (const e in t.searchParam)
|
|
122
130
|
(t.searchParam[e] || t.searchParam[e] === !1 || t.searchParam[e] === 0) && (T[e] = t.searchParam[e]);
|
|
@@ -125,9 +133,9 @@ const oe = (g, d) => {
|
|
|
125
133
|
Object.assign(t.pageable, T);
|
|
126
134
|
}, A = () => {
|
|
127
135
|
t.pageable.page = 1, h(), n().then();
|
|
128
|
-
},
|
|
136
|
+
}, x = () => {
|
|
129
137
|
t.pageable.page = 1, t.searchParam = { ...t.searchInitParam }, h(), n().then();
|
|
130
|
-
},
|
|
138
|
+
}, H = (T) => {
|
|
131
139
|
t.pageable.page = 1, t.pageable.size = T, n().then();
|
|
132
140
|
}, O = (T) => {
|
|
133
141
|
t.pageable.page = T, n().then();
|
|
@@ -136,25 +144,25 @@ const oe = (g, d) => {
|
|
|
136
144
|
...Ae(t),
|
|
137
145
|
getTableList: n,
|
|
138
146
|
search: A,
|
|
139
|
-
reset:
|
|
140
|
-
handleSizeChange:
|
|
147
|
+
reset: x,
|
|
148
|
+
handleSizeChange: H,
|
|
141
149
|
handleCurrentChange: O,
|
|
142
150
|
updatedTotalParam: h
|
|
143
151
|
};
|
|
144
|
-
},
|
|
145
|
-
const a =
|
|
152
|
+
}, ta = (g = "id", p) => {
|
|
153
|
+
const a = I(!1), f = I([]), m = D(() => {
|
|
146
154
|
const t = [];
|
|
147
|
-
return f.value.forEach((b) => t.push(
|
|
155
|
+
return f.value.forEach((b) => t.push(Ne(b, g))), t;
|
|
148
156
|
});
|
|
149
157
|
return {
|
|
150
158
|
isSelected: a,
|
|
151
159
|
selectedList: f,
|
|
152
160
|
selectedListIds: m,
|
|
153
161
|
selectionChange: (t) => {
|
|
154
|
-
t.length ? a.value = !0 : a.value = !1, f.value = t,
|
|
162
|
+
t.length ? a.value = !0 : a.value = !1, f.value = t, p && p(t);
|
|
155
163
|
}
|
|
156
164
|
};
|
|
157
|
-
},
|
|
165
|
+
}, aa = { class: "search-form-item" }, na = /* @__PURE__ */ le({
|
|
158
166
|
name: "SearchFormItem",
|
|
159
167
|
__name: "SearchFormItem",
|
|
160
168
|
props: {
|
|
@@ -162,30 +170,30 @@ const oe = (g, d) => {
|
|
|
162
170
|
searchParam: {}
|
|
163
171
|
},
|
|
164
172
|
emits: ["search"],
|
|
165
|
-
setup(g, { emit:
|
|
173
|
+
setup(g, { emit: p }) {
|
|
166
174
|
dt((e) => ({
|
|
167
175
|
"6720d772": A.value
|
|
168
176
|
}));
|
|
169
|
-
const a = g, f =
|
|
170
|
-
var e,
|
|
177
|
+
const a = g, f = p, m = D(() => a.searchParam), C = D(() => {
|
|
178
|
+
var e, c, s;
|
|
171
179
|
return {
|
|
172
180
|
label: ((e = a.column.fieldNames) == null ? void 0 : e.label) ?? "label",
|
|
173
|
-
value: ((
|
|
181
|
+
value: ((c = a.column.fieldNames) == null ? void 0 : c.value) ?? "value",
|
|
174
182
|
children: ((s = a.column.fieldNames) == null ? void 0 : s.children) ?? "children"
|
|
175
183
|
};
|
|
176
|
-
}), t = Ue("enumMap",
|
|
177
|
-
var
|
|
184
|
+
}), t = Ue("enumMap", I(/* @__PURE__ */ new Map())), b = D(() => {
|
|
185
|
+
var c;
|
|
178
186
|
let e = t.value.get(a.column.prop);
|
|
179
|
-
return e ? (((
|
|
180
|
-
}), n =
|
|
181
|
-
var e,
|
|
182
|
-
return ((
|
|
183
|
-
}), h =
|
|
187
|
+
return e ? (((c = a.column.search) == null ? void 0 : c.el) === "select-v2" && a.column.fieldNames && (e = e.map((s) => ({ ...s, label: s[C.value.label], value: s[C.value.value] }))), e) : [];
|
|
188
|
+
}), n = D(() => {
|
|
189
|
+
var e, c;
|
|
190
|
+
return ((c = (e = a.column.search) == null ? void 0 : e.props) == null ? void 0 : c.options) ?? b.value ?? [];
|
|
191
|
+
}), h = D(() => {
|
|
184
192
|
var B, _;
|
|
185
|
-
const e =
|
|
193
|
+
const e = C.value.label, c = C.value.value, s = C.value.children, l = (B = a.column.search) == null ? void 0 : B.el;
|
|
186
194
|
let v = ((_ = a.column.search) == null ? void 0 : _.props) ?? {};
|
|
187
|
-
return l === "tree-select" && (v = { ...v, props: { ...v.props, label: e, children: s }, nodeKey:
|
|
188
|
-
}), W =
|
|
195
|
+
return l === "tree-select" && (v = { ...v, props: { ...v.props, label: e, children: s }, nodeKey: c }), l === "cascader" && (v = { ...v, props: { ...v.props, label: e, value: c, children: s } }), v;
|
|
196
|
+
}), W = D(() => {
|
|
189
197
|
var s, l, v, B, _, P, k;
|
|
190
198
|
const e = a.column.search;
|
|
191
199
|
return ["datetimerange", "daterange", "monthrange"].includes((s = e == null ? void 0 : e.props) == null ? void 0 : s.type) || (l = e == null ? void 0 : e.props) != null && l.isRange ? {
|
|
@@ -193,67 +201,67 @@ const oe = (g, d) => {
|
|
|
193
201
|
startPlaceholder: ((B = e == null ? void 0 : e.props) == null ? void 0 : B.startPlaceholder) ?? "开始时间",
|
|
194
202
|
endPlaceholder: ((_ = e == null ? void 0 : e.props) == null ? void 0 : _.endPlaceholder) ?? "结束时间"
|
|
195
203
|
} : { placeholder: ((P = e == null ? void 0 : e.props) == null ? void 0 : P.placeholder) ?? ((k = e == null ? void 0 : e.el) != null && k.includes("input") ? "请输入" : "请选择") };
|
|
196
|
-
}), A =
|
|
204
|
+
}), A = D(() => {
|
|
197
205
|
var v, B;
|
|
198
|
-
const e = a.column.search,
|
|
206
|
+
const e = a.column.search, c = m.value[(e == null ? void 0 : e.key) ?? R(a.column.prop)], s = e == null ? void 0 : e.el, l = (v = e == null ? void 0 : e.props) == null ? void 0 : v.placeholder;
|
|
199
207
|
if (e != null && e.width)
|
|
200
208
|
if (Tt(e == null ? void 0 : e.width)) {
|
|
201
|
-
if (e == null ? void 0 : e.width(
|
|
202
|
-
return (e == null ? void 0 : e.width(
|
|
209
|
+
if (e == null ? void 0 : e.width(c))
|
|
210
|
+
return (e == null ? void 0 : e.width(c)) + "px";
|
|
203
211
|
} else
|
|
204
212
|
return (e == null ? void 0 : e.width) + "px";
|
|
205
|
-
if (
|
|
206
|
-
if (
|
|
213
|
+
if (c && c.length !== 0 && ["select", "select-v2", "tree-select", "cascader"].includes(s || "")) {
|
|
214
|
+
if (qe(c)) {
|
|
207
215
|
let k = n.value;
|
|
208
|
-
const
|
|
209
|
-
if (
|
|
210
|
-
const U = k.find((
|
|
211
|
-
|
|
212
|
-
const j = U[
|
|
216
|
+
const F = [];
|
|
217
|
+
if (c.forEach((V) => {
|
|
218
|
+
const U = k.find((Z) => Z[C.value.value] === V);
|
|
219
|
+
F.push(U ? U[C.value.label] : V);
|
|
220
|
+
const j = U[C.value.children] ?? n.value;
|
|
213
221
|
k = U ? j : [];
|
|
214
222
|
}), (B = e == null ? void 0 : e.props) != null && B.multiple) {
|
|
215
|
-
const j = oe(
|
|
216
|
-
return
|
|
223
|
+
const j = oe(F[0]) + 42;
|
|
224
|
+
return c.length > 1 ? j + 26 + oe("+ " + (c.length - 1)) + "px" : j + "px";
|
|
217
225
|
}
|
|
218
|
-
return oe(
|
|
226
|
+
return oe(F.join(" / ")) + "px";
|
|
219
227
|
}
|
|
220
|
-
let _ = n.value.find((k) => k[
|
|
221
|
-
const P = _ ? _[
|
|
228
|
+
let _ = n.value.find((k) => k[C.value.value] === c);
|
|
229
|
+
const P = _ ? _[C.value.label] : c;
|
|
222
230
|
return oe(P) + "px";
|
|
223
231
|
} else return l ? oe(l) + "px" : ["date-picker", "time-picker", "time-select"].includes(s || "") ? "210px" : "100px";
|
|
224
|
-
}),
|
|
225
|
-
var e,
|
|
226
|
-
return (s = (
|
|
232
|
+
}), x = D(() => {
|
|
233
|
+
var e, c, s, l, v;
|
|
234
|
+
return (s = (c = (e = a.column) == null ? void 0 : e.search) == null ? void 0 : c.props) != null && s.multiple && ((v = (l = a.column) == null ? void 0 : l.search) == null ? void 0 : v.el) === "select" ? {
|
|
227
235
|
collapseTags: !0,
|
|
228
236
|
collapseTagsTooltip: !0
|
|
229
237
|
} : {};
|
|
230
|
-
}),
|
|
231
|
-
var
|
|
238
|
+
}), H = D(() => {
|
|
239
|
+
var c;
|
|
232
240
|
const e = a.column.search;
|
|
233
|
-
return ((
|
|
241
|
+
return ((c = e == null ? void 0 : e.props) == null ? void 0 : c.clearable) ?? ((e == null ? void 0 : e.defaultValue) == null || !1);
|
|
234
242
|
}), O = (e) => {
|
|
235
|
-
var
|
|
236
|
-
if (((l = (s = (
|
|
237
|
-
const { searchParam:
|
|
243
|
+
var c, s, l, v, B, _, P, k, F;
|
|
244
|
+
if (((l = (s = (c = a.column) == null ? void 0 : c.search) == null ? void 0 : s.props) == null ? void 0 : l.type) === "daterange") {
|
|
245
|
+
const { searchParam: V } = Ae(a);
|
|
238
246
|
if (e != null && e.length) {
|
|
239
|
-
const U = ((_ = (B = (v = a.column) == null ? void 0 : v.search) == null ? void 0 : B.props) == null ? void 0 : _.beginTime) || "beginTime", j = ((
|
|
240
|
-
|
|
247
|
+
const U = ((_ = (B = (v = a.column) == null ? void 0 : v.search) == null ? void 0 : B.props) == null ? void 0 : _.beginTime) || "beginTime", j = ((F = (k = (P = a.column) == null ? void 0 : P.search) == null ? void 0 : k.props) == null ? void 0 : F.endTime) || "endTime";
|
|
248
|
+
V.value[U] = e[0], V.value[j] = e[1];
|
|
241
249
|
} else
|
|
242
|
-
delete
|
|
250
|
+
delete V.value.beginTime, delete V.value.endTime;
|
|
243
251
|
}
|
|
244
252
|
(e == null || e === "") && f("search"), e instanceof Array && !e.length && f("search");
|
|
245
253
|
}, T = () => {
|
|
246
254
|
var e;
|
|
247
255
|
["input", "input-number"].includes(((e = a.column.search) == null ? void 0 : e.el) || "") && f("search");
|
|
248
256
|
};
|
|
249
|
-
return (e,
|
|
250
|
-
var s, l, v, B, _, P, k,
|
|
251
|
-
return
|
|
252
|
-
((s = e.column.search) == null ? void 0 : s.type) !== "custom" ? (
|
|
253
|
-
modelValue: m.value[((B = e.column.search) == null ? void 0 : B.key) ??
|
|
254
|
-
"onUpdate:modelValue":
|
|
255
|
-
var
|
|
256
|
-
return m.value[((
|
|
257
|
+
return (e, c) => {
|
|
258
|
+
var s, l, v, B, _, P, k, F, V, U, j;
|
|
259
|
+
return y(), M("div", aa, [
|
|
260
|
+
((s = e.column.search) == null ? void 0 : s.type) !== "custom" ? (y(), L(fe(((l = e.column.search) == null ? void 0 : l.render) ?? `el-${(v = e.column.search) == null ? void 0 : v.el}`), Y({ key: 0 }, { ...h.value, ...W.value, searchParam: m.value, clearable: H.value, ...x.value }, {
|
|
261
|
+
modelValue: m.value[((B = e.column.search) == null ? void 0 : B.key) ?? i(R)(e.column.prop)],
|
|
262
|
+
"onUpdate:modelValue": c[0] || (c[0] = (Z) => {
|
|
263
|
+
var N;
|
|
264
|
+
return m.value[((N = e.column.search) == null ? void 0 : N.key) ?? i(R)(e.column.prop)] = Z;
|
|
257
265
|
}),
|
|
258
266
|
modelModifiers: { trim: !0 },
|
|
259
267
|
data: ((_ = e.column.search) == null ? void 0 : _.el) === "tree-select" ? b.value : [],
|
|
@@ -263,31 +271,31 @@ const oe = (g, d) => {
|
|
|
263
271
|
onKeyup: pt(T, ["enter"])
|
|
264
272
|
}), me({
|
|
265
273
|
default: S(() => {
|
|
266
|
-
var
|
|
274
|
+
var Z;
|
|
267
275
|
return [
|
|
268
|
-
((
|
|
276
|
+
((Z = e.column.search) == null ? void 0 : Z.el) === "select" ? (y(!0), M(J, { key: 0 }, ge(b.value, (N, ue) => (y(), L(fe("el-option"), {
|
|
269
277
|
key: ue,
|
|
270
|
-
label:
|
|
271
|
-
value:
|
|
272
|
-
}, null, 8, ["label", "value"]))), 128)) :
|
|
278
|
+
label: N[C.value.label] ?? "",
|
|
279
|
+
value: N[C.value.value]
|
|
280
|
+
}, null, 8, ["label", "value"]))), 128)) : K(e.$slots, "default", { key: 1 }, void 0, !0)
|
|
273
281
|
];
|
|
274
282
|
}),
|
|
275
283
|
_: 2
|
|
276
284
|
}, [
|
|
277
|
-
((
|
|
285
|
+
((F = e.column.search) == null ? void 0 : F.el) === "cascader" ? {
|
|
278
286
|
name: "default",
|
|
279
|
-
fn: S(({ data:
|
|
280
|
-
|
|
287
|
+
fn: S(({ data: Z }) => [
|
|
288
|
+
$("span", null, X(Z[C.value.label]), 1)
|
|
281
289
|
]),
|
|
282
290
|
key: "0"
|
|
283
291
|
} : void 0
|
|
284
|
-
]), 1040, ["modelValue", "data", "options", "prefix-icon"])) : (
|
|
285
|
-
((
|
|
292
|
+
]), 1040, ["modelValue", "data", "options", "prefix-icon"])) : (y(), M(J, { key: 1 }, [
|
|
293
|
+
((V = e.column.search) == null ? void 0 : V.el) === "zhCascaderLoadMore" ? (y(), L(i(Nt), Y({
|
|
286
294
|
key: 0,
|
|
287
|
-
modelValue: m.value[((U = e.column.search) == null ? void 0 : U.key) ??
|
|
288
|
-
"onUpdate:modelValue":
|
|
289
|
-
var
|
|
290
|
-
return m.value[((
|
|
295
|
+
modelValue: m.value[((U = e.column.search) == null ? void 0 : U.key) ?? i(R)(e.column.prop)],
|
|
296
|
+
"onUpdate:modelValue": c[1] || (c[1] = (Z) => {
|
|
297
|
+
var N;
|
|
298
|
+
return m.value[((N = e.column.search) == null ? void 0 : N.key) ?? i(R)(e.column.prop)] = Z;
|
|
291
299
|
}),
|
|
292
300
|
modelModifiers: { trim: !0 }
|
|
293
301
|
}, (j = e.column.search) == null ? void 0 : j.props), null, 16, ["modelValue"])) : z("", !0)
|
|
@@ -295,10 +303,10 @@ const oe = (g, d) => {
|
|
|
295
303
|
]);
|
|
296
304
|
};
|
|
297
305
|
}
|
|
298
|
-
}),
|
|
306
|
+
}), oa = /* @__PURE__ */ se(na, [["__scopeId", "data-v-5c18e8bc"]]), la = { class: "table-search" }, ra = { key: 0 }, sa = {
|
|
299
307
|
key: 0,
|
|
300
308
|
class: "operation"
|
|
301
|
-
},
|
|
309
|
+
}, ua = /* @__PURE__ */ le({
|
|
302
310
|
name: "SearchForm",
|
|
303
311
|
__name: "SearchForm",
|
|
304
312
|
props: {
|
|
@@ -310,9 +318,9 @@ const oe = (g, d) => {
|
|
|
310
318
|
isShowSearchBtn: { type: Boolean, default: !0 }
|
|
311
319
|
},
|
|
312
320
|
setup(g) {
|
|
313
|
-
const
|
|
314
|
-
return (a, f) => (
|
|
315
|
-
w(
|
|
321
|
+
const p = g;
|
|
322
|
+
return (a, f) => (y(), M("div", la, [
|
|
323
|
+
w(i(Et), {
|
|
316
324
|
ref: "formRef",
|
|
317
325
|
model: a.searchParam,
|
|
318
326
|
class: "table-search--left",
|
|
@@ -320,17 +328,17 @@ const oe = (g, d) => {
|
|
|
320
328
|
}, ["prevent"]))
|
|
321
329
|
}, {
|
|
322
330
|
default: S(() => [
|
|
323
|
-
|
|
324
|
-
a.columns.length ? (
|
|
325
|
-
(
|
|
326
|
-
var
|
|
327
|
-
return
|
|
331
|
+
K(a.$slots, "default", {}, void 0, !0),
|
|
332
|
+
a.columns.length ? (y(), M(J, { key: 0 }, [
|
|
333
|
+
(y(!0), M(J, null, ge(a.columns, (m) => {
|
|
334
|
+
var C, t, b;
|
|
335
|
+
return y(), M(J, {
|
|
328
336
|
key: m.prop
|
|
329
337
|
}, [
|
|
330
|
-
!
|
|
331
|
-
w(
|
|
338
|
+
!i($t)((C = m.search) == null ? void 0 : C.isShow) || (t = m.search) != null && t.isShow ? (y(), M("div", ra, [
|
|
339
|
+
w(i(Bt), null, me({
|
|
332
340
|
default: S(() => [
|
|
333
|
-
w(
|
|
341
|
+
w(oa, {
|
|
334
342
|
column: m,
|
|
335
343
|
"search-param": a.searchParam,
|
|
336
344
|
onSearch: a.search
|
|
@@ -341,20 +349,20 @@ const oe = (g, d) => {
|
|
|
341
349
|
(b = m.search) != null && b.label ? {
|
|
342
350
|
name: "label",
|
|
343
351
|
fn: S(() => [
|
|
344
|
-
w(
|
|
352
|
+
w(i(zt), { size: 4 }, {
|
|
345
353
|
default: S(() => {
|
|
346
354
|
var n, h;
|
|
347
355
|
return [
|
|
348
|
-
|
|
349
|
-
(n = m.search) != null && n.tooltip ? (
|
|
356
|
+
$("span", null, X(`${m.search.label}`), 1),
|
|
357
|
+
(n = m.search) != null && n.tooltip ? (y(), L(i(be), {
|
|
350
358
|
key: 0,
|
|
351
359
|
effect: "dark",
|
|
352
360
|
content: (h = m.search) == null ? void 0 : h.tooltip,
|
|
353
361
|
placement: "top"
|
|
354
362
|
}, {
|
|
355
363
|
default: S(() => f[1] || (f[1] = [
|
|
356
|
-
|
|
357
|
-
class:
|
|
364
|
+
$("i", {
|
|
365
|
+
class: Ze("iconfont icon-yiwen")
|
|
358
366
|
}, null, -1)
|
|
359
367
|
])),
|
|
360
368
|
_: 2
|
|
@@ -363,7 +371,7 @@ const oe = (g, d) => {
|
|
|
363
371
|
}),
|
|
364
372
|
_: 2
|
|
365
373
|
}, 1024),
|
|
366
|
-
f[2] || (f[2] =
|
|
374
|
+
f[2] || (f[2] = $("span", null, ":", -1))
|
|
367
375
|
]),
|
|
368
376
|
key: "0"
|
|
369
377
|
} : void 0
|
|
@@ -371,17 +379,17 @@ const oe = (g, d) => {
|
|
|
371
379
|
])) : z("", !0)
|
|
372
380
|
], 64);
|
|
373
381
|
}), 128)),
|
|
374
|
-
|
|
382
|
+
p.isShowSearchBtn ? (y(), L(i(Te), {
|
|
375
383
|
key: 0,
|
|
376
384
|
type: "primary",
|
|
377
385
|
class: "table-search--search-btn",
|
|
378
386
|
onClick: a.search
|
|
379
387
|
}, {
|
|
380
388
|
icon: S(() => f[3] || (f[3] = [
|
|
381
|
-
|
|
389
|
+
$("i", { class: "ztable-iconfont icon-zhihao-table-search" }, null, -1)
|
|
382
390
|
])),
|
|
383
391
|
default: S(() => [
|
|
384
|
-
f[4] || (f[4] =
|
|
392
|
+
f[4] || (f[4] = Q(" 搜索 "))
|
|
385
393
|
]),
|
|
386
394
|
_: 1
|
|
387
395
|
}, 8, ["onClick"])) : z("", !0)
|
|
@@ -389,22 +397,22 @@ const oe = (g, d) => {
|
|
|
389
397
|
]),
|
|
390
398
|
_: 3
|
|
391
399
|
}, 8, ["model"]),
|
|
392
|
-
|
|
393
|
-
w(
|
|
400
|
+
p.isShowResetBtn && a.columns.length ? (y(), M("div", sa, [
|
|
401
|
+
w(i(be), {
|
|
394
402
|
class: "box-item",
|
|
395
403
|
effect: "light",
|
|
396
404
|
content: "重置",
|
|
397
405
|
placement: "top"
|
|
398
406
|
}, {
|
|
399
407
|
default: S(() => [
|
|
400
|
-
w(
|
|
408
|
+
w(i(Te), {
|
|
401
409
|
class: "table-search--reset-btn",
|
|
402
410
|
onClick: a.reset
|
|
403
411
|
}, {
|
|
404
412
|
icon: S(() => [
|
|
405
|
-
w(
|
|
413
|
+
w(i(Ce), { size: 14 }, {
|
|
406
414
|
default: S(() => [
|
|
407
|
-
w(
|
|
415
|
+
w(i(Mt))
|
|
408
416
|
]),
|
|
409
417
|
_: 1
|
|
410
418
|
})
|
|
@@ -417,7 +425,7 @@ const oe = (g, d) => {
|
|
|
417
425
|
])) : z("", !0)
|
|
418
426
|
]));
|
|
419
427
|
}
|
|
420
|
-
}),
|
|
428
|
+
}), ia = /* @__PURE__ */ se(ua, [["__scopeId", "data-v-e524e82e"]]), ca = { class: "el-pagination__total zh-page-total" }, da = /* @__PURE__ */ le({
|
|
421
429
|
name: "Pagination",
|
|
422
430
|
__name: "tablePagination",
|
|
423
431
|
props: {
|
|
@@ -426,31 +434,31 @@ const oe = (g, d) => {
|
|
|
426
434
|
handleCurrentChange: { type: Function }
|
|
427
435
|
},
|
|
428
436
|
setup(g) {
|
|
429
|
-
return (
|
|
437
|
+
return (p, a) => p.pageable.total ? (y(), L(i(Ft), {
|
|
430
438
|
key: 0,
|
|
431
439
|
class: "zh-pagination",
|
|
432
440
|
background: !0,
|
|
433
|
-
"current-page":
|
|
434
|
-
"page-size":
|
|
435
|
-
total:
|
|
441
|
+
"current-page": p.pageable.page,
|
|
442
|
+
"page-size": p.pageable.size,
|
|
443
|
+
total: p.pageable.total,
|
|
436
444
|
teleported: !1,
|
|
437
445
|
layout: "slot, sizes, prev, pager, next, jumper",
|
|
438
|
-
onSizeChange:
|
|
439
|
-
onCurrentChange:
|
|
446
|
+
onSizeChange: p.handleSizeChange,
|
|
447
|
+
onCurrentChange: p.handleCurrentChange
|
|
440
448
|
}, {
|
|
441
449
|
default: S(() => [
|
|
442
|
-
|
|
443
|
-
|
|
450
|
+
K(p.$slots, "zhPaginationLeftSlot", { pageable: p.pageable }, () => [
|
|
451
|
+
$("div", ca, "共" + X(p.pageable.total) + "条数据", 1)
|
|
444
452
|
], !0)
|
|
445
453
|
]),
|
|
446
454
|
_: 3
|
|
447
455
|
}, 8, ["current-page", "page-size", "total", "onSizeChange", "onCurrentChange"])) : z("", !0);
|
|
448
456
|
}
|
|
449
|
-
}),
|
|
457
|
+
}), pa = /* @__PURE__ */ se(da, [["__scopeId", "data-v-5965b30c"]]);
|
|
450
458
|
function Pe(g) {
|
|
451
459
|
return typeof g == "function" || Object.prototype.toString.call(g) === "[object Object]" && !ft(g);
|
|
452
460
|
}
|
|
453
|
-
const
|
|
461
|
+
const ha = /* @__PURE__ */ le({
|
|
454
462
|
name: "TableColumn",
|
|
455
463
|
__name: "TableColumn",
|
|
456
464
|
props: {
|
|
@@ -460,112 +468,112 @@ const pa = /* @__PURE__ */ le({
|
|
|
460
468
|
}
|
|
461
469
|
},
|
|
462
470
|
setup(g) {
|
|
463
|
-
const
|
|
471
|
+
const p = g, a = I(p.column), f = Ke(), m = Ue("enumMap", I(/* @__PURE__ */ new Map())), C = (n, h) => m.value.get(n.prop) && n.isFilterEnum ? Oe(he(h.row, n.prop), m.value.get(n.prop), n.fieldNames) : Gt(he(h.row, n.prop)), t = (n, h) => Oe(he(h.row, n.prop), m.value.get(n.prop), n.fieldNames, "tag"), b = (n) => w(J, null, [n.isShow && w(re, Y(n, {
|
|
464
472
|
"class-name": n.wrap && "table-column--wrap",
|
|
465
473
|
showOverflowTooltip: n.showOverflowTooltip ?? n.prop !== "operation"
|
|
466
474
|
}), {
|
|
467
475
|
default: (h) => {
|
|
468
|
-
var A,
|
|
476
|
+
var A, x, H;
|
|
469
477
|
let W;
|
|
470
478
|
if (n._children) return n._children.map((O) => b(O));
|
|
471
479
|
if (n.render) return n.render(h);
|
|
472
480
|
if (n.prop === "operation") {
|
|
473
|
-
if (!f[
|
|
481
|
+
if (!f[R(n.prop)]) {
|
|
474
482
|
a.value.width = 0;
|
|
475
483
|
return;
|
|
476
484
|
}
|
|
477
|
-
const O = ((
|
|
478
|
-
var
|
|
479
|
-
return ((
|
|
480
|
-
}).filter(Boolean).flat(), e = T(O),
|
|
485
|
+
const O = ((x = (A = f[R(n.prop)](h)) == null ? void 0 : A.at(0)) == null ? void 0 : x.children) || [], T = (P) => Array.from(P).map((k) => {
|
|
486
|
+
var F, V;
|
|
487
|
+
return ((F = k.type) == null ? void 0 : F.name) === "ElButton" && k.children !== "v-if" ? k : (V = k.children) != null && V.length ? T(k.children) : null;
|
|
488
|
+
}).filter(Boolean).flat(), e = T(O), c = (P) => {
|
|
481
489
|
let k = "";
|
|
482
|
-
return P.forEach((
|
|
483
|
-
k +=
|
|
490
|
+
return P.forEach((F) => {
|
|
491
|
+
k += F.children.default()[0].children;
|
|
484
492
|
}), oe(k, 14) + 16 * (P.length > 0 ? P.length - 1 : 0);
|
|
485
493
|
}, s = (P) => {
|
|
486
494
|
a.value.hasOperationMaxWidth || (a.value.width = 0, a.value.hasOperationMaxWidth = !0);
|
|
487
495
|
const k = a.value.width;
|
|
488
|
-
let
|
|
489
|
-
P > 0 && (
|
|
496
|
+
let F = 0;
|
|
497
|
+
P > 0 && (F = Math.round(P) + 32), F > Number.parseInt((k == null ? void 0 : k.toString()) || "0") && (a.value.width = F, a.value.hasOperationMaxWidth = !0);
|
|
490
498
|
};
|
|
491
499
|
if (e.length <= 3 || n.expandOperationButtons) {
|
|
492
|
-
const P = Math.ceil(
|
|
500
|
+
const P = Math.ceil(c(e));
|
|
493
501
|
let k = P;
|
|
494
|
-
return
|
|
502
|
+
return p.customColumn && (k = e.length ? e.length === 1 ? P + 30 : P : 50), s(k), w("div", {
|
|
495
503
|
class: "operation-container all-action"
|
|
496
|
-
}, [f[
|
|
504
|
+
}, [f[R(n.prop)](h)]);
|
|
497
505
|
}
|
|
498
506
|
const l = [], v = e.slice(0, 2), B = w(Te, {
|
|
499
507
|
link: !0,
|
|
500
508
|
type: "primary"
|
|
501
509
|
}, {
|
|
502
|
-
default: () => [
|
|
510
|
+
default: () => [Q("更多")]
|
|
503
511
|
});
|
|
504
|
-
l.push(...v), l[3] = w(
|
|
512
|
+
l.push(...v), l[3] = w(It, null, {
|
|
505
513
|
default: () => B,
|
|
506
514
|
dropdown: () => {
|
|
507
515
|
let P;
|
|
508
|
-
return w(
|
|
516
|
+
return w(Lt, null, Pe(P = e.slice(2).map((k) => w(Vt, null, Pe(k) ? k : {
|
|
509
517
|
default: () => [k]
|
|
510
518
|
}))) ? P : {
|
|
511
519
|
default: () => [P]
|
|
512
520
|
});
|
|
513
521
|
}
|
|
514
522
|
});
|
|
515
|
-
const _ =
|
|
523
|
+
const _ = c([...v, B]);
|
|
516
524
|
return s(_), w("div", {
|
|
517
525
|
class: "operation-container"
|
|
518
526
|
}, [l]);
|
|
519
527
|
}
|
|
520
|
-
return f[
|
|
528
|
+
return f[R(n.prop)] ? f[R(n.prop)](h) : n.tag ? w(xe, {
|
|
521
529
|
type: t(n, h)
|
|
522
|
-
}, Pe(W =
|
|
530
|
+
}, Pe(W = C(n, h)) ? W : {
|
|
523
531
|
default: () => [W]
|
|
524
|
-
}) : n.click &&
|
|
532
|
+
}) : n.click && C(n, h) !== ae ? w("span", {
|
|
525
533
|
class: "el-link el-link--primary scan-link",
|
|
526
534
|
onClick: function() {
|
|
527
535
|
n.click(h == null ? void 0 : h.row, h == null ? void 0 : h.$index);
|
|
528
536
|
}
|
|
529
|
-
}, [n.formatter ? n.formatter(h.row, h.column, h.row[n.prop], h.$index) :
|
|
530
|
-
class: ((
|
|
531
|
-
}, [n.formatter ? n.formatter(h.row, h.column, h.row[n.prop], h.$index) :
|
|
537
|
+
}, [n.formatter ? n.formatter(h.row, h.column, h.row[n.prop], h.$index) : C(n, h)]) : w("span", {
|
|
538
|
+
class: ((H = Yt(he(h.row, n.prop), m.value.get(n.prop))) == null ? void 0 : H.state) || "text"
|
|
539
|
+
}, [n.formatter ? n.formatter(h.row, h.column, h.row[n.prop], h.$index) : C(n, h)]);
|
|
532
540
|
},
|
|
533
|
-
header: (h) => n.headerRender ? n.headerRender(h) : f[`${
|
|
541
|
+
header: (h) => n.headerRender ? n.headerRender(h) : f[`${R(n.prop)}Header`] ? f[`${R(n.prop)}Header`](h) : n.label
|
|
534
542
|
})]);
|
|
535
|
-
return (n, h) => (
|
|
543
|
+
return (n, h) => (y(), L(b, We(je(a.value)), null, 16));
|
|
536
544
|
}
|
|
537
|
-
}),
|
|
545
|
+
}), fa = { class: "custom-column-dialog" }, ma = { class: "table-body" }, ga = { class: "name" }, va = {
|
|
538
546
|
key: 0,
|
|
539
547
|
class: "ml-10"
|
|
540
|
-
},
|
|
548
|
+
}, ba = { class: "custom-width-label text" }, Ca = {
|
|
541
549
|
key: 0,
|
|
542
550
|
class: "custom-width-input-box"
|
|
543
|
-
}, ya = { class: "custom-column-footer" },
|
|
551
|
+
}, ya = { class: "custom-column-footer" }, Sa = { class: "flex-1" }, wa = /* @__PURE__ */ le({
|
|
544
552
|
name: "ColSetting",
|
|
545
553
|
__name: "ColSetting",
|
|
546
554
|
props: {
|
|
547
555
|
originTableColumns: { default: () => [] }
|
|
548
556
|
},
|
|
549
557
|
emits: ["close", "submit", "dragSort"],
|
|
550
|
-
setup(g, { expose:
|
|
551
|
-
const f =
|
|
552
|
-
t.value =
|
|
558
|
+
setup(g, { expose: p, emit: a }) {
|
|
559
|
+
const f = I(), m = I(!1), C = g, t = I([]), b = I((/* @__PURE__ */ new Date()).getTime()), n = I(!1), h = I(), W = (c) => {
|
|
560
|
+
t.value = c, n.value = !0, ve(() => {
|
|
553
561
|
O();
|
|
554
562
|
});
|
|
555
|
-
}, A = (
|
|
556
|
-
m.value =
|
|
557
|
-
},
|
|
558
|
-
|
|
563
|
+
}, A = (c) => {
|
|
564
|
+
m.value = c;
|
|
565
|
+
}, x = a, H = async () => {
|
|
566
|
+
x("submit", t.value), n.value = !1;
|
|
559
567
|
}, O = () => {
|
|
560
568
|
h.value && (h.value.destroy(), b.value = (/* @__PURE__ */ new Date()).getTime(), f.value.doLayout()), ve(() => {
|
|
561
|
-
const
|
|
562
|
-
h.value =
|
|
569
|
+
const c = document.querySelector(".custom-column-dialog tbody");
|
|
570
|
+
h.value = He.create(c, {
|
|
563
571
|
handle: ".move",
|
|
564
572
|
animation: 300,
|
|
565
573
|
filter: ".operation",
|
|
566
574
|
onEnd({ newIndex: s, oldIndex: l }) {
|
|
567
575
|
if (!s && s !== 0 || !l && l !== 0) return;
|
|
568
|
-
let v =
|
|
576
|
+
let v = G(t.value);
|
|
569
577
|
const B = v[l];
|
|
570
578
|
if (s < l)
|
|
571
579
|
for (let _ = s; _ < l; _++)
|
|
@@ -573,44 +581,44 @@ const pa = /* @__PURE__ */ le({
|
|
|
573
581
|
else
|
|
574
582
|
for (let _ = l + 1; _ <= s; _++)
|
|
575
583
|
v[_].order = String(Number(v[_].order) - 1);
|
|
576
|
-
B.order = String(s), t.value =
|
|
584
|
+
B.order = String(s), t.value = G(v);
|
|
577
585
|
}
|
|
578
586
|
});
|
|
579
587
|
});
|
|
580
588
|
}, T = () => {
|
|
581
|
-
const
|
|
582
|
-
m.value ? t.value =
|
|
589
|
+
const c = G(C.originTableColumns);
|
|
590
|
+
m.value ? t.value = c : t.value = t.value.map((s) => {
|
|
583
591
|
const l = t.value.find((v) => v.prop === s.prop);
|
|
584
|
-
return !(l != null && l.isShow) || l.prop === "operation" ? s :
|
|
592
|
+
return !(l != null && l.isShow) || l.prop === "operation" ? s : c.find((v) => v.prop === s.prop);
|
|
585
593
|
}), O();
|
|
586
594
|
}, e = () => {
|
|
587
595
|
n.value = !1;
|
|
588
596
|
};
|
|
589
|
-
return
|
|
597
|
+
return p({
|
|
590
598
|
openColSetting: W
|
|
591
|
-
}), (
|
|
592
|
-
w(
|
|
599
|
+
}), (c, s) => (y(), M("div", fa, [
|
|
600
|
+
w(qt, {
|
|
593
601
|
modelValue: n.value,
|
|
594
602
|
"onUpdate:modelValue": s[1] || (s[1] = (l) => n.value = l),
|
|
595
603
|
size: "middle"
|
|
596
604
|
}, {
|
|
597
605
|
header: S(() => s[2] || (s[2] = [
|
|
598
|
-
|
|
599
|
-
|
|
606
|
+
$("div", { class: "title" }, "自定义列", -1),
|
|
607
|
+
$("div", { class: "sub-title" }, "勾选需要展示的列,拖动列名进行排序", -1)
|
|
600
608
|
])),
|
|
601
609
|
footer: S(() => [
|
|
602
|
-
|
|
603
|
-
w(
|
|
610
|
+
$("div", ya, [
|
|
611
|
+
w(i(Le), {
|
|
604
612
|
modelValue: m.value,
|
|
605
613
|
"onUpdate:modelValue": s[0] || (s[0] = (l) => m.value = l),
|
|
606
614
|
class: "checkbox",
|
|
607
615
|
label: "全局",
|
|
608
616
|
onChange: A
|
|
609
617
|
}, null, 8, ["modelValue"]),
|
|
610
|
-
|
|
618
|
+
$("div", Sa, [
|
|
611
619
|
w(_e, { onClick: e }, {
|
|
612
620
|
default: S(() => s[4] || (s[4] = [
|
|
613
|
-
|
|
621
|
+
Q("取消")
|
|
614
622
|
])),
|
|
615
623
|
_: 1
|
|
616
624
|
}),
|
|
@@ -619,16 +627,16 @@ const pa = /* @__PURE__ */ le({
|
|
|
619
627
|
onClick: T
|
|
620
628
|
}, {
|
|
621
629
|
default: S(() => [
|
|
622
|
-
|
|
630
|
+
Q(X(m.value ? "全局恢复默认" : "恢复默认"), 1)
|
|
623
631
|
]),
|
|
624
632
|
_: 1
|
|
625
633
|
}),
|
|
626
634
|
w(_e, {
|
|
627
635
|
type: "primary",
|
|
628
|
-
onClick:
|
|
636
|
+
onClick: H
|
|
629
637
|
}, {
|
|
630
638
|
default: S(() => s[5] || (s[5] = [
|
|
631
|
-
|
|
639
|
+
Q("保存")
|
|
632
640
|
])),
|
|
633
641
|
_: 1
|
|
634
642
|
})
|
|
@@ -636,8 +644,8 @@ const pa = /* @__PURE__ */ le({
|
|
|
636
644
|
])
|
|
637
645
|
]),
|
|
638
646
|
default: S(() => [
|
|
639
|
-
|
|
640
|
-
(
|
|
647
|
+
$("div", ma, [
|
|
648
|
+
(y(), L(i(Je), {
|
|
641
649
|
ref_key: "tableRef",
|
|
642
650
|
ref: f,
|
|
643
651
|
class: "custom-colum-table",
|
|
@@ -646,12 +654,12 @@ const pa = /* @__PURE__ */ le({
|
|
|
646
654
|
"row-class-name": (l) => l.row.prop === "operation" ? "operation" : ""
|
|
647
655
|
}, {
|
|
648
656
|
default: S(() => [
|
|
649
|
-
w(
|
|
657
|
+
w(i(re), {
|
|
650
658
|
width: "100",
|
|
651
659
|
label: "选择"
|
|
652
660
|
}, {
|
|
653
661
|
default: S(({ row: l }) => [
|
|
654
|
-
w(
|
|
662
|
+
w(i(Le), {
|
|
655
663
|
class: "custom-column-check",
|
|
656
664
|
modelValue: l.isShow,
|
|
657
665
|
"onUpdate:modelValue": (v) => l.isShow = v,
|
|
@@ -660,20 +668,20 @@ const pa = /* @__PURE__ */ le({
|
|
|
660
668
|
]),
|
|
661
669
|
_: 1
|
|
662
670
|
}),
|
|
663
|
-
w(
|
|
671
|
+
w(i(re), {
|
|
664
672
|
prop: "label",
|
|
665
673
|
label: "名称"
|
|
666
674
|
}, {
|
|
667
675
|
default: S(({ row: l }) => [
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
l.readonly ? (
|
|
671
|
-
l.prop !== "operation" ? (
|
|
676
|
+
$("div", ga, [
|
|
677
|
+
Q(X(l.label) + " ", 1),
|
|
678
|
+
l.readonly ? (y(), M("span", va, "(必选)")) : z("", !0),
|
|
679
|
+
l.prop !== "operation" ? (y(), L(i(Ce), {
|
|
672
680
|
key: 1,
|
|
673
681
|
class: "move move-icon"
|
|
674
682
|
}, {
|
|
675
683
|
default: S(() => [
|
|
676
|
-
w(
|
|
684
|
+
w(i(Dt))
|
|
677
685
|
]),
|
|
678
686
|
_: 1
|
|
679
687
|
})) : z("", !0)
|
|
@@ -681,19 +689,19 @@ const pa = /* @__PURE__ */ le({
|
|
|
681
689
|
]),
|
|
682
690
|
_: 1
|
|
683
691
|
}),
|
|
684
|
-
w(
|
|
692
|
+
w(i(re), {
|
|
685
693
|
prop: "width",
|
|
686
694
|
label: "宽度",
|
|
687
695
|
width: "180"
|
|
688
696
|
}, {
|
|
689
697
|
default: S(({ row: l }) => [
|
|
690
|
-
|
|
691
|
-
class:
|
|
698
|
+
$("div", {
|
|
699
|
+
class: Ze(`custom-width-box ${l.readonly && "readonly"}`)
|
|
692
700
|
}, [
|
|
693
|
-
s[3] || (s[3] =
|
|
694
|
-
|
|
695
|
-
l.readonly ? z("", !0) : (
|
|
696
|
-
w(
|
|
701
|
+
s[3] || (s[3] = $("span", { class: "text" }, "宽度", -1)),
|
|
702
|
+
$("span", ba, X(l.width) + " px", 1),
|
|
703
|
+
l.readonly ? z("", !0) : (y(), M("div", Ca, [
|
|
704
|
+
w(i(Ye), {
|
|
697
705
|
modelValue: l.width,
|
|
698
706
|
"onUpdate:modelValue": (v) => l.width = v,
|
|
699
707
|
class: "custom-width-input",
|
|
@@ -715,16 +723,16 @@ const pa = /* @__PURE__ */ le({
|
|
|
715
723
|
}, 8, ["modelValue"])
|
|
716
724
|
]));
|
|
717
725
|
}
|
|
718
|
-
}),
|
|
726
|
+
}), ka = /* @__PURE__ */ se(wa, [["__scopeId", "data-v-597569aa"]]), _a = { class: "no-card table-main zh-table" }, Pa = { class: "table-title-container" }, Ta = {
|
|
719
727
|
key: 0,
|
|
720
728
|
class: "table-title"
|
|
721
|
-
},
|
|
729
|
+
}, Ea = {
|
|
722
730
|
key: 1,
|
|
723
731
|
class: "table-header-tip"
|
|
724
|
-
}, $a = { class: "table-header-container" },
|
|
732
|
+
}, $a = { class: "table-header-container" }, Ba = {
|
|
725
733
|
key: 0,
|
|
726
734
|
class: "table-header"
|
|
727
|
-
},
|
|
735
|
+
}, za = { class: "header-button-ri" }, Ma = { key: 0 }, Fa = { class: "table-body-container" }, Ia = { class: "text d-flex inline-input-text pointer" }, La = {
|
|
728
736
|
key: 1,
|
|
729
737
|
class: "inline-input-box d-flex"
|
|
730
738
|
}, Va = { class: "table-empty" }, Da = ["src"], Ra = /* @__PURE__ */ le({
|
|
@@ -759,15 +767,15 @@ const pa = /* @__PURE__ */ le({
|
|
|
759
767
|
searchClearSelection: { type: Boolean, default: !0 }
|
|
760
768
|
},
|
|
761
769
|
emits: ["search", "reset", "dargSort"],
|
|
762
|
-
setup(g, { expose:
|
|
763
|
-
var
|
|
764
|
-
const f =
|
|
770
|
+
setup(g, { expose: p, emit: a }) {
|
|
771
|
+
var Ie;
|
|
772
|
+
const f = I((/* @__PURE__ */ new Date()).getTime()), m = {
|
|
765
773
|
mounted(o) {
|
|
766
|
-
var
|
|
767
|
-
(
|
|
774
|
+
var u;
|
|
775
|
+
(u = o.querySelector("input")) == null || u.focus();
|
|
768
776
|
}
|
|
769
|
-
},
|
|
770
|
-
loading:
|
|
777
|
+
}, C = Ke(), t = g, b = I(), n = ["selection", "radio", "index", "expand", "sort", "input"], h = I(t.isShowSearch), W = I(""), A = I({}), x = I(t.maxHeight), { selectionChange: H, selectedList: O, selectedListIds: T, isSelected: e } = ta(t.rowKey, t.selectChangeCallback), {
|
|
778
|
+
loading: c,
|
|
771
779
|
tableData: s,
|
|
772
780
|
pageable: l,
|
|
773
781
|
searchParam: v,
|
|
@@ -775,178 +783,178 @@ const pa = /* @__PURE__ */ le({
|
|
|
775
783
|
getTableList: _,
|
|
776
784
|
search: P,
|
|
777
785
|
reset: k,
|
|
778
|
-
handleSizeChange:
|
|
779
|
-
handleCurrentChange:
|
|
780
|
-
} =
|
|
781
|
-
function
|
|
786
|
+
handleSizeChange: F,
|
|
787
|
+
handleCurrentChange: V
|
|
788
|
+
} = ea(t.requestApi, t.initParam, t.pagination, t.dataCallback, t.requestError, t.handleParam), U = (o) => {
|
|
789
|
+
function u(it) {
|
|
782
790
|
return it.replace(/[A-Z]/g, (ct) => "_" + ct.toLowerCase());
|
|
783
791
|
}
|
|
784
|
-
const
|
|
792
|
+
const d = {
|
|
785
793
|
ascending: "asc",
|
|
786
794
|
descending: "desc"
|
|
787
|
-
}, { prop: r, order:
|
|
795
|
+
}, { prop: r, order: E } = o, q = u(R(r)), pe = d[E];
|
|
788
796
|
v.value = {
|
|
789
797
|
...v.value,
|
|
790
|
-
sortKey:
|
|
798
|
+
sortKey: q,
|
|
791
799
|
sortOrder: pe
|
|
792
800
|
}, l.value.page = 1, P();
|
|
793
|
-
}, j = () => b.value.clearSelection(),
|
|
801
|
+
}, j = () => b.value.clearSelection(), Z = () => b.value.clearSort(), N = I(!1), ue = () => {
|
|
794
802
|
at(), t.customColumn && st(), t.requestAuto && _(), t.data && (l.value.total = t.data.length);
|
|
795
803
|
};
|
|
796
804
|
mt(() => {
|
|
797
805
|
ue(), ve(() => {
|
|
798
|
-
|
|
806
|
+
N.value = !0;
|
|
799
807
|
});
|
|
800
808
|
}), gt(() => {
|
|
801
|
-
|
|
809
|
+
N.value && ue();
|
|
802
810
|
}), vt(() => {
|
|
803
811
|
}), bt(() => {
|
|
804
812
|
});
|
|
805
|
-
const ie =
|
|
813
|
+
const ie = D(() => t.data ? t.pagination ? t.data.slice((l.value.page - 1) * l.value.size, l.value.size * l.value.page) : t.data : s.value), Ge = (o) => {
|
|
806
814
|
l.value.total = o;
|
|
807
815
|
};
|
|
808
|
-
|
|
816
|
+
Ct(() => t.initParam, _, { deep: !0 });
|
|
809
817
|
let ne = te(t.columns);
|
|
810
|
-
const
|
|
811
|
-
if (!
|
|
812
|
-
if (typeof
|
|
818
|
+
const Qe = D(() => $e(ne)), ee = I(/* @__PURE__ */ new Map()), Xe = async ({ prop: o, enum: u }) => {
|
|
819
|
+
if (!u || ee.value.has(o) && (typeof u == "function" || ee.value.get(o) === u)) return;
|
|
820
|
+
if (typeof u != "function") return ee.value.set(o, i(u));
|
|
813
821
|
ee.value.set(o, []);
|
|
814
|
-
const { data:
|
|
815
|
-
ee.value.set(o,
|
|
822
|
+
const { data: d } = await u();
|
|
823
|
+
ee.value.set(o, d);
|
|
816
824
|
};
|
|
817
|
-
|
|
818
|
-
const
|
|
825
|
+
yt("enumMap", ee);
|
|
826
|
+
const $e = (o, u = []) => (o.forEach(async (d) => {
|
|
819
827
|
var r;
|
|
820
|
-
(r =
|
|
821
|
-
}),
|
|
828
|
+
(r = d._children) != null && r.length && u.push(...$e(d._children)), u.push(d), d.isShow = d.isShow ?? !0, d.isFilterEnum = d.isFilterEnum ?? !0, await Xe(d);
|
|
829
|
+
}), u.filter((d) => {
|
|
822
830
|
var r;
|
|
823
|
-
return !((r =
|
|
824
|
-
})), Be =
|
|
831
|
+
return !((r = d._children) != null && r.length);
|
|
832
|
+
})), Be = D(() => {
|
|
825
833
|
var o;
|
|
826
|
-
return (o =
|
|
827
|
-
var
|
|
828
|
-
return ((
|
|
829
|
-
}).sort((
|
|
834
|
+
return (o = Qe.value) == null ? void 0 : o.filter((u) => {
|
|
835
|
+
var d, r;
|
|
836
|
+
return ((d = u.search) == null ? void 0 : d.el) || ((r = u.search) == null ? void 0 : r.render);
|
|
837
|
+
}).sort((u, d) => u.search.order - d.search.order);
|
|
830
838
|
});
|
|
831
|
-
(
|
|
832
|
-
var
|
|
833
|
-
o.search.order = ((
|
|
834
|
-
const
|
|
835
|
-
r != null && (B.value[
|
|
839
|
+
(Ie = Be.value) == null || Ie.forEach((o, u) => {
|
|
840
|
+
var E, q, pe;
|
|
841
|
+
o.search.order = ((E = o.search) == null ? void 0 : E.order) ?? u + 2;
|
|
842
|
+
const d = ((q = o.search) == null ? void 0 : q.key) ?? R(o.prop), r = (pe = o.search) == null ? void 0 : pe.defaultValue;
|
|
843
|
+
r != null && (B.value[d] = r, v.value[d] = r);
|
|
836
844
|
});
|
|
837
|
-
const
|
|
845
|
+
const ye = a, et = () => {
|
|
838
846
|
var o;
|
|
839
|
-
t.searchClearSelection && ((o = b.value) == null || o.clearSelection()), P(),
|
|
847
|
+
t.searchClearSelection && ((o = b.value) == null || o.clearSelection()), P(), ye("search");
|
|
840
848
|
}, tt = () => {
|
|
841
|
-
t.beforeReset && t.beforeReset(), k(),
|
|
849
|
+
t.beforeReset && t.beforeReset(), k(), Z(), ye("reset");
|
|
842
850
|
}, at = () => {
|
|
843
851
|
const o = document.querySelector(".el-table__body-wrapper tbody");
|
|
844
|
-
o &&
|
|
852
|
+
o && He.create(o, {
|
|
845
853
|
handle: ".move",
|
|
846
854
|
animation: 300,
|
|
847
|
-
onEnd({ newIndex:
|
|
848
|
-
const [r] = ie.value.splice(
|
|
849
|
-
ie.value.splice(
|
|
855
|
+
onEnd({ newIndex: u, oldIndex: d }) {
|
|
856
|
+
const [r] = ie.value.splice(d, 1);
|
|
857
|
+
ie.value.splice(u, 0, r), ye("dargSort", { newIndex: u, oldIndex: d });
|
|
850
858
|
}
|
|
851
859
|
});
|
|
852
|
-
}, ce =
|
|
853
|
-
const
|
|
854
|
-
|
|
855
|
-
}, ot = async (o,
|
|
856
|
-
|
|
860
|
+
}, ce = I(0), nt = (o, u) => {
|
|
861
|
+
const d = s.value.findIndex((r) => r.$showInput);
|
|
862
|
+
d > -1 && (s.value[d] = G(A.value), s.value[d].$showInput = !1), ce.value = Re(o, String(u)), o.$showInput = !0, A.value = G(o);
|
|
863
|
+
}, ot = async (o, u, d) => {
|
|
864
|
+
Zt(o, u, ce.value), d && await d(o), o.$showInput = !1, Kt.success("更新成功"), await _();
|
|
857
865
|
}, lt = async (o) => {
|
|
858
|
-
const
|
|
859
|
-
|
|
860
|
-
}, ze =
|
|
861
|
-
(o,
|
|
866
|
+
const u = s.value.findIndex((d) => Wt(Ve(d, De), Ve(o, De)));
|
|
867
|
+
u > -1 && (s.value[u] = G(A.value), s.value[u].$showInput = !1);
|
|
868
|
+
}, ze = Qt(t.customColumnCacheKey), Me = I(null), Se = () => ne.map(
|
|
869
|
+
(o, u) => ({
|
|
862
870
|
readonly: o.isCustomDisable || ["id", "operation"].includes(String(o.prop)),
|
|
863
|
-
order:
|
|
864
|
-
index:
|
|
871
|
+
order: u,
|
|
872
|
+
index: u,
|
|
865
873
|
width: o.width || o.minWidth,
|
|
866
874
|
...o
|
|
867
875
|
})
|
|
868
|
-
).sort((o,
|
|
869
|
-
const
|
|
870
|
-
return
|
|
876
|
+
).sort((o, u) => {
|
|
877
|
+
const d = Number(o.order), r = Number(u.order);
|
|
878
|
+
return d - r;
|
|
871
879
|
}), rt = () => {
|
|
872
880
|
de = te(Se()), ve(() => {
|
|
873
|
-
|
|
881
|
+
Me.value.openColSetting(G(de));
|
|
874
882
|
});
|
|
875
883
|
}, st = () => {
|
|
876
884
|
if (!t.customColumnPageCacheKey) return;
|
|
877
885
|
const o = ze.getColumnCache(t.customColumnPageCacheKey);
|
|
878
886
|
if (o != null && o.length) {
|
|
879
|
-
const
|
|
880
|
-
const r = o.find((
|
|
887
|
+
const u = ne.map((d) => {
|
|
888
|
+
const r = o.find((E) => E.prop === d.prop);
|
|
881
889
|
if (r) {
|
|
882
|
-
const
|
|
883
|
-
...
|
|
884
|
-
order: r.order ||
|
|
885
|
-
isShow: r.isShow !== void 0 ? r.isShow :
|
|
886
|
-
readonly: r.readonly !== void 0 ? r.readonly :
|
|
887
|
-
prop: r.prop ||
|
|
888
|
-
index: r.index ||
|
|
890
|
+
const E = {
|
|
891
|
+
...d,
|
|
892
|
+
order: r.order || d.order,
|
|
893
|
+
isShow: r.isShow !== void 0 ? r.isShow : d.isShow,
|
|
894
|
+
readonly: r.readonly !== void 0 ? r.readonly : d.readonly,
|
|
895
|
+
prop: r.prop || d.prop,
|
|
896
|
+
index: r.index || d.index
|
|
889
897
|
};
|
|
890
|
-
return
|
|
898
|
+
return d.minWidth && (E.minWidth = r.minWidth || d.minWidth), d.width && (E.width = r.width || d.width), E;
|
|
891
899
|
}
|
|
892
|
-
return
|
|
900
|
+
return d;
|
|
893
901
|
});
|
|
894
|
-
de = te(
|
|
902
|
+
de = te(u), ne = te(de);
|
|
895
903
|
}
|
|
896
904
|
};
|
|
897
905
|
let de = te(Se());
|
|
898
|
-
const
|
|
906
|
+
const Fe = G(Se()), ut = (o) => {
|
|
899
907
|
if (!t.customColumnPageCacheKey) return console.error("请添加自定义列缓存配置项:customColumnPageCacheKey");
|
|
900
|
-
o = o.map((
|
|
901
|
-
const
|
|
902
|
-
return
|
|
903
|
-
}), ne = te(
|
|
908
|
+
o = o.map((u) => {
|
|
909
|
+
const d = Fe.find((r) => r.prop === u.prop);
|
|
910
|
+
return d && d.minWidth && (u.minWidth = u.width, delete u.width), u;
|
|
911
|
+
}), ne = te(G(o)), ze.setColumnCache(t.customColumnPageCacheKey, o), f.value = (/* @__PURE__ */ new Date()).getTime(), b.value.doLayout();
|
|
904
912
|
};
|
|
905
|
-
return
|
|
913
|
+
return p({
|
|
906
914
|
element: b,
|
|
907
915
|
tableData: ie,
|
|
908
916
|
radio: W,
|
|
909
917
|
pageable: l,
|
|
910
918
|
searchParam: v,
|
|
911
919
|
searchInitParam: B,
|
|
912
|
-
setPageTotal:
|
|
920
|
+
setPageTotal: Ge,
|
|
913
921
|
getTableList: _,
|
|
914
922
|
search: P,
|
|
915
923
|
reset: k,
|
|
916
|
-
handleSizeChange:
|
|
917
|
-
handleCurrentChange:
|
|
924
|
+
handleSizeChange: F,
|
|
925
|
+
handleCurrentChange: V,
|
|
918
926
|
clearSelection: j,
|
|
919
927
|
enumMap: ee,
|
|
920
928
|
isSelected: e,
|
|
921
929
|
selectedList: O,
|
|
922
930
|
selectedListIds: T
|
|
923
|
-
}), (o,
|
|
924
|
-
const
|
|
925
|
-
return
|
|
931
|
+
}), (o, u) => {
|
|
932
|
+
const d = St("loading");
|
|
933
|
+
return y(), L(i(Rt), { locale: i(Ot) }, {
|
|
926
934
|
default: S(() => [
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
o.title ? (
|
|
930
|
-
|
|
931
|
-
|
|
935
|
+
$("div", _a, [
|
|
936
|
+
$("div", Pa, [
|
|
937
|
+
o.title ? (y(), M("div", Ta, X(o.title), 1)) : z("", !0),
|
|
938
|
+
i(C).headerTip ? (y(), M("div", Ea, [
|
|
939
|
+
K(o.$slots, "headerTip", {}, void 0, !0)
|
|
932
940
|
])) : z("", !0)
|
|
933
941
|
]),
|
|
934
|
-
|
|
935
|
-
we(w(
|
|
942
|
+
$("div", $a, [
|
|
943
|
+
we(w(ia, {
|
|
936
944
|
search: et,
|
|
937
945
|
reset: tt,
|
|
938
946
|
columns: Be.value,
|
|
939
|
-
"search-param":
|
|
947
|
+
"search-param": i(v),
|
|
940
948
|
"is-show-reset-btn": t.isShowResetBtn,
|
|
941
949
|
"is-show-search-btn": t.isShowSearchBtn
|
|
942
950
|
}, {
|
|
943
951
|
default: S(() => [
|
|
944
|
-
o.$slots.tableHeader ? (
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
selectedList:
|
|
948
|
-
selectedListIds:
|
|
949
|
-
isSelected:
|
|
952
|
+
o.$slots.tableHeader ? (y(), M("div", Ba, [
|
|
953
|
+
$("div", za, [
|
|
954
|
+
K(o.$slots, "tableHeader", {
|
|
955
|
+
selectedList: i(O),
|
|
956
|
+
selectedListIds: i(T),
|
|
957
|
+
isSelected: i(e)
|
|
950
958
|
}, void 0, !0)
|
|
951
959
|
])
|
|
952
960
|
])) : z("", !0)
|
|
@@ -956,28 +964,28 @@ const pa = /* @__PURE__ */ le({
|
|
|
956
964
|
[wt, h.value]
|
|
957
965
|
])
|
|
958
966
|
]),
|
|
959
|
-
|
|
960
|
-
|
|
967
|
+
i(C).searchBarBottom ? (y(), M("div", Ma, [
|
|
968
|
+
K(o.$slots, "searchBarBottom", {}, void 0, !0)
|
|
961
969
|
])) : z("", !0),
|
|
962
|
-
|
|
963
|
-
t.customColumn ? (
|
|
970
|
+
$("div", Fa, [
|
|
971
|
+
t.customColumn ? (y(), M("div", {
|
|
964
972
|
key: 0,
|
|
965
973
|
class: "col-setting-button",
|
|
966
974
|
onClick: rt
|
|
967
975
|
}, [
|
|
968
|
-
w(
|
|
976
|
+
w(i(be), {
|
|
969
977
|
class: "box-item",
|
|
970
978
|
effect: "dark",
|
|
971
979
|
content: "自定义列",
|
|
972
980
|
placement: "top"
|
|
973
981
|
}, {
|
|
974
982
|
default: S(() => [
|
|
975
|
-
w(
|
|
983
|
+
w(i(Ce), {
|
|
976
984
|
size: 16,
|
|
977
985
|
color: "#000000a6"
|
|
978
986
|
}, {
|
|
979
987
|
default: S(() => [
|
|
980
|
-
w(
|
|
988
|
+
w(i(At))
|
|
981
989
|
]),
|
|
982
990
|
_: 1
|
|
983
991
|
})
|
|
@@ -985,7 +993,7 @@ const pa = /* @__PURE__ */ le({
|
|
|
985
993
|
_: 1
|
|
986
994
|
})
|
|
987
995
|
])) : z("", !0),
|
|
988
|
-
we((
|
|
996
|
+
we((y(), L(i(Je), Y({
|
|
989
997
|
ref_key: "tableRef",
|
|
990
998
|
ref: b
|
|
991
999
|
}, o.$attrs, {
|
|
@@ -993,109 +1001,111 @@ const pa = /* @__PURE__ */ le({
|
|
|
993
1001
|
data: ie.value,
|
|
994
1002
|
border: o.border,
|
|
995
1003
|
"row-key": o.rowKey,
|
|
996
|
-
"max-height":
|
|
1004
|
+
"max-height": x.value,
|
|
997
1005
|
"row-style": { height: "42px" },
|
|
998
1006
|
"tooltip-effect": "light",
|
|
999
|
-
"tooltip-options": { showArrow: !1, placement: "bottom-start", offset: t.offset ? t.offset : -20 }
|
|
1007
|
+
"tooltip-options": { showArrow: !1, placement: "bottom-start", offset: t.offset ? t.offset : -20 },
|
|
1008
|
+
"element-loading-spinner": i(Xt),
|
|
1009
|
+
"element-loading-svg-view-box": "0 0 64 64"
|
|
1000
1010
|
}, kt(o.$attrs), {
|
|
1001
|
-
onSelectionChange:
|
|
1002
|
-
onSortChange:
|
|
1011
|
+
onSelectionChange: i(H),
|
|
1012
|
+
onSortChange: u[1] || (u[1] = (r) => t.onSortChange ? t.onSortChange(r) : U(r))
|
|
1003
1013
|
}), {
|
|
1004
1014
|
append: S(() => [
|
|
1005
|
-
|
|
1015
|
+
K(o.$slots, "append", {}, void 0, !0)
|
|
1006
1016
|
]),
|
|
1007
1017
|
empty: S(() => [
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
src: `${
|
|
1018
|
+
$("div", Va, [
|
|
1019
|
+
K(o.$slots, "empty", {}, () => [
|
|
1020
|
+
$("img", {
|
|
1021
|
+
src: `${i(jt)}ghy-components/empty.png`,
|
|
1012
1022
|
class: "zh-empty-img",
|
|
1013
1023
|
alt: "notData"
|
|
1014
1024
|
}, null, 8, Da),
|
|
1015
|
-
|
|
1025
|
+
u[5] || (u[5] = $("div", null, "暂无数据", -1))
|
|
1016
1026
|
], !0)
|
|
1017
1027
|
])
|
|
1018
1028
|
]),
|
|
1019
1029
|
default: S(() => [
|
|
1020
|
-
(
|
|
1021
|
-
r.type && n.includes(r.type) && r.isShow ? (
|
|
1030
|
+
(y(!0), M(J, null, ge(i(ne).sort((r, E) => r.order - E.order), (r) => (y(), M(J, { key: r }, [
|
|
1031
|
+
r.type && n.includes(r.type) && r.isShow ? (y(), L(i(re), Y({
|
|
1022
1032
|
key: 0,
|
|
1023
1033
|
ref_for: !0
|
|
1024
1034
|
}, r, {
|
|
1025
1035
|
align: r.align ?? "left",
|
|
1026
1036
|
"reserve-selection": r.type == "selection"
|
|
1027
1037
|
}), me({
|
|
1028
|
-
default: S((
|
|
1029
|
-
r.type == "expand" ? (
|
|
1030
|
-
r.render ? (
|
|
1038
|
+
default: S((E) => [
|
|
1039
|
+
r.type == "expand" ? (y(), M(J, { key: 0 }, [
|
|
1040
|
+
r.render ? (y(), L(fe(r.render), Y({
|
|
1031
1041
|
key: 0,
|
|
1032
1042
|
ref_for: !0
|
|
1033
|
-
},
|
|
1043
|
+
}, E), null, 16)) : K(o.$slots, r.type, Y({
|
|
1034
1044
|
key: 1,
|
|
1035
1045
|
ref_for: !0
|
|
1036
|
-
},
|
|
1046
|
+
}, E), void 0, !0)
|
|
1037
1047
|
], 64)) : z("", !0),
|
|
1038
|
-
r.type == "sort" ? (
|
|
1048
|
+
r.type == "sort" ? (y(), L(i(xe), {
|
|
1039
1049
|
key: 1,
|
|
1040
1050
|
class: "move"
|
|
1041
1051
|
}, {
|
|
1042
1052
|
default: S(() => [
|
|
1043
|
-
w(
|
|
1053
|
+
w(i(Ce), null, {
|
|
1044
1054
|
default: S(() => [
|
|
1045
|
-
w(
|
|
1055
|
+
w(i(Ut))
|
|
1046
1056
|
]),
|
|
1047
1057
|
_: 1
|
|
1048
1058
|
})
|
|
1049
1059
|
]),
|
|
1050
1060
|
_: 1
|
|
1051
1061
|
})) : z("", !0),
|
|
1052
|
-
r.type == "input" ? (
|
|
1053
|
-
|
|
1054
|
-
we(w(
|
|
1062
|
+
r.type == "input" ? (y(), M(J, { key: 2 }, [
|
|
1063
|
+
E.row.$showInput ? (y(), M("div", La, [
|
|
1064
|
+
we(w(i(Ye), {
|
|
1055
1065
|
modelValue: ce.value,
|
|
1056
|
-
"onUpdate:modelValue":
|
|
1066
|
+
"onUpdate:modelValue": u[0] || (u[0] = (q) => ce.value = q),
|
|
1057
1067
|
min: 0,
|
|
1058
1068
|
controls: !1
|
|
1059
1069
|
}, null, 8, ["modelValue"]), [
|
|
1060
1070
|
[m]
|
|
1061
1071
|
]),
|
|
1062
|
-
w(
|
|
1072
|
+
w(i(ke), {
|
|
1063
1073
|
underline: !1,
|
|
1064
1074
|
type: "primary",
|
|
1065
|
-
onClick: (
|
|
1075
|
+
onClick: (q) => ot(E.row, String(r.prop), r.blurCallback),
|
|
1066
1076
|
class: "ml-5"
|
|
1067
1077
|
}, {
|
|
1068
|
-
default: S(() =>
|
|
1069
|
-
|
|
1078
|
+
default: S(() => u[3] || (u[3] = [
|
|
1079
|
+
Q(" 保存 ")
|
|
1070
1080
|
])),
|
|
1071
1081
|
_: 2
|
|
1072
1082
|
}, 1032, ["onClick"]),
|
|
1073
|
-
w(
|
|
1083
|
+
w(i(ke), {
|
|
1074
1084
|
type: "primary",
|
|
1075
1085
|
underline: !1,
|
|
1076
|
-
onClick: (
|
|
1086
|
+
onClick: (q) => lt(E.row),
|
|
1077
1087
|
class: "ml-5"
|
|
1078
1088
|
}, {
|
|
1079
|
-
default: S(() =>
|
|
1080
|
-
|
|
1089
|
+
default: S(() => u[4] || (u[4] = [
|
|
1090
|
+
Q(" 取消 ")
|
|
1081
1091
|
])),
|
|
1082
1092
|
_: 2
|
|
1083
1093
|
}, 1032, ["onClick"])
|
|
1084
|
-
])) : (
|
|
1094
|
+
])) : (y(), L(i(be), {
|
|
1085
1095
|
key: 0,
|
|
1086
1096
|
content: "编辑",
|
|
1087
1097
|
placement: "top"
|
|
1088
1098
|
}, {
|
|
1089
1099
|
default: S(() => [
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
w(
|
|
1100
|
+
$("span", Ia, [
|
|
1101
|
+
Q(X(i(Re)(E.row, String(r.prop))) + " ", 1),
|
|
1102
|
+
w(i(ke), {
|
|
1093
1103
|
underline: !1,
|
|
1094
1104
|
class: "text d-flex inline-input-text pointer",
|
|
1095
|
-
onClick: (
|
|
1105
|
+
onClick: (q) => nt(E.row, r.prop)
|
|
1096
1106
|
}, {
|
|
1097
|
-
default: S(() =>
|
|
1098
|
-
|
|
1107
|
+
default: S(() => u[2] || (u[2] = [
|
|
1108
|
+
$("i", { class: "iconfont icon-edit" }, null, -1)
|
|
1099
1109
|
])),
|
|
1100
1110
|
_: 2
|
|
1101
1111
|
}, 1032, ["onClick"])
|
|
@@ -1109,50 +1119,50 @@ const pa = /* @__PURE__ */ le({
|
|
|
1109
1119
|
}, [
|
|
1110
1120
|
r.headerRender ? {
|
|
1111
1121
|
name: "header",
|
|
1112
|
-
fn: S((
|
|
1113
|
-
(
|
|
1122
|
+
fn: S((E) => [
|
|
1123
|
+
(y(), L(fe(r.headerRender), Y({ ref_for: !0 }, E), null, 16))
|
|
1114
1124
|
]),
|
|
1115
1125
|
key: "0"
|
|
1116
1126
|
} : void 0
|
|
1117
1127
|
]), 1040, ["align", "reserve-selection"])) : z("", !0),
|
|
1118
|
-
!r.type && r.prop && r.isShow ? (
|
|
1128
|
+
!r.type && r.prop && r.isShow ? (y(), L(ha, {
|
|
1119
1129
|
key: 1,
|
|
1120
1130
|
column: r,
|
|
1121
1131
|
"custom-column": o.customColumn
|
|
1122
1132
|
}, me({ _: 2 }, [
|
|
1123
|
-
ge(Object.keys(o.$slots), (
|
|
1124
|
-
name:
|
|
1125
|
-
fn: S((
|
|
1126
|
-
|
|
1133
|
+
ge(Object.keys(o.$slots), (E) => ({
|
|
1134
|
+
name: E,
|
|
1135
|
+
fn: S((q) => [
|
|
1136
|
+
K(o.$slots, E, Y({ ref_for: !0 }, q), void 0, !0)
|
|
1127
1137
|
])
|
|
1128
1138
|
}))
|
|
1129
1139
|
]), 1032, ["column", "custom-column"])) : z("", !0)
|
|
1130
1140
|
], 64))), 128))
|
|
1131
1141
|
]),
|
|
1132
1142
|
_: 3
|
|
1133
|
-
}, 16, ["data", "border", "row-key", "max-height", "tooltip-options", "onSelectionChange"])), [
|
|
1134
|
-
[
|
|
1143
|
+
}, 16, ["data", "border", "row-key", "max-height", "tooltip-options", "element-loading-spinner", "onSelectionChange"])), [
|
|
1144
|
+
[d, i(c)]
|
|
1135
1145
|
])
|
|
1136
1146
|
]),
|
|
1137
|
-
|
|
1138
|
-
o.pagination ? (
|
|
1147
|
+
K(o.$slots, "pagination", {}, () => [
|
|
1148
|
+
o.pagination ? (y(), L(pa, {
|
|
1139
1149
|
key: 0,
|
|
1140
|
-
pageable:
|
|
1141
|
-
"handle-size-change":
|
|
1142
|
-
"handle-current-change":
|
|
1150
|
+
pageable: i(l),
|
|
1151
|
+
"handle-size-change": i(F),
|
|
1152
|
+
"handle-current-change": i(V)
|
|
1143
1153
|
}, {
|
|
1144
1154
|
zhPaginationLeftSlot: S((r) => [
|
|
1145
|
-
|
|
1155
|
+
K(o.$slots, "zhPaginationLeft", We(je(r)), void 0, !0)
|
|
1146
1156
|
]),
|
|
1147
1157
|
_: 3
|
|
1148
1158
|
}, 8, ["pageable", "handle-size-change", "handle-current-change"])) : z("", !0)
|
|
1149
1159
|
], !0)
|
|
1150
1160
|
]),
|
|
1151
|
-
t.customColumn ? (
|
|
1161
|
+
t.customColumn ? (y(), L(ka, {
|
|
1152
1162
|
key: 0,
|
|
1153
1163
|
ref_key: "colRef",
|
|
1154
|
-
ref:
|
|
1155
|
-
"origin-table-columns":
|
|
1164
|
+
ref: Me,
|
|
1165
|
+
"origin-table-columns": i(Fe),
|
|
1156
1166
|
onSubmit: ut
|
|
1157
1167
|
}, null, 8, ["origin-table-columns"])) : z("", !0)
|
|
1158
1168
|
]),
|
|
@@ -1160,7 +1170,7 @@ const pa = /* @__PURE__ */ le({
|
|
|
1160
1170
|
}, 8, ["locale"]);
|
|
1161
1171
|
};
|
|
1162
1172
|
}
|
|
1163
|
-
}),
|
|
1173
|
+
}), Oa = /* @__PURE__ */ se(Ra, [["__scopeId", "data-v-cea8b715"]]), qa = xt(Oa);
|
|
1164
1174
|
export {
|
|
1165
1175
|
qa as Z,
|
|
1166
1176
|
oe as g
|