@yqg/permission 1.3.0 → 1.3.1-1.beta.0
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/{apply-modal-Ct9rKeUf.js → apply-modal-B4niAWln.js} +3882 -4161
- package/dist/{category-selector-BnUMBDty.js → category-selector-CJ2VLSr7.js} +81 -81
- package/dist/{index-XvlOgi6s.js → index-CJ_Ktj6t.js} +1828 -1836
- package/dist/{index-CAVNFmBo.js → index-CZ6UV6_X.js} +4 -4
- package/dist/index.js +2 -2
- package/dist/permission-item-Bm9OiOSx.js +1252 -0
- package/dist/{yqg-permission-BrOMv4sA.js → yqg-permission-Cb-_sywm.js} +3738 -3696
- package/dist/yqg-permission.umd.js +65 -65
- package/package.json +9 -10
- package/src/App.vue +10 -13
- package/src/axios/index.ts +1 -1
- package/src/components/apply-modal.vue +162 -75
- package/src/components/approval-steps.vue +39 -40
- package/src/components/category-selector.vue +27 -12
- package/src/components/permission-item.vue +49 -37
- package/src/components/success-modal.vue +45 -45
- package/src/components/yqg-permission.vue +169 -144
- package/src/hooks/useAttributesCache.ts +23 -1
- package/src/hooks/useCategory.ts +2 -1
- package/src/hooks/useFormat.ts +20 -7
- package/src/i18n/en-US.ts +50 -50
- package/src/i18n/in-ID.ts +57 -0
- package/src/i18n/index.ts +5 -2
- package/src/i18n/zh-CH.ts +4 -10
- package/src/style/reset.css +3 -0
- package/src/typings/index.d.ts +8 -0
- package/src/utils/index.ts +16 -2
- package/src/yqg-permission/react.js +0 -0
- package/tsconfig.app.json +8 -8
- package/dist/permission-item-2JurQrn-.js +0 -1250
|
@@ -0,0 +1,1252 @@
|
|
|
1
|
+
import { c as he, Y as Te, a as H, a1 as We, b as ot, _ as T, ae as Xe, aX as Me, aZ as He, P as ae, a0 as Be, ar as at, as as it, aD as st, aY as rt, a_ as ct, ai as ut, ak as Ae, aj as dt, $ as je, N as vt, Q as mt, a$ as ft, R as gt, b0 as pt, aq as ht, b1 as bt, b2 as yt, b3 as St, aE as Ct, aP as X, aR as we, aS as At } from "./yqg-permission-Cb-_sywm.js";
|
|
2
|
+
import { p as Ot, a as It, d as be, c as A, G as wt, w as Fe, E as Ye, q as _e, e as N, F as Ve, s as ve, b as Ne, y as oe, r as Qe, N as ue, L as U, K as Oe, R as de, P as K, M as J, U as Pe, S as M, O as xt, u as B, $ as Vt, Y as ze } from "./index-CJ_Ktj6t.js";
|
|
3
|
+
import { j as Nt, L as Tt, p as Pt, K as Z, d as Et, F as Ft, e as Dt, f as Rt, Q as Bt } from "./apply-modal-B4niAWln.js";
|
|
4
|
+
import { u as kt, b as $t, T as Lt, i as De, c as Mt, h as Ht, j as jt, k as _t, t as zt, B as Ut, e as Kt, f as Gt, g as Wt } from "./index-CZ6UV6_X.js";
|
|
5
|
+
function Xt() {
|
|
6
|
+
return /(mac\sos|macintosh)/i.test(navigator.appVersion);
|
|
7
|
+
}
|
|
8
|
+
const qe = Symbol("SelectContextKey");
|
|
9
|
+
function Yt(e) {
|
|
10
|
+
return Ot(qe, e);
|
|
11
|
+
}
|
|
12
|
+
function Qt() {
|
|
13
|
+
return It(qe, {});
|
|
14
|
+
}
|
|
15
|
+
var qt = function(e, g) {
|
|
16
|
+
var i = {};
|
|
17
|
+
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && g.indexOf(n) < 0 && (i[n] = e[n]);
|
|
18
|
+
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var t = 0, n = Object.getOwnPropertySymbols(e); t < n.length; t++)
|
|
19
|
+
g.indexOf(n[t]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[t]) && (i[n[t]] = e[n[t]]);
|
|
20
|
+
return i;
|
|
21
|
+
};
|
|
22
|
+
function Ue(e) {
|
|
23
|
+
return typeof e == "string" || typeof e == "number";
|
|
24
|
+
}
|
|
25
|
+
const Jt = be({
|
|
26
|
+
compatConfig: {
|
|
27
|
+
MODE: 3
|
|
28
|
+
},
|
|
29
|
+
name: "OptionList",
|
|
30
|
+
inheritAttrs: !1,
|
|
31
|
+
setup(e, g) {
|
|
32
|
+
let {
|
|
33
|
+
expose: i,
|
|
34
|
+
slots: n
|
|
35
|
+
} = g;
|
|
36
|
+
const t = kt(), o = Qt(), v = A(() => `${t.prefixCls}-item`), m = $t(() => o.flattenOptions, [() => t.open, () => o.flattenOptions], (s) => s[0]), p = Nt(), f = (s) => {
|
|
37
|
+
s.preventDefault();
|
|
38
|
+
}, a = (s) => {
|
|
39
|
+
p.current && p.current.scrollTo(typeof s == "number" ? {
|
|
40
|
+
index: s
|
|
41
|
+
} : s);
|
|
42
|
+
}, y = function(s) {
|
|
43
|
+
let I = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 1;
|
|
44
|
+
const x = m.value.length;
|
|
45
|
+
for (let S = 0; S < x; S += 1) {
|
|
46
|
+
const P = (s + S * I + x) % x, {
|
|
47
|
+
group: j,
|
|
48
|
+
data: $
|
|
49
|
+
} = m.value[P];
|
|
50
|
+
if (!j && !$.disabled)
|
|
51
|
+
return P;
|
|
52
|
+
}
|
|
53
|
+
return -1;
|
|
54
|
+
}, V = wt({
|
|
55
|
+
activeIndex: y(0)
|
|
56
|
+
}), w = function(s) {
|
|
57
|
+
let I = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
58
|
+
V.activeIndex = s;
|
|
59
|
+
const x = {
|
|
60
|
+
source: I ? "keyboard" : "mouse"
|
|
61
|
+
}, S = m.value[s];
|
|
62
|
+
if (!S) {
|
|
63
|
+
o.onActiveValue(null, -1, x);
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
o.onActiveValue(S.value, s, x);
|
|
67
|
+
};
|
|
68
|
+
Fe([() => m.value.length, () => t.searchValue], () => {
|
|
69
|
+
w(o.defaultActiveFirstOption !== !1 ? y(0) : -1);
|
|
70
|
+
}, {
|
|
71
|
+
immediate: !0
|
|
72
|
+
});
|
|
73
|
+
const c = (s) => o.rawValues.has(s) && t.mode !== "combobox";
|
|
74
|
+
Fe([() => t.open, () => t.searchValue], () => {
|
|
75
|
+
if (!t.multiple && t.open && o.rawValues.size === 1) {
|
|
76
|
+
const s = Array.from(o.rawValues)[0], I = Ye(m.value).findIndex((x) => {
|
|
77
|
+
let {
|
|
78
|
+
data: S
|
|
79
|
+
} = x;
|
|
80
|
+
return S[o.fieldNames.value] === s;
|
|
81
|
+
});
|
|
82
|
+
I !== -1 && (w(I), _e(() => {
|
|
83
|
+
a(I);
|
|
84
|
+
}));
|
|
85
|
+
}
|
|
86
|
+
t.open && _e(() => {
|
|
87
|
+
var s;
|
|
88
|
+
(s = p.current) === null || s === void 0 || s.scrollTo(void 0);
|
|
89
|
+
});
|
|
90
|
+
}, {
|
|
91
|
+
immediate: !0,
|
|
92
|
+
flush: "post"
|
|
93
|
+
});
|
|
94
|
+
const C = (s) => {
|
|
95
|
+
s !== void 0 && o.onSelect(s, {
|
|
96
|
+
selected: !o.rawValues.has(s)
|
|
97
|
+
}), t.multiple || t.toggleOpen(!1);
|
|
98
|
+
}, O = (s) => typeof s.label == "function" ? s.label() : s.label;
|
|
99
|
+
function F(s) {
|
|
100
|
+
const I = m.value[s];
|
|
101
|
+
if (!I) return null;
|
|
102
|
+
const x = I.data || {}, {
|
|
103
|
+
value: S
|
|
104
|
+
} = x, {
|
|
105
|
+
group: P
|
|
106
|
+
} = I, j = Pt(x, !0), $ = O(I);
|
|
107
|
+
return I ? N("div", H(H({
|
|
108
|
+
"aria-label": typeof $ == "string" && !P ? $ : null
|
|
109
|
+
}, j), {}, {
|
|
110
|
+
key: s,
|
|
111
|
+
role: P ? "presentation" : "option",
|
|
112
|
+
id: `${t.id}_list_${s}`,
|
|
113
|
+
"aria-selected": c(S)
|
|
114
|
+
}), [S]) : null;
|
|
115
|
+
}
|
|
116
|
+
return i({
|
|
117
|
+
onKeydown: (s) => {
|
|
118
|
+
const {
|
|
119
|
+
which: I,
|
|
120
|
+
ctrlKey: x
|
|
121
|
+
} = s;
|
|
122
|
+
switch (I) {
|
|
123
|
+
case Z.N:
|
|
124
|
+
case Z.P:
|
|
125
|
+
case Z.UP:
|
|
126
|
+
case Z.DOWN: {
|
|
127
|
+
let S = 0;
|
|
128
|
+
if (I === Z.UP ? S = -1 : I === Z.DOWN ? S = 1 : Xt() && x && (I === Z.N ? S = 1 : I === Z.P && (S = -1)), S !== 0) {
|
|
129
|
+
const P = y(V.activeIndex + S, S);
|
|
130
|
+
a(P), w(P, !0);
|
|
131
|
+
}
|
|
132
|
+
break;
|
|
133
|
+
}
|
|
134
|
+
case Z.ENTER: {
|
|
135
|
+
const S = m.value[V.activeIndex];
|
|
136
|
+
S && !S.data.disabled ? C(S.value) : C(void 0), t.open && s.preventDefault();
|
|
137
|
+
break;
|
|
138
|
+
}
|
|
139
|
+
case Z.ESC:
|
|
140
|
+
t.toggleOpen(!1), t.open && s.stopPropagation();
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
onKeyup: () => {
|
|
144
|
+
},
|
|
145
|
+
scrollTo: (s) => {
|
|
146
|
+
a(s);
|
|
147
|
+
}
|
|
148
|
+
}), () => {
|
|
149
|
+
const {
|
|
150
|
+
id: s,
|
|
151
|
+
notFoundContent: I,
|
|
152
|
+
onPopupScroll: x
|
|
153
|
+
} = t, {
|
|
154
|
+
menuItemSelectedIcon: S,
|
|
155
|
+
fieldNames: P,
|
|
156
|
+
virtual: j,
|
|
157
|
+
listHeight: $,
|
|
158
|
+
listItemHeight: me
|
|
159
|
+
} = o, te = n.option, {
|
|
160
|
+
activeIndex: _
|
|
161
|
+
} = V, ye = Object.keys(P).map((L) => P[L]);
|
|
162
|
+
return m.value.length === 0 ? N("div", {
|
|
163
|
+
role: "listbox",
|
|
164
|
+
id: `${s}_list`,
|
|
165
|
+
class: `${v.value}-empty`,
|
|
166
|
+
onMousedown: f
|
|
167
|
+
}, [I]) : N(Ve, null, [N("div", {
|
|
168
|
+
role: "listbox",
|
|
169
|
+
id: `${s}_list`,
|
|
170
|
+
style: {
|
|
171
|
+
height: 0,
|
|
172
|
+
width: 0,
|
|
173
|
+
overflow: "hidden"
|
|
174
|
+
}
|
|
175
|
+
}, [F(_ - 1), F(_), F(_ + 1)]), N(Tt, {
|
|
176
|
+
itemKey: "key",
|
|
177
|
+
ref: p,
|
|
178
|
+
data: m.value,
|
|
179
|
+
height: $,
|
|
180
|
+
itemHeight: me,
|
|
181
|
+
fullHeight: !1,
|
|
182
|
+
onMousedown: f,
|
|
183
|
+
onScroll: x,
|
|
184
|
+
virtual: j
|
|
185
|
+
}, {
|
|
186
|
+
default: (L, ie) => {
|
|
187
|
+
var se;
|
|
188
|
+
const {
|
|
189
|
+
group: fe,
|
|
190
|
+
groupOption: Se,
|
|
191
|
+
data: h,
|
|
192
|
+
value: D
|
|
193
|
+
} = L, {
|
|
194
|
+
key: z
|
|
195
|
+
} = h, Q = typeof L.label == "function" ? L.label() : L.label;
|
|
196
|
+
if (fe) {
|
|
197
|
+
const ce = (se = h.title) !== null && se !== void 0 ? se : Ue(Q) && Q;
|
|
198
|
+
return N("div", {
|
|
199
|
+
class: he(v.value, `${v.value}-group`),
|
|
200
|
+
title: ce
|
|
201
|
+
}, [te ? te(h) : Q !== void 0 ? Q : z]);
|
|
202
|
+
}
|
|
203
|
+
const {
|
|
204
|
+
disabled: le,
|
|
205
|
+
title: ge,
|
|
206
|
+
children: re,
|
|
207
|
+
style: Ce,
|
|
208
|
+
class: l,
|
|
209
|
+
className: r
|
|
210
|
+
} = h, u = qt(h, ["disabled", "title", "children", "style", "class", "className"]), b = Te(u, ye), d = c(D), E = `${v.value}-option`, ne = he(v.value, E, l, r, {
|
|
211
|
+
[`${E}-grouped`]: Se,
|
|
212
|
+
[`${E}-active`]: _ === ie && !le,
|
|
213
|
+
[`${E}-disabled`]: le,
|
|
214
|
+
[`${E}-selected`]: d
|
|
215
|
+
}), W = O(L), q = !S || typeof S == "function" || d, R = typeof W == "number" ? W : W || D;
|
|
216
|
+
let Ie = Ue(R) ? R.toString() : void 0;
|
|
217
|
+
return ge !== void 0 && (Ie = ge), N("div", H(H({}, b), {}, {
|
|
218
|
+
"aria-selected": d,
|
|
219
|
+
class: ne,
|
|
220
|
+
title: Ie,
|
|
221
|
+
onMousemove: (ce) => {
|
|
222
|
+
u.onMousemove && u.onMousemove(ce), !(_ === ie || le) && w(ie);
|
|
223
|
+
},
|
|
224
|
+
onClick: (ce) => {
|
|
225
|
+
le || C(D), u.onClick && u.onClick(ce);
|
|
226
|
+
},
|
|
227
|
+
style: Ce
|
|
228
|
+
}), [N("div", {
|
|
229
|
+
class: `${E}-content`
|
|
230
|
+
}, [te ? te(h) : R]), We(S) || d, q && N(Lt, {
|
|
231
|
+
class: `${v.value}-option-state`,
|
|
232
|
+
customizeIcon: S,
|
|
233
|
+
customizeIconProps: {
|
|
234
|
+
isSelected: d
|
|
235
|
+
}
|
|
236
|
+
}, {
|
|
237
|
+
default: () => [d ? "✓" : null]
|
|
238
|
+
})]);
|
|
239
|
+
}
|
|
240
|
+
})]);
|
|
241
|
+
};
|
|
242
|
+
}
|
|
243
|
+
});
|
|
244
|
+
var Zt = function(e, g) {
|
|
245
|
+
var i = {};
|
|
246
|
+
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && g.indexOf(n) < 0 && (i[n] = e[n]);
|
|
247
|
+
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var t = 0, n = Object.getOwnPropertySymbols(e); t < n.length; t++)
|
|
248
|
+
g.indexOf(n[t]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[t]) && (i[n[t]] = e[n[t]]);
|
|
249
|
+
return i;
|
|
250
|
+
};
|
|
251
|
+
function el(e) {
|
|
252
|
+
const g = e, {
|
|
253
|
+
key: i,
|
|
254
|
+
children: n
|
|
255
|
+
} = g, t = g.props, {
|
|
256
|
+
value: o,
|
|
257
|
+
disabled: v
|
|
258
|
+
} = t, m = Zt(t, ["value", "disabled"]), p = n == null ? void 0 : n.default;
|
|
259
|
+
return T({
|
|
260
|
+
key: i,
|
|
261
|
+
value: o !== void 0 ? o : i,
|
|
262
|
+
children: p,
|
|
263
|
+
disabled: v || v === ""
|
|
264
|
+
}, m);
|
|
265
|
+
}
|
|
266
|
+
function Je(e) {
|
|
267
|
+
let g = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
268
|
+
return ot(e).map((n, t) => {
|
|
269
|
+
var o;
|
|
270
|
+
if (!We(n) || !n.type)
|
|
271
|
+
return null;
|
|
272
|
+
const {
|
|
273
|
+
type: {
|
|
274
|
+
isSelectOptGroup: v
|
|
275
|
+
},
|
|
276
|
+
key: m,
|
|
277
|
+
children: p,
|
|
278
|
+
props: f
|
|
279
|
+
} = n;
|
|
280
|
+
if (g || !v)
|
|
281
|
+
return el(n);
|
|
282
|
+
const a = p && p.default ? p.default() : void 0, y = (f == null ? void 0 : f.label) || ((o = p.label) === null || o === void 0 ? void 0 : o.call(p)) || m;
|
|
283
|
+
return T(T({
|
|
284
|
+
key: `__RC_SELECT_GRP__${m === null ? t : String(m)}__`
|
|
285
|
+
}, f), {
|
|
286
|
+
label: y,
|
|
287
|
+
options: Je(a || [])
|
|
288
|
+
});
|
|
289
|
+
}).filter((n) => n);
|
|
290
|
+
}
|
|
291
|
+
function tl(e, g, i) {
|
|
292
|
+
const n = ve(), t = ve(), o = ve(), v = ve([]);
|
|
293
|
+
return Fe([e, g], () => {
|
|
294
|
+
e.value ? v.value = Ye(e.value).slice() : v.value = Je(g.value);
|
|
295
|
+
}, {
|
|
296
|
+
immediate: !0,
|
|
297
|
+
deep: !0
|
|
298
|
+
}), Ne(() => {
|
|
299
|
+
const m = v.value, p = /* @__PURE__ */ new Map(), f = /* @__PURE__ */ new Map(), a = i.value;
|
|
300
|
+
function y(V) {
|
|
301
|
+
let w = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
302
|
+
for (let c = 0; c < V.length; c += 1) {
|
|
303
|
+
const C = V[c];
|
|
304
|
+
!C[a.options] || w ? (p.set(C[a.value], C), f.set(C[a.label], C)) : y(C[a.options], !0);
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
y(m), n.value = m, t.value = p, o.value = f;
|
|
308
|
+
}), {
|
|
309
|
+
options: n,
|
|
310
|
+
valueOptions: t,
|
|
311
|
+
labelOptions: o
|
|
312
|
+
};
|
|
313
|
+
}
|
|
314
|
+
function Ze(e) {
|
|
315
|
+
return Array.isArray(e) ? e : e !== void 0 ? [e] : [];
|
|
316
|
+
}
|
|
317
|
+
function Ee(e, g) {
|
|
318
|
+
return Ze(e).join("").toUpperCase().includes(g);
|
|
319
|
+
}
|
|
320
|
+
const ll = (e, g, i, n, t) => A(() => {
|
|
321
|
+
const o = i.value, v = t == null ? void 0 : t.value, m = n == null ? void 0 : n.value;
|
|
322
|
+
if (!o || m === !1)
|
|
323
|
+
return e.value;
|
|
324
|
+
const {
|
|
325
|
+
options: p,
|
|
326
|
+
label: f,
|
|
327
|
+
value: a
|
|
328
|
+
} = g.value, y = [], V = typeof m == "function", w = o.toUpperCase(), c = V ? m : (O, F) => v ? Ee(F[v], w) : F[p] ? Ee(F[f !== "children" ? f : "label"], w) : Ee(F[a], w), C = V ? (O) => De(O) : (O) => O;
|
|
329
|
+
return e.value.forEach((O) => {
|
|
330
|
+
if (O[p]) {
|
|
331
|
+
if (c(o, C(O)))
|
|
332
|
+
y.push(O);
|
|
333
|
+
else {
|
|
334
|
+
const Y = O[p].filter((G) => c(o, C(G)));
|
|
335
|
+
Y.length && y.push(T(T({}, O), {
|
|
336
|
+
[p]: Y
|
|
337
|
+
}));
|
|
338
|
+
}
|
|
339
|
+
return;
|
|
340
|
+
}
|
|
341
|
+
c(o, C(O)) && y.push(O);
|
|
342
|
+
}), y;
|
|
343
|
+
}), nl = (e, g) => {
|
|
344
|
+
const i = ve({
|
|
345
|
+
values: /* @__PURE__ */ new Map(),
|
|
346
|
+
options: /* @__PURE__ */ new Map()
|
|
347
|
+
});
|
|
348
|
+
return [A(() => {
|
|
349
|
+
const {
|
|
350
|
+
values: o,
|
|
351
|
+
options: v
|
|
352
|
+
} = i.value, m = e.value.map((a) => {
|
|
353
|
+
var y;
|
|
354
|
+
return a.label === void 0 ? T(T({}, a), {
|
|
355
|
+
label: (y = o.get(a.value)) === null || y === void 0 ? void 0 : y.label
|
|
356
|
+
}) : a;
|
|
357
|
+
}), p = /* @__PURE__ */ new Map(), f = /* @__PURE__ */ new Map();
|
|
358
|
+
return m.forEach((a) => {
|
|
359
|
+
p.set(a.value, a), f.set(a.value, g.value.get(a.value) || v.get(a.value));
|
|
360
|
+
}), i.value.values = p, i.value.options = f, m;
|
|
361
|
+
}), (o) => g.value.get(o) || i.value.options.get(o)];
|
|
362
|
+
}, ol = ["inputValue"];
|
|
363
|
+
function et() {
|
|
364
|
+
return T(T({}, Kt()), {
|
|
365
|
+
prefixCls: String,
|
|
366
|
+
id: String,
|
|
367
|
+
backfill: {
|
|
368
|
+
type: Boolean,
|
|
369
|
+
default: void 0
|
|
370
|
+
},
|
|
371
|
+
// >>> Field Names
|
|
372
|
+
fieldNames: Object,
|
|
373
|
+
// >>> Search
|
|
374
|
+
/** @deprecated Use `searchValue` instead */
|
|
375
|
+
inputValue: String,
|
|
376
|
+
searchValue: String,
|
|
377
|
+
onSearch: Function,
|
|
378
|
+
autoClearSearchValue: {
|
|
379
|
+
type: Boolean,
|
|
380
|
+
default: void 0
|
|
381
|
+
},
|
|
382
|
+
// >>> Select
|
|
383
|
+
onSelect: Function,
|
|
384
|
+
onDeselect: Function,
|
|
385
|
+
// >>> Options
|
|
386
|
+
/**
|
|
387
|
+
* In Select, `false` means do nothing.
|
|
388
|
+
* In TreeSelect, `false` will highlight match item.
|
|
389
|
+
* It's by design.
|
|
390
|
+
*/
|
|
391
|
+
filterOption: {
|
|
392
|
+
type: [Boolean, Function],
|
|
393
|
+
default: void 0
|
|
394
|
+
},
|
|
395
|
+
filterSort: Function,
|
|
396
|
+
optionFilterProp: String,
|
|
397
|
+
optionLabelProp: String,
|
|
398
|
+
options: Array,
|
|
399
|
+
defaultActiveFirstOption: {
|
|
400
|
+
type: Boolean,
|
|
401
|
+
default: void 0
|
|
402
|
+
},
|
|
403
|
+
virtual: {
|
|
404
|
+
type: Boolean,
|
|
405
|
+
default: void 0
|
|
406
|
+
},
|
|
407
|
+
listHeight: Number,
|
|
408
|
+
listItemHeight: Number,
|
|
409
|
+
// >>> Icon
|
|
410
|
+
menuItemSelectedIcon: ae.any,
|
|
411
|
+
mode: String,
|
|
412
|
+
labelInValue: {
|
|
413
|
+
type: Boolean,
|
|
414
|
+
default: void 0
|
|
415
|
+
},
|
|
416
|
+
value: ae.any,
|
|
417
|
+
defaultValue: ae.any,
|
|
418
|
+
onChange: Function,
|
|
419
|
+
children: Array
|
|
420
|
+
});
|
|
421
|
+
}
|
|
422
|
+
function al(e) {
|
|
423
|
+
return !e || typeof e != "object";
|
|
424
|
+
}
|
|
425
|
+
const il = be({
|
|
426
|
+
compatConfig: {
|
|
427
|
+
MODE: 3
|
|
428
|
+
},
|
|
429
|
+
name: "VcSelect",
|
|
430
|
+
inheritAttrs: !1,
|
|
431
|
+
props: Xe(et(), {
|
|
432
|
+
prefixCls: "vc-select",
|
|
433
|
+
autoClearSearchValue: !0,
|
|
434
|
+
listHeight: 200,
|
|
435
|
+
listItemHeight: 20,
|
|
436
|
+
dropdownMatchSelectWidth: !0
|
|
437
|
+
}),
|
|
438
|
+
setup(e, g) {
|
|
439
|
+
let {
|
|
440
|
+
expose: i,
|
|
441
|
+
attrs: n,
|
|
442
|
+
slots: t
|
|
443
|
+
} = g;
|
|
444
|
+
const o = Mt(oe(e, "id")), v = A(() => Ht(e.mode)), m = A(() => !!(!e.options && e.children)), p = A(() => e.filterOption === void 0 && e.mode === "combobox" ? !1 : e.filterOption), f = A(() => jt(e.fieldNames, m.value)), [a, y] = Me("", {
|
|
445
|
+
value: A(() => e.searchValue !== void 0 ? e.searchValue : e.inputValue),
|
|
446
|
+
postState: (l) => l || ""
|
|
447
|
+
}), V = tl(oe(e, "options"), oe(e, "children"), f), {
|
|
448
|
+
valueOptions: w,
|
|
449
|
+
labelOptions: c,
|
|
450
|
+
options: C
|
|
451
|
+
} = V, O = (l) => Ze(l).map((u) => {
|
|
452
|
+
var b, d;
|
|
453
|
+
let E, ne, W, q;
|
|
454
|
+
al(u) ? E = u : (W = u.key, ne = u.label, E = (b = u.value) !== null && b !== void 0 ? b : W);
|
|
455
|
+
const R = w.value.get(E);
|
|
456
|
+
return R && (ne === void 0 && (ne = R == null ? void 0 : R[e.optionLabelProp || f.value.label]), W === void 0 && (W = (d = R == null ? void 0 : R.key) !== null && d !== void 0 ? d : E), q = R == null ? void 0 : R.disabled), {
|
|
457
|
+
label: ne,
|
|
458
|
+
value: E,
|
|
459
|
+
key: W,
|
|
460
|
+
disabled: q,
|
|
461
|
+
option: R
|
|
462
|
+
};
|
|
463
|
+
}), [F, Y] = Me(e.defaultValue, {
|
|
464
|
+
value: oe(e, "value")
|
|
465
|
+
}), G = A(() => {
|
|
466
|
+
var l;
|
|
467
|
+
const r = O(F.value);
|
|
468
|
+
return e.mode === "combobox" && !(!((l = r[0]) === null || l === void 0) && l.value) ? [] : r;
|
|
469
|
+
}), [k, s] = nl(G, w), I = A(() => {
|
|
470
|
+
if (!e.mode && k.value.length === 1) {
|
|
471
|
+
const l = k.value[0];
|
|
472
|
+
if (l.value === null && (l.label === null || l.label === void 0))
|
|
473
|
+
return [];
|
|
474
|
+
}
|
|
475
|
+
return k.value.map((l) => {
|
|
476
|
+
var r;
|
|
477
|
+
return T(T({}, l), {
|
|
478
|
+
label: (r = typeof l.label == "function" ? l.label() : l.label) !== null && r !== void 0 ? r : l.value
|
|
479
|
+
});
|
|
480
|
+
});
|
|
481
|
+
}), x = A(() => new Set(k.value.map((l) => l.value)));
|
|
482
|
+
Ne(() => {
|
|
483
|
+
var l;
|
|
484
|
+
if (e.mode === "combobox") {
|
|
485
|
+
const r = (l = k.value[0]) === null || l === void 0 ? void 0 : l.value;
|
|
486
|
+
r != null && y(String(r));
|
|
487
|
+
}
|
|
488
|
+
}, {
|
|
489
|
+
flush: "post"
|
|
490
|
+
});
|
|
491
|
+
const S = (l, r) => {
|
|
492
|
+
const u = r ?? l;
|
|
493
|
+
return {
|
|
494
|
+
[f.value.value]: l,
|
|
495
|
+
[f.value.label]: u
|
|
496
|
+
};
|
|
497
|
+
}, P = ve();
|
|
498
|
+
Ne(() => {
|
|
499
|
+
if (e.mode !== "tags") {
|
|
500
|
+
P.value = C.value;
|
|
501
|
+
return;
|
|
502
|
+
}
|
|
503
|
+
const l = C.value.slice(), r = (u) => w.value.has(u);
|
|
504
|
+
[...k.value].sort((u, b) => u.value < b.value ? -1 : 1).forEach((u) => {
|
|
505
|
+
const b = u.value;
|
|
506
|
+
r(b) || l.push(S(b, u.label));
|
|
507
|
+
}), P.value = l;
|
|
508
|
+
});
|
|
509
|
+
const j = ll(P, f, a, p, oe(e, "optionFilterProp")), $ = A(() => e.mode !== "tags" || !a.value || j.value.some((l) => l[e.optionFilterProp || "value"] === a.value) ? j.value : [S(a.value), ...j.value]), me = A(() => e.filterSort ? [...$.value].sort((l, r) => e.filterSort(l, r)) : $.value), te = A(() => _t(me.value, {
|
|
510
|
+
fieldNames: f.value,
|
|
511
|
+
childrenAsData: m.value
|
|
512
|
+
})), _ = (l) => {
|
|
513
|
+
const r = O(l);
|
|
514
|
+
if (Y(r), e.onChange && // Trigger event only when value changed
|
|
515
|
+
(r.length !== k.value.length || r.some((u, b) => {
|
|
516
|
+
var d;
|
|
517
|
+
return ((d = k.value[b]) === null || d === void 0 ? void 0 : d.value) !== (u == null ? void 0 : u.value);
|
|
518
|
+
}))) {
|
|
519
|
+
const u = e.labelInValue ? r.map((d) => T(T({}, d), {
|
|
520
|
+
originLabel: d.label,
|
|
521
|
+
label: typeof d.label == "function" ? d.label() : d.label
|
|
522
|
+
})) : r.map((d) => d.value), b = r.map((d) => De(s(d.value)));
|
|
523
|
+
e.onChange(
|
|
524
|
+
// Value
|
|
525
|
+
v.value ? u : u[0],
|
|
526
|
+
// Option
|
|
527
|
+
v.value ? b : b[0]
|
|
528
|
+
);
|
|
529
|
+
}
|
|
530
|
+
}, [ye, L] = He(null), [ie, se] = He(0), fe = A(() => e.defaultActiveFirstOption !== void 0 ? e.defaultActiveFirstOption : e.mode !== "combobox"), Se = function(l, r) {
|
|
531
|
+
let {
|
|
532
|
+
source: u = "keyboard"
|
|
533
|
+
} = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
534
|
+
se(r), e.backfill && e.mode === "combobox" && l !== null && u === "keyboard" && L(String(l));
|
|
535
|
+
}, h = (l, r) => {
|
|
536
|
+
const u = () => {
|
|
537
|
+
var b;
|
|
538
|
+
const d = s(l), E = d == null ? void 0 : d[f.value.label];
|
|
539
|
+
return [e.labelInValue ? {
|
|
540
|
+
label: typeof E == "function" ? E() : E,
|
|
541
|
+
originLabel: E,
|
|
542
|
+
value: l,
|
|
543
|
+
key: (b = d == null ? void 0 : d.key) !== null && b !== void 0 ? b : l
|
|
544
|
+
} : l, De(d)];
|
|
545
|
+
};
|
|
546
|
+
if (r && e.onSelect) {
|
|
547
|
+
const [b, d] = u();
|
|
548
|
+
e.onSelect(b, d);
|
|
549
|
+
} else if (!r && e.onDeselect) {
|
|
550
|
+
const [b, d] = u();
|
|
551
|
+
e.onDeselect(b, d);
|
|
552
|
+
}
|
|
553
|
+
}, D = (l, r) => {
|
|
554
|
+
let u;
|
|
555
|
+
const b = v.value ? r.selected : !0;
|
|
556
|
+
b ? u = v.value ? [...k.value, l] : [l] : u = k.value.filter((d) => d.value !== l), _(u), h(l, b), e.mode === "combobox" ? L("") : (!v.value || e.autoClearSearchValue) && (y(""), L(""));
|
|
557
|
+
}, z = (l, r) => {
|
|
558
|
+
_(l), (r.type === "remove" || r.type === "clear") && r.values.forEach((u) => {
|
|
559
|
+
h(u.value, !1);
|
|
560
|
+
});
|
|
561
|
+
}, Q = (l, r) => {
|
|
562
|
+
var u;
|
|
563
|
+
if (y(l), L(null), r.source === "submit") {
|
|
564
|
+
const b = (l || "").trim();
|
|
565
|
+
if (b) {
|
|
566
|
+
const d = Array.from(/* @__PURE__ */ new Set([...x.value, b]));
|
|
567
|
+
_(d), h(b, !0), y("");
|
|
568
|
+
}
|
|
569
|
+
return;
|
|
570
|
+
}
|
|
571
|
+
r.source !== "blur" && (e.mode === "combobox" && _(l), (u = e.onSearch) === null || u === void 0 || u.call(e, l));
|
|
572
|
+
}, le = (l) => {
|
|
573
|
+
let r = l;
|
|
574
|
+
e.mode !== "tags" && (r = l.map((b) => {
|
|
575
|
+
const d = c.value.get(b);
|
|
576
|
+
return d == null ? void 0 : d.value;
|
|
577
|
+
}).filter((b) => b !== void 0));
|
|
578
|
+
const u = Array.from(/* @__PURE__ */ new Set([...x.value, ...r]));
|
|
579
|
+
_(u), u.forEach((b) => {
|
|
580
|
+
h(b, !0);
|
|
581
|
+
});
|
|
582
|
+
}, ge = A(() => e.virtual !== !1 && e.dropdownMatchSelectWidth !== !1);
|
|
583
|
+
Yt(zt(T(T({}, V), {
|
|
584
|
+
flattenOptions: te,
|
|
585
|
+
onActiveValue: Se,
|
|
586
|
+
defaultActiveFirstOption: fe,
|
|
587
|
+
onSelect: D,
|
|
588
|
+
menuItemSelectedIcon: oe(e, "menuItemSelectedIcon"),
|
|
589
|
+
rawValues: x,
|
|
590
|
+
fieldNames: f,
|
|
591
|
+
virtual: ge,
|
|
592
|
+
listHeight: oe(e, "listHeight"),
|
|
593
|
+
listItemHeight: oe(e, "listItemHeight"),
|
|
594
|
+
childrenAsData: m
|
|
595
|
+
})));
|
|
596
|
+
const re = Qe();
|
|
597
|
+
i({
|
|
598
|
+
focus() {
|
|
599
|
+
var l;
|
|
600
|
+
(l = re.value) === null || l === void 0 || l.focus();
|
|
601
|
+
},
|
|
602
|
+
blur() {
|
|
603
|
+
var l;
|
|
604
|
+
(l = re.value) === null || l === void 0 || l.blur();
|
|
605
|
+
},
|
|
606
|
+
scrollTo(l) {
|
|
607
|
+
var r;
|
|
608
|
+
(r = re.value) === null || r === void 0 || r.scrollTo(l);
|
|
609
|
+
}
|
|
610
|
+
});
|
|
611
|
+
const Ce = A(() => Te(e, [
|
|
612
|
+
"id",
|
|
613
|
+
"mode",
|
|
614
|
+
"prefixCls",
|
|
615
|
+
"backfill",
|
|
616
|
+
"fieldNames",
|
|
617
|
+
// Search
|
|
618
|
+
"inputValue",
|
|
619
|
+
"searchValue",
|
|
620
|
+
"onSearch",
|
|
621
|
+
"autoClearSearchValue",
|
|
622
|
+
// Select
|
|
623
|
+
"onSelect",
|
|
624
|
+
"onDeselect",
|
|
625
|
+
"dropdownMatchSelectWidth",
|
|
626
|
+
// Options
|
|
627
|
+
"filterOption",
|
|
628
|
+
"filterSort",
|
|
629
|
+
"optionFilterProp",
|
|
630
|
+
"optionLabelProp",
|
|
631
|
+
"options",
|
|
632
|
+
"children",
|
|
633
|
+
"defaultActiveFirstOption",
|
|
634
|
+
"menuItemSelectedIcon",
|
|
635
|
+
"virtual",
|
|
636
|
+
"listHeight",
|
|
637
|
+
"listItemHeight",
|
|
638
|
+
// Value
|
|
639
|
+
"value",
|
|
640
|
+
"defaultValue",
|
|
641
|
+
"labelInValue",
|
|
642
|
+
"onChange"
|
|
643
|
+
]));
|
|
644
|
+
return () => N(Ut, H(H(H({}, Ce.value), n), {}, {
|
|
645
|
+
id: o,
|
|
646
|
+
prefixCls: e.prefixCls,
|
|
647
|
+
ref: re,
|
|
648
|
+
omitDomProps: ol,
|
|
649
|
+
mode: e.mode,
|
|
650
|
+
displayValues: I.value,
|
|
651
|
+
onDisplayValuesChange: z,
|
|
652
|
+
searchValue: a.value,
|
|
653
|
+
onSearch: Q,
|
|
654
|
+
onSearchSplit: le,
|
|
655
|
+
dropdownMatchSelectWidth: e.dropdownMatchSelectWidth,
|
|
656
|
+
OptionList: Jt,
|
|
657
|
+
emptyOptions: !te.value.length,
|
|
658
|
+
activeValue: ye.value,
|
|
659
|
+
activeDescendantId: `${o}_list_${ie.value}`
|
|
660
|
+
}), t);
|
|
661
|
+
}
|
|
662
|
+
}), ke = () => null;
|
|
663
|
+
ke.isSelectOption = !0;
|
|
664
|
+
ke.displayName = "ASelectOption";
|
|
665
|
+
const $e = () => null;
|
|
666
|
+
$e.isSelectOptGroup = !0;
|
|
667
|
+
$e.displayName = "ASelectOptGroup";
|
|
668
|
+
const sl = () => T(T({}, Te(et(), ["inputIcon", "mode", "getInputElement", "getRawInputElement", "backfill"])), {
|
|
669
|
+
value: je([Array, Object, String, Number]),
|
|
670
|
+
defaultValue: je([Array, Object, String, Number]),
|
|
671
|
+
notFoundContent: ae.any,
|
|
672
|
+
suffixIcon: ae.any,
|
|
673
|
+
itemIcon: ae.any,
|
|
674
|
+
size: Ae(),
|
|
675
|
+
mode: Ae(),
|
|
676
|
+
bordered: dt(!0),
|
|
677
|
+
transitionName: String,
|
|
678
|
+
choiceTransitionName: Ae(""),
|
|
679
|
+
popupClassName: String,
|
|
680
|
+
/** @deprecated Please use `popupClassName` instead */
|
|
681
|
+
dropdownClassName: String,
|
|
682
|
+
placement: Ae(),
|
|
683
|
+
status: Ae(),
|
|
684
|
+
"onUpdate:value": ut()
|
|
685
|
+
}), Ke = "SECRET_COMBOBOX_MODE_DO_NOT_USE", ee = be({
|
|
686
|
+
compatConfig: {
|
|
687
|
+
MODE: 3
|
|
688
|
+
},
|
|
689
|
+
name: "ASelect",
|
|
690
|
+
Option: ke,
|
|
691
|
+
OptGroup: $e,
|
|
692
|
+
inheritAttrs: !1,
|
|
693
|
+
props: Xe(sl(), {
|
|
694
|
+
listHeight: 256,
|
|
695
|
+
listItemHeight: 24
|
|
696
|
+
}),
|
|
697
|
+
SECRET_COMBOBOX_MODE_DO_NOT_USE: Ke,
|
|
698
|
+
slots: Object,
|
|
699
|
+
setup(e, g) {
|
|
700
|
+
let {
|
|
701
|
+
attrs: i,
|
|
702
|
+
emit: n,
|
|
703
|
+
slots: t,
|
|
704
|
+
expose: o
|
|
705
|
+
} = g;
|
|
706
|
+
const v = Qe(), m = Et(), p = Ft.useInject(), f = A(() => Dt(p.status, e.status)), a = () => {
|
|
707
|
+
var h;
|
|
708
|
+
(h = v.value) === null || h === void 0 || h.focus();
|
|
709
|
+
}, y = () => {
|
|
710
|
+
var h;
|
|
711
|
+
(h = v.value) === null || h === void 0 || h.blur();
|
|
712
|
+
}, V = (h) => {
|
|
713
|
+
var D;
|
|
714
|
+
(D = v.value) === null || D === void 0 || D.scrollTo(h);
|
|
715
|
+
}, w = A(() => {
|
|
716
|
+
const {
|
|
717
|
+
mode: h
|
|
718
|
+
} = e;
|
|
719
|
+
if (h !== "combobox")
|
|
720
|
+
return h === Ke ? "combobox" : h;
|
|
721
|
+
}), {
|
|
722
|
+
prefixCls: c,
|
|
723
|
+
direction: C,
|
|
724
|
+
renderEmpty: O,
|
|
725
|
+
size: F,
|
|
726
|
+
getPrefixCls: Y,
|
|
727
|
+
getPopupContainer: G,
|
|
728
|
+
disabled: k,
|
|
729
|
+
select: s
|
|
730
|
+
} = Be("select", e), {
|
|
731
|
+
compactSize: I,
|
|
732
|
+
compactItemClassnames: x
|
|
733
|
+
} = at(c, C), S = A(() => I.value || F.value), P = it(), j = A(() => {
|
|
734
|
+
var h;
|
|
735
|
+
return (h = k.value) !== null && h !== void 0 ? h : P.value;
|
|
736
|
+
}), [$, me] = Gt(c), te = A(() => Y()), _ = A(() => e.placement !== void 0 ? e.placement : C.value === "rtl" ? "bottomRight" : "bottomLeft"), ye = A(() => st(te.value, rt(_.value), e.transitionName)), L = A(() => he({
|
|
737
|
+
[`${c.value}-lg`]: S.value === "large",
|
|
738
|
+
[`${c.value}-sm`]: S.value === "small",
|
|
739
|
+
[`${c.value}-rtl`]: C.value === "rtl",
|
|
740
|
+
[`${c.value}-borderless`]: !e.bordered,
|
|
741
|
+
[`${c.value}-in-form-item`]: p.isFormItemInput
|
|
742
|
+
}, Rt(c.value, f.value, p.hasFeedback), x.value, me.value)), ie = function() {
|
|
743
|
+
for (var h = arguments.length, D = new Array(h), z = 0; z < h; z++)
|
|
744
|
+
D[z] = arguments[z];
|
|
745
|
+
n("update:value", D[0]), n("change", ...D), m.onFieldChange();
|
|
746
|
+
}, se = (h) => {
|
|
747
|
+
n("blur", h), m.onFieldBlur();
|
|
748
|
+
};
|
|
749
|
+
o({
|
|
750
|
+
blur: y,
|
|
751
|
+
focus: a,
|
|
752
|
+
scrollTo: V
|
|
753
|
+
});
|
|
754
|
+
const fe = A(() => w.value === "multiple" || w.value === "tags"), Se = A(() => e.showArrow !== void 0 ? e.showArrow : e.loading || !(fe.value || w.value === "combobox"));
|
|
755
|
+
return () => {
|
|
756
|
+
var h, D, z, Q;
|
|
757
|
+
const {
|
|
758
|
+
notFoundContent: le,
|
|
759
|
+
listHeight: ge = 256,
|
|
760
|
+
listItemHeight: re = 24,
|
|
761
|
+
popupClassName: Ce,
|
|
762
|
+
dropdownClassName: l,
|
|
763
|
+
virtual: r,
|
|
764
|
+
dropdownMatchSelectWidth: u,
|
|
765
|
+
id: b = m.id.value,
|
|
766
|
+
placeholder: d = (h = t.placeholder) === null || h === void 0 ? void 0 : h.call(t),
|
|
767
|
+
showArrow: E
|
|
768
|
+
} = e, {
|
|
769
|
+
hasFeedback: ne,
|
|
770
|
+
feedbackIcon: W
|
|
771
|
+
} = p;
|
|
772
|
+
let q;
|
|
773
|
+
le !== void 0 ? q = le : t.notFoundContent ? q = t.notFoundContent() : w.value === "combobox" ? q = null : q = (O == null ? void 0 : O("Select")) || N(ct, {
|
|
774
|
+
componentName: "Select"
|
|
775
|
+
}, null);
|
|
776
|
+
const {
|
|
777
|
+
suffixIcon: R,
|
|
778
|
+
itemIcon: Ie,
|
|
779
|
+
removeIcon: ce,
|
|
780
|
+
clearIcon: lt
|
|
781
|
+
} = Wt(T(T({}, e), {
|
|
782
|
+
multiple: fe.value,
|
|
783
|
+
prefixCls: c.value,
|
|
784
|
+
hasFeedback: ne,
|
|
785
|
+
feedbackIcon: W,
|
|
786
|
+
showArrow: Se.value
|
|
787
|
+
}), t), Le = Te(e, ["prefixCls", "suffixIcon", "itemIcon", "removeIcon", "clearIcon", "size", "bordered", "status"]), nt = he(Ce || l, {
|
|
788
|
+
[`${c.value}-dropdown-${C.value}`]: C.value === "rtl"
|
|
789
|
+
}, me.value);
|
|
790
|
+
return $(N(il, H(H(H({
|
|
791
|
+
ref: v,
|
|
792
|
+
virtual: r,
|
|
793
|
+
dropdownMatchSelectWidth: u
|
|
794
|
+
}, Le), i), {}, {
|
|
795
|
+
showSearch: (D = e.showSearch) !== null && D !== void 0 ? D : (z = s == null ? void 0 : s.value) === null || z === void 0 ? void 0 : z.showSearch,
|
|
796
|
+
placeholder: d,
|
|
797
|
+
listHeight: ge,
|
|
798
|
+
listItemHeight: re,
|
|
799
|
+
mode: w.value,
|
|
800
|
+
prefixCls: c.value,
|
|
801
|
+
direction: C.value,
|
|
802
|
+
inputIcon: R,
|
|
803
|
+
menuItemSelectedIcon: Ie,
|
|
804
|
+
removeIcon: ce,
|
|
805
|
+
clearIcon: lt,
|
|
806
|
+
notFoundContent: q,
|
|
807
|
+
class: [L.value, i.class],
|
|
808
|
+
getPopupContainer: G == null ? void 0 : G.value,
|
|
809
|
+
dropdownClassName: nt,
|
|
810
|
+
onChange: ie,
|
|
811
|
+
onBlur: se,
|
|
812
|
+
id: b,
|
|
813
|
+
dropdownRender: Le.dropdownRender || t.dropdownRender,
|
|
814
|
+
transitionName: ye.value,
|
|
815
|
+
children: (Q = t.default) === null || Q === void 0 ? void 0 : Q.call(t),
|
|
816
|
+
tagRender: e.tagRender || t.tagRender,
|
|
817
|
+
optionLabelRender: t.optionLabel,
|
|
818
|
+
maxTagPlaceholder: e.maxTagPlaceholder || t.maxTagPlaceholder,
|
|
819
|
+
showArrow: ne || E,
|
|
820
|
+
disabled: j.value
|
|
821
|
+
}), {
|
|
822
|
+
option: t.option
|
|
823
|
+
}));
|
|
824
|
+
};
|
|
825
|
+
}
|
|
826
|
+
});
|
|
827
|
+
ee.install = function(e) {
|
|
828
|
+
return e.component(ee.name, ee), e.component(ee.Option.displayName, ee.Option), e.component(ee.OptGroup.displayName, ee.OptGroup), e;
|
|
829
|
+
};
|
|
830
|
+
ee.Option;
|
|
831
|
+
ee.OptGroup;
|
|
832
|
+
const xe = (e, g, i) => {
|
|
833
|
+
const n = pt(i);
|
|
834
|
+
return {
|
|
835
|
+
[`${e.componentCls}-${g}`]: {
|
|
836
|
+
color: e[`color${i}`],
|
|
837
|
+
background: e[`color${n}Bg`],
|
|
838
|
+
borderColor: e[`color${n}Border`],
|
|
839
|
+
[`&${e.componentCls}-borderless`]: {
|
|
840
|
+
borderColor: "transparent"
|
|
841
|
+
}
|
|
842
|
+
}
|
|
843
|
+
};
|
|
844
|
+
}, rl = (e) => ft(e, (g, i) => {
|
|
845
|
+
let {
|
|
846
|
+
textColor: n,
|
|
847
|
+
lightBorderColor: t,
|
|
848
|
+
lightColor: o,
|
|
849
|
+
darkColor: v
|
|
850
|
+
} = i;
|
|
851
|
+
return {
|
|
852
|
+
[`${e.componentCls}-${g}`]: {
|
|
853
|
+
color: n,
|
|
854
|
+
background: o,
|
|
855
|
+
borderColor: t,
|
|
856
|
+
// Inverse color
|
|
857
|
+
"&-inverse": {
|
|
858
|
+
color: e.colorTextLightSolid,
|
|
859
|
+
background: v,
|
|
860
|
+
borderColor: v
|
|
861
|
+
},
|
|
862
|
+
[`&${e.componentCls}-borderless`]: {
|
|
863
|
+
borderColor: "transparent"
|
|
864
|
+
}
|
|
865
|
+
}
|
|
866
|
+
};
|
|
867
|
+
}), cl = (e) => {
|
|
868
|
+
const {
|
|
869
|
+
paddingXXS: g,
|
|
870
|
+
lineWidth: i,
|
|
871
|
+
tagPaddingHorizontal: n,
|
|
872
|
+
componentCls: t
|
|
873
|
+
} = e, o = n - i, v = g - i;
|
|
874
|
+
return {
|
|
875
|
+
// Result
|
|
876
|
+
[t]: T(T({}, gt(e)), {
|
|
877
|
+
display: "inline-block",
|
|
878
|
+
height: "auto",
|
|
879
|
+
marginInlineEnd: e.marginXS,
|
|
880
|
+
paddingInline: o,
|
|
881
|
+
fontSize: e.tagFontSize,
|
|
882
|
+
lineHeight: `${e.tagLineHeight}px`,
|
|
883
|
+
whiteSpace: "nowrap",
|
|
884
|
+
background: e.tagDefaultBg,
|
|
885
|
+
border: `${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,
|
|
886
|
+
borderRadius: e.borderRadiusSM,
|
|
887
|
+
opacity: 1,
|
|
888
|
+
transition: `all ${e.motionDurationMid}`,
|
|
889
|
+
textAlign: "start",
|
|
890
|
+
// RTL
|
|
891
|
+
[`&${t}-rtl`]: {
|
|
892
|
+
direction: "rtl"
|
|
893
|
+
},
|
|
894
|
+
"&, a, a:hover": {
|
|
895
|
+
color: e.tagDefaultColor
|
|
896
|
+
},
|
|
897
|
+
[`${t}-close-icon`]: {
|
|
898
|
+
marginInlineStart: v,
|
|
899
|
+
color: e.colorTextDescription,
|
|
900
|
+
fontSize: e.tagIconSize,
|
|
901
|
+
cursor: "pointer",
|
|
902
|
+
transition: `all ${e.motionDurationMid}`,
|
|
903
|
+
"&:hover": {
|
|
904
|
+
color: e.colorTextHeading
|
|
905
|
+
}
|
|
906
|
+
},
|
|
907
|
+
[`&${t}-has-color`]: {
|
|
908
|
+
borderColor: "transparent",
|
|
909
|
+
[`&, a, a:hover, ${e.iconCls}-close, ${e.iconCls}-close:hover`]: {
|
|
910
|
+
color: e.colorTextLightSolid
|
|
911
|
+
}
|
|
912
|
+
},
|
|
913
|
+
"&-checkable": {
|
|
914
|
+
backgroundColor: "transparent",
|
|
915
|
+
borderColor: "transparent",
|
|
916
|
+
cursor: "pointer",
|
|
917
|
+
[`&:not(${t}-checkable-checked):hover`]: {
|
|
918
|
+
color: e.colorPrimary,
|
|
919
|
+
backgroundColor: e.colorFillSecondary
|
|
920
|
+
},
|
|
921
|
+
"&:active, &-checked": {
|
|
922
|
+
color: e.colorTextLightSolid
|
|
923
|
+
},
|
|
924
|
+
"&-checked": {
|
|
925
|
+
backgroundColor: e.colorPrimary,
|
|
926
|
+
"&:hover": {
|
|
927
|
+
backgroundColor: e.colorPrimaryHover
|
|
928
|
+
}
|
|
929
|
+
},
|
|
930
|
+
"&:active": {
|
|
931
|
+
backgroundColor: e.colorPrimaryActive
|
|
932
|
+
}
|
|
933
|
+
},
|
|
934
|
+
"&-hidden": {
|
|
935
|
+
display: "none"
|
|
936
|
+
},
|
|
937
|
+
// To ensure that a space will be placed between character and `Icon`.
|
|
938
|
+
[`> ${e.iconCls} + span, > span + ${e.iconCls}`]: {
|
|
939
|
+
marginInlineStart: o
|
|
940
|
+
}
|
|
941
|
+
}),
|
|
942
|
+
[`${t}-borderless`]: {
|
|
943
|
+
borderColor: "transparent",
|
|
944
|
+
background: e.tagBorderlessBg
|
|
945
|
+
}
|
|
946
|
+
};
|
|
947
|
+
}, tt = vt("Tag", (e) => {
|
|
948
|
+
const {
|
|
949
|
+
fontSize: g,
|
|
950
|
+
lineHeight: i,
|
|
951
|
+
lineWidth: n,
|
|
952
|
+
fontSizeIcon: t
|
|
953
|
+
} = e, o = Math.round(g * i), v = e.fontSizeSM, m = o - n * 2, p = e.colorFillAlter, f = e.colorText, a = mt(e, {
|
|
954
|
+
tagFontSize: v,
|
|
955
|
+
tagLineHeight: m,
|
|
956
|
+
tagDefaultBg: p,
|
|
957
|
+
tagDefaultColor: f,
|
|
958
|
+
tagIconSize: t - 2 * n,
|
|
959
|
+
tagPaddingHorizontal: 8,
|
|
960
|
+
tagBorderlessBg: e.colorFillTertiary
|
|
961
|
+
});
|
|
962
|
+
return [cl(a), rl(a), xe(a, "success", "Success"), xe(a, "processing", "Info"), xe(a, "error", "Error"), xe(a, "warning", "Warning")];
|
|
963
|
+
}), ul = () => ({
|
|
964
|
+
prefixCls: String,
|
|
965
|
+
checked: {
|
|
966
|
+
type: Boolean,
|
|
967
|
+
default: void 0
|
|
968
|
+
},
|
|
969
|
+
onChange: {
|
|
970
|
+
type: Function
|
|
971
|
+
},
|
|
972
|
+
onClick: {
|
|
973
|
+
type: Function
|
|
974
|
+
},
|
|
975
|
+
"onUpdate:checked": Function
|
|
976
|
+
}), Re = be({
|
|
977
|
+
compatConfig: {
|
|
978
|
+
MODE: 3
|
|
979
|
+
},
|
|
980
|
+
name: "ACheckableTag",
|
|
981
|
+
inheritAttrs: !1,
|
|
982
|
+
props: ul(),
|
|
983
|
+
// emits: ['update:checked', 'change', 'click'],
|
|
984
|
+
setup(e, g) {
|
|
985
|
+
let {
|
|
986
|
+
slots: i,
|
|
987
|
+
emit: n,
|
|
988
|
+
attrs: t
|
|
989
|
+
} = g;
|
|
990
|
+
const {
|
|
991
|
+
prefixCls: o
|
|
992
|
+
} = Be("tag", e), [v, m] = tt(o), p = (a) => {
|
|
993
|
+
const {
|
|
994
|
+
checked: y
|
|
995
|
+
} = e;
|
|
996
|
+
n("update:checked", !y), n("change", !y), n("click", a);
|
|
997
|
+
}, f = A(() => he(o.value, m.value, {
|
|
998
|
+
[`${o.value}-checkable`]: !0,
|
|
999
|
+
[`${o.value}-checkable-checked`]: e.checked
|
|
1000
|
+
}));
|
|
1001
|
+
return () => {
|
|
1002
|
+
var a;
|
|
1003
|
+
return v(N("span", H(H({}, t), {}, {
|
|
1004
|
+
class: [f.value, t.class],
|
|
1005
|
+
onClick: p
|
|
1006
|
+
}), [(a = i.default) === null || a === void 0 ? void 0 : a.call(i)]));
|
|
1007
|
+
};
|
|
1008
|
+
}
|
|
1009
|
+
}), dl = () => ({
|
|
1010
|
+
prefixCls: String,
|
|
1011
|
+
color: {
|
|
1012
|
+
type: String
|
|
1013
|
+
},
|
|
1014
|
+
closable: {
|
|
1015
|
+
type: Boolean,
|
|
1016
|
+
default: !1
|
|
1017
|
+
},
|
|
1018
|
+
closeIcon: ae.any,
|
|
1019
|
+
/** @deprecated `visible` will be removed in next major version. */
|
|
1020
|
+
visible: {
|
|
1021
|
+
type: Boolean,
|
|
1022
|
+
default: void 0
|
|
1023
|
+
},
|
|
1024
|
+
onClose: {
|
|
1025
|
+
type: Function
|
|
1026
|
+
},
|
|
1027
|
+
onClick: ht(),
|
|
1028
|
+
"onUpdate:visible": Function,
|
|
1029
|
+
icon: ae.any,
|
|
1030
|
+
bordered: {
|
|
1031
|
+
type: Boolean,
|
|
1032
|
+
default: !0
|
|
1033
|
+
}
|
|
1034
|
+
}), pe = be({
|
|
1035
|
+
compatConfig: {
|
|
1036
|
+
MODE: 3
|
|
1037
|
+
},
|
|
1038
|
+
name: "ATag",
|
|
1039
|
+
inheritAttrs: !1,
|
|
1040
|
+
props: dl(),
|
|
1041
|
+
// emits: ['update:visible', 'close'],
|
|
1042
|
+
slots: Object,
|
|
1043
|
+
setup(e, g) {
|
|
1044
|
+
let {
|
|
1045
|
+
slots: i,
|
|
1046
|
+
emit: n,
|
|
1047
|
+
attrs: t
|
|
1048
|
+
} = g;
|
|
1049
|
+
const {
|
|
1050
|
+
prefixCls: o,
|
|
1051
|
+
direction: v
|
|
1052
|
+
} = Be("tag", e), [m, p] = tt(o), f = ve(!0);
|
|
1053
|
+
Ne(() => {
|
|
1054
|
+
e.visible !== void 0 && (f.value = e.visible);
|
|
1055
|
+
});
|
|
1056
|
+
const a = (c) => {
|
|
1057
|
+
c.stopPropagation(), n("update:visible", !1), n("close", c), !c.defaultPrevented && e.visible === void 0 && (f.value = !1);
|
|
1058
|
+
}, y = A(() => bt(e.color) || yt(e.color)), V = A(() => he(o.value, p.value, {
|
|
1059
|
+
[`${o.value}-${e.color}`]: y.value,
|
|
1060
|
+
[`${o.value}-has-color`]: e.color && !y.value,
|
|
1061
|
+
[`${o.value}-hidden`]: !f.value,
|
|
1062
|
+
[`${o.value}-rtl`]: v.value === "rtl",
|
|
1063
|
+
[`${o.value}-borderless`]: !e.bordered
|
|
1064
|
+
})), w = (c) => {
|
|
1065
|
+
n("click", c);
|
|
1066
|
+
};
|
|
1067
|
+
return () => {
|
|
1068
|
+
var c, C, O;
|
|
1069
|
+
const {
|
|
1070
|
+
icon: F = (c = i.icon) === null || c === void 0 ? void 0 : c.call(i),
|
|
1071
|
+
color: Y,
|
|
1072
|
+
closeIcon: G = (C = i.closeIcon) === null || C === void 0 ? void 0 : C.call(i),
|
|
1073
|
+
closable: k = !1
|
|
1074
|
+
} = e, s = () => k ? G ? N("span", {
|
|
1075
|
+
class: `${o.value}-close-icon`,
|
|
1076
|
+
onClick: a
|
|
1077
|
+
}, [G]) : N(Ct, {
|
|
1078
|
+
class: `${o.value}-close-icon`,
|
|
1079
|
+
onClick: a
|
|
1080
|
+
}, null) : null, I = {
|
|
1081
|
+
backgroundColor: Y && !y.value ? Y : void 0
|
|
1082
|
+
}, x = F || null, S = (O = i.default) === null || O === void 0 ? void 0 : O.call(i), P = x ? N(Ve, null, [x, N("span", null, [S])]) : S, j = e.onClick !== void 0, $ = N("span", H(H({}, t), {}, {
|
|
1083
|
+
onClick: w,
|
|
1084
|
+
class: [V.value, t.class],
|
|
1085
|
+
style: [I, t.style]
|
|
1086
|
+
}), [P, s()]);
|
|
1087
|
+
return m(j ? N(St, null, {
|
|
1088
|
+
default: () => [$]
|
|
1089
|
+
}) : $);
|
|
1090
|
+
};
|
|
1091
|
+
}
|
|
1092
|
+
});
|
|
1093
|
+
pe.CheckableTag = Re;
|
|
1094
|
+
pe.install = function(e) {
|
|
1095
|
+
return e.component(pe.name, pe), e.component(Re.name, Re), e;
|
|
1096
|
+
};
|
|
1097
|
+
const vl = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAGXSURBVHgBlVNLTgJBEK1qOrjtI4w34AhwAuQEZBJc4yyVBbCRxE2HrZoQT4CcAI7AEeYIbDUM5asGZYj0KJX0J1WvX9eXqUIm/qUpbNp6ZzHT+yzNY1iOGR796w2sc1w3B5Ujoc5D1ns/hzcxImb2OPJPqV3rwn0NYh/DR4mEJBGhxShLN7pEZAF1EsPbmAExr7C1kad9KGy6oF/RpR6R1FIGkzAvw4KPqqv4OC4jP3N1LpZ6R55aGiJd7JES4SF+CquK5JdHWnKE48o6YenjcCw8PtGTbMqtwGWSQ9/8X0p9ZY+M7DShLNKCOq9m2Cb7Ahy9P1N+m1eNgsrEz7AXJ7qQ7Cf/3IBLw71rxQzApIIkUUyAsgzDWyXSEhdcm2tY6N4xuqXxDTwrsCkGXT/VPtuyWSqHuaJtQ8cBuUkH2e0IgDcAmzEeteHD6SDr3eHMoHLKYT/IruuIF0PaR+UczjaIc4rLGpguRmfFTN1dUNncHAZyDEUoP0iclV0nxgLbz+joG32rxeGTJKKs6uFfXaw50XDK2C8hpcmbpfjHLAAAAABJRU5ErkJggg==", ml = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAGxSURBVHgB1VQ9TsNQDLYTKtYeIUeAjQXRboztESLoTDIGhqZLA1OSua3CEdqRidygPULYGDsipMTYLy9Sq/yIbuDqqe99tr989nMC8NcNu5xBmFiAeUIAF3zsGwBrItP1XDs7mVDICPOtEHFQKhgTD/hvj2RetpEabYRMFioyoqHn3Ksle8FEdVteKyHbSJR57iStANkLpltwMuG+w9c/mZCV7KRnQbgYVJjsBePSN215Z20OINPmXm0J8T2IlqmC9KVwmtOWZjaBfpj0TcivCOgDEYXE0guI6EWor2/Hn+nb5gvqlR3bc7x8KAh86OiTtozZ40d3Eh2CRz0M4tWUySJVFpGrllIFsR4ZsR0S2ihaEMN5uHAaCdUgE/ny5G8eXHkygrEvg2hdjgxmcvbcu1cgY6jOiFNpUYPCYlCqwZnv2oqIoFCBfDHJPFqF3FOrilZvCsFMWtODYlQjLKBQwT3IdxUmKlm1JLGPnLJcc3xQYKqzrQaFpeXQOxroJ3fis5KxEHMrhl0fBrH6HPJ7ynNXh/l3DvnNoY8g77cSGmBkIKOg5+03pmcuI31Z/8N+AJZHvSBz6IiBAAAAAElFTkSuQmCC", fl = { class: "crane-flex-center permission-item-wraper" }, gl = { style: { "flex-shrink": "0" } }, pl = { style: { "max-width": "400px" } }, hl = { class: "crane-text-overflow" }, bl = { style: { "max-width": "400px" } }, yl = { class: "crane-department-wraper" }, Sl = { class: "crane-flex-center crane-margin-left-4" }, Cl = ["src"], Al = { class: "crane-weak-color crane-margin-left-4" }, Ol = ["src"], Il = { style: { "max-width": "400px" } }, wl = { class: "crane-weak-color crane-margin-left-4 crane-text-overflow" }, xl = {
|
|
1098
|
+
key: 6,
|
|
1099
|
+
class: "crane-weak-color crane-margin-left-12"
|
|
1100
|
+
}, Ge = "OWNER", Vl = /* @__PURE__ */ be({
|
|
1101
|
+
__name: "permission-item",
|
|
1102
|
+
props: {
|
|
1103
|
+
checkedKeys: {
|
|
1104
|
+
type: Array,
|
|
1105
|
+
default: () => []
|
|
1106
|
+
},
|
|
1107
|
+
validTimeOptions: {
|
|
1108
|
+
type: Array,
|
|
1109
|
+
default: () => []
|
|
1110
|
+
},
|
|
1111
|
+
item: {
|
|
1112
|
+
type: Object,
|
|
1113
|
+
default: () => {
|
|
1114
|
+
}
|
|
1115
|
+
}
|
|
1116
|
+
},
|
|
1117
|
+
emits: ["onChangeTime", "updateTime"],
|
|
1118
|
+
setup(e, { emit: g }) {
|
|
1119
|
+
const i = {
|
|
1120
|
+
L1: {
|
|
1121
|
+
color: "#1AA83B",
|
|
1122
|
+
text: X("levels.L1"),
|
|
1123
|
+
background: "#E3F9E9"
|
|
1124
|
+
},
|
|
1125
|
+
L2: {
|
|
1126
|
+
color: "#F37D1C",
|
|
1127
|
+
text: X("levels.L2"),
|
|
1128
|
+
background: "#FFE4BA"
|
|
1129
|
+
},
|
|
1130
|
+
L3: {
|
|
1131
|
+
color: "#F2494B",
|
|
1132
|
+
text: X("levels.L3"),
|
|
1133
|
+
background: "#FDCDC5"
|
|
1134
|
+
}
|
|
1135
|
+
};
|
|
1136
|
+
let n = g, t = e;
|
|
1137
|
+
const o = X("status"), v = A(() => t.validTimeOptions.filter((f) => f.value !== "FOREVER")), m = (f) => {
|
|
1138
|
+
var a, y;
|
|
1139
|
+
return `【${f.categoryName}】:${((y = (a = f.attributeValues) == null ? void 0 : a.map((V) => V.attributeName)) == null ? void 0 : y.join("、")) || X("empty")}`;
|
|
1140
|
+
}, p = () => {
|
|
1141
|
+
n("updateTime", t.item), n("onChangeTime", t.item);
|
|
1142
|
+
};
|
|
1143
|
+
return (f, a) => {
|
|
1144
|
+
var y, V, w;
|
|
1145
|
+
return U(), ue("div", fl, [
|
|
1146
|
+
e.item.securityLevel ? (U(), Oe(B(pe), {
|
|
1147
|
+
key: 0,
|
|
1148
|
+
bordered: !1,
|
|
1149
|
+
style: xt({ color: i[e.item.securityLevel].color, background: i[e.item.securityLevel].background }),
|
|
1150
|
+
class: "crane-tag-position"
|
|
1151
|
+
}, {
|
|
1152
|
+
default: J(() => [
|
|
1153
|
+
Pe(M(i[e.item.securityLevel].text), 1)
|
|
1154
|
+
]),
|
|
1155
|
+
_: 1
|
|
1156
|
+
}, 8, ["style"])) : de("", !0),
|
|
1157
|
+
K("div", gl, M(B(X)(`operationType.${e.item.operationType}`)) + "| ", 1),
|
|
1158
|
+
N(B(we), null, {
|
|
1159
|
+
content: J(() => [
|
|
1160
|
+
K("div", pl, M(e.item.name), 1)
|
|
1161
|
+
]),
|
|
1162
|
+
default: J(() => [
|
|
1163
|
+
K("div", hl, M(e.item.shortName), 1)
|
|
1164
|
+
]),
|
|
1165
|
+
_: 1
|
|
1166
|
+
}),
|
|
1167
|
+
e.item.businessApplyType ? (U(), Oe(B(pe), {
|
|
1168
|
+
key: 1,
|
|
1169
|
+
bordered: !1,
|
|
1170
|
+
class: Vt(["crane-tag-position crane-margin-left-4 crane-margin-right-0", ["PENDING"].includes(e.item.businessApplyType) ? "" : "crane-disabled-color"])
|
|
1171
|
+
}, {
|
|
1172
|
+
default: J(() => {
|
|
1173
|
+
var c, C, O, F;
|
|
1174
|
+
return [
|
|
1175
|
+
Pe(M(B(o)[e.item.businessApplyType]) + " " + M(e.item.businessApplyType === "TEMP_OWNER" ? `(${((C = (c = e.item) == null ? void 0 : c.ownStatusVO) == null ? void 0 : C.dayDiff) > 0 ? B(X)("lastDays", {
|
|
1176
|
+
count: (F = (O = e.item) == null ? void 0 : O.ownStatusVO) == null ? void 0 : F.dayDiff
|
|
1177
|
+
}) : B(X)("today")})` : ""), 1)
|
|
1178
|
+
];
|
|
1179
|
+
}),
|
|
1180
|
+
_: 1
|
|
1181
|
+
}, 8, ["class"])) : de("", !0),
|
|
1182
|
+
e.item.desc ? (U(), Oe(B(we), { key: 2 }, {
|
|
1183
|
+
content: J(() => [
|
|
1184
|
+
K("div", bl, M(e.item.desc), 1)
|
|
1185
|
+
]),
|
|
1186
|
+
default: J(() => [
|
|
1187
|
+
N(B(Bt), { class: "crane-weak-color crane-margin-left-4" })
|
|
1188
|
+
]),
|
|
1189
|
+
_: 1
|
|
1190
|
+
})) : de("", !0),
|
|
1191
|
+
(y = e.item.relatedCompleteNames) != null && y.length ? (U(), Oe(B(we), { key: 3 }, {
|
|
1192
|
+
content: J(() => [
|
|
1193
|
+
K("div", yl, [
|
|
1194
|
+
K("div", null, M(B(X)("adaptDepartment")) + ": ", 1),
|
|
1195
|
+
(U(!0), ue(Ve, null, ze(e.item.relatedCompleteNames, (c) => (U(), ue("div", null, M(c), 1))), 256))
|
|
1196
|
+
])
|
|
1197
|
+
]),
|
|
1198
|
+
default: J(() => [
|
|
1199
|
+
K("div", Sl, [
|
|
1200
|
+
K("img", {
|
|
1201
|
+
src: B(vl),
|
|
1202
|
+
height: "14",
|
|
1203
|
+
width: "14"
|
|
1204
|
+
}, null, 8, Cl),
|
|
1205
|
+
K("span", Al, M(e.item.relatedCompleteNames.length), 1)
|
|
1206
|
+
])
|
|
1207
|
+
]),
|
|
1208
|
+
_: 1
|
|
1209
|
+
})) : de("", !0),
|
|
1210
|
+
(V = e.item.categoryVOS) != null && V.length ? (U(), ue("img", {
|
|
1211
|
+
key: 4,
|
|
1212
|
+
src: B(ml),
|
|
1213
|
+
height: "16",
|
|
1214
|
+
width: "16",
|
|
1215
|
+
class: "crane-margin-left-4"
|
|
1216
|
+
}, null, 8, Ol)) : de("", !0),
|
|
1217
|
+
(w = e.item.categoryVOS) != null && w.length ? (U(), Oe(B(we), { key: 5 }, {
|
|
1218
|
+
content: J(() => [
|
|
1219
|
+
K("div", Il, [
|
|
1220
|
+
K("div", null, M(B(X)("categoryTips")), 1),
|
|
1221
|
+
(U(!0), ue(Ve, null, ze(e.item.categoryVOS, (c) => (U(), ue("div", {
|
|
1222
|
+
key: c.id
|
|
1223
|
+
}, M(m(c)), 1))), 128))
|
|
1224
|
+
])
|
|
1225
|
+
]),
|
|
1226
|
+
default: J(() => {
|
|
1227
|
+
var c;
|
|
1228
|
+
return [
|
|
1229
|
+
K("div", wl, M((c = e.item.categoryVOS) == null ? void 0 : c.map((C) => C.categoryName).join("、")), 1)
|
|
1230
|
+
];
|
|
1231
|
+
}),
|
|
1232
|
+
_: 1
|
|
1233
|
+
})) : de("", !0),
|
|
1234
|
+
e.checkedKeys.includes(e.item.feature) && !e.item.disabled ? (U(), ue("span", xl, [
|
|
1235
|
+
Pe(M(B(X)("availableTime")) + ": ", 1),
|
|
1236
|
+
N(B(ee), {
|
|
1237
|
+
value: e.item.validTime,
|
|
1238
|
+
"onUpdate:value": a[0] || (a[0] = (c) => e.item.validTime = c),
|
|
1239
|
+
style: { width: "100px" },
|
|
1240
|
+
disabled: e.item.businessApplyType === Ge,
|
|
1241
|
+
options: e.item.businessApplyType === Ge ? e.validTimeOptions : v.value,
|
|
1242
|
+
onChange: p,
|
|
1243
|
+
size: "small"
|
|
1244
|
+
}, null, 8, ["value", "disabled", "options"])
|
|
1245
|
+
])) : de("", !0)
|
|
1246
|
+
]);
|
|
1247
|
+
};
|
|
1248
|
+
}
|
|
1249
|
+
}), Fl = /* @__PURE__ */ At(Vl, [["__scopeId", "data-v-7299ba1e"]]);
|
|
1250
|
+
export {
|
|
1251
|
+
Fl as default
|
|
1252
|
+
};
|