erp-plus 1.0.20 → 1.0.21
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/erp-plus.es.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import kA, { ElOption as vA, ElSelect as zA } from "element-plus";
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
const sA = /* @__PURE__ */
|
|
2
|
+
import { defineComponent as x, useSlots as fA, resolveComponent as O, createBlock as Y, openBlock as c, mergeProps as F, createSlots as tA, renderList as R, unref as h, withCtx as f, renderSlot as N, normalizeProps as nA, guardReactiveProps as dA, computed as Z, createElementBlock as D, normalizeStyle as X, normalizeClass as gA, h as J, createVNode as S, isRef as oA, ref as W, Fragment as eA, resolveDynamicComponent as YA, createTextVNode as wA, toDisplayString as $, createElementVNode as L, createCommentVNode as _, watch as yA, withKeys as SA } from "vue";
|
|
3
|
+
const sA = /* @__PURE__ */ x({
|
|
4
4
|
__name: "Button",
|
|
5
5
|
props: {
|
|
6
6
|
// 基础属性
|
|
@@ -79,20 +79,20 @@ const sA = /* @__PURE__ */ L({
|
|
|
79
79
|
}
|
|
80
80
|
},
|
|
81
81
|
emits: ["click"],
|
|
82
|
-
setup(A, { emit:
|
|
83
|
-
const
|
|
84
|
-
|
|
82
|
+
setup(A, { emit: u }) {
|
|
83
|
+
const t = fA(), l = A, e = u, r = (g) => {
|
|
84
|
+
e("click", g);
|
|
85
85
|
};
|
|
86
|
-
return (
|
|
87
|
-
const
|
|
88
|
-
return
|
|
86
|
+
return (g, m) => {
|
|
87
|
+
const C = O("el-button");
|
|
88
|
+
return c(), Y(C, F(l, {
|
|
89
89
|
class: ["yw-button-" + A.type, "yw-button"],
|
|
90
|
-
onClick:
|
|
90
|
+
onClick: r
|
|
91
91
|
}), tA({ _: 2 }, [
|
|
92
|
-
|
|
93
|
-
name:
|
|
94
|
-
fn:
|
|
95
|
-
|
|
92
|
+
R(h(t), (i, w) => ({
|
|
93
|
+
name: w,
|
|
94
|
+
fn: f((y) => [
|
|
95
|
+
N(g.$slots, w, nA(dA(y || {})))
|
|
96
96
|
])
|
|
97
97
|
}))
|
|
98
98
|
]), 1040, ["class"]);
|
|
@@ -131,10 +131,10 @@ const ZA = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//D
|
|
|
131
131
|
"./more.svg": oe
|
|
132
132
|
}), KA = {};
|
|
133
133
|
for (const A in MA) {
|
|
134
|
-
const
|
|
135
|
-
|
|
134
|
+
const u = A.split("/").pop()?.replace(".svg", "");
|
|
135
|
+
u && (KA[u] = MA[A]);
|
|
136
136
|
}
|
|
137
|
-
const ne = ["innerHTML"], se = /* @__PURE__ */
|
|
137
|
+
const ne = ["innerHTML"], se = /* @__PURE__ */ x({
|
|
138
138
|
__name: "index",
|
|
139
139
|
props: {
|
|
140
140
|
iconClass: {
|
|
@@ -156,34 +156,34 @@ const ne = ["innerHTML"], se = /* @__PURE__ */ L({
|
|
|
156
156
|
}
|
|
157
157
|
},
|
|
158
158
|
setup(A) {
|
|
159
|
-
const
|
|
160
|
-
const
|
|
161
|
-
return
|
|
162
|
-
}),
|
|
163
|
-
const
|
|
159
|
+
const u = A, t = Z(() => u.className ? `erp-svg-icon ${u.className}` : "erp-svg-icon"), l = Z(() => {
|
|
160
|
+
const r = KA[u.iconClass];
|
|
161
|
+
return r || (console.warn(`[ErpPlus] 图标 "${u.iconClass}" 不存在,请检查 src/assets 目录`), "");
|
|
162
|
+
}), e = Z(() => {
|
|
163
|
+
const r = typeof u.size == "number" ? u.size + "px" : u.size;
|
|
164
164
|
return {
|
|
165
|
-
width:
|
|
166
|
-
height:
|
|
167
|
-
color:
|
|
165
|
+
width: r,
|
|
166
|
+
height: r,
|
|
167
|
+
color: u.color,
|
|
168
168
|
display: "inline-flex",
|
|
169
169
|
alignItems: "center",
|
|
170
170
|
justifyContent: "center",
|
|
171
171
|
verticalAlign: "middle"
|
|
172
172
|
};
|
|
173
173
|
});
|
|
174
|
-
return (
|
|
175
|
-
class: gA(
|
|
174
|
+
return (r, g) => (c(), D("i", {
|
|
175
|
+
class: gA(t.value),
|
|
176
176
|
innerHTML: l.value,
|
|
177
|
-
style:
|
|
177
|
+
style: X(e.value),
|
|
178
178
|
"aria-hidden": "true"
|
|
179
179
|
}, null, 14, ne));
|
|
180
180
|
}
|
|
181
|
-
}), DA = (A,
|
|
182
|
-
const
|
|
183
|
-
for (const [l,
|
|
184
|
-
|
|
185
|
-
return
|
|
186
|
-
},
|
|
181
|
+
}), DA = (A, u) => {
|
|
182
|
+
const t = A.__vccOpts || A;
|
|
183
|
+
for (const [l, e] of u)
|
|
184
|
+
t[l] = e;
|
|
185
|
+
return t;
|
|
186
|
+
}, U = /* @__PURE__ */ DA(se, [["__scopeId", "data-v-18665067"]]), BA = /* @__PURE__ */ x({
|
|
187
187
|
__name: "DatePicker",
|
|
188
188
|
props: {
|
|
189
189
|
modelValue: {
|
|
@@ -261,7 +261,7 @@ const ne = ["innerHTML"], se = /* @__PURE__ */ L({
|
|
|
261
261
|
},
|
|
262
262
|
prefixIcon: {
|
|
263
263
|
type: [String, Object],
|
|
264
|
-
default: () =>
|
|
264
|
+
default: () => J("svg", {
|
|
265
265
|
viewBox: "0 0 1024 1024",
|
|
266
266
|
width: "16",
|
|
267
267
|
height: "16",
|
|
@@ -270,20 +270,20 @@ const ne = ["innerHTML"], se = /* @__PURE__ */ L({
|
|
|
270
270
|
"aria-hidden": "true",
|
|
271
271
|
style: { color: "#838599" }
|
|
272
272
|
}, [
|
|
273
|
-
|
|
273
|
+
J("path", {
|
|
274
274
|
d: "M640 53.312a32 32 0 0 1 32 32V256a32 32 0 0 1-64 0v-53.312H448a32 32 0 0 1 0-64h160v-53.312a32 32 0 0 1 32-32zM96 426.688a32 32 0 0 1 32-32h768a32 32 0 0 1 32 32v384c0 64.768-52.48 117.312-117.312 117.312H213.312A117.312 117.312 0 0 1 96 810.688v-384z m64 32v352c0 29.44 23.872 53.312 53.312 53.312h597.376c29.44 0 53.312-23.872 53.312-53.312v-352h-704z"
|
|
275
275
|
}),
|
|
276
|
-
|
|
276
|
+
J("path", {
|
|
277
277
|
d: "M213.312 202.688A53.312 53.312 0 0 0 160 256v170.688a32 32 0 0 1-64 0V256c0-64.768 52.48-117.312 117.312-117.312h85.376a32 32 0 0 1 0 64H213.312z"
|
|
278
278
|
}),
|
|
279
|
-
|
|
279
|
+
J("path", {
|
|
280
280
|
d: "M298.688 53.312a32 32 0 0 1 32 32V256a32 32 0 1 1-64 0V85.312a32 32 0 0 1 32-32zM757.312 170.688a32 32 0 0 1 32-32h21.376c64.768 0 117.312 52.48 117.312 117.312v170.688a32 32 0 0 1-64 0V256a53.312 53.312 0 0 0-53.312-53.312h-21.376a32 32 0 0 1-32-32z"
|
|
281
281
|
})
|
|
282
282
|
])
|
|
283
283
|
},
|
|
284
284
|
clearIcon: {
|
|
285
285
|
type: [String, Object],
|
|
286
|
-
default: () =>
|
|
286
|
+
default: () => J("svg", {
|
|
287
287
|
viewBox: "0 0 1024 1024",
|
|
288
288
|
width: "12",
|
|
289
289
|
height: "12",
|
|
@@ -291,7 +291,7 @@ const ne = ["innerHTML"], se = /* @__PURE__ */ L({
|
|
|
291
291
|
class: "your-prefix-clear-icon",
|
|
292
292
|
style: { color: "#b2b4c6" }
|
|
293
293
|
}, [
|
|
294
|
-
|
|
294
|
+
J("path", {
|
|
295
295
|
d: "M0 512a512 512 0 1 0 1024 0A512 512 0 0 0 0 512z m631.210667-179.541333a42.666667 42.666667 0 0 1 60.330666 60.416L572.330667 512l119.210666 119.125333a42.666667 42.666667 0 0 1-60.330666 60.416L512 572.330667 392.874667 691.541333a42.666667 42.666667 0 0 1-60.330667-60.416L451.669333 512 332.544 392.874667a42.666667 42.666667 0 1 1 60.330667-60.416L512 451.669333l119.210667-119.210666z"
|
|
296
296
|
})
|
|
297
297
|
])
|
|
@@ -342,66 +342,66 @@ const ne = ["innerHTML"], se = /* @__PURE__ */ L({
|
|
|
342
342
|
}
|
|
343
343
|
},
|
|
344
344
|
emits: ["update:modelValue", "change", "clear", "blur", "focus", "calendar-change", "visible-change", "panel-change"],
|
|
345
|
-
setup(A, { emit:
|
|
346
|
-
const
|
|
345
|
+
setup(A, { emit: u }) {
|
|
346
|
+
const t = A, l = Z(() => t.type === "daterange" || t.type === "datetimerange" ? `yw-daterange-picker ${t.popperClass}` : `yw-date-picker ${t.popperClass}`), e = u, r = Z({
|
|
347
347
|
get() {
|
|
348
|
-
return
|
|
348
|
+
return t.modelValue;
|
|
349
349
|
},
|
|
350
|
-
set(
|
|
351
|
-
|
|
350
|
+
set(p) {
|
|
351
|
+
e("update:modelValue", p);
|
|
352
352
|
}
|
|
353
|
-
}),
|
|
354
|
-
|
|
355
|
-
},
|
|
356
|
-
|
|
357
|
-
},
|
|
358
|
-
|
|
359
|
-
},
|
|
360
|
-
|
|
361
|
-
},
|
|
362
|
-
|
|
363
|
-
},
|
|
364
|
-
|
|
365
|
-
},
|
|
366
|
-
|
|
353
|
+
}), g = (p) => {
|
|
354
|
+
e("change", p);
|
|
355
|
+
}, m = (p) => {
|
|
356
|
+
e("clear", p);
|
|
357
|
+
}, C = (p) => {
|
|
358
|
+
e("blur", p);
|
|
359
|
+
}, i = (p) => {
|
|
360
|
+
e("focus", p);
|
|
361
|
+
}, w = (p) => {
|
|
362
|
+
e("calendar-change", p);
|
|
363
|
+
}, y = (p) => {
|
|
364
|
+
e("visible-change", p);
|
|
365
|
+
}, M = (p) => {
|
|
366
|
+
e("panel-change", p);
|
|
367
367
|
};
|
|
368
|
-
return (
|
|
369
|
-
const
|
|
370
|
-
return
|
|
371
|
-
modelValue:
|
|
372
|
-
"onUpdate:modelValue":
|
|
368
|
+
return (p, s) => {
|
|
369
|
+
const I = O("el-date-picker");
|
|
370
|
+
return c(), Y(I, F(t, {
|
|
371
|
+
modelValue: r.value,
|
|
372
|
+
"onUpdate:modelValue": s[0] || (s[0] = (a) => r.value = a),
|
|
373
373
|
popperClass: l.value,
|
|
374
|
-
onChange:
|
|
375
|
-
onClear:
|
|
376
|
-
onBlur:
|
|
377
|
-
onFocus:
|
|
378
|
-
onCalendarChange:
|
|
379
|
-
onVisibleChange:
|
|
380
|
-
onPanelChange:
|
|
374
|
+
onChange: g,
|
|
375
|
+
onClear: m,
|
|
376
|
+
onBlur: C,
|
|
377
|
+
onFocus: i,
|
|
378
|
+
onCalendarChange: w,
|
|
379
|
+
onVisibleChange: y,
|
|
380
|
+
onPanelChange: M
|
|
381
381
|
}), {
|
|
382
|
-
"prev-month":
|
|
383
|
-
|
|
382
|
+
"prev-month": f(() => [
|
|
383
|
+
S(U, {
|
|
384
384
|
iconClass: "16_16_arrow_left",
|
|
385
385
|
color: "#1a1a1a",
|
|
386
386
|
style: { width: "16px", height: "16px" }
|
|
387
387
|
})
|
|
388
388
|
]),
|
|
389
|
-
"next-month":
|
|
390
|
-
|
|
389
|
+
"next-month": f(() => [
|
|
390
|
+
S(U, {
|
|
391
391
|
iconClass: "16_16_arrow_right",
|
|
392
392
|
color: "#1a1a1a",
|
|
393
393
|
style: { width: "16px", height: "16px" }
|
|
394
394
|
})
|
|
395
395
|
]),
|
|
396
|
-
"prev-year":
|
|
397
|
-
|
|
396
|
+
"prev-year": f(() => [
|
|
397
|
+
S(U, {
|
|
398
398
|
iconClass: "16_16_arrow_2left",
|
|
399
399
|
color: "#1a1a1a",
|
|
400
400
|
style: { width: "16px", height: "16px" }
|
|
401
401
|
})
|
|
402
402
|
]),
|
|
403
|
-
"next-year":
|
|
404
|
-
|
|
403
|
+
"next-year": f(() => [
|
|
404
|
+
S(U, {
|
|
405
405
|
iconClass: "16_16_arrow_2right",
|
|
406
406
|
color: "#1a1a1a",
|
|
407
407
|
style: { width: "16px", height: "16px" }
|
|
@@ -415,7 +415,7 @@ const ne = ["innerHTML"], se = /* @__PURE__ */ L({
|
|
|
415
415
|
BA.install = (A) => {
|
|
416
416
|
A.component("YwDatePicker", BA);
|
|
417
417
|
};
|
|
418
|
-
const pA = /* @__PURE__ */
|
|
418
|
+
const pA = /* @__PURE__ */ x({
|
|
419
419
|
__name: "Avatar",
|
|
420
420
|
props: {
|
|
421
421
|
size: {
|
|
@@ -448,17 +448,17 @@ const pA = /* @__PURE__ */ L({
|
|
|
448
448
|
}
|
|
449
449
|
},
|
|
450
450
|
emits: ["error"],
|
|
451
|
-
setup(A, { emit:
|
|
452
|
-
const
|
|
453
|
-
l("error",
|
|
451
|
+
setup(A, { emit: u }) {
|
|
452
|
+
const t = A, l = u, e = (r) => {
|
|
453
|
+
l("error", r);
|
|
454
454
|
};
|
|
455
|
-
return (
|
|
456
|
-
const
|
|
457
|
-
return
|
|
458
|
-
|
|
459
|
-
name:
|
|
460
|
-
fn:
|
|
461
|
-
|
|
455
|
+
return (r, g) => {
|
|
456
|
+
const m = O("el-avatar");
|
|
457
|
+
return c(), Y(m, F(t, { onError: e }), tA({ _: 2 }, [
|
|
458
|
+
R(r.$slots, (C, i) => ({
|
|
459
|
+
name: i,
|
|
460
|
+
fn: f((w) => [
|
|
461
|
+
N(r.$slots, i, nA(dA(w || {})))
|
|
462
462
|
])
|
|
463
463
|
}))
|
|
464
464
|
]), 1040);
|
|
@@ -468,7 +468,7 @@ const pA = /* @__PURE__ */ L({
|
|
|
468
468
|
pA.install = (A) => {
|
|
469
469
|
A.component("YwAvatar", pA);
|
|
470
470
|
};
|
|
471
|
-
const mA = /* @__PURE__ */
|
|
471
|
+
const mA = /* @__PURE__ */ x({
|
|
472
472
|
__name: "Input",
|
|
473
473
|
props: {
|
|
474
474
|
modelValue: {
|
|
@@ -493,7 +493,7 @@ const mA = /* @__PURE__ */ L({
|
|
|
493
493
|
},
|
|
494
494
|
clearIcon: {
|
|
495
495
|
type: [String, Object],
|
|
496
|
-
default: () =>
|
|
496
|
+
default: () => J("svg", {
|
|
497
497
|
viewBox: "0 0 1024 1024",
|
|
498
498
|
width: "12",
|
|
499
499
|
height: "12",
|
|
@@ -501,7 +501,7 @@ const mA = /* @__PURE__ */ L({
|
|
|
501
501
|
class: "your-prefix-clear-icon",
|
|
502
502
|
style: { color: "#b2b4c6" }
|
|
503
503
|
}, [
|
|
504
|
-
|
|
504
|
+
J("path", {
|
|
505
505
|
d: "M0 512a512 512 0 1 0 1024 0A512 512 0 0 0 0 512z m631.210667-179.541333a42.666667 42.666667 0 0 1 60.330666 60.416L572.330667 512l119.210666 119.125333a42.666667 42.666667 0 0 1-60.330666 60.416L512 572.330667 392.874667 691.541333a42.666667 42.666667 0 0 1-60.330667-60.416L451.669333 512 332.544 392.874667a42.666667 42.666667 0 1 1 60.330667-60.416L512 451.669333l119.210667-119.210666z"
|
|
506
506
|
})
|
|
507
507
|
])
|
|
@@ -612,59 +612,59 @@ const mA = /* @__PURE__ */ L({
|
|
|
612
612
|
}
|
|
613
613
|
},
|
|
614
614
|
emits: ["update:modelValue", "change", "blur", "focus", "input", "clear", "keydown", "mouseleave", "mouseenter", "compositionstart", "compositionupdate", "compositionend"],
|
|
615
|
-
setup(A, { emit:
|
|
616
|
-
const
|
|
615
|
+
setup(A, { emit: u }) {
|
|
616
|
+
const t = A, l = u, e = Z({
|
|
617
617
|
get() {
|
|
618
|
-
return
|
|
618
|
+
return t.modelValue;
|
|
619
619
|
},
|
|
620
620
|
set(a) {
|
|
621
621
|
l("update:modelValue", a);
|
|
622
622
|
}
|
|
623
|
-
}),
|
|
623
|
+
}), r = (a) => {
|
|
624
624
|
l("input", a);
|
|
625
|
-
},
|
|
625
|
+
}, g = (a) => {
|
|
626
626
|
l("change", a);
|
|
627
|
-
},
|
|
627
|
+
}, m = (a) => {
|
|
628
628
|
l("blur", a);
|
|
629
|
-
},
|
|
629
|
+
}, C = (a) => {
|
|
630
630
|
l("focus", a);
|
|
631
|
-
},
|
|
631
|
+
}, i = () => {
|
|
632
632
|
l("clear");
|
|
633
|
-
},
|
|
633
|
+
}, w = (a) => {
|
|
634
634
|
l("keydown", a);
|
|
635
|
-
},
|
|
635
|
+
}, y = (a) => {
|
|
636
636
|
l("mouseleave", a);
|
|
637
|
-
},
|
|
637
|
+
}, M = (a) => {
|
|
638
638
|
l("mouseenter", a);
|
|
639
|
-
},
|
|
639
|
+
}, p = (a) => {
|
|
640
640
|
l("compositionstart", a);
|
|
641
|
-
}, g = (a) => {
|
|
642
|
-
l("compositionupdate", a);
|
|
643
641
|
}, s = (a) => {
|
|
642
|
+
l("compositionupdate", a);
|
|
643
|
+
}, I = (a) => {
|
|
644
644
|
l("compositionend", a);
|
|
645
645
|
};
|
|
646
|
-
return (a,
|
|
647
|
-
const
|
|
648
|
-
return
|
|
649
|
-
modelValue:
|
|
650
|
-
"onUpdate:modelValue":
|
|
646
|
+
return (a, o) => {
|
|
647
|
+
const b = O("el-input");
|
|
648
|
+
return c(), Y(b, F(t, {
|
|
649
|
+
modelValue: h(e),
|
|
650
|
+
"onUpdate:modelValue": o[0] || (o[0] = (G) => oA(e) ? e.value = G : null),
|
|
651
651
|
class: "yw-input",
|
|
652
|
-
onInput:
|
|
653
|
-
onChange:
|
|
654
|
-
onBlur:
|
|
655
|
-
onFocus:
|
|
656
|
-
onClear:
|
|
657
|
-
onKeydown:
|
|
658
|
-
onMouseleave:
|
|
659
|
-
onMouseenter:
|
|
660
|
-
onCompositionstart:
|
|
661
|
-
onCompositionupdate:
|
|
662
|
-
onCompositionend:
|
|
652
|
+
onInput: r,
|
|
653
|
+
onChange: g,
|
|
654
|
+
onBlur: m,
|
|
655
|
+
onFocus: C,
|
|
656
|
+
onClear: i,
|
|
657
|
+
onKeydown: w,
|
|
658
|
+
onMouseleave: y,
|
|
659
|
+
onMouseenter: M,
|
|
660
|
+
onCompositionstart: p,
|
|
661
|
+
onCompositionupdate: s,
|
|
662
|
+
onCompositionend: I
|
|
663
663
|
}), tA({ _: 2 }, [
|
|
664
|
-
|
|
665
|
-
name:
|
|
666
|
-
fn:
|
|
667
|
-
|
|
664
|
+
R(a.$slots, (G, B) => ({
|
|
665
|
+
name: B,
|
|
666
|
+
fn: f((E) => [
|
|
667
|
+
N(a.$slots, B, nA(dA(E || {})))
|
|
668
668
|
])
|
|
669
669
|
}))
|
|
670
670
|
]), 1040, ["modelValue"]);
|
|
@@ -674,7 +674,7 @@ const mA = /* @__PURE__ */ L({
|
|
|
674
674
|
mA.install = (A) => {
|
|
675
675
|
A.component("YwInput", mA);
|
|
676
676
|
};
|
|
677
|
-
const IA = /* @__PURE__ */
|
|
677
|
+
const IA = /* @__PURE__ */ x({
|
|
678
678
|
__name: "Select",
|
|
679
679
|
props: {
|
|
680
680
|
modelValue: {
|
|
@@ -812,7 +812,7 @@ const IA = /* @__PURE__ */ L({
|
|
|
812
812
|
},
|
|
813
813
|
clearIcon: {
|
|
814
814
|
type: [String, Object],
|
|
815
|
-
default: () =>
|
|
815
|
+
default: () => J("svg", {
|
|
816
816
|
viewBox: "0 0 1024 1024",
|
|
817
817
|
width: "12",
|
|
818
818
|
height: "12",
|
|
@@ -820,7 +820,7 @@ const IA = /* @__PURE__ */ L({
|
|
|
820
820
|
class: "your-prefix-clear-icon",
|
|
821
821
|
style: { color: "#b2b4c6" }
|
|
822
822
|
}, [
|
|
823
|
-
|
|
823
|
+
J("path", {
|
|
824
824
|
d: "M0 512a512 512 0 1 0 1024 0A512 512 0 0 0 0 512z m631.210667-179.541333a42.666667 42.666667 0 0 1 60.330666 60.416L572.330667 512l119.210666 119.125333a42.666667 42.666667 0 0 1-60.330666 60.416L512 572.330667 392.874667 691.541333a42.666667 42.666667 0 0 1-60.330667-60.416L451.669333 512 332.544 392.874667a42.666667 42.666667 0 1 1 60.330667-60.416L512 451.669333l119.210667-119.210666z"
|
|
825
825
|
})
|
|
826
826
|
])
|
|
@@ -831,7 +831,7 @@ const IA = /* @__PURE__ */ L({
|
|
|
831
831
|
},
|
|
832
832
|
suffixIcon: {
|
|
833
833
|
type: [String, Object],
|
|
834
|
-
default: () =>
|
|
834
|
+
default: () => J("svg", {
|
|
835
835
|
viewBox: "0 0 1024 1024",
|
|
836
836
|
width: "12",
|
|
837
837
|
height: "12",
|
|
@@ -840,7 +840,7 @@ const IA = /* @__PURE__ */ L({
|
|
|
840
840
|
"aria-hidden": "true",
|
|
841
841
|
style: { color: "#1a1a1a" }
|
|
842
842
|
}, [
|
|
843
|
-
|
|
843
|
+
J("path", {
|
|
844
844
|
d: "M396.458667 396.458667a42.666667 42.666667 0 0 1 60.416 0L682.666667 622.336l225.792-225.877333a42.666667 42.666667 0 0 1 60.416 60.416l-256 256a42.666667 42.666667 0 0 1-60.416 0l-256-256a42.666667 42.666667 0 0 1 0-60.416z"
|
|
845
845
|
})
|
|
846
846
|
])
|
|
@@ -883,67 +883,80 @@ const IA = /* @__PURE__ */ L({
|
|
|
883
883
|
}
|
|
884
884
|
},
|
|
885
885
|
emits: ["update:modelValue", "change", "visible-change", "remove-tag", "clear", "focus", "blur", "popup-scroll"],
|
|
886
|
-
setup(A, { emit:
|
|
887
|
-
const
|
|
888
|
-
const
|
|
889
|
-
if (
|
|
890
|
-
const
|
|
886
|
+
setup(A, { expose: u, emit: t }) {
|
|
887
|
+
const l = A, e = Z(() => l.props), r = fA(), g = Z(() => r.default?.().length === 0 ? [] : r.default?.().flatMap((o) => {
|
|
888
|
+
const b = String(o.type);
|
|
889
|
+
if (b.includes("yw-option") || b.includes("ywOption")) {
|
|
890
|
+
const G = o.children;
|
|
891
891
|
return {
|
|
892
892
|
type: vA,
|
|
893
|
-
props:
|
|
894
|
-
children:
|
|
895
|
-
key:
|
|
893
|
+
props: o.props || {},
|
|
894
|
+
children: G && G[0].children,
|
|
895
|
+
key: o.key
|
|
896
896
|
};
|
|
897
897
|
}
|
|
898
|
-
return
|
|
899
|
-
})),
|
|
898
|
+
return o;
|
|
899
|
+
})), m = t, C = Z({
|
|
900
900
|
get() {
|
|
901
|
-
return
|
|
901
|
+
return l.modelValue;
|
|
902
902
|
},
|
|
903
|
-
set(
|
|
904
|
-
|
|
903
|
+
set(o) {
|
|
904
|
+
m("update:modelValue", o);
|
|
905
905
|
}
|
|
906
|
-
}),
|
|
907
|
-
|
|
908
|
-
},
|
|
909
|
-
|
|
910
|
-
},
|
|
911
|
-
|
|
906
|
+
}), i = (o) => {
|
|
907
|
+
m("change", o);
|
|
908
|
+
}, w = (o) => {
|
|
909
|
+
m("visible-change", o);
|
|
910
|
+
}, y = (o) => {
|
|
911
|
+
m("remove-tag", o);
|
|
912
912
|
}, M = () => {
|
|
913
|
-
|
|
914
|
-
},
|
|
915
|
-
|
|
916
|
-
},
|
|
917
|
-
|
|
918
|
-
},
|
|
919
|
-
|
|
920
|
-
};
|
|
921
|
-
return
|
|
922
|
-
|
|
923
|
-
|
|
913
|
+
m("clear");
|
|
914
|
+
}, p = (o) => {
|
|
915
|
+
m("focus", o);
|
|
916
|
+
}, s = (o) => {
|
|
917
|
+
m("blur", o);
|
|
918
|
+
}, I = (o) => {
|
|
919
|
+
m("popup-scroll", o);
|
|
920
|
+
}, a = W(null);
|
|
921
|
+
return u({
|
|
922
|
+
/** 使选择器的输入框获取焦点 */
|
|
923
|
+
focus: () => {
|
|
924
|
+
a.value?.focus();
|
|
925
|
+
},
|
|
926
|
+
/** 使选择器的输入框失去焦点,并隐藏下拉框 */
|
|
927
|
+
blur: () => {
|
|
928
|
+
a.value?.blur();
|
|
929
|
+
},
|
|
930
|
+
/** 暴露当前选中的 label 属性 */
|
|
931
|
+
selectedLabel: Z(() => a.value?.selectedLabel)
|
|
932
|
+
}), (o, b) => (c(), Y(h(zA), F(l, {
|
|
933
|
+
modelValue: C.value,
|
|
934
|
+
"onUpdate:modelValue": b[0] || (b[0] = (G) => C.value = G),
|
|
935
|
+
ref_key: "selectInstance",
|
|
936
|
+
ref: a,
|
|
924
937
|
class: "yw-select",
|
|
925
938
|
"popper-class": "yw-select-popper",
|
|
926
|
-
onChange:
|
|
927
|
-
onVisibleChange:
|
|
928
|
-
onRemoveTag:
|
|
939
|
+
onChange: i,
|
|
940
|
+
onVisibleChange: w,
|
|
941
|
+
onRemoveTag: y,
|
|
929
942
|
onClear: M,
|
|
930
|
-
onBlur:
|
|
931
|
-
onFocus:
|
|
932
|
-
onPopupScroll:
|
|
943
|
+
onBlur: s,
|
|
944
|
+
onFocus: p,
|
|
945
|
+
onPopupScroll: I
|
|
933
946
|
}), {
|
|
934
|
-
default:
|
|
935
|
-
|
|
936
|
-
key:
|
|
947
|
+
default: f(() => [
|
|
948
|
+
o.$slots.default ? (c(!0), D(eA, { key: 0 }, R(g.value, (G, B) => (c(), Y(YA(G.type), F({ ref_for: !0 }, G.props, {
|
|
949
|
+
key: G.key || B
|
|
937
950
|
}), {
|
|
938
|
-
default:
|
|
939
|
-
wA(
|
|
951
|
+
default: f(() => [
|
|
952
|
+
wA($(G.children), 1)
|
|
940
953
|
]),
|
|
941
954
|
_: 2
|
|
942
|
-
}, 1040))), 128)) : (
|
|
943
|
-
key:
|
|
944
|
-
label:
|
|
945
|
-
value:
|
|
946
|
-
disabled:
|
|
955
|
+
}, 1040))), 128)) : (c(!0), D(eA, { key: 1 }, R(A.options, (G) => (c(), Y(h(vA), {
|
|
956
|
+
key: G[e.value.value],
|
|
957
|
+
label: G[e.value.label],
|
|
958
|
+
value: G[e.value.value],
|
|
959
|
+
disabled: G[e.value.disabled]
|
|
947
960
|
}, null, 8, ["label", "value", "disabled"]))), 128))
|
|
948
961
|
]),
|
|
949
962
|
_: 1
|
|
@@ -953,10 +966,10 @@ const IA = /* @__PURE__ */ L({
|
|
|
953
966
|
IA.install = (A) => {
|
|
954
967
|
A.component("YwSelect", IA);
|
|
955
968
|
};
|
|
956
|
-
|
|
957
|
-
A.component("YwSvgIcon",
|
|
969
|
+
U.install = (A) => {
|
|
970
|
+
A.component("YwSvgIcon", U);
|
|
958
971
|
};
|
|
959
|
-
const ie = { class: "custom-checkbox-group" }, ge = ["onClick"], re = { class: "custom-checkbox" }, Ce = { class: "checkbox-label" }, hA = /* @__PURE__ */
|
|
972
|
+
const ie = { class: "custom-checkbox-group" }, ge = ["onClick"], re = { class: "custom-checkbox" }, Ce = { class: "checkbox-label" }, hA = /* @__PURE__ */ x({
|
|
960
973
|
__name: "CheckboxGroup",
|
|
961
974
|
props: {
|
|
962
975
|
modelValue: { type: [Array, String, Number, Boolean] },
|
|
@@ -964,34 +977,34 @@ const ie = { class: "custom-checkbox-group" }, ge = ["onClick"], re = { class: "
|
|
|
964
977
|
options: {}
|
|
965
978
|
},
|
|
966
979
|
emits: ["update:modelValue", "change"],
|
|
967
|
-
setup(A, { emit:
|
|
968
|
-
const
|
|
969
|
-
if (
|
|
970
|
-
let
|
|
971
|
-
Array.isArray(
|
|
980
|
+
setup(A, { emit: u }) {
|
|
981
|
+
const t = A, l = u, e = (g) => Array.isArray(t.modelValue) ? t.modelValue.includes(g) : t.modelValue === g, r = (g, m) => {
|
|
982
|
+
if (m || t.disabled) return;
|
|
983
|
+
let C;
|
|
984
|
+
Array.isArray(t.modelValue) ? e(g) ? C = t.modelValue.filter((i) => i !== g) : C = [...t.modelValue, g] : e(g) ? C = "" : C = g, l("update:modelValue", C), l("change", C);
|
|
972
985
|
};
|
|
973
|
-
return (
|
|
974
|
-
const
|
|
975
|
-
return
|
|
976
|
-
(
|
|
977
|
-
key:
|
|
986
|
+
return (g, m) => {
|
|
987
|
+
const C = O("svg-icon");
|
|
988
|
+
return c(), D("div", ie, [
|
|
989
|
+
(c(!0), D(eA, null, R(A.options, (i, w) => (c(), D("div", {
|
|
990
|
+
key: w,
|
|
978
991
|
class: gA(["custom-checkbox-wrapper", {
|
|
979
|
-
"is-checked":
|
|
980
|
-
"is-disabled":
|
|
992
|
+
"is-checked": e(i.value),
|
|
993
|
+
"is-disabled": i.disabled || A.disabled
|
|
981
994
|
}]),
|
|
982
|
-
onClick: (
|
|
995
|
+
onClick: (y) => r(i.value, i.disabled)
|
|
983
996
|
}, [
|
|
984
|
-
|
|
985
|
-
|
|
997
|
+
L("span", re, [
|
|
998
|
+
e(i.value) ? (c(), Y(C, {
|
|
986
999
|
key: 0,
|
|
987
1000
|
style: { width: "16px", height: "16px" },
|
|
988
|
-
"icon-class":
|
|
989
|
-
}, null, 8, ["icon-class"])) : (
|
|
1001
|
+
"icon-class": i.disabled || A.disabled ? "checked_disabled_fill" : "checked_fill"
|
|
1002
|
+
}, null, 8, ["icon-class"])) : (c(), Y(C, {
|
|
990
1003
|
key: 1,
|
|
991
1004
|
style: { width: "16px", height: "16px" },
|
|
992
|
-
"icon-class":
|
|
1005
|
+
"icon-class": i.disabled || A.disabled ? "unchecked_disabled" : "unchecked"
|
|
993
1006
|
}, null, 8, ["icon-class"])),
|
|
994
|
-
|
|
1007
|
+
L("span", Ce, $(i.label), 1)
|
|
995
1008
|
])
|
|
996
1009
|
], 10, ge))), 128))
|
|
997
1010
|
]);
|
|
@@ -1001,7 +1014,7 @@ const ie = { class: "custom-checkbox-group" }, ge = ["onClick"], re = { class: "
|
|
|
1001
1014
|
hA.install = (A) => {
|
|
1002
1015
|
A.component("YwCheckboxGroup", hA);
|
|
1003
1016
|
};
|
|
1004
|
-
const ce = { class: "custom-checkbox-group" }, ue = ["onClick"], de = { class: "custom-checkbox" }, we = { class: "checkbox-label" }, QA = /* @__PURE__ */
|
|
1017
|
+
const ce = { class: "custom-checkbox-group" }, ue = ["onClick"], de = { class: "custom-checkbox" }, we = { class: "checkbox-label" }, QA = /* @__PURE__ */ x({
|
|
1005
1018
|
__name: "RadioGroup",
|
|
1006
1019
|
props: {
|
|
1007
1020
|
modelValue: { type: [Array, String, Number, Boolean] },
|
|
@@ -1009,34 +1022,34 @@ const ce = { class: "custom-checkbox-group" }, ue = ["onClick"], de = { class: "
|
|
|
1009
1022
|
options: {}
|
|
1010
1023
|
},
|
|
1011
1024
|
emits: ["update:modelValue", "change"],
|
|
1012
|
-
setup(A, { emit:
|
|
1013
|
-
const
|
|
1014
|
-
if (
|
|
1015
|
-
let
|
|
1016
|
-
Array.isArray(
|
|
1025
|
+
setup(A, { emit: u }) {
|
|
1026
|
+
const t = A, l = u, e = (g) => Array.isArray(t.modelValue) ? t.modelValue.includes(g) : t.modelValue === g, r = (g, m) => {
|
|
1027
|
+
if (m || t.disabled) return;
|
|
1028
|
+
let C;
|
|
1029
|
+
Array.isArray(t.modelValue) ? e(g) ? C = t.modelValue.filter((i) => i !== g) : C = [...t.modelValue, g] : e(g) ? C = "" : C = g, l("update:modelValue", C), l("change", C);
|
|
1017
1030
|
};
|
|
1018
|
-
return (
|
|
1019
|
-
const
|
|
1020
|
-
return
|
|
1021
|
-
(
|
|
1022
|
-
key:
|
|
1031
|
+
return (g, m) => {
|
|
1032
|
+
const C = O("svg-icon");
|
|
1033
|
+
return c(), D("div", ce, [
|
|
1034
|
+
(c(!0), D(eA, null, R(A.options, (i, w) => (c(), D("div", {
|
|
1035
|
+
key: w,
|
|
1023
1036
|
class: gA(["custom-checkbox-wrapper", {
|
|
1024
|
-
"is-checked":
|
|
1025
|
-
"is-disabled":
|
|
1037
|
+
"is-checked": e(i.value),
|
|
1038
|
+
"is-disabled": i.disabled || A.disabled
|
|
1026
1039
|
}]),
|
|
1027
|
-
onClick: (
|
|
1040
|
+
onClick: (y) => r(i.value, i.disabled)
|
|
1028
1041
|
}, [
|
|
1029
|
-
|
|
1030
|
-
|
|
1042
|
+
L("span", de, [
|
|
1043
|
+
e(i.value) ? (c(), Y(C, {
|
|
1031
1044
|
key: 0,
|
|
1032
1045
|
style: { width: "16px", height: "16px" },
|
|
1033
|
-
"icon-class":
|
|
1034
|
-
}, null, 8, ["icon-class"])) : (
|
|
1046
|
+
"icon-class": i.disabled || A.disabled ? "checked_disabled_fill" : "checked_fill"
|
|
1047
|
+
}, null, 8, ["icon-class"])) : (c(), Y(C, {
|
|
1035
1048
|
key: 1,
|
|
1036
1049
|
style: { width: "16px", height: "16px" },
|
|
1037
|
-
"icon-class":
|
|
1050
|
+
"icon-class": i.disabled || A.disabled ? "unchecked_disabled" : "unchecked"
|
|
1038
1051
|
}, null, 8, ["icon-class"])),
|
|
1039
|
-
|
|
1052
|
+
L("span", we, $(i.label), 1)
|
|
1040
1053
|
])
|
|
1041
1054
|
], 10, ue))), 128))
|
|
1042
1055
|
]);
|
|
@@ -1049,7 +1062,7 @@ QA.install = (A) => {
|
|
|
1049
1062
|
const Be = {
|
|
1050
1063
|
key: 1,
|
|
1051
1064
|
class: "dialog-footer"
|
|
1052
|
-
}, rA = /* @__PURE__ */
|
|
1065
|
+
}, rA = /* @__PURE__ */ x({
|
|
1053
1066
|
__name: "Dialog",
|
|
1054
1067
|
props: {
|
|
1055
1068
|
modelValue: {
|
|
@@ -1158,7 +1171,7 @@ const Be = {
|
|
|
1158
1171
|
},
|
|
1159
1172
|
closeIcon: {
|
|
1160
1173
|
type: Function,
|
|
1161
|
-
default: () =>
|
|
1174
|
+
default: () => J(U, { iconClass: "16_16_close", color: "#1a1a1a" })
|
|
1162
1175
|
// 设置默认参数
|
|
1163
1176
|
},
|
|
1164
1177
|
zIndex: {
|
|
@@ -1175,47 +1188,47 @@ const Be = {
|
|
|
1175
1188
|
}
|
|
1176
1189
|
},
|
|
1177
1190
|
emits: ["open", "opened", "close", "closed", "open-auto-focus", "close-auto-focus", "submit"],
|
|
1178
|
-
setup(A, { emit:
|
|
1179
|
-
const
|
|
1180
|
-
|
|
1181
|
-
},
|
|
1182
|
-
|
|
1183
|
-
},
|
|
1184
|
-
|
|
1185
|
-
},
|
|
1186
|
-
|
|
1187
|
-
},
|
|
1188
|
-
|
|
1189
|
-
},
|
|
1190
|
-
|
|
1191
|
-
},
|
|
1192
|
-
|
|
1191
|
+
setup(A, { emit: u }) {
|
|
1192
|
+
const t = A, l = Z(() => t.width && t.width !== "680" ? t.width : t.size === "small" ? "400" : t.size === "default" ? "680" : t.size === "large" ? "960" : t.size === "huge" ? "1200" : t.size === "full" ? "100%" : "680"), e = u, r = () => {
|
|
1193
|
+
e("open");
|
|
1194
|
+
}, g = () => {
|
|
1195
|
+
e("opened");
|
|
1196
|
+
}, m = () => {
|
|
1197
|
+
e("close");
|
|
1198
|
+
}, C = () => {
|
|
1199
|
+
e("closed");
|
|
1200
|
+
}, i = () => {
|
|
1201
|
+
e("open-auto-focus");
|
|
1202
|
+
}, w = () => {
|
|
1203
|
+
e("close-auto-focus");
|
|
1204
|
+
}, y = () => {
|
|
1205
|
+
e("submit");
|
|
1193
1206
|
};
|
|
1194
|
-
return (
|
|
1195
|
-
const
|
|
1196
|
-
return
|
|
1197
|
-
width:
|
|
1198
|
-
onOpen:
|
|
1199
|
-
onOpened:
|
|
1200
|
-
onClose:
|
|
1201
|
-
onClosed:
|
|
1202
|
-
onOpenAutoFocus:
|
|
1203
|
-
onCloseAutoFocus:
|
|
1207
|
+
return (M, p) => {
|
|
1208
|
+
const s = O("el-dialog");
|
|
1209
|
+
return c(), Y(s, F({ class: "yw-dialog" }, M.$props, {
|
|
1210
|
+
width: h(l),
|
|
1211
|
+
onOpen: r,
|
|
1212
|
+
onOpened: g,
|
|
1213
|
+
onClose: m,
|
|
1214
|
+
onClosed: C,
|
|
1215
|
+
onOpenAutoFocus: i,
|
|
1216
|
+
onCloseAutoFocus: w
|
|
1204
1217
|
}), tA({
|
|
1205
|
-
footer:
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
default:
|
|
1209
|
-
wA(
|
|
1218
|
+
footer: f(() => [
|
|
1219
|
+
M.$slots.footer ? N(M.$slots, "footer", { key: 0 }) : (c(), D("div", Be, [
|
|
1220
|
+
S(sA, { onClick: m }, {
|
|
1221
|
+
default: f(() => [
|
|
1222
|
+
wA($(A.cancelText), 1)
|
|
1210
1223
|
]),
|
|
1211
1224
|
_: 1
|
|
1212
1225
|
}),
|
|
1213
|
-
|
|
1226
|
+
S(sA, {
|
|
1214
1227
|
type: "primary",
|
|
1215
|
-
onClick:
|
|
1228
|
+
onClick: y
|
|
1216
1229
|
}, {
|
|
1217
|
-
default:
|
|
1218
|
-
wA(
|
|
1230
|
+
default: f(() => [
|
|
1231
|
+
wA($(A.confirmText), 1)
|
|
1219
1232
|
]),
|
|
1220
1233
|
_: 1
|
|
1221
1234
|
})
|
|
@@ -1223,10 +1236,10 @@ const Be = {
|
|
|
1223
1236
|
]),
|
|
1224
1237
|
_: 2
|
|
1225
1238
|
}, [
|
|
1226
|
-
|
|
1239
|
+
R(M.$slots, (I, a) => ({
|
|
1227
1240
|
name: a,
|
|
1228
|
-
fn:
|
|
1229
|
-
|
|
1241
|
+
fn: f((o) => [
|
|
1242
|
+
N(M.$slots, a, nA(dA(o || {})))
|
|
1230
1243
|
])
|
|
1231
1244
|
}))
|
|
1232
1245
|
]), 1040, ["width"]);
|
|
@@ -1236,7 +1249,7 @@ const Be = {
|
|
|
1236
1249
|
rA.install = (A) => {
|
|
1237
1250
|
A.component("YwDialog", rA);
|
|
1238
1251
|
};
|
|
1239
|
-
const CA = /* @__PURE__ */
|
|
1252
|
+
const CA = /* @__PURE__ */ x({
|
|
1240
1253
|
__name: "Tree",
|
|
1241
1254
|
props: {
|
|
1242
1255
|
data: {
|
|
@@ -1321,7 +1334,7 @@ const CA = /* @__PURE__ */ L({
|
|
|
1321
1334
|
},
|
|
1322
1335
|
icon: {
|
|
1323
1336
|
type: Object,
|
|
1324
|
-
default: () =>
|
|
1337
|
+
default: () => J(U, { iconClass: "12_12_fill_arrow_right" })
|
|
1325
1338
|
// 设置默认参数
|
|
1326
1339
|
},
|
|
1327
1340
|
lazy: {
|
|
@@ -1340,64 +1353,64 @@ const CA = /* @__PURE__ */ L({
|
|
|
1340
1353
|
}
|
|
1341
1354
|
},
|
|
1342
1355
|
emits: ["node-click", "node-contextmenu", "check-change", "check", "current-change", "node-expand", "node-collapse", "node-drag-start", "node-drag-enter", "node-drag-leave", "node-drag-over", "node-drag-end", "node-drop"],
|
|
1343
|
-
setup(A, { expose:
|
|
1344
|
-
const l = A,
|
|
1345
|
-
|
|
1346
|
-
},
|
|
1347
|
-
|
|
1348
|
-
},
|
|
1349
|
-
|
|
1350
|
-
},
|
|
1351
|
-
|
|
1352
|
-
},
|
|
1353
|
-
|
|
1354
|
-
},
|
|
1355
|
-
|
|
1356
|
-
},
|
|
1357
|
-
|
|
1358
|
-
},
|
|
1359
|
-
|
|
1360
|
-
},
|
|
1361
|
-
|
|
1362
|
-
},
|
|
1363
|
-
|
|
1364
|
-
}, a = (
|
|
1365
|
-
|
|
1366
|
-
},
|
|
1367
|
-
|
|
1368
|
-
},
|
|
1369
|
-
|
|
1356
|
+
setup(A, { expose: u, emit: t }) {
|
|
1357
|
+
const l = A, e = t, r = W(), g = (B, E, k) => {
|
|
1358
|
+
e("node-click", B, E, k);
|
|
1359
|
+
}, m = (B, E, k) => {
|
|
1360
|
+
e("node-contextmenu", B, E, k);
|
|
1361
|
+
}, C = (B, E, k) => {
|
|
1362
|
+
e("check-change", B, E, k);
|
|
1363
|
+
}, i = (B, E) => {
|
|
1364
|
+
e("check", B, E);
|
|
1365
|
+
}, w = (B) => {
|
|
1366
|
+
e("current-change", B);
|
|
1367
|
+
}, y = (B) => {
|
|
1368
|
+
e("node-expand", B);
|
|
1369
|
+
}, M = (B) => {
|
|
1370
|
+
e("node-collapse", B);
|
|
1371
|
+
}, p = (B, E) => {
|
|
1372
|
+
e("node-drag-start", B, E);
|
|
1373
|
+
}, s = (B, E, k) => {
|
|
1374
|
+
e("node-drag-enter", B, E, k);
|
|
1375
|
+
}, I = (B, E, k) => {
|
|
1376
|
+
e("node-drag-leave", B, E, k);
|
|
1377
|
+
}, a = (B, E, k) => {
|
|
1378
|
+
e("node-drag-over", B, E, k);
|
|
1379
|
+
}, o = (B, E, k) => {
|
|
1380
|
+
e("node-drag-end", B, E, k);
|
|
1381
|
+
}, b = (B, E, k, H) => {
|
|
1382
|
+
e("node-drop", B, E, k, H);
|
|
1370
1383
|
};
|
|
1371
|
-
return
|
|
1384
|
+
return u({
|
|
1372
1385
|
clearSelection: () => {
|
|
1373
|
-
const
|
|
1374
|
-
|
|
1386
|
+
const B = r.value;
|
|
1387
|
+
B && B.setCurrentKey(null);
|
|
1375
1388
|
}
|
|
1376
|
-
}), (
|
|
1377
|
-
const k =
|
|
1378
|
-
return
|
|
1389
|
+
}), (B, E) => {
|
|
1390
|
+
const k = O("el-tree");
|
|
1391
|
+
return c(), Y(k, F({
|
|
1379
1392
|
ref_key: "treeRef",
|
|
1380
|
-
ref:
|
|
1393
|
+
ref: r,
|
|
1381
1394
|
class: "custom-tree"
|
|
1382
1395
|
}, l, {
|
|
1383
|
-
onNodeClick:
|
|
1384
|
-
onNodeContextmenu:
|
|
1385
|
-
onCheckChange:
|
|
1386
|
-
onCheck:
|
|
1387
|
-
onCurrentChange:
|
|
1388
|
-
onNodeExpand:
|
|
1389
|
-
onNodeCollapse:
|
|
1390
|
-
onNodeDragStart:
|
|
1391
|
-
onNodeDragEnter:
|
|
1392
|
-
onNodeDragLeave:
|
|
1396
|
+
onNodeClick: g,
|
|
1397
|
+
onNodeContextmenu: m,
|
|
1398
|
+
onCheckChange: C,
|
|
1399
|
+
onCheck: i,
|
|
1400
|
+
onCurrentChange: w,
|
|
1401
|
+
onNodeExpand: y,
|
|
1402
|
+
onNodeCollapse: M,
|
|
1403
|
+
onNodeDragStart: p,
|
|
1404
|
+
onNodeDragEnter: s,
|
|
1405
|
+
onNodeDragLeave: I,
|
|
1393
1406
|
onNodeDragOver: a,
|
|
1394
|
-
onNodeDragEnd:
|
|
1395
|
-
onNodeDrop:
|
|
1407
|
+
onNodeDragEnd: o,
|
|
1408
|
+
onNodeDrop: b
|
|
1396
1409
|
}), {
|
|
1397
|
-
default:
|
|
1398
|
-
|
|
1399
|
-
node:
|
|
1400
|
-
data:
|
|
1410
|
+
default: f(({ node: H, data: z }) => [
|
|
1411
|
+
N(B.$slots, "default", {
|
|
1412
|
+
node: H,
|
|
1413
|
+
data: z
|
|
1401
1414
|
})
|
|
1402
1415
|
]),
|
|
1403
1416
|
_: 3
|
|
@@ -1408,7 +1421,7 @@ const CA = /* @__PURE__ */ L({
|
|
|
1408
1421
|
CA.install = (A) => {
|
|
1409
1422
|
A.component("YwTree", CA);
|
|
1410
1423
|
};
|
|
1411
|
-
const pe = /* @__PURE__ */
|
|
1424
|
+
const pe = /* @__PURE__ */ x({
|
|
1412
1425
|
__name: "Table",
|
|
1413
1426
|
props: {
|
|
1414
1427
|
data: { default: () => [] },
|
|
@@ -1477,120 +1490,120 @@ const pe = /* @__PURE__ */ L({
|
|
|
1477
1490
|
"expand-change",
|
|
1478
1491
|
"scroll"
|
|
1479
1492
|
],
|
|
1480
|
-
setup(A, { expose:
|
|
1481
|
-
const l =
|
|
1482
|
-
|
|
1483
|
-
},
|
|
1484
|
-
const
|
|
1485
|
-
if (!
|
|
1486
|
-
return
|
|
1487
|
-
const lA = v[
|
|
1488
|
-
return lA == null || lA === "" ? (
|
|
1493
|
+
setup(A, { expose: u, emit: t }) {
|
|
1494
|
+
const l = t, e = A, r = W({}), g = W(), m = (n, d) => r.value[n]?.[d], C = (n, d, q) => {
|
|
1495
|
+
r.value[n] || (r.value[n] = {}), q ? r.value[n][d] = q : (delete r.value[n][d], Object.keys(r.value[n]).length === 0 && delete r.value[n]);
|
|
1496
|
+
}, i = (n, d) => {
|
|
1497
|
+
const q = e.columns?.find((T) => T.prop === d), v = e.data?.[n];
|
|
1498
|
+
if (!q || !q.required || !d || !v)
|
|
1499
|
+
return C(n, d, null), !0;
|
|
1500
|
+
const lA = v[d];
|
|
1501
|
+
return lA == null || lA === "" ? (C(n, d, `${q.label || q.prop} 为必填项`), !1) : (C(n, d, null), !0);
|
|
1489
1502
|
};
|
|
1490
|
-
|
|
1503
|
+
u({
|
|
1491
1504
|
validate: async () => {
|
|
1492
|
-
if (!
|
|
1505
|
+
if (!e.columns || !e.data) return !0;
|
|
1493
1506
|
let n = !0;
|
|
1494
|
-
return
|
|
1495
|
-
|
|
1496
|
-
v.required && v.prop && v.slotName && (
|
|
1507
|
+
return e.data.forEach((d, q) => {
|
|
1508
|
+
e.columns.forEach((v) => {
|
|
1509
|
+
v.required && v.prop && v.slotName && (i(q, v.prop) || (n = !1));
|
|
1497
1510
|
});
|
|
1498
1511
|
}), n;
|
|
1499
1512
|
},
|
|
1500
1513
|
clearValidate: () => {
|
|
1501
|
-
|
|
1514
|
+
r.value = {};
|
|
1502
1515
|
},
|
|
1503
|
-
validateCell:
|
|
1516
|
+
validateCell: i,
|
|
1504
1517
|
// 暴露给父组件,以便在插槽组件的事件中手动触发单项校验
|
|
1505
|
-
tableRef:
|
|
1518
|
+
tableRef: g
|
|
1506
1519
|
// 暴露 el-table 实例
|
|
1507
1520
|
});
|
|
1508
|
-
const
|
|
1509
|
-
l("select", n,
|
|
1510
|
-
},
|
|
1521
|
+
const M = (n, d) => {
|
|
1522
|
+
l("select", n, d);
|
|
1523
|
+
}, p = (n) => {
|
|
1511
1524
|
l("select-all", n);
|
|
1512
|
-
},
|
|
1525
|
+
}, s = (n) => {
|
|
1513
1526
|
l("selection-change", n);
|
|
1514
|
-
},
|
|
1515
|
-
l("cell-mouse-enter", n,
|
|
1516
|
-
}, a = (n,
|
|
1517
|
-
l("cell-mouse-leave", n,
|
|
1518
|
-
},
|
|
1519
|
-
l("cell-click", n,
|
|
1520
|
-
},
|
|
1521
|
-
l("cell-dblclick", n,
|
|
1522
|
-
},
|
|
1523
|
-
l("cell-contextmenu", n,
|
|
1524
|
-
},
|
|
1525
|
-
l("row-click", n,
|
|
1526
|
-
},
|
|
1527
|
-
l("row-dblclick", n,
|
|
1528
|
-
}, k = (n,
|
|
1529
|
-
l("row-contextmenu", n,
|
|
1530
|
-
},
|
|
1531
|
-
l("header-click", n,
|
|
1532
|
-
},
|
|
1533
|
-
l("header-contextmenu", n,
|
|
1534
|
-
},
|
|
1527
|
+
}, I = (n, d, q, v) => {
|
|
1528
|
+
l("cell-mouse-enter", n, d, q, v);
|
|
1529
|
+
}, a = (n, d, q, v) => {
|
|
1530
|
+
l("cell-mouse-leave", n, d, q, v);
|
|
1531
|
+
}, o = (n, d, q, v) => {
|
|
1532
|
+
l("cell-click", n, d, q, v);
|
|
1533
|
+
}, b = (n, d, q, v) => {
|
|
1534
|
+
l("cell-dblclick", n, d, q, v);
|
|
1535
|
+
}, G = (n, d, q, v) => {
|
|
1536
|
+
l("cell-contextmenu", n, d, q, v);
|
|
1537
|
+
}, B = (n, d, q, v) => {
|
|
1538
|
+
l("row-click", n, d, q, v);
|
|
1539
|
+
}, E = (n, d, q, v) => {
|
|
1540
|
+
l("row-dblclick", n, d, q, v);
|
|
1541
|
+
}, k = (n, d, q, v) => {
|
|
1542
|
+
l("row-contextmenu", n, d, q, v);
|
|
1543
|
+
}, H = (n, d) => {
|
|
1544
|
+
l("header-click", n, d);
|
|
1545
|
+
}, z = (n, d) => {
|
|
1546
|
+
l("header-contextmenu", n, d);
|
|
1547
|
+
}, Q = (n) => {
|
|
1535
1548
|
l("sort-change", n);
|
|
1536
|
-
},
|
|
1549
|
+
}, j = (n) => {
|
|
1537
1550
|
l("filter-change", n);
|
|
1538
|
-
},
|
|
1539
|
-
l("current-change", n,
|
|
1540
|
-
},
|
|
1541
|
-
l("header-dragend", n,
|
|
1542
|
-
},
|
|
1543
|
-
l("expand-change", n,
|
|
1544
|
-
},
|
|
1551
|
+
}, P = (n, d) => {
|
|
1552
|
+
l("current-change", n, d);
|
|
1553
|
+
}, K = (n, d, q) => {
|
|
1554
|
+
l("header-dragend", n, d, q);
|
|
1555
|
+
}, V = (n, d) => {
|
|
1556
|
+
l("expand-change", n, d);
|
|
1557
|
+
}, AA = (n) => {
|
|
1545
1558
|
l("scroll", n);
|
|
1546
1559
|
};
|
|
1547
|
-
return (n,
|
|
1548
|
-
const
|
|
1549
|
-
return
|
|
1560
|
+
return (n, d) => {
|
|
1561
|
+
const q = O("el-tooltip"), v = O("el-table-column"), lA = O("el-table");
|
|
1562
|
+
return c(), Y(lA, F({
|
|
1550
1563
|
ref_key: "tableRef",
|
|
1551
|
-
ref:
|
|
1564
|
+
ref: g,
|
|
1552
1565
|
class: "yw-table"
|
|
1553
|
-
},
|
|
1554
|
-
data:
|
|
1555
|
-
onSelect:
|
|
1556
|
-
onSelectAll:
|
|
1557
|
-
onSelectionChange:
|
|
1558
|
-
onCellMouseEnter:
|
|
1566
|
+
}, e, {
|
|
1567
|
+
data: e.data,
|
|
1568
|
+
onSelect: M,
|
|
1569
|
+
onSelectAll: p,
|
|
1570
|
+
onSelectionChange: s,
|
|
1571
|
+
onCellMouseEnter: I,
|
|
1559
1572
|
onCellMouseLeave: a,
|
|
1560
|
-
onCellClick:
|
|
1561
|
-
onCellDblclick:
|
|
1562
|
-
onCellContextmenu:
|
|
1563
|
-
onRowClick:
|
|
1573
|
+
onCellClick: o,
|
|
1574
|
+
onCellDblclick: b,
|
|
1575
|
+
onCellContextmenu: G,
|
|
1576
|
+
onRowClick: B,
|
|
1564
1577
|
onRowContextmenu: k,
|
|
1565
|
-
onRowDblclick:
|
|
1566
|
-
onHeaderClick:
|
|
1567
|
-
onHeaderContextmenu:
|
|
1568
|
-
onSortChange:
|
|
1569
|
-
onFilterChange:
|
|
1570
|
-
onCurrentChange:
|
|
1571
|
-
onHeaderDragend:
|
|
1572
|
-
onExpandChange:
|
|
1573
|
-
onScroll:
|
|
1578
|
+
onRowDblclick: E,
|
|
1579
|
+
onHeaderClick: H,
|
|
1580
|
+
onHeaderContextmenu: z,
|
|
1581
|
+
onSortChange: Q,
|
|
1582
|
+
onFilterChange: j,
|
|
1583
|
+
onCurrentChange: P,
|
|
1584
|
+
onHeaderDragend: K,
|
|
1585
|
+
onExpandChange: V,
|
|
1586
|
+
onScroll: AA
|
|
1574
1587
|
}), {
|
|
1575
|
-
default:
|
|
1576
|
-
(
|
|
1577
|
-
|
|
1588
|
+
default: f(() => [
|
|
1589
|
+
(c(!0), D(eA, null, R(e.columns, (T, GA) => (c(), Y(v, F({ key: GA }, { ref_for: !0 }, T), tA({ _: 2 }, [
|
|
1590
|
+
T.slotName ? {
|
|
1578
1591
|
name: "default",
|
|
1579
|
-
fn:
|
|
1580
|
-
|
|
1581
|
-
visible: !!
|
|
1592
|
+
fn: f((aA) => [
|
|
1593
|
+
S(q, {
|
|
1594
|
+
visible: !!m(aA.$index, T.prop),
|
|
1582
1595
|
"show-arrow": !1,
|
|
1583
|
-
content:
|
|
1596
|
+
content: m(aA.$index, T.prop),
|
|
1584
1597
|
placement: "bottom-start",
|
|
1585
1598
|
manual: "",
|
|
1586
1599
|
effect: "light",
|
|
1587
1600
|
"popper-class": "yw-table-error-tip"
|
|
1588
1601
|
}, {
|
|
1589
|
-
default:
|
|
1590
|
-
|
|
1591
|
-
class: gA(["yw-table-cell-content", { "is-error":
|
|
1602
|
+
default: f(() => [
|
|
1603
|
+
L("div", {
|
|
1604
|
+
class: gA(["yw-table-cell-content", { "is-error": m(aA.$index, T.prop) }])
|
|
1592
1605
|
}, [
|
|
1593
|
-
|
|
1606
|
+
N(n.$slots, T.slotName, F({ ref_for: !0 }, aA || {}), void 0, !0)
|
|
1594
1607
|
], 2)
|
|
1595
1608
|
]),
|
|
1596
1609
|
_: 2
|
|
@@ -1598,10 +1611,10 @@ const pe = /* @__PURE__ */ L({
|
|
|
1598
1611
|
]),
|
|
1599
1612
|
key: "0"
|
|
1600
1613
|
} : void 0,
|
|
1601
|
-
|
|
1614
|
+
T.type == "checkbox" ? {
|
|
1602
1615
|
name: "header",
|
|
1603
|
-
fn:
|
|
1604
|
-
|
|
1616
|
+
fn: f((aA) => [
|
|
1617
|
+
N(n.$slots, T.slotHeaderName, F({ ref_for: !0 }, aA || {}), void 0, !0)
|
|
1605
1618
|
]),
|
|
1606
1619
|
key: "1"
|
|
1607
1620
|
} : void 0
|
|
@@ -1621,7 +1634,7 @@ const me = "data:image/gif;base64,R0lGODlhqACoAOZ/AN3l/pKt/fb4/+Ho/nKU/M3Z/unu/j
|
|
|
1621
1634
|
}, he = { class: "gif-container" }, Qe = {
|
|
1622
1635
|
key: 0,
|
|
1623
1636
|
class: "cover-text"
|
|
1624
|
-
}, qA = /* @__PURE__ */
|
|
1637
|
+
}, qA = /* @__PURE__ */ x({
|
|
1625
1638
|
__name: "Loading",
|
|
1626
1639
|
props: {
|
|
1627
1640
|
modelValue: {
|
|
@@ -1634,23 +1647,23 @@ const me = "data:image/gif;base64,R0lGODlhqACoAOZ/AN3l/pKt/fb4/+Ho/nKU/M3Z/unu/j
|
|
|
1634
1647
|
}
|
|
1635
1648
|
},
|
|
1636
1649
|
setup(A) {
|
|
1637
|
-
const
|
|
1638
|
-
return (l,
|
|
1639
|
-
|
|
1640
|
-
|
|
1650
|
+
const u = A, t = Z(() => u.modelValue);
|
|
1651
|
+
return (l, e) => h(t) ? (c(), D("div", Ie, [
|
|
1652
|
+
L("div", he, [
|
|
1653
|
+
e[0] || (e[0] = L("img", {
|
|
1641
1654
|
src: me,
|
|
1642
1655
|
alt: "Loading animation",
|
|
1643
1656
|
class: "gif-animation"
|
|
1644
1657
|
}, null, -1)),
|
|
1645
|
-
A.title ? (
|
|
1658
|
+
A.title ? (c(), D("div", Qe, $(A.title), 1)) : _("", !0)
|
|
1646
1659
|
])
|
|
1647
|
-
])) :
|
|
1660
|
+
])) : _("", !0);
|
|
1648
1661
|
}
|
|
1649
1662
|
});
|
|
1650
1663
|
qA.install = (A) => {
|
|
1651
1664
|
A.component("YwLoading", qA);
|
|
1652
1665
|
};
|
|
1653
|
-
const cA = /* @__PURE__ */
|
|
1666
|
+
const cA = /* @__PURE__ */ x({
|
|
1654
1667
|
__name: "InputNumber",
|
|
1655
1668
|
props: {
|
|
1656
1669
|
modelValue: {
|
|
@@ -1728,10 +1741,10 @@ const cA = /* @__PURE__ */ L({
|
|
|
1728
1741
|
}
|
|
1729
1742
|
},
|
|
1730
1743
|
setup(A) {
|
|
1731
|
-
const
|
|
1732
|
-
return (
|
|
1733
|
-
const
|
|
1734
|
-
return
|
|
1744
|
+
const u = A;
|
|
1745
|
+
return (t, l) => {
|
|
1746
|
+
const e = O("el-input-number");
|
|
1747
|
+
return c(), Y(e, F(u, { class: "yw-input-number" }), null, 16);
|
|
1735
1748
|
};
|
|
1736
1749
|
}
|
|
1737
1750
|
}), qe = { class: "custom-pagination" }, Ee = {
|
|
@@ -1743,7 +1756,7 @@ const cA = /* @__PURE__ */ L({
|
|
|
1743
1756
|
}, ye = {
|
|
1744
1757
|
key: 2,
|
|
1745
1758
|
class: "custom-pagination__jumper"
|
|
1746
|
-
}, Me = /* @__PURE__ */
|
|
1759
|
+
}, Me = /* @__PURE__ */ x({
|
|
1747
1760
|
__name: "Pagination",
|
|
1748
1761
|
props: {
|
|
1749
1762
|
total: {},
|
|
@@ -1754,8 +1767,8 @@ const cA = /* @__PURE__ */ L({
|
|
|
1754
1767
|
layouts: { default: () => ["Total", "Sizes", "Prev", "Pagers", "Next", "Jumper"] }
|
|
1755
1768
|
},
|
|
1756
1769
|
emits: ["update:currentPage", "update:pageSize", "page-change"],
|
|
1757
|
-
setup(A, { emit:
|
|
1758
|
-
const
|
|
1770
|
+
setup(A, { emit: u }) {
|
|
1771
|
+
const t = A, l = Z(() => t.layouts.includes("Total")), e = Z(() => t.layouts.includes("Sizes")), r = Z(() => t.layouts.includes("Jumper")), g = u, m = J("svg", {
|
|
1759
1772
|
viewBox: "0 0 1024 1024",
|
|
1760
1773
|
width: "12",
|
|
1761
1774
|
height: "12",
|
|
@@ -1764,157 +1777,164 @@ const cA = /* @__PURE__ */ L({
|
|
|
1764
1777
|
"aria-hidden": "true",
|
|
1765
1778
|
style: { color: "#1a1a1a" }
|
|
1766
1779
|
}, [
|
|
1767
|
-
|
|
1780
|
+
J("path", {
|
|
1768
1781
|
d: "M396.458667 396.458667a42.666667 42.666667 0 0 1 60.416 0L682.666667 622.336l225.792-225.877333a42.666667 42.666667 0 0 1 60.416 60.416l-256 256a42.666667 42.666667 0 0 1-60.416 0l-256-256a42.666667 42.666667 0 0 1 0-60.416z"
|
|
1769
1782
|
})
|
|
1770
|
-
]),
|
|
1771
|
-
yA(() =>
|
|
1772
|
-
|
|
1773
|
-
}), yA(() =>
|
|
1774
|
-
|
|
1783
|
+
]), C = W(!1), i = W(!1), w = W(t.currentPage), y = W(t.pageSize), M = W(1), p = Z(() => Math.max(1, Math.ceil(t.total / y.value)));
|
|
1784
|
+
yA(() => t.currentPage, (z) => {
|
|
1785
|
+
w.value = z;
|
|
1786
|
+
}), yA(() => t.pageSize, (z) => {
|
|
1787
|
+
y.value = z;
|
|
1775
1788
|
});
|
|
1776
|
-
const
|
|
1777
|
-
const
|
|
1778
|
-
if (
|
|
1779
|
-
return
|
|
1780
|
-
const
|
|
1781
|
-
let
|
|
1782
|
-
|
|
1783
|
-
let
|
|
1784
|
-
return
|
|
1789
|
+
const s = Z(() => {
|
|
1790
|
+
const z = w.value, Q = p.value, j = t.pagerCount;
|
|
1791
|
+
if (Q <= j)
|
|
1792
|
+
return I(1, Q);
|
|
1793
|
+
const P = (j - 1) / 2;
|
|
1794
|
+
let K = z - P, V = z + P;
|
|
1795
|
+
K < 1 ? (K = 1, V = j) : V > Q && (V = Q, K = Q - j + 1);
|
|
1796
|
+
let AA = I(K, V);
|
|
1797
|
+
return K > 2 ? AA.unshift(1, "...") : K === 2 && AA.unshift(1), V < Q - 1 ? AA.push("....", Q) : V === Q - 1 && AA.push(Q), console.log("显示的页码:", AA), AA;
|
|
1785
1798
|
});
|
|
1786
|
-
function
|
|
1787
|
-
const
|
|
1788
|
-
for (let
|
|
1789
|
-
|
|
1790
|
-
return
|
|
1799
|
+
function I(z, Q) {
|
|
1800
|
+
const j = [];
|
|
1801
|
+
for (let P = z; P <= Q; P++)
|
|
1802
|
+
j.push(P);
|
|
1803
|
+
return j;
|
|
1791
1804
|
}
|
|
1792
1805
|
const a = () => {
|
|
1793
|
-
|
|
1794
|
-
},
|
|
1795
|
-
|
|
1796
|
-
},
|
|
1797
|
-
|
|
1798
|
-
},
|
|
1799
|
-
|
|
1800
|
-
},
|
|
1801
|
-
typeof
|
|
1802
|
-
},
|
|
1803
|
-
|
|
1806
|
+
w.value > 1 && (w.value--, H());
|
|
1807
|
+
}, o = () => {
|
|
1808
|
+
w.value = Math.max(1, w.value - 4), H();
|
|
1809
|
+
}, b = () => {
|
|
1810
|
+
w.value = Math.min(p.value, w.value + 4), H();
|
|
1811
|
+
}, G = () => {
|
|
1812
|
+
w.value < p.value && (w.value++, H());
|
|
1813
|
+
}, B = (z) => {
|
|
1814
|
+
typeof z == "number" && z !== w.value && (w.value = z, H());
|
|
1815
|
+
}, E = () => {
|
|
1816
|
+
w.value = 1, g("update:pageSize", y.value), H();
|
|
1804
1817
|
}, k = () => {
|
|
1805
|
-
if (
|
|
1806
|
-
const
|
|
1807
|
-
|
|
1818
|
+
if (M.value !== null) {
|
|
1819
|
+
const z = Math.max(1, Math.min(p.value, M.value));
|
|
1820
|
+
z !== w.value ? (w.value = z, H()) : M.value = 1;
|
|
1808
1821
|
}
|
|
1809
|
-
},
|
|
1810
|
-
|
|
1811
|
-
currentPage:
|
|
1812
|
-
pageSize:
|
|
1822
|
+
}, H = () => {
|
|
1823
|
+
g("update:currentPage", w.value), g("page-change", {
|
|
1824
|
+
currentPage: w.value,
|
|
1825
|
+
pageSize: y.value
|
|
1813
1826
|
});
|
|
1814
1827
|
};
|
|
1815
|
-
return (
|
|
1816
|
-
const
|
|
1817
|
-
return
|
|
1818
|
-
|
|
1819
|
-
|
|
1828
|
+
return (z, Q) => {
|
|
1829
|
+
const j = O("el-option"), P = O("el-select");
|
|
1830
|
+
return c(), D("div", qe, [
|
|
1831
|
+
h(l) ? (c(), D("span", Ee, " 共 " + $(A.total) + " 条 ", 1)) : _("", !0),
|
|
1832
|
+
L("div", {
|
|
1820
1833
|
class: "btn-prev btn-number",
|
|
1821
|
-
style:
|
|
1834
|
+
style: X({ cursor: A.currentPage === 1 ? "not-allowed" : "pointer" }),
|
|
1822
1835
|
onClick: a
|
|
1823
1836
|
}, [
|
|
1824
|
-
|
|
1837
|
+
S(h(U), {
|
|
1825
1838
|
"icon-class": "12_12_arrow_left",
|
|
1826
1839
|
class: "svg-icon-page",
|
|
1827
|
-
style:
|
|
1840
|
+
style: X({ color: A.currentPage == 1 ? "#B3B5C7" : "#1A1A1A" })
|
|
1828
1841
|
}, null, 8, ["style"])
|
|
1829
1842
|
], 4),
|
|
1830
|
-
(
|
|
1831
|
-
|
|
1843
|
+
(c(!0), D(eA, null, R(h(s), (K) => (c(), D(eA, { key: K }, [
|
|
1844
|
+
K === "..." ? (c(), D("div", {
|
|
1832
1845
|
key: 0,
|
|
1833
1846
|
class: "btn-number custom-pagination__btn custom-pagination__more",
|
|
1834
|
-
style:
|
|
1835
|
-
onMouseenter:
|
|
1836
|
-
onMouseleave:
|
|
1837
|
-
onClick:
|
|
1847
|
+
style: X({ paddingLeft: h(C) ? "9px" : "" }),
|
|
1848
|
+
onMouseenter: Q[0] || (Q[0] = (V) => C.value = !0),
|
|
1849
|
+
onMouseleave: Q[1] || (Q[1] = (V) => C.value = !1),
|
|
1850
|
+
onClick: o
|
|
1838
1851
|
}, [
|
|
1839
|
-
|
|
1840
|
-
"icon-class":
|
|
1852
|
+
S(h(U), {
|
|
1853
|
+
"icon-class": h(C) ? "arrow_2left" : "more",
|
|
1841
1854
|
class: "svg-icon-page",
|
|
1842
|
-
style:
|
|
1855
|
+
style: X({ color: h(C) ? "#1951FA" : "" })
|
|
1843
1856
|
}, null, 8, ["icon-class", "style"])
|
|
1844
|
-
], 36)) :
|
|
1857
|
+
], 36)) : K === "...." ? (c(), D("div", {
|
|
1845
1858
|
key: 1,
|
|
1846
1859
|
class: "btn-number custom-pagination__btn custom-pagination__more",
|
|
1847
|
-
style:
|
|
1848
|
-
onMouseenter:
|
|
1849
|
-
onMouseleave:
|
|
1850
|
-
onClick:
|
|
1860
|
+
style: X({ paddingRight: h(i) ? "9px" : "" }),
|
|
1861
|
+
onMouseenter: Q[2] || (Q[2] = (V) => i.value = !0),
|
|
1862
|
+
onMouseleave: Q[3] || (Q[3] = (V) => i.value = !1),
|
|
1863
|
+
onClick: b
|
|
1851
1864
|
}, [
|
|
1852
|
-
|
|
1853
|
-
"icon-class":
|
|
1865
|
+
S(h(U), {
|
|
1866
|
+
"icon-class": h(i) ? "arrow_2right" : "more",
|
|
1854
1867
|
class: "svg-icon-page",
|
|
1855
|
-
style:
|
|
1868
|
+
style: X({ color: h(i) ? "#1951FA" : "" })
|
|
1856
1869
|
}, null, 8, ["icon-class", "style"])
|
|
1857
|
-
], 36)) : (
|
|
1870
|
+
], 36)) : (c(), D("div", {
|
|
1858
1871
|
key: 2,
|
|
1859
|
-
class: gA(["btn-number custom-pagination__btn", { "is-active":
|
|
1860
|
-
onClick: (
|
|
1861
|
-
},
|
|
1872
|
+
class: gA(["btn-number custom-pagination__btn", { "is-active": A.currentPage === K }]),
|
|
1873
|
+
onClick: (V) => B(K)
|
|
1874
|
+
}, $(K), 11, De))
|
|
1862
1875
|
], 64))), 128)),
|
|
1863
|
-
|
|
1876
|
+
L("div", {
|
|
1864
1877
|
class: "btn-prev btn-number",
|
|
1865
|
-
style:
|
|
1866
|
-
onClick:
|
|
1878
|
+
style: X({ cursor: A.currentPage === h(p) ? "not-allowed" : "pointer" }),
|
|
1879
|
+
onClick: G
|
|
1867
1880
|
}, [
|
|
1868
|
-
|
|
1881
|
+
S(h(U), {
|
|
1869
1882
|
"icon-class": "12_12_arrow_right",
|
|
1870
1883
|
class: "svg-icon-page",
|
|
1871
|
-
style:
|
|
1884
|
+
style: X({ color: A.currentPage == h(p) ? "#B3B5C7" : "#1A1A1A" })
|
|
1872
1885
|
}, null, 8, ["style"])
|
|
1873
1886
|
], 4),
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
modelValue:
|
|
1877
|
-
"onUpdate:modelValue":
|
|
1878
|
-
"suffix-icon":
|
|
1879
|
-
onChange:
|
|
1887
|
+
h(e) ? (c(), D("div", ve, [
|
|
1888
|
+
S(P, {
|
|
1889
|
+
modelValue: h(y),
|
|
1890
|
+
"onUpdate:modelValue": Q[4] || (Q[4] = (K) => oA(y) ? y.value = K : null),
|
|
1891
|
+
"suffix-icon": h(m),
|
|
1892
|
+
onChange: E
|
|
1880
1893
|
}, {
|
|
1881
|
-
default:
|
|
1882
|
-
(
|
|
1883
|
-
key:
|
|
1884
|
-
label: `${
|
|
1885
|
-
value:
|
|
1894
|
+
default: f(() => [
|
|
1895
|
+
(c(!0), D(eA, null, R(A.pageSizes, (K) => (c(), Y(j, {
|
|
1896
|
+
key: K,
|
|
1897
|
+
label: `${K} 条/页`,
|
|
1898
|
+
value: K
|
|
1886
1899
|
}, null, 8, ["label", "value"]))), 128))
|
|
1887
1900
|
]),
|
|
1888
1901
|
_: 1
|
|
1889
1902
|
}, 8, ["modelValue", "suffix-icon"])
|
|
1890
|
-
])) :
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
modelValue:
|
|
1895
|
-
"onUpdate:modelValue":
|
|
1903
|
+
])) : _("", !0),
|
|
1904
|
+
h(r) ? (c(), D("div", ye, [
|
|
1905
|
+
Q[6] || (Q[6] = L("span", null, "前往", -1)),
|
|
1906
|
+
S(cA, {
|
|
1907
|
+
modelValue: h(M),
|
|
1908
|
+
"onUpdate:modelValue": Q[5] || (Q[5] = (K) => oA(M) ? M.value = K : null),
|
|
1896
1909
|
min: 1,
|
|
1897
|
-
max:
|
|
1910
|
+
max: h(p),
|
|
1898
1911
|
onKeyup: SA(k, ["enter"])
|
|
1899
1912
|
}, null, 8, ["modelValue", "max"]),
|
|
1900
|
-
|
|
1901
|
-
])) :
|
|
1913
|
+
Q[7] || (Q[7] = L("span", null, "页", -1))
|
|
1914
|
+
])) : _("", !0)
|
|
1902
1915
|
]);
|
|
1903
1916
|
};
|
|
1904
1917
|
}
|
|
1905
|
-
}), uA = /* @__PURE__ */ DA(Me, [["__scopeId", "data-v-87a6fd83"]]), fe = { class: "yw-selector-dialog" }, Ke = {
|
|
1918
|
+
}), uA = /* @__PURE__ */ DA(Me, [["__scopeId", "data-v-87a6fd83"]]), fe = { class: "yw-selector-dialog" }, Ke = {
|
|
1919
|
+
key: 0,
|
|
1920
|
+
class: "left"
|
|
1921
|
+
}, Ge = { class: "center" }, ke = {
|
|
1906
1922
|
key: 0,
|
|
1907
1923
|
class: "search"
|
|
1908
1924
|
}, ze = {
|
|
1909
1925
|
key: 1,
|
|
1910
1926
|
class: "table"
|
|
1911
|
-
}, Ye = { class: "right" }, Se = { class: "checked-total" }, EA = /* @__PURE__ */
|
|
1927
|
+
}, Ye = { class: "right" }, Se = { class: "checked-total" }, EA = /* @__PURE__ */ x({
|
|
1912
1928
|
__name: "SelectorDialog",
|
|
1913
1929
|
props: {
|
|
1914
1930
|
modelValue: {
|
|
1915
1931
|
type: Boolean,
|
|
1916
1932
|
default: !1
|
|
1917
1933
|
},
|
|
1934
|
+
isTree: {
|
|
1935
|
+
type: Boolean,
|
|
1936
|
+
default: !0
|
|
1937
|
+
},
|
|
1918
1938
|
title: {
|
|
1919
1939
|
type: String,
|
|
1920
1940
|
default: ""
|
|
@@ -1958,46 +1978,55 @@ const cA = /* @__PURE__ */ L({
|
|
|
1958
1978
|
multiple: {
|
|
1959
1979
|
type: Boolean,
|
|
1960
1980
|
default: !1
|
|
1981
|
+
},
|
|
1982
|
+
// 右侧选中table字段
|
|
1983
|
+
selectedTableColumns: {
|
|
1984
|
+
type: Array,
|
|
1985
|
+
default: () => []
|
|
1986
|
+
},
|
|
1987
|
+
selectedTableData: {
|
|
1988
|
+
type: Array,
|
|
1989
|
+
default: () => []
|
|
1961
1990
|
}
|
|
1962
1991
|
},
|
|
1963
1992
|
emits: ["update:modelValue", "update:selectedIds", "node-click", "page-change"],
|
|
1964
|
-
setup(A, { emit:
|
|
1965
|
-
const
|
|
1993
|
+
setup(A, { emit: u }) {
|
|
1994
|
+
const t = A, l = u, e = W(1), r = W(15), g = Z({
|
|
1966
1995
|
get() {
|
|
1967
|
-
return
|
|
1996
|
+
return t.modelValue;
|
|
1968
1997
|
},
|
|
1969
|
-
set(
|
|
1970
|
-
l("update:modelValue",
|
|
1998
|
+
set(s) {
|
|
1999
|
+
l("update:modelValue", s);
|
|
1971
2000
|
}
|
|
1972
|
-
}),
|
|
1973
|
-
l("node-click",
|
|
1974
|
-
},
|
|
1975
|
-
l("page-change",
|
|
1976
|
-
},
|
|
1977
|
-
const
|
|
1978
|
-
let a = [...
|
|
1979
|
-
|
|
1980
|
-
},
|
|
1981
|
-
const
|
|
1982
|
-
return
|
|
1983
|
-
},
|
|
1984
|
-
let
|
|
1985
|
-
const
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
}), l("update:selectedIds",
|
|
2001
|
+
}), m = (s) => {
|
|
2002
|
+
l("node-click", s);
|
|
2003
|
+
}, C = (s) => {
|
|
2004
|
+
l("page-change", s);
|
|
2005
|
+
}, i = (s) => s !== "search" && s !== "table" && s !== "default" && s !== "selection", w = (s) => t.selectedIds.includes(s[t.rowKey]) ? "16_16_checkbox_select" : "16_16_checkbox_normal", y = (s) => {
|
|
2006
|
+
const I = s[t.rowKey];
|
|
2007
|
+
let a = [...t.selectedIds];
|
|
2008
|
+
t.multiple ? a.includes(I) ? a = a.filter((o) => o !== I) : a.push(I) : a.includes(I) ? a = [] : a = [I], l("update:selectedIds", a);
|
|
2009
|
+
}, M = () => {
|
|
2010
|
+
const s = t.tableData.map((o) => o[t.rowKey]), I = s.every((o) => t.selectedIds.includes(o));
|
|
2011
|
+
return s.some((o) => t.selectedIds.includes(o)) && !I ? "16_16_checkbox_halfselect" : I ? "16_16_checkbox_select" : "16_16_checkbox_normal";
|
|
2012
|
+
}, p = () => {
|
|
2013
|
+
let s = [...t.selectedIds];
|
|
2014
|
+
const I = t.tableData.map((o) => o[t.rowKey]);
|
|
2015
|
+
I.every((o) => s.includes(o)) ? s = s.filter((o) => !I.includes(o)) : I.forEach((o) => {
|
|
2016
|
+
s.includes(o) || s.push(o);
|
|
2017
|
+
}), l("update:selectedIds", s);
|
|
1989
2018
|
};
|
|
1990
|
-
return (
|
|
2019
|
+
return (s, I) => (c(), Y(rA, {
|
|
1991
2020
|
class: "selector-dialog",
|
|
1992
|
-
modelValue:
|
|
1993
|
-
"onUpdate:modelValue":
|
|
2021
|
+
modelValue: h(g),
|
|
2022
|
+
"onUpdate:modelValue": I[2] || (I[2] = (a) => oA(g) ? g.value = a : null),
|
|
1994
2023
|
title: A.title,
|
|
1995
2024
|
size: A.size
|
|
1996
2025
|
}, {
|
|
1997
|
-
default:
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2026
|
+
default: f(() => [
|
|
2027
|
+
L("div", fe, [
|
|
2028
|
+
A.isTree ? (c(), D("div", Ke, [
|
|
2029
|
+
S(CA, {
|
|
2001
2030
|
ref: "treeRef",
|
|
2002
2031
|
class: "organization-tree",
|
|
2003
2032
|
data: A.treeData,
|
|
@@ -2007,16 +2036,16 @@ const cA = /* @__PURE__ */ L({
|
|
|
2007
2036
|
draggable: !1,
|
|
2008
2037
|
"highlight-current": "",
|
|
2009
2038
|
"node-key": "id",
|
|
2010
|
-
onNodeClick:
|
|
2039
|
+
onNodeClick: m
|
|
2011
2040
|
}, null, 8, ["data", "props"])
|
|
2012
|
-
]),
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
])) :
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
])) : (
|
|
2041
|
+
])) : _("", !0),
|
|
2042
|
+
L("div", Ge, [
|
|
2043
|
+
s.$slots.search ? (c(), D("div", ke, [
|
|
2044
|
+
N(s.$slots, "search")
|
|
2045
|
+
])) : _("", !0),
|
|
2046
|
+
s.$slots.table ? (c(), D("div", ze, [
|
|
2047
|
+
N(s.$slots, "table")
|
|
2048
|
+
])) : (c(), Y(iA, {
|
|
2020
2049
|
key: 2,
|
|
2021
2050
|
class: "selector-dialog-table",
|
|
2022
2051
|
ref: "tableRef",
|
|
@@ -2025,55 +2054,55 @@ const cA = /* @__PURE__ */ L({
|
|
|
2025
2054
|
data: A.tableData,
|
|
2026
2055
|
height: 400,
|
|
2027
2056
|
"max-height": 400,
|
|
2028
|
-
onRowClick:
|
|
2057
|
+
onRowClick: y
|
|
2029
2058
|
}, tA({
|
|
2030
|
-
"header-selection":
|
|
2031
|
-
|
|
2032
|
-
"icon-class":
|
|
2059
|
+
"header-selection": f((a) => [
|
|
2060
|
+
S(h(U), {
|
|
2061
|
+
"icon-class": M(),
|
|
2033
2062
|
style: { width: "16px", height: "16px" },
|
|
2034
|
-
onClick:
|
|
2063
|
+
onClick: p
|
|
2035
2064
|
}, null, 8, ["icon-class"])
|
|
2036
2065
|
]),
|
|
2037
|
-
selection:
|
|
2038
|
-
|
|
2039
|
-
"icon-class":
|
|
2066
|
+
selection: f((a) => [
|
|
2067
|
+
S(h(U), {
|
|
2068
|
+
"icon-class": w(a.row),
|
|
2040
2069
|
style: { width: "16px", height: "16px" }
|
|
2041
2070
|
}, null, 8, ["icon-class"])
|
|
2042
2071
|
]),
|
|
2043
2072
|
_: 2
|
|
2044
2073
|
}, [
|
|
2045
|
-
|
|
2046
|
-
name:
|
|
2047
|
-
fn:
|
|
2048
|
-
|
|
2074
|
+
R(s.$slots, (a, o) => ({
|
|
2075
|
+
name: o,
|
|
2076
|
+
fn: f((b) => [
|
|
2077
|
+
i(o) ? N(s.$slots, o, nA(F({ key: 0 }, b))) : _("", !0)
|
|
2049
2078
|
])
|
|
2050
2079
|
}))
|
|
2051
2080
|
]), 1032, ["columns", "data"])),
|
|
2052
|
-
|
|
2081
|
+
S(uA, {
|
|
2053
2082
|
class: "selector-pagination",
|
|
2054
2083
|
total: A.tableTotal,
|
|
2055
2084
|
pagerCount: 3,
|
|
2056
2085
|
layouts: ["Total", "PrevPage", "Number", "NextPage", "Sizes", "FullJump", "Jumper"],
|
|
2057
|
-
"current-page":
|
|
2058
|
-
"onUpdate:currentPage":
|
|
2059
|
-
"page-size":
|
|
2060
|
-
"onUpdate:pageSize":
|
|
2061
|
-
onPageChange:
|
|
2086
|
+
"current-page": h(e),
|
|
2087
|
+
"onUpdate:currentPage": I[0] || (I[0] = (a) => oA(e) ? e.value = a : null),
|
|
2088
|
+
"page-size": h(r),
|
|
2089
|
+
"onUpdate:pageSize": I[1] || (I[1] = (a) => oA(r) ? r.value = a : null),
|
|
2090
|
+
onPageChange: C
|
|
2062
2091
|
}, null, 8, ["total", "current-page", "page-size"])
|
|
2063
2092
|
]),
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2093
|
+
L("div", Ye, [
|
|
2094
|
+
L("div", Se, "已选(" + $(A.selectedTableData.length) + ")", 1),
|
|
2095
|
+
S(iA, {
|
|
2067
2096
|
border: !0,
|
|
2068
|
-
columns: A.
|
|
2069
|
-
data: A.
|
|
2097
|
+
columns: A.selectedTableColumns,
|
|
2098
|
+
data: A.selectedTableData,
|
|
2070
2099
|
height: 454,
|
|
2071
2100
|
"max-height": 454
|
|
2072
2101
|
}, tA({ _: 2 }, [
|
|
2073
|
-
|
|
2074
|
-
name:
|
|
2075
|
-
fn:
|
|
2076
|
-
|
|
2102
|
+
R(s.$slots, (a, o) => ({
|
|
2103
|
+
name: o,
|
|
2104
|
+
fn: f((b) => [
|
|
2105
|
+
i(o) ? N(s.$slots, o, nA(F({ key: 0 }, b))) : _("", !0)
|
|
2077
2106
|
])
|
|
2078
2107
|
}))
|
|
2079
2108
|
]), 1032, ["columns", "data"])
|
|
@@ -2093,10 +2122,10 @@ uA.install = (A) => {
|
|
|
2093
2122
|
cA.install = (A) => {
|
|
2094
2123
|
A.component("YwInputNumber", cA);
|
|
2095
2124
|
};
|
|
2096
|
-
const Ze = [sA, BA, pA, mA, IA,
|
|
2125
|
+
const Ze = [sA, BA, pA, mA, IA, U, hA, QA, rA, CA, iA, qA, EA, uA, cA], Fe = {
|
|
2097
2126
|
install(A) {
|
|
2098
|
-
A.use(kA), Ze.forEach((
|
|
2099
|
-
A.use(
|
|
2127
|
+
A.use(kA), Ze.forEach((u) => {
|
|
2128
|
+
A.use(u);
|
|
2100
2129
|
});
|
|
2101
2130
|
}
|
|
2102
2131
|
};
|