auto-vue-basic 0.0.11 → 0.0.13
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/auto-vue-basic.es.js +1295 -310
- package/dist/auto-vue-basic.umd.js +1 -1
- package/dist/index.css +1 -0
- package/dist/types/api/admin.d.ts +3 -0
- package/dist/types/api/language.d.ts +3 -0
- package/dist/types/api/menu.d.ts +6 -0
- package/dist/types/api/role.d.ts +3 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/types/admin.d.ts +17 -0
- package/dist/types/types/index.d.ts +4 -0
- package/dist/types/types/language.d.ts +10 -0
- package/dist/types/types/role.d.ts +12 -0
- package/dist/types/views/index.d.ts +2 -26
- package/dist/types/views/{menus → menu}/index.vue.d.ts +1 -1
- package/dist/types/views/role/components/info.vue.d.ts +53 -0
- package/dist/types/views/role/components/rulesCheck.vue.d.ts +32 -0
- package/dist/types/views/role/index.vue.d.ts +67 -0
- package/dist/version.js +1 -1
- package/package.json +2 -2
- /package/dist/types/views/{menus → menu}/components/info.vue.d.ts +0 -0
- /package/dist/types/views/{menus → menu}/components/menuSelect.vue.d.ts +0 -0
@@ -1,6 +1,597 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import { createAutoApi as
|
3
|
-
const te = /* @__PURE__ */
|
1
|
+
import { defineComponent as z, reactive as N, computed as ce, ref as oe, resolveComponent as d, createBlock as L, openBlock as C, unref as e, isRef as j, withCtx as t, createVNode as l, createTextVNode as I, createElementBlock as D, Fragment as K, renderList as B, toDisplayString as ee, withKeys as P, toRef as ue, createElementVNode as le, normalizeClass as fe, onMounted as be, watch as _e, nextTick as ge, createCommentVNode as he } from "vue";
|
2
|
+
import { createAutoApi as te, Translate as a, RulesUtils as Ve, useForm as F, FormDialog as Y, ModifyButton as W, useTablePage as G, ProTable as H, DEFAULT_PAGE_KEY as J, RefreshButton as $, OpenButton as Q, SearchButton as X, ResetButton as Z, DEFAULT_STATUS_KEY as de, AutoApiUtils as ye, useLoading as se, useSelect as pe } from "auto-vue-manual";
|
3
|
+
const ie = te("admin", {}, "key"), ne = te("role", {}, "key"), ke = /* @__PURE__ */ z({
|
4
|
+
__name: "info",
|
5
|
+
emits: ["refresh"],
|
6
|
+
setup(S, { expose: x, emit: v }) {
|
7
|
+
const M = v, o = N({
|
8
|
+
key: "",
|
9
|
+
avatar: "",
|
10
|
+
username: "",
|
11
|
+
password: "",
|
12
|
+
salt: "",
|
13
|
+
phone: "",
|
14
|
+
email: "",
|
15
|
+
language: "zh-CN",
|
16
|
+
remark: "",
|
17
|
+
roles: []
|
18
|
+
}), s = ce(() => !o.key), b = {
|
19
|
+
username: [
|
20
|
+
{ required: !0, message: a("base.placeholder.input base.username"), trigger: "blur" }
|
21
|
+
],
|
22
|
+
phone: [
|
23
|
+
{ required: !0, validator: Ve.phoneRule, message: a("base.placeholder.input base.phone"), trigger: "blur" }
|
24
|
+
],
|
25
|
+
password: [
|
26
|
+
{ required: s, message: a("base.placeholder.input base.password"), trigger: "blur" }
|
27
|
+
],
|
28
|
+
email: [
|
29
|
+
{ required: !0, message: a("base.placeholder.input base.email"), trigger: "blur" }
|
30
|
+
],
|
31
|
+
language: [
|
32
|
+
{ required: !0, message: a("base.placeholder.select base.language"), trigger: "change" }
|
33
|
+
],
|
34
|
+
roles: [
|
35
|
+
{ required: !0, type: "array", message: a("base.placeholder.select base.roles"), trigger: "change" }
|
36
|
+
]
|
37
|
+
}, p = oe([]), h = async () => {
|
38
|
+
const u = await ne.list();
|
39
|
+
p.value = Array.isArray(u == null ? void 0 : u.data) ? u.data : [];
|
40
|
+
}, { modal: k, title: w, form: m, requesting: g, executing: V, open: A, modify: O, submit: i, closed: n } = F(
|
41
|
+
M,
|
42
|
+
o,
|
43
|
+
ie
|
44
|
+
);
|
45
|
+
return x({
|
46
|
+
openOrModify: async (u) => {
|
47
|
+
p.value.length || await h(), u ? (o.key = u, O()) : A();
|
48
|
+
}
|
49
|
+
}), (u, f) => {
|
50
|
+
const U = d("el-input"), y = d("el-form-item"), _ = d("el-radio-button"), E = d("el-radio-group"), c = d("el-checkbox"), q = d("el-checkbox-group"), me = d("el-form");
|
51
|
+
return C(), L(e(Y), {
|
52
|
+
modelValue: e(k),
|
53
|
+
"onUpdate:modelValue": f[7] || (f[7] = (R) => j(k) ? k.value = R : null),
|
54
|
+
title: e(w)(),
|
55
|
+
width: "900px",
|
56
|
+
executing: e(V),
|
57
|
+
onClosed: e(n),
|
58
|
+
onSubmit: e(i)
|
59
|
+
}, {
|
60
|
+
default: t(() => [
|
61
|
+
l(me, {
|
62
|
+
ref_key: "form",
|
63
|
+
ref: m,
|
64
|
+
model: o,
|
65
|
+
"label-width": "auto",
|
66
|
+
rules: b,
|
67
|
+
disabled: e(g) || e(V)
|
68
|
+
}, {
|
69
|
+
default: t(() => [
|
70
|
+
l(y, {
|
71
|
+
label: e(a)("base.username"),
|
72
|
+
prop: "username"
|
73
|
+
}, {
|
74
|
+
default: t(() => [
|
75
|
+
l(U, {
|
76
|
+
modelValue: o.username,
|
77
|
+
"onUpdate:modelValue": f[0] || (f[0] = (R) => o.username = R),
|
78
|
+
placeholder: e(a)("base.placeholder.input"),
|
79
|
+
autocomplete: "off"
|
80
|
+
}, null, 8, ["modelValue", "placeholder"])
|
81
|
+
]),
|
82
|
+
_: 1
|
83
|
+
}, 8, ["label"]),
|
84
|
+
l(y, {
|
85
|
+
label: e(a)("base.phone"),
|
86
|
+
prop: "phone"
|
87
|
+
}, {
|
88
|
+
default: t(() => [
|
89
|
+
l(U, {
|
90
|
+
modelValue: o.phone,
|
91
|
+
"onUpdate:modelValue": f[1] || (f[1] = (R) => o.phone = R),
|
92
|
+
placeholder: e(a)("base.placeholder.input"),
|
93
|
+
autocomplete: "off"
|
94
|
+
}, null, 8, ["modelValue", "placeholder"])
|
95
|
+
]),
|
96
|
+
_: 1
|
97
|
+
}, 8, ["label"]),
|
98
|
+
l(y, {
|
99
|
+
label: e(a)("base.password"),
|
100
|
+
prop: "password",
|
101
|
+
required: s.value
|
102
|
+
}, {
|
103
|
+
default: t(() => [
|
104
|
+
l(U, {
|
105
|
+
modelValue: o.password,
|
106
|
+
"onUpdate:modelValue": f[2] || (f[2] = (R) => o.password = R),
|
107
|
+
placeholder: e(a)("base.placeholder.input"),
|
108
|
+
"show-password": "",
|
109
|
+
autocomplete: "off"
|
110
|
+
}, null, 8, ["modelValue", "placeholder"])
|
111
|
+
]),
|
112
|
+
_: 1
|
113
|
+
}, 8, ["label", "required"]),
|
114
|
+
l(y, {
|
115
|
+
label: e(a)("base.email"),
|
116
|
+
prop: "email"
|
117
|
+
}, {
|
118
|
+
default: t(() => [
|
119
|
+
l(U, {
|
120
|
+
modelValue: o.email,
|
121
|
+
"onUpdate:modelValue": f[3] || (f[3] = (R) => o.email = R),
|
122
|
+
placeholder: e(a)("base.placeholder.input")
|
123
|
+
}, null, 8, ["modelValue", "placeholder"])
|
124
|
+
]),
|
125
|
+
_: 1
|
126
|
+
}, 8, ["label"]),
|
127
|
+
l(y, {
|
128
|
+
label: e(a)("base.language"),
|
129
|
+
prop: "language"
|
130
|
+
}, {
|
131
|
+
default: t(() => [
|
132
|
+
l(E, {
|
133
|
+
modelValue: o.language,
|
134
|
+
"onUpdate:modelValue": f[4] || (f[4] = (R) => o.language = R)
|
135
|
+
}, {
|
136
|
+
default: t(() => [
|
137
|
+
l(_, { label: "zh-CN" }, {
|
138
|
+
default: t(() => f[8] || (f[8] = [
|
139
|
+
I("zh-CN")
|
140
|
+
])),
|
141
|
+
_: 1,
|
142
|
+
__: [8]
|
143
|
+
}),
|
144
|
+
l(_, { label: "en-US" }, {
|
145
|
+
default: t(() => f[9] || (f[9] = [
|
146
|
+
I("en-US")
|
147
|
+
])),
|
148
|
+
_: 1,
|
149
|
+
__: [9]
|
150
|
+
})
|
151
|
+
]),
|
152
|
+
_: 1
|
153
|
+
}, 8, ["modelValue"])
|
154
|
+
]),
|
155
|
+
_: 1
|
156
|
+
}, 8, ["label"]),
|
157
|
+
l(y, {
|
158
|
+
label: e(a)("base.roles"),
|
159
|
+
prop: "roles"
|
160
|
+
}, {
|
161
|
+
default: t(() => [
|
162
|
+
l(q, {
|
163
|
+
modelValue: o.roles,
|
164
|
+
"onUpdate:modelValue": f[5] || (f[5] = (R) => o.roles = R)
|
165
|
+
}, {
|
166
|
+
default: t(() => [
|
167
|
+
(C(!0), D(K, null, B(p.value, (R) => (C(), L(c, {
|
168
|
+
key: R.key,
|
169
|
+
label: R.key
|
170
|
+
}, {
|
171
|
+
default: t(() => [
|
172
|
+
I(ee(R.translate), 1)
|
173
|
+
]),
|
174
|
+
_: 2
|
175
|
+
}, 1032, ["label"]))), 128))
|
176
|
+
]),
|
177
|
+
_: 1
|
178
|
+
}, 8, ["modelValue"])
|
179
|
+
]),
|
180
|
+
_: 1
|
181
|
+
}, 8, ["label"]),
|
182
|
+
l(y, {
|
183
|
+
label: e(a)("base.remark"),
|
184
|
+
prop: "remark"
|
185
|
+
}, {
|
186
|
+
default: t(() => [
|
187
|
+
l(U, {
|
188
|
+
modelValue: o.remark,
|
189
|
+
"onUpdate:modelValue": f[6] || (f[6] = (R) => o.remark = R),
|
190
|
+
placeholder: e(a)("base.placeholder.input")
|
191
|
+
}, null, 8, ["modelValue", "placeholder"])
|
192
|
+
]),
|
193
|
+
_: 1
|
194
|
+
}, 8, ["label"])
|
195
|
+
]),
|
196
|
+
_: 1
|
197
|
+
}, 8, ["model", "disabled"])
|
198
|
+
]),
|
199
|
+
_: 1
|
200
|
+
}, 8, ["modelValue", "title", "executing", "onClosed", "onSubmit"]);
|
201
|
+
};
|
202
|
+
}
|
203
|
+
}), ve = /* @__PURE__ */ z({
|
204
|
+
__name: "index",
|
205
|
+
setup(S) {
|
206
|
+
const x = {
|
207
|
+
keyword: ""
|
208
|
+
}, v = [{
|
209
|
+
label: a("base.avatar"),
|
210
|
+
prop: "avatar",
|
211
|
+
width: 60,
|
212
|
+
render: ({
|
213
|
+
row: m
|
214
|
+
}) => l(d("el-avatar"), {
|
215
|
+
size: "default",
|
216
|
+
src: m.avatar
|
217
|
+
}, null)
|
218
|
+
}, {
|
219
|
+
label: a("base.user"),
|
220
|
+
width: 200,
|
221
|
+
align: "left",
|
222
|
+
render: ({
|
223
|
+
row: m
|
224
|
+
}) => l(d("el-space"), {
|
225
|
+
direction: "vertical",
|
226
|
+
alignment: "start"
|
227
|
+
}, {
|
228
|
+
default: () => [l("div", null, [m.username]), l("div", null, [m.email])]
|
229
|
+
})
|
230
|
+
}, {
|
231
|
+
label: a("base.phone"),
|
232
|
+
prop: "phone",
|
233
|
+
width: 140
|
234
|
+
}, {
|
235
|
+
label: a("base.remark"),
|
236
|
+
prop: "remark",
|
237
|
+
width: 0
|
238
|
+
}, {
|
239
|
+
label: a("base.login_at"),
|
240
|
+
prop: "login_at",
|
241
|
+
width: 160
|
242
|
+
}, {
|
243
|
+
label: a("base.created_at"),
|
244
|
+
prop: "created_at",
|
245
|
+
width: 160
|
246
|
+
}, {
|
247
|
+
label: a("base.updated_at"),
|
248
|
+
prop: "updated_at",
|
249
|
+
width: 160
|
250
|
+
}, {
|
251
|
+
prop: "action",
|
252
|
+
label: a("base.action"),
|
253
|
+
width: 80,
|
254
|
+
align: "center",
|
255
|
+
render: ({
|
256
|
+
row: m
|
257
|
+
}) => l(W, {
|
258
|
+
onModify: () => w(m.key)
|
259
|
+
}, null)
|
260
|
+
}], {
|
261
|
+
tableRef: M,
|
262
|
+
infoRef: o,
|
263
|
+
keyword: s,
|
264
|
+
search: b,
|
265
|
+
refresh: p,
|
266
|
+
reset: h,
|
267
|
+
openInfo: k,
|
268
|
+
modifyInfo: w
|
269
|
+
} = G(x);
|
270
|
+
return (m, g) => {
|
271
|
+
const V = d("el-input"), A = d("el-space"), O = d("el-card");
|
272
|
+
return C(), L(O, {
|
273
|
+
class: "basic-card flex-full",
|
274
|
+
"body-class": "flex-1"
|
275
|
+
}, {
|
276
|
+
header: t(() => [l(A, {
|
277
|
+
class: "search-bar"
|
278
|
+
}, {
|
279
|
+
default: t(() => [l(e($), {
|
280
|
+
onRefresh: e(p)
|
281
|
+
}, null, 8, ["onRefresh"]), l(e(Q), {
|
282
|
+
onOpen: e(k)
|
283
|
+
}, null, 8, ["onOpen"]), l(V, {
|
284
|
+
class: "basic-search-input",
|
285
|
+
modelValue: e(s).keyword,
|
286
|
+
"onUpdate:modelValue": g[0] || (g[0] = (i) => e(s).keyword = i),
|
287
|
+
placeholder: e(a)("base.placeholder.keyword"),
|
288
|
+
clearable: "",
|
289
|
+
onKeyup: P(e(b), ["enter"]),
|
290
|
+
onClear: e(b)
|
291
|
+
}, null, 8, ["modelValue", "placeholder", "onKeyup", "onClear"]), l(e(X), {
|
292
|
+
onSearch: e(b)
|
293
|
+
}, null, 8, ["onSearch"]), l(e(Z), {
|
294
|
+
onReset: e(h)
|
295
|
+
}, null, 8, ["onReset"])]),
|
296
|
+
_: 1
|
297
|
+
})]),
|
298
|
+
default: t(() => [l(e(H), {
|
299
|
+
ref_key: "tableRef",
|
300
|
+
ref: M,
|
301
|
+
size: "small",
|
302
|
+
columns: v,
|
303
|
+
url: e(ie).urls[e(J)],
|
304
|
+
"search-param": e(s),
|
305
|
+
autoSearch: ""
|
306
|
+
}, null, 8, ["url", "search-param"]), l(ke, {
|
307
|
+
ref_key: "infoRef",
|
308
|
+
ref: o,
|
309
|
+
onRefresh: e(h)
|
310
|
+
}, null, 8, ["onRefresh"])]),
|
311
|
+
_: 1
|
312
|
+
});
|
313
|
+
};
|
314
|
+
}
|
315
|
+
}), we = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
316
|
+
__proto__: null,
|
317
|
+
default: ve
|
318
|
+
}, Symbol.toStringTag, { value: "Module" })), ae = te("translate", {}, "key"), xe = /* @__PURE__ */ z({
|
319
|
+
__name: "info",
|
320
|
+
emits: ["refresh"],
|
321
|
+
setup(S, { expose: x, emit: v }) {
|
322
|
+
const M = v, o = N({
|
323
|
+
module: "",
|
324
|
+
key: "",
|
325
|
+
language: "",
|
326
|
+
result: "",
|
327
|
+
status: 1,
|
328
|
+
remark: "",
|
329
|
+
created_at: "",
|
330
|
+
updated_at: ""
|
331
|
+
}), s = {
|
332
|
+
module: [
|
333
|
+
{ required: !0, message: a("language.placeholder.module"), trigger: "blur" }
|
334
|
+
],
|
335
|
+
key: [
|
336
|
+
{ required: !0, message: a("language.placeholder.key"), trigger: "blur" }
|
337
|
+
],
|
338
|
+
language: [
|
339
|
+
{ required: !0, message: a("language.placeholder.language"), trigger: "change" }
|
340
|
+
],
|
341
|
+
result: [
|
342
|
+
{ required: !0, message: a("language.placeholder.result"), trigger: "blur" }
|
343
|
+
]
|
344
|
+
}, { modal: b, title: p, form: h, requesting: k, executing: w, open: m, modify: g, submit: V, closed: A } = F(
|
345
|
+
M,
|
346
|
+
o,
|
347
|
+
ae
|
348
|
+
);
|
349
|
+
return x({
|
350
|
+
openOrModify: (i) => {
|
351
|
+
i ? (o.key = i, g()) : m();
|
352
|
+
}
|
353
|
+
}), (i, n) => {
|
354
|
+
const r = d("el-input"), u = d("el-form-item"), f = d("el-radio-button"), U = d("el-radio-group"), y = d("el-form");
|
355
|
+
return C(), L(e(Y), {
|
356
|
+
modelValue: e(b),
|
357
|
+
"onUpdate:modelValue": n[5] || (n[5] = (_) => j(b) ? b.value = _ : null),
|
358
|
+
title: e(p)(),
|
359
|
+
width: "900px",
|
360
|
+
executing: e(w),
|
361
|
+
onClosed: e(A),
|
362
|
+
onSubmit: e(V)
|
363
|
+
}, {
|
364
|
+
default: t(() => [
|
365
|
+
l(y, {
|
366
|
+
ref_key: "form",
|
367
|
+
ref: h,
|
368
|
+
model: o,
|
369
|
+
"label-width": "auto",
|
370
|
+
rules: s,
|
371
|
+
disabled: e(k) || e(w)
|
372
|
+
}, {
|
373
|
+
default: t(() => [
|
374
|
+
l(u, {
|
375
|
+
label: e(a)("language.module"),
|
376
|
+
prop: "module",
|
377
|
+
required: ""
|
378
|
+
}, {
|
379
|
+
default: t(() => [
|
380
|
+
l(r, {
|
381
|
+
modelValue: o.module,
|
382
|
+
"onUpdate:modelValue": n[0] || (n[0] = (_) => o.module = _),
|
383
|
+
placeholder: e(a)("language.placeholder.module")
|
384
|
+
}, null, 8, ["modelValue", "placeholder"])
|
385
|
+
]),
|
386
|
+
_: 1
|
387
|
+
}, 8, ["label"]),
|
388
|
+
l(u, {
|
389
|
+
label: e(a)("language.key"),
|
390
|
+
prop: "key",
|
391
|
+
required: ""
|
392
|
+
}, {
|
393
|
+
default: t(() => [
|
394
|
+
l(r, {
|
395
|
+
modelValue: o.key,
|
396
|
+
"onUpdate:modelValue": n[1] || (n[1] = (_) => o.key = _),
|
397
|
+
placeholder: e(a)("language.placeholder.key")
|
398
|
+
}, null, 8, ["modelValue", "placeholder"])
|
399
|
+
]),
|
400
|
+
_: 1
|
401
|
+
}, 8, ["label"]),
|
402
|
+
l(u, {
|
403
|
+
label: e(a)("language.language"),
|
404
|
+
prop: "language",
|
405
|
+
required: ""
|
406
|
+
}, {
|
407
|
+
default: t(() => [
|
408
|
+
l(U, {
|
409
|
+
modelValue: o.language,
|
410
|
+
"onUpdate:modelValue": n[2] || (n[2] = (_) => o.language = _)
|
411
|
+
}, {
|
412
|
+
default: t(() => [
|
413
|
+
l(f, { label: "zh-CN" }, {
|
414
|
+
default: t(() => n[6] || (n[6] = [
|
415
|
+
I("zh-CN")
|
416
|
+
])),
|
417
|
+
_: 1,
|
418
|
+
__: [6]
|
419
|
+
}),
|
420
|
+
l(f, { label: "en-US" }, {
|
421
|
+
default: t(() => n[7] || (n[7] = [
|
422
|
+
I("en-US")
|
423
|
+
])),
|
424
|
+
_: 1,
|
425
|
+
__: [7]
|
426
|
+
})
|
427
|
+
]),
|
428
|
+
_: 1
|
429
|
+
}, 8, ["modelValue"])
|
430
|
+
]),
|
431
|
+
_: 1
|
432
|
+
}, 8, ["label"]),
|
433
|
+
l(u, {
|
434
|
+
label: e(a)("language.result"),
|
435
|
+
prop: "result",
|
436
|
+
required: ""
|
437
|
+
}, {
|
438
|
+
default: t(() => [
|
439
|
+
l(r, {
|
440
|
+
modelValue: o.result,
|
441
|
+
"onUpdate:modelValue": n[3] || (n[3] = (_) => o.result = _),
|
442
|
+
placeholder: e(a)("language.placeholder.result")
|
443
|
+
}, null, 8, ["modelValue", "placeholder"])
|
444
|
+
]),
|
445
|
+
_: 1
|
446
|
+
}, 8, ["label"]),
|
447
|
+
l(u, {
|
448
|
+
label: e(a)("base.remark"),
|
449
|
+
prop: "remark"
|
450
|
+
}, {
|
451
|
+
default: t(() => [
|
452
|
+
l(r, {
|
453
|
+
modelValue: o.remark,
|
454
|
+
"onUpdate:modelValue": n[4] || (n[4] = (_) => o.remark = _),
|
455
|
+
placeholder: e(a)("base.placeholder.input")
|
456
|
+
}, null, 8, ["modelValue", "placeholder"])
|
457
|
+
]),
|
458
|
+
_: 1
|
459
|
+
}, 8, ["label"])
|
460
|
+
]),
|
461
|
+
_: 1
|
462
|
+
}, 8, ["model", "disabled"])
|
463
|
+
]),
|
464
|
+
_: 1
|
465
|
+
}, 8, ["modelValue", "title", "executing", "onClosed", "onSubmit"]);
|
466
|
+
};
|
467
|
+
}
|
468
|
+
}), Ue = /* @__PURE__ */ z({
|
469
|
+
__name: "index",
|
470
|
+
setup(S) {
|
471
|
+
const x = {
|
472
|
+
keyword: "",
|
473
|
+
status: 0
|
474
|
+
}, v = [{
|
475
|
+
label: a("base.module"),
|
476
|
+
prop: "module",
|
477
|
+
width: 120
|
478
|
+
}, {
|
479
|
+
label: a("base.language"),
|
480
|
+
prop: "language",
|
481
|
+
width: 100
|
482
|
+
}, {
|
483
|
+
label: a("base.key"),
|
484
|
+
prop: "key",
|
485
|
+
width: 200
|
486
|
+
}, {
|
487
|
+
label: a("base.result"),
|
488
|
+
prop: "result",
|
489
|
+
width: 200
|
490
|
+
}, {
|
491
|
+
label: a("base.status"),
|
492
|
+
prop: "status",
|
493
|
+
width: 80,
|
494
|
+
type: "switch",
|
495
|
+
props: {
|
496
|
+
activeValue: 1,
|
497
|
+
inactiveValue: 2,
|
498
|
+
api: ae.urls[de],
|
499
|
+
refresh: !0
|
500
|
+
}
|
501
|
+
}, {
|
502
|
+
label: a("base.remark"),
|
503
|
+
prop: "remark",
|
504
|
+
width: 0
|
505
|
+
}, {
|
506
|
+
label: a("base.created_at"),
|
507
|
+
prop: "created_at",
|
508
|
+
width: 160
|
509
|
+
}, {
|
510
|
+
label: a("base.updated_at"),
|
511
|
+
prop: "updated_at",
|
512
|
+
width: 160
|
513
|
+
}, {
|
514
|
+
prop: "action",
|
515
|
+
label: a("base.action"),
|
516
|
+
width: 80,
|
517
|
+
align: "center",
|
518
|
+
render: ({
|
519
|
+
row: m
|
520
|
+
}) => l(W, {
|
521
|
+
onModify: () => w(m.key)
|
522
|
+
}, null)
|
523
|
+
}], {
|
524
|
+
tableRef: M,
|
525
|
+
infoRef: o,
|
526
|
+
keyword: s,
|
527
|
+
search: b,
|
528
|
+
refresh: p,
|
529
|
+
reset: h,
|
530
|
+
openInfo: k,
|
531
|
+
modifyInfo: w
|
532
|
+
} = G(x);
|
533
|
+
return (m, g) => {
|
534
|
+
const V = d("el-input"), A = d("el-radio-button"), O = d("el-radio-group"), i = d("el-space"), n = d("el-card");
|
535
|
+
return C(), L(n, {
|
536
|
+
class: "basic-card flex-full",
|
537
|
+
"body-class": "flex-1"
|
538
|
+
}, {
|
539
|
+
header: t(() => [l(i, {
|
540
|
+
class: "search-bar"
|
541
|
+
}, {
|
542
|
+
default: t(() => [l(e($), {
|
543
|
+
onRefresh: e(p)
|
544
|
+
}, null, 8, ["onRefresh"]), l(e(Q), {
|
545
|
+
onOpen: e(k)
|
546
|
+
}, null, 8, ["onOpen"]), l(V, {
|
547
|
+
class: "basic-search-input",
|
548
|
+
modelValue: e(s).keyword,
|
549
|
+
"onUpdate:modelValue": g[0] || (g[0] = (r) => e(s).keyword = r),
|
550
|
+
placeholder: e(a)("base.placeholder.keyword"),
|
551
|
+
clearable: "",
|
552
|
+
onKeyup: P(e(b), ["enter"]),
|
553
|
+
onClear: e(b)
|
554
|
+
}, null, 8, ["modelValue", "placeholder", "onKeyup", "onClear"]), l(O, {
|
555
|
+
modelValue: e(s).status,
|
556
|
+
"onUpdate:modelValue": g[1] || (g[1] = (r) => e(s).status = r),
|
557
|
+
onChange: e(b)
|
558
|
+
}, {
|
559
|
+
default: t(() => [(C(), D(K, null, B([0, 1, 2], (r) => l(A, {
|
560
|
+
key: r,
|
561
|
+
label: e(a)(`base.DISABLE_ENABLE.${r}`),
|
562
|
+
value: r
|
563
|
+
}, null, 8, ["label", "value"])), 64))]),
|
564
|
+
_: 1
|
565
|
+
}, 8, ["modelValue", "onChange"]), l(e(X), {
|
566
|
+
onSearch: e(b)
|
567
|
+
}, null, 8, ["onSearch"]), l(e(Z), {
|
568
|
+
onReset: e(h)
|
569
|
+
}, null, 8, ["onReset"])]),
|
570
|
+
_: 1
|
571
|
+
})]),
|
572
|
+
default: t(() => [l(e(H), {
|
573
|
+
ref: "proTableRef",
|
574
|
+
size: "small",
|
575
|
+
columns: v,
|
576
|
+
url: e(ae).urls[e(J)],
|
577
|
+
"search-param": e(s),
|
578
|
+
autoSearch: ""
|
579
|
+
}, null, 8, ["url", "search-param"]), l(xe, {
|
580
|
+
ref_key: "infoRef",
|
581
|
+
ref: o,
|
582
|
+
onRefresh: e(h)
|
583
|
+
}, null, 8, ["onRefresh"])]),
|
584
|
+
_: 1
|
585
|
+
});
|
586
|
+
};
|
587
|
+
}
|
588
|
+
}), Re = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
589
|
+
__proto__: null,
|
590
|
+
default: Ue
|
591
|
+
}, Symbol.toStringTag, { value: "Module" })), re = {
|
592
|
+
tops: "tops",
|
593
|
+
rules: "rules"
|
594
|
+
}, T = ye.createAutoApi("menu", re, "id", Object.keys(re)), Ce = /* @__PURE__ */ z({
|
4
595
|
__name: "menuSelect",
|
5
596
|
props: {
|
6
597
|
modelValue: {
|
@@ -13,53 +604,51 @@ const te = /* @__PURE__ */ T({
|
|
13
604
|
}
|
14
605
|
},
|
15
606
|
emits: ["update:modelValue", "change"],
|
16
|
-
setup(
|
17
|
-
emit:
|
607
|
+
setup(S, {
|
608
|
+
emit: x
|
18
609
|
}) {
|
19
|
-
const
|
20
|
-
|
21
|
-
}), {
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
filterOptions: w
|
29
|
-
} = H(I(g, "modelValue"), i, {
|
610
|
+
const v = x, M = S, {
|
611
|
+
requesting: o
|
612
|
+
} = se(T), {
|
613
|
+
value: s,
|
614
|
+
options: b,
|
615
|
+
change: p,
|
616
|
+
refresh: h,
|
617
|
+
filterOptions: k
|
618
|
+
} = pe(ue(M, "modelValue"), v, {
|
30
619
|
key: "MENU_LIST",
|
31
|
-
api:
|
32
|
-
url:
|
620
|
+
api: T,
|
621
|
+
url: T.urls.tops,
|
33
622
|
isArray: !0
|
34
623
|
});
|
35
|
-
return (
|
36
|
-
const
|
37
|
-
return
|
38
|
-
modelValue:
|
39
|
-
"onUpdate:modelValue":
|
40
|
-
options:
|
41
|
-
multiple:
|
42
|
-
disabled:
|
43
|
-
placeholder:
|
624
|
+
return (w, m) => {
|
625
|
+
const g = d("el-select-v2");
|
626
|
+
return C(), L(g, {
|
627
|
+
modelValue: e(s),
|
628
|
+
"onUpdate:modelValue": m[1] || (m[1] = (V) => j(s) ? s.value = V : null),
|
629
|
+
options: e(b),
|
630
|
+
multiple: S.multiple,
|
631
|
+
disabled: e(o),
|
632
|
+
placeholder: e(a)("base.placeholder.select"),
|
44
633
|
filterable: "",
|
45
|
-
filterOptions:
|
46
|
-
onChange:
|
634
|
+
filterOptions: e(k),
|
635
|
+
onChange: e(p)
|
47
636
|
}, {
|
48
|
-
prefix:
|
49
|
-
loading:
|
637
|
+
prefix: t(() => [l(e($), {
|
638
|
+
loading: e(o),
|
50
639
|
text: "",
|
51
640
|
size: "small",
|
52
|
-
onRefresh:
|
53
|
-
}, null, 8, ["loading"
|
641
|
+
onRefresh: m[0] || (m[0] = (V) => e(h)(!0))
|
642
|
+
}, null, 8, ["loading"])]),
|
54
643
|
_: 1
|
55
644
|
}, 8, ["modelValue", "options", "multiple", "disabled", "placeholder", "filterOptions", "onChange"]);
|
56
645
|
};
|
57
646
|
}
|
58
|
-
}),
|
647
|
+
}), Se = /* @__PURE__ */ z({
|
59
648
|
__name: "info",
|
60
649
|
emits: ["refresh"],
|
61
|
-
setup(
|
62
|
-
const
|
650
|
+
setup(S, { expose: x, emit: v }) {
|
651
|
+
const M = v, o = N({
|
63
652
|
id: 0,
|
64
653
|
menu_id: 0,
|
65
654
|
level: 0,
|
@@ -82,71 +671,71 @@ const te = /* @__PURE__ */ T({
|
|
82
671
|
keep_alive: !1,
|
83
672
|
link: !1
|
84
673
|
}
|
85
|
-
}),
|
674
|
+
}), s = {
|
86
675
|
sort: [
|
87
|
-
{ required: !0, type: "number", message:
|
676
|
+
{ required: !0, type: "number", message: a("base.placeholder.input base.sort"), trigger: "blur" }
|
88
677
|
],
|
89
678
|
module: [
|
90
|
-
{ required: !0, message:
|
679
|
+
{ required: !0, message: a("base.placeholder.input menu.module"), trigger: "blur" }
|
91
680
|
],
|
92
681
|
name: [
|
93
|
-
{ required: !0, message:
|
682
|
+
{ required: !0, message: a("base.placeholder.input base.name"), trigger: "blur" }
|
94
683
|
],
|
95
684
|
en_name: [
|
96
|
-
{ required: !0, message:
|
685
|
+
{ required: !0, message: a("base.placeholder.input base.en_name"), trigger: "blur" }
|
97
686
|
],
|
98
687
|
url: [
|
99
|
-
{ required: !0, message:
|
688
|
+
{ required: !0, message: a("base.placeholder.input base.url"), trigger: "blur" }
|
100
689
|
],
|
101
690
|
component: [
|
102
|
-
{ required: !0, message:
|
691
|
+
{ required: !0, message: a("base.placeholder.input menu.component"), trigger: "blur" }
|
103
692
|
]
|
104
|
-
}, { modal:
|
105
|
-
|
106
|
-
|
107
|
-
|
693
|
+
}, { modal: b, title: p, form: h, requesting: k, executing: w, open: m, modify: g, submit: V, closed: A } = F(
|
694
|
+
M,
|
695
|
+
o,
|
696
|
+
T
|
108
697
|
);
|
109
|
-
return
|
110
|
-
openOrModify: (
|
111
|
-
|
698
|
+
return x({
|
699
|
+
openOrModify: (i) => {
|
700
|
+
i ? (o.id = i, g()) : m();
|
112
701
|
}
|
113
|
-
}), (
|
114
|
-
const
|
115
|
-
return
|
116
|
-
modelValue:
|
117
|
-
"onUpdate:modelValue":
|
118
|
-
title:
|
702
|
+
}), (i, n) => {
|
703
|
+
const r = d("el-form-item"), u = d("el-col"), f = d("el-input-number"), U = d("el-row"), y = d("el-input"), _ = d("el-switch"), E = d("el-form");
|
704
|
+
return C(), L(e(Y), {
|
705
|
+
modelValue: e(b),
|
706
|
+
"onUpdate:modelValue": n[17] || (n[17] = (c) => j(b) ? b.value = c : null),
|
707
|
+
title: e(p)(),
|
119
708
|
width: "900px",
|
120
|
-
executing:
|
121
|
-
onClosed:
|
122
|
-
onSubmit:
|
709
|
+
executing: e(w),
|
710
|
+
onClosed: e(A),
|
711
|
+
onSubmit: e(V)
|
123
712
|
}, {
|
124
|
-
default:
|
125
|
-
|
713
|
+
default: t(() => [
|
714
|
+
l(E, {
|
126
715
|
ref_key: "form",
|
127
|
-
ref:
|
128
|
-
model:
|
716
|
+
ref: h,
|
717
|
+
model: o,
|
129
718
|
"label-width": "auto",
|
130
|
-
rules:
|
131
|
-
disabled:
|
719
|
+
rules: s,
|
720
|
+
disabled: e(k) || e(w)
|
132
721
|
}, {
|
133
|
-
default:
|
134
|
-
|
135
|
-
default:
|
136
|
-
|
137
|
-
default:
|
138
|
-
|
139
|
-
default:
|
140
|
-
|
141
|
-
default:
|
142
|
-
|
143
|
-
label:
|
722
|
+
default: t(() => [
|
723
|
+
l(U, { gutter: 20 }, {
|
724
|
+
default: t(() => [
|
725
|
+
l(u, { span: 12 }, {
|
726
|
+
default: t(() => [
|
727
|
+
l(U, { gutter: 10 }, {
|
728
|
+
default: t(() => [
|
729
|
+
l(u, { span: 12 }, {
|
730
|
+
default: t(() => [
|
731
|
+
l(r, {
|
732
|
+
label: e(a)("base.parent"),
|
144
733
|
prop: "menu_id"
|
145
734
|
}, {
|
146
|
-
default:
|
147
|
-
|
148
|
-
modelValue:
|
149
|
-
"onUpdate:modelValue":
|
735
|
+
default: t(() => [
|
736
|
+
l(Ce, {
|
737
|
+
modelValue: o.menu_id,
|
738
|
+
"onUpdate:modelValue": n[0] || (n[0] = (c) => o.menu_id = c)
|
150
739
|
}, null, 8, ["modelValue"])
|
151
740
|
]),
|
152
741
|
_: 1
|
@@ -154,18 +743,18 @@ const te = /* @__PURE__ */ T({
|
|
154
743
|
]),
|
155
744
|
_: 1
|
156
745
|
}),
|
157
|
-
|
158
|
-
default:
|
159
|
-
|
160
|
-
label:
|
746
|
+
l(u, { span: 12 }, {
|
747
|
+
default: t(() => [
|
748
|
+
l(r, {
|
749
|
+
label: e(a)("base.sort"),
|
161
750
|
prop: "sort"
|
162
751
|
}, {
|
163
|
-
default:
|
164
|
-
|
165
|
-
modelValue:
|
166
|
-
"onUpdate:modelValue":
|
752
|
+
default: t(() => [
|
753
|
+
l(f, {
|
754
|
+
modelValue: o.sort,
|
755
|
+
"onUpdate:modelValue": n[1] || (n[1] = (c) => o.sort = c),
|
167
756
|
min: 0,
|
168
|
-
placeholder:
|
757
|
+
placeholder: e(a)("base.placeholder.input")
|
169
758
|
}, null, 8, ["modelValue", "placeholder"])
|
170
759
|
]),
|
171
760
|
_: 1
|
@@ -176,80 +765,80 @@ const te = /* @__PURE__ */ T({
|
|
176
765
|
]),
|
177
766
|
_: 1
|
178
767
|
}),
|
179
|
-
|
180
|
-
label:
|
768
|
+
l(r, {
|
769
|
+
label: e(a)("menu.module"),
|
181
770
|
prop: "module"
|
182
771
|
}, {
|
183
|
-
default:
|
184
|
-
|
185
|
-
modelValue:
|
186
|
-
"onUpdate:modelValue":
|
187
|
-
placeholder:
|
772
|
+
default: t(() => [
|
773
|
+
l(y, {
|
774
|
+
modelValue: o.module,
|
775
|
+
"onUpdate:modelValue": n[2] || (n[2] = (c) => o.module = c),
|
776
|
+
placeholder: e(a)("base.placeholder.input")
|
188
777
|
}, null, 8, ["modelValue", "placeholder"])
|
189
778
|
]),
|
190
779
|
_: 1
|
191
780
|
}, 8, ["label"]),
|
192
|
-
|
193
|
-
label:
|
781
|
+
l(r, {
|
782
|
+
label: e(a)("base.name"),
|
194
783
|
prop: "name"
|
195
784
|
}, {
|
196
|
-
default:
|
197
|
-
|
198
|
-
modelValue:
|
199
|
-
"onUpdate:modelValue":
|
200
|
-
placeholder:
|
785
|
+
default: t(() => [
|
786
|
+
l(y, {
|
787
|
+
modelValue: o.name,
|
788
|
+
"onUpdate:modelValue": n[3] || (n[3] = (c) => o.name = c),
|
789
|
+
placeholder: e(a)("base.placeholder.input")
|
201
790
|
}, null, 8, ["modelValue", "placeholder"])
|
202
791
|
]),
|
203
792
|
_: 1
|
204
793
|
}, 8, ["label"]),
|
205
|
-
|
206
|
-
label:
|
794
|
+
l(r, {
|
795
|
+
label: e(a)("base.en_name"),
|
207
796
|
prop: "en_name"
|
208
797
|
}, {
|
209
|
-
default:
|
210
|
-
|
211
|
-
modelValue:
|
212
|
-
"onUpdate:modelValue":
|
213
|
-
placeholder:
|
798
|
+
default: t(() => [
|
799
|
+
l(y, {
|
800
|
+
modelValue: o.en_name,
|
801
|
+
"onUpdate:modelValue": n[4] || (n[4] = (c) => o.en_name = c),
|
802
|
+
placeholder: e(a)("base.placeholder.input")
|
214
803
|
}, null, 8, ["modelValue", "placeholder"])
|
215
804
|
]),
|
216
805
|
_: 1
|
217
806
|
}, 8, ["label"]),
|
218
|
-
|
219
|
-
label:
|
807
|
+
l(r, {
|
808
|
+
label: e(a)("menu.component"),
|
220
809
|
prop: "component"
|
221
810
|
}, {
|
222
|
-
default:
|
223
|
-
|
224
|
-
modelValue:
|
225
|
-
"onUpdate:modelValue":
|
226
|
-
placeholder:
|
811
|
+
default: t(() => [
|
812
|
+
l(y, {
|
813
|
+
modelValue: o.component,
|
814
|
+
"onUpdate:modelValue": n[5] || (n[5] = (c) => o.component = c),
|
815
|
+
placeholder: e(a)("base.placeholder.input")
|
227
816
|
}, null, 8, ["modelValue", "placeholder"])
|
228
817
|
]),
|
229
818
|
_: 1
|
230
819
|
}, 8, ["label"]),
|
231
|
-
|
232
|
-
label:
|
820
|
+
l(r, {
|
821
|
+
label: e(a)("base.url"),
|
233
822
|
prop: "url"
|
234
823
|
}, {
|
235
|
-
default:
|
236
|
-
|
237
|
-
modelValue:
|
238
|
-
"onUpdate:modelValue":
|
239
|
-
placeholder:
|
824
|
+
default: t(() => [
|
825
|
+
l(y, {
|
826
|
+
modelValue: o.url,
|
827
|
+
"onUpdate:modelValue": n[6] || (n[6] = (c) => o.url = c),
|
828
|
+
placeholder: e(a)("base.placeholder.input")
|
240
829
|
}, null, 8, ["modelValue", "placeholder"])
|
241
830
|
]),
|
242
831
|
_: 1
|
243
832
|
}, 8, ["label"]),
|
244
|
-
|
245
|
-
label:
|
833
|
+
l(r, {
|
834
|
+
label: e(a)("base.remark"),
|
246
835
|
prop: "remark"
|
247
836
|
}, {
|
248
|
-
default:
|
249
|
-
|
250
|
-
modelValue:
|
251
|
-
"onUpdate:modelValue":
|
252
|
-
placeholder:
|
837
|
+
default: t(() => [
|
838
|
+
l(y, {
|
839
|
+
modelValue: o.remark,
|
840
|
+
"onUpdate:modelValue": n[7] || (n[7] = (c) => o.remark = c),
|
841
|
+
placeholder: e(a)("base.placeholder.input")
|
253
842
|
}, null, 8, ["modelValue", "placeholder"])
|
254
843
|
]),
|
255
844
|
_: 1
|
@@ -257,24 +846,24 @@ const te = /* @__PURE__ */ T({
|
|
257
846
|
]),
|
258
847
|
_: 1
|
259
848
|
}),
|
260
|
-
|
261
|
-
default:
|
262
|
-
|
263
|
-
label:
|
849
|
+
l(u, { span: 12 }, {
|
850
|
+
default: t(() => [
|
851
|
+
l(r, {
|
852
|
+
label: e(a)("base.icon"),
|
264
853
|
prop: "icon"
|
265
854
|
}, {
|
266
|
-
default:
|
267
|
-
|
268
|
-
modelValue:
|
269
|
-
"onUpdate:modelValue":
|
270
|
-
placeholder:
|
271
|
-
onInput:
|
272
|
-
|
855
|
+
default: t(() => [
|
856
|
+
l(y, {
|
857
|
+
modelValue: o.icon,
|
858
|
+
"onUpdate:modelValue": n[8] || (n[8] = (c) => o.icon = c),
|
859
|
+
placeholder: e(a)("base.placeholder.input"),
|
860
|
+
onInput: n[9] || (n[9] = (c) => {
|
861
|
+
o.meta.icon = c;
|
273
862
|
})
|
274
863
|
}, {
|
275
|
-
prepend:
|
276
|
-
|
277
|
-
class:
|
864
|
+
prepend: t(() => [
|
865
|
+
le("span", {
|
866
|
+
class: fe("iconfont " + o.icon)
|
278
867
|
}, null, 2)
|
279
868
|
]),
|
280
869
|
_: 1
|
@@ -282,44 +871,44 @@ const te = /* @__PURE__ */ T({
|
|
282
871
|
]),
|
283
872
|
_: 1
|
284
873
|
}, 8, ["label"]),
|
285
|
-
|
286
|
-
label:
|
874
|
+
l(r, {
|
875
|
+
label: e(a)("base.title"),
|
287
876
|
prop: "meta.title"
|
288
877
|
}, {
|
289
|
-
default:
|
290
|
-
|
291
|
-
modelValue:
|
292
|
-
"onUpdate:modelValue":
|
293
|
-
placeholder:
|
878
|
+
default: t(() => [
|
879
|
+
l(y, {
|
880
|
+
modelValue: o.meta.title,
|
881
|
+
"onUpdate:modelValue": n[10] || (n[10] = (c) => o.meta.title = c),
|
882
|
+
placeholder: e(a)("base.placeholder.input")
|
294
883
|
}, null, 8, ["modelValue", "placeholder"])
|
295
884
|
]),
|
296
885
|
_: 1
|
297
886
|
}, 8, ["label"]),
|
298
|
-
|
299
|
-
label:
|
887
|
+
l(r, {
|
888
|
+
label: e(a)("menu.active"),
|
300
889
|
prop: "meta.active"
|
301
890
|
}, {
|
302
|
-
default:
|
303
|
-
|
304
|
-
modelValue:
|
305
|
-
"onUpdate:modelValue":
|
306
|
-
placeholder:
|
891
|
+
default: t(() => [
|
892
|
+
l(y, {
|
893
|
+
modelValue: o.meta.active,
|
894
|
+
"onUpdate:modelValue": n[11] || (n[11] = (c) => o.meta.active = c),
|
895
|
+
placeholder: e(a)("base.placeholder.input")
|
307
896
|
}, null, 8, ["modelValue", "placeholder"])
|
308
897
|
]),
|
309
898
|
_: 1
|
310
899
|
}, 8, ["label"]),
|
311
|
-
|
312
|
-
default:
|
313
|
-
|
314
|
-
default:
|
315
|
-
|
316
|
-
label:
|
900
|
+
l(U, null, {
|
901
|
+
default: t(() => [
|
902
|
+
l(u, { span: 12 }, {
|
903
|
+
default: t(() => [
|
904
|
+
l(r, {
|
905
|
+
label: e(a)("menu.link"),
|
317
906
|
prop: "meta.link"
|
318
907
|
}, {
|
319
|
-
default:
|
320
|
-
|
321
|
-
modelValue:
|
322
|
-
"onUpdate:modelValue":
|
908
|
+
default: t(() => [
|
909
|
+
l(_, {
|
910
|
+
modelValue: o.meta.link,
|
911
|
+
"onUpdate:modelValue": n[12] || (n[12] = (c) => o.meta.link = c)
|
323
912
|
}, null, 8, ["modelValue"])
|
324
913
|
]),
|
325
914
|
_: 1
|
@@ -327,16 +916,16 @@ const te = /* @__PURE__ */ T({
|
|
327
916
|
]),
|
328
917
|
_: 1
|
329
918
|
}),
|
330
|
-
|
331
|
-
default:
|
332
|
-
|
333
|
-
label:
|
919
|
+
l(u, { span: 12 }, {
|
920
|
+
default: t(() => [
|
921
|
+
l(r, {
|
922
|
+
label: e(a)("menu.keep_alive"),
|
334
923
|
prop: "meta.keep_alive"
|
335
924
|
}, {
|
336
|
-
default:
|
337
|
-
|
338
|
-
modelValue:
|
339
|
-
"onUpdate:modelValue":
|
925
|
+
default: t(() => [
|
926
|
+
l(_, {
|
927
|
+
modelValue: o.meta.keep_alive,
|
928
|
+
"onUpdate:modelValue": n[13] || (n[13] = (c) => o.meta.keep_alive = c)
|
340
929
|
}, null, 8, ["modelValue"])
|
341
930
|
]),
|
342
931
|
_: 1
|
@@ -344,16 +933,16 @@ const te = /* @__PURE__ */ T({
|
|
344
933
|
]),
|
345
934
|
_: 1
|
346
935
|
}),
|
347
|
-
|
348
|
-
default:
|
349
|
-
|
350
|
-
label:
|
936
|
+
l(u, { span: 12 }, {
|
937
|
+
default: t(() => [
|
938
|
+
l(r, {
|
939
|
+
label: e(a)("menu.hide"),
|
351
940
|
prop: "meta.hide"
|
352
941
|
}, {
|
353
|
-
default:
|
354
|
-
|
355
|
-
modelValue:
|
356
|
-
"onUpdate:modelValue":
|
942
|
+
default: t(() => [
|
943
|
+
l(_, {
|
944
|
+
modelValue: o.meta.hide,
|
945
|
+
"onUpdate:modelValue": n[14] || (n[14] = (c) => o.meta.hide = c)
|
357
946
|
}, null, 8, ["modelValue"])
|
358
947
|
]),
|
359
948
|
_: 1
|
@@ -361,16 +950,16 @@ const te = /* @__PURE__ */ T({
|
|
361
950
|
]),
|
362
951
|
_: 1
|
363
952
|
}),
|
364
|
-
|
365
|
-
default:
|
366
|
-
|
367
|
-
label:
|
953
|
+
l(u, { span: 12 }, {
|
954
|
+
default: t(() => [
|
955
|
+
l(r, {
|
956
|
+
label: e(a)("menu.full"),
|
368
957
|
prop: "meta.full"
|
369
958
|
}, {
|
370
|
-
default:
|
371
|
-
|
372
|
-
modelValue:
|
373
|
-
"onUpdate:modelValue":
|
959
|
+
default: t(() => [
|
960
|
+
l(_, {
|
961
|
+
modelValue: o.meta.full,
|
962
|
+
"onUpdate:modelValue": n[15] || (n[15] = (c) => o.meta.full = c)
|
374
963
|
}, null, 8, ["modelValue"])
|
375
964
|
]),
|
376
965
|
_: 1
|
@@ -378,16 +967,16 @@ const te = /* @__PURE__ */ T({
|
|
378
967
|
]),
|
379
968
|
_: 1
|
380
969
|
}),
|
381
|
-
|
382
|
-
default:
|
383
|
-
|
384
|
-
label:
|
970
|
+
l(u, { span: 12 }, {
|
971
|
+
default: t(() => [
|
972
|
+
l(r, {
|
973
|
+
label: e(a)("menu.affix"),
|
385
974
|
prop: "meta.affix"
|
386
975
|
}, {
|
387
|
-
default:
|
388
|
-
|
389
|
-
modelValue:
|
390
|
-
"onUpdate:modelValue":
|
976
|
+
default: t(() => [
|
977
|
+
l(_, {
|
978
|
+
modelValue: o.meta.affix,
|
979
|
+
"onUpdate:modelValue": n[16] || (n[16] = (c) => o.meta.affix = c)
|
391
980
|
}, null, 8, ["modelValue"])
|
392
981
|
]),
|
393
982
|
_: 1
|
@@ -412,201 +1001,597 @@ const te = /* @__PURE__ */ T({
|
|
412
1001
|
}, 8, ["modelValue", "title", "executing", "onClosed", "onSubmit"]);
|
413
1002
|
};
|
414
1003
|
}
|
415
|
-
})
|
416
|
-
function ue(m) {
|
417
|
-
return typeof m == "function" || Object.prototype.toString.call(m) === "[object Object]" && !G(m);
|
418
|
-
}
|
419
|
-
const re = /* @__PURE__ */ T({
|
1004
|
+
}), Me = /* @__PURE__ */ z({
|
420
1005
|
__name: "index",
|
421
|
-
setup(
|
422
|
-
const
|
1006
|
+
setup(S) {
|
1007
|
+
const x = {
|
423
1008
|
keyword: "",
|
424
1009
|
status: 0
|
425
|
-
},
|
426
|
-
...h
|
427
|
-
}), v = [
|
1010
|
+
}, v = [
|
428
1011
|
{
|
429
|
-
label:
|
1012
|
+
label: a("base.index"),
|
430
1013
|
type: "index",
|
431
1014
|
width: 60
|
432
1015
|
},
|
433
1016
|
{
|
434
|
-
label:
|
1017
|
+
label: a("base.icon"),
|
435
1018
|
prop: "icon",
|
436
1019
|
width: 60,
|
437
1020
|
render: ({
|
438
|
-
row:
|
439
|
-
}) =>
|
440
|
-
class: "iconfont " +
|
1021
|
+
row: m
|
1022
|
+
}) => l("span", {
|
1023
|
+
class: "iconfont " + m.icon,
|
441
1024
|
style: "font-size: 16px;"
|
442
1025
|
}, null)
|
443
1026
|
},
|
444
1027
|
{
|
445
|
-
label:
|
1028
|
+
label: a("menu.module"),
|
446
1029
|
prop: "module",
|
447
1030
|
width: 120
|
448
1031
|
},
|
449
1032
|
{
|
450
|
-
label:
|
1033
|
+
label: a("base.parent"),
|
451
1034
|
prop: "parent",
|
452
1035
|
width: 120,
|
453
1036
|
render: ({
|
454
|
-
row:
|
1037
|
+
row: m
|
455
1038
|
}) => {
|
456
|
-
var
|
457
|
-
return
|
1039
|
+
var g;
|
1040
|
+
return l(K, null, [(g = m.menu) == null ? void 0 : g.name]);
|
458
1041
|
}
|
459
1042
|
},
|
460
1043
|
{
|
461
|
-
label:
|
1044
|
+
label: a("base.name"),
|
462
1045
|
prop: "translate",
|
463
1046
|
width: 120
|
464
1047
|
},
|
465
1048
|
// name 字段优先查看实体内是否有 translate 无则使用name
|
466
1049
|
{
|
467
|
-
label:
|
1050
|
+
label: a("base.url"),
|
468
1051
|
prop: "url",
|
469
1052
|
width: 200
|
470
1053
|
},
|
471
1054
|
{
|
472
|
-
label:
|
1055
|
+
label: a("menu.component"),
|
473
1056
|
prop: "component",
|
474
1057
|
width: 200
|
475
1058
|
},
|
476
1059
|
{
|
477
|
-
label:
|
1060
|
+
label: a("menu.rules"),
|
478
1061
|
prop: "rules",
|
479
1062
|
width: 0,
|
480
1063
|
align: "left",
|
481
1064
|
render: ({
|
482
|
-
row:
|
483
|
-
}) =>
|
1065
|
+
row: m
|
1066
|
+
}) => l(d("el-space"), null, {
|
484
1067
|
default: () => {
|
485
|
-
var
|
486
|
-
return [(
|
487
|
-
key:
|
1068
|
+
var g;
|
1069
|
+
return [(g = m.rules) == null ? void 0 : g.map((V) => l(d("el-tag"), {
|
1070
|
+
key: V.key
|
488
1071
|
}, {
|
489
|
-
default: () => [
|
1072
|
+
default: () => [V.translate]
|
490
1073
|
}))];
|
491
1074
|
}
|
492
1075
|
})
|
493
1076
|
},
|
494
1077
|
{
|
495
|
-
label:
|
1078
|
+
label: a("base.status"),
|
496
1079
|
prop: "status",
|
497
1080
|
width: 80,
|
498
1081
|
type: "switch",
|
499
1082
|
props: {
|
500
1083
|
activeValue: 1,
|
501
1084
|
inactiveValue: 2,
|
502
|
-
api:
|
1085
|
+
api: T.urls[de],
|
503
1086
|
refresh: !0
|
504
1087
|
}
|
505
1088
|
},
|
506
1089
|
{
|
507
1090
|
prop: "action",
|
508
|
-
label:
|
1091
|
+
label: a("base.action"),
|
509
1092
|
width: 60,
|
510
1093
|
align: "center",
|
511
1094
|
render: ({
|
512
|
-
row:
|
513
|
-
}) => {
|
514
|
-
|
515
|
-
|
516
|
-
type: "primary",
|
517
|
-
size: "small",
|
518
|
-
link: !0,
|
519
|
-
onClick: (f) => {
|
520
|
-
f.stopPropagation(), x(r.id);
|
521
|
-
}
|
522
|
-
}, ue(p = o("base.modify")) ? p : {
|
523
|
-
default: () => [p]
|
524
|
-
});
|
525
|
-
}
|
1095
|
+
row: m
|
1096
|
+
}) => l(W, {
|
1097
|
+
onModify: () => w(m.id)
|
1098
|
+
}, null)
|
526
1099
|
}
|
527
|
-
],
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
(r = g.value) == null || r.openOrModify();
|
541
|
-
}, x = (r) => {
|
542
|
-
var p;
|
543
|
-
(p = g.value) == null || p.openOrModify(r);
|
544
|
-
};
|
545
|
-
return (r, p) => {
|
546
|
-
const f = s("el-input"), E = s("el-radio-button"), q = s("el-radio-group"), U = s("el-space"), t = s("el-card");
|
547
|
-
return S(), A(t, {
|
1100
|
+
], {
|
1101
|
+
tableRef: M,
|
1102
|
+
infoRef: o,
|
1103
|
+
keyword: s,
|
1104
|
+
search: b,
|
1105
|
+
refresh: p,
|
1106
|
+
reset: h,
|
1107
|
+
openInfo: k,
|
1108
|
+
modifyInfo: w
|
1109
|
+
} = G(x);
|
1110
|
+
return (m, g) => {
|
1111
|
+
const V = d("el-input"), A = d("el-radio-button"), O = d("el-radio-group"), i = d("el-space"), n = d("el-card");
|
1112
|
+
return C(), L(n, {
|
548
1113
|
class: "basic-card flex-full",
|
549
1114
|
"body-class": "flex-1"
|
550
1115
|
}, {
|
551
|
-
header:
|
1116
|
+
header: t(() => [l(i, {
|
552
1117
|
class: "search-bar"
|
553
1118
|
}, {
|
554
|
-
default:
|
555
|
-
onRefresh:
|
556
|
-
}), e(
|
557
|
-
onOpen:
|
558
|
-
}),
|
1119
|
+
default: t(() => [l(e($), {
|
1120
|
+
onRefresh: e(p)
|
1121
|
+
}, null, 8, ["onRefresh"]), l(e(Q), {
|
1122
|
+
onOpen: e(k)
|
1123
|
+
}, null, 8, ["onOpen"]), l(V, {
|
559
1124
|
class: "basic-search-input",
|
560
|
-
modelValue:
|
561
|
-
"onUpdate:modelValue":
|
562
|
-
placeholder:
|
1125
|
+
modelValue: e(s).keyword,
|
1126
|
+
"onUpdate:modelValue": g[0] || (g[0] = (r) => e(s).keyword = r),
|
1127
|
+
placeholder: e(a)("base.placeholder.keyword"),
|
563
1128
|
clearable: "",
|
564
|
-
onKeyup:
|
565
|
-
onClear:
|
566
|
-
}, null, 8, ["modelValue", "placeholder"]),
|
567
|
-
modelValue:
|
568
|
-
"onUpdate:modelValue":
|
569
|
-
onChange:
|
1129
|
+
onKeyup: P(e(b), ["enter"]),
|
1130
|
+
onClear: e(b)
|
1131
|
+
}, null, 8, ["modelValue", "placeholder", "onKeyup", "onClear"]), l(O, {
|
1132
|
+
modelValue: e(s).status,
|
1133
|
+
"onUpdate:modelValue": g[1] || (g[1] = (r) => e(s).status = r),
|
1134
|
+
onChange: e(b)
|
570
1135
|
}, {
|
571
|
-
default:
|
572
|
-
key:
|
573
|
-
label:
|
574
|
-
value:
|
1136
|
+
default: t(() => [(C(), D(K, null, B([0, 1, 2], (r) => l(A, {
|
1137
|
+
key: r,
|
1138
|
+
label: e(a)(`base.DISABLE_ENABLE.${r}`),
|
1139
|
+
value: r
|
575
1140
|
}, null, 8, ["label", "value"])), 64))]),
|
576
1141
|
_: 1
|
577
|
-
}, 8, ["modelValue"]), e(
|
578
|
-
onSearch:
|
579
|
-
}), e(
|
580
|
-
onReset:
|
581
|
-
})]),
|
1142
|
+
}, 8, ["modelValue", "onChange"]), l(e(X), {
|
1143
|
+
onSearch: e(b)
|
1144
|
+
}, null, 8, ["onSearch"]), l(e(Z), {
|
1145
|
+
onReset: e(h)
|
1146
|
+
}, null, 8, ["onReset"])]),
|
1147
|
+
_: 1
|
1148
|
+
})]),
|
1149
|
+
default: t(() => [l(e(H), {
|
1150
|
+
ref_key: "tableRef",
|
1151
|
+
ref: M,
|
1152
|
+
size: "small",
|
1153
|
+
columns: v,
|
1154
|
+
url: e(T).urls[e(J)],
|
1155
|
+
"search-param": e(s),
|
1156
|
+
autoSearch: ""
|
1157
|
+
}, null, 8, ["url", "search-param"]), l(Se, {
|
1158
|
+
ref_key: "infoRef",
|
1159
|
+
ref: o,
|
1160
|
+
onRefresh: e(h)
|
1161
|
+
}, null, 8, ["onRefresh"])]),
|
1162
|
+
_: 1
|
1163
|
+
});
|
1164
|
+
};
|
1165
|
+
}
|
1166
|
+
}), Ae = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
1167
|
+
__proto__: null,
|
1168
|
+
default: Me
|
1169
|
+
}, Symbol.toStringTag, { value: "Module" })), Oe = { class: "rule-check" }, qe = { style: { width: "80px", "line-height": "36px" } }, Ee = /* @__PURE__ */ z({
|
1170
|
+
__name: "rulesCheck",
|
1171
|
+
props: {
|
1172
|
+
modelValue: { type: Array, required: !0 },
|
1173
|
+
disabled: { type: Boolean, default: !1 }
|
1174
|
+
},
|
1175
|
+
emits: ["update:modelValue"],
|
1176
|
+
setup(S, { expose: x, emit: v }) {
|
1177
|
+
const { requesting: M } = se(T), o = S, s = v, b = oe(!1), p = N({
|
1178
|
+
checkAll: !1,
|
1179
|
+
indeterminate: !1,
|
1180
|
+
MenuAll: {},
|
1181
|
+
MenuList: {},
|
1182
|
+
MenuIndeterminate: {}
|
1183
|
+
}), { options: h, refresh: k } = pe(
|
1184
|
+
ue(o, "modelValue"),
|
1185
|
+
s,
|
1186
|
+
{ key: "RULE_CHECK", api: T, url: T.urls.rules, isArray: !0 },
|
1187
|
+
!1
|
1188
|
+
);
|
1189
|
+
function w() {
|
1190
|
+
h.value.forEach((i) => {
|
1191
|
+
var n;
|
1192
|
+
(n = i.rules) != null && n.length && (p.MenuAll[i.id] = !1, p.MenuIndeterminate[i.id] = !1, p.MenuList[i.id] = []);
|
1193
|
+
});
|
1194
|
+
}
|
1195
|
+
function m(i) {
|
1196
|
+
h.value.forEach((n) => {
|
1197
|
+
var r;
|
1198
|
+
(r = n.rules) != null && r.length && (p.MenuList[n.id] = i ? n.rules.map((u) => u.key) : []);
|
1199
|
+
}), V();
|
1200
|
+
}
|
1201
|
+
function g(i, n) {
|
1202
|
+
const r = h.value.find((u) => u.id === n);
|
1203
|
+
p.MenuList[n] = i && r ? r.rules.map((u) => u.key) : [], V();
|
1204
|
+
}
|
1205
|
+
function V() {
|
1206
|
+
h.value.forEach((i) => {
|
1207
|
+
var u, f;
|
1208
|
+
const n = ((u = i.rules) == null ? void 0 : u.length) || 0, r = ((f = p.MenuList[i.id]) == null ? void 0 : f.length) || 0;
|
1209
|
+
p.MenuAll[i.id] = r === n && n > 0, p.MenuIndeterminate[i.id] = r > 0 && r < n;
|
1210
|
+
}), p.checkAll = Object.values(p.MenuAll).every(Boolean), p.indeterminate = !p.checkAll && Object.values(p.MenuList).some((i) => i.length > 0), s("update:modelValue", Object.values(p.MenuList).flat());
|
1211
|
+
}
|
1212
|
+
function A() {
|
1213
|
+
p.checkAll = !1, p.indeterminate = !1, p.MenuAll = {}, p.MenuList = {}, p.MenuIndeterminate = {}, w(), s("update:modelValue", []), b.value = !1;
|
1214
|
+
}
|
1215
|
+
function O(i) {
|
1216
|
+
var n;
|
1217
|
+
if (Array.isArray(h.value) && h.value.length > 0) {
|
1218
|
+
for (let r of h.value)
|
1219
|
+
if (Array.isArray(r.rules) && r.rules.length > 0)
|
1220
|
+
for (let u of r.rules)
|
1221
|
+
i.some((f) => f === u.key) && (p.MenuList[r.id] = (((n = p.MenuList) == null ? void 0 : n[r.id]) || []).concat([u.key]));
|
1222
|
+
V(), b.value = !0;
|
1223
|
+
}
|
1224
|
+
}
|
1225
|
+
return be(async () => {
|
1226
|
+
var i;
|
1227
|
+
(i = h.value) != null && i.length || await k(), !b.value && o.modelValue && O(o.modelValue);
|
1228
|
+
}), _e(
|
1229
|
+
() => o.modelValue,
|
1230
|
+
(i) => {
|
1231
|
+
ge(() => {
|
1232
|
+
var n;
|
1233
|
+
b.value || !((n = h.value) != null && n.length) || i && i.length > 0 && O(i);
|
1234
|
+
});
|
1235
|
+
},
|
1236
|
+
{ deep: !0, immediate: !0 }
|
1237
|
+
), x({
|
1238
|
+
generateOption: O,
|
1239
|
+
cleanChecked: A
|
1240
|
+
}), (i, n) => {
|
1241
|
+
const r = d("el-checkbox"), u = d("el-space"), f = d("el-text"), U = d("el-divider"), y = d("el-checkbox-group");
|
1242
|
+
return C(), D("div", Oe, [
|
1243
|
+
l(u, { style: { "margin-bottom": "6px" } }, {
|
1244
|
+
default: t(() => [
|
1245
|
+
l(r, {
|
1246
|
+
"model-value": p.checkAll,
|
1247
|
+
indeterminate: p.indeterminate,
|
1248
|
+
id: "all",
|
1249
|
+
disabled: S.disabled,
|
1250
|
+
onChange: m
|
1251
|
+
}, {
|
1252
|
+
default: t(() => n[1] || (n[1] = [
|
1253
|
+
le("span", null, "全选", -1)
|
1254
|
+
])),
|
1255
|
+
_: 1,
|
1256
|
+
__: [1]
|
1257
|
+
}, 8, ["model-value", "indeterminate", "disabled"]),
|
1258
|
+
l(e($), {
|
1259
|
+
loading: e(M),
|
1260
|
+
text: "",
|
1261
|
+
size: "small",
|
1262
|
+
onRefresh: n[0] || (n[0] = (_) => e(k)(!0))
|
1263
|
+
}, null, 8, ["loading"])
|
1264
|
+
]),
|
1265
|
+
_: 1
|
1266
|
+
}),
|
1267
|
+
l(u, {
|
1268
|
+
direction: "vertical",
|
1269
|
+
alignment: "start"
|
1270
|
+
}, {
|
1271
|
+
default: t(() => [
|
1272
|
+
(C(!0), D(K, null, B(e(h), (_) => (C(), D("div", {
|
1273
|
+
key: _.id
|
1274
|
+
}, [
|
1275
|
+
l(u, {
|
1276
|
+
direction: "horizontal",
|
1277
|
+
size: 2
|
1278
|
+
}, {
|
1279
|
+
default: t(() => [
|
1280
|
+
l(r, {
|
1281
|
+
style: { "min-width": "150px" },
|
1282
|
+
"model-value": p.MenuAll[_.id],
|
1283
|
+
disabled: S.disabled || !_.rules || _.rules.length <= 0,
|
1284
|
+
indeterminate: p.MenuIndeterminate[_.id],
|
1285
|
+
onChange: (E) => g(E, _.id)
|
1286
|
+
}, {
|
1287
|
+
default: t(() => [
|
1288
|
+
l(f, { style: { "font-size": "15px" } }, {
|
1289
|
+
default: t(() => [
|
1290
|
+
I(ee(_.translate), 1)
|
1291
|
+
]),
|
1292
|
+
_: 2
|
1293
|
+
}, 1024)
|
1294
|
+
]),
|
1295
|
+
_: 2
|
1296
|
+
}, 1032, ["model-value", "disabled", "indeterminate", "onChange"]),
|
1297
|
+
l(U, { direction: "vertical" }),
|
1298
|
+
_.rules ? (C(), L(y, {
|
1299
|
+
key: 0,
|
1300
|
+
modelValue: p.MenuList[_.id],
|
1301
|
+
"onUpdate:modelValue": (E) => p.MenuList[_.id] = E,
|
1302
|
+
disabled: S.disabled,
|
1303
|
+
style: { margin: "auto" }
|
1304
|
+
}, {
|
1305
|
+
default: t(() => [
|
1306
|
+
(C(!0), D(K, null, B(_.rules, (E) => (C(), L(r, {
|
1307
|
+
key: E.key,
|
1308
|
+
value: E.key
|
1309
|
+
}, {
|
1310
|
+
default: t(() => [
|
1311
|
+
le("div", qe, ee(E.translate), 1)
|
1312
|
+
]),
|
1313
|
+
_: 2
|
1314
|
+
}, 1032, ["value"]))), 128))
|
1315
|
+
]),
|
1316
|
+
_: 2
|
1317
|
+
}, 1032, ["modelValue", "onUpdate:modelValue", "disabled"])) : he("", !0)
|
1318
|
+
]),
|
1319
|
+
_: 2
|
1320
|
+
}, 1024)
|
1321
|
+
]))), 128))
|
1322
|
+
]),
|
1323
|
+
_: 1
|
1324
|
+
})
|
1325
|
+
]);
|
1326
|
+
};
|
1327
|
+
}
|
1328
|
+
}), Le = /* @__PURE__ */ z({
|
1329
|
+
__name: "info",
|
1330
|
+
emits: ["refresh"],
|
1331
|
+
setup(S, { expose: x, emit: v }) {
|
1332
|
+
const M = v, o = oe(), s = N({
|
1333
|
+
key: "",
|
1334
|
+
module: "",
|
1335
|
+
sort: 0,
|
1336
|
+
name: "",
|
1337
|
+
en_name: "",
|
1338
|
+
translate: "",
|
1339
|
+
remark: "",
|
1340
|
+
rules: []
|
1341
|
+
}), b = {
|
1342
|
+
name: [
|
1343
|
+
{ required: !0, message: a("base.placeholder.input base.name"), trigger: "blur" }
|
1344
|
+
],
|
1345
|
+
en_name: [
|
1346
|
+
{ required: !0, message: a("base.placeholder.input base.en_name"), trigger: "blur" }
|
1347
|
+
]
|
1348
|
+
}, { modal: p, title: h, form: k, requesting: w, executing: m, open: g, modify: V, submit: A, closed: O } = F(
|
1349
|
+
M,
|
1350
|
+
s,
|
1351
|
+
ne
|
1352
|
+
), i = (r) => {
|
1353
|
+
r ? (s.key = r, V()) : g();
|
1354
|
+
}, n = () => {
|
1355
|
+
var r;
|
1356
|
+
(r = o.value) == null || r.cleanChecked(), O();
|
1357
|
+
};
|
1358
|
+
return x({
|
1359
|
+
openOrModify: i
|
1360
|
+
}), (r, u) => {
|
1361
|
+
const f = d("el-input"), U = d("el-form-item"), y = d("el-col"), _ = d("el-input-number"), E = d("el-row"), c = d("el-form");
|
1362
|
+
return C(), L(e(Y), {
|
1363
|
+
modelValue: e(p),
|
1364
|
+
"onUpdate:modelValue": u[6] || (u[6] = (q) => j(p) ? p.value = q : null),
|
1365
|
+
title: e(h)(),
|
1366
|
+
width: "900px",
|
1367
|
+
executing: e(m),
|
1368
|
+
onClosed: n,
|
1369
|
+
onSubmit: e(A)
|
1370
|
+
}, {
|
1371
|
+
default: t(() => [
|
1372
|
+
l(c, {
|
1373
|
+
ref_key: "form",
|
1374
|
+
ref: k,
|
1375
|
+
model: s,
|
1376
|
+
"label-width": "auto",
|
1377
|
+
rules: b,
|
1378
|
+
disabled: e(w) || e(m)
|
1379
|
+
}, {
|
1380
|
+
default: t(() => [
|
1381
|
+
l(E, { gutter: 20 }, {
|
1382
|
+
default: t(() => [
|
1383
|
+
l(y, { span: 12 }, {
|
1384
|
+
default: t(() => [
|
1385
|
+
l(U, {
|
1386
|
+
label: e(a)("base.module"),
|
1387
|
+
prop: "module"
|
1388
|
+
}, {
|
1389
|
+
default: t(() => [
|
1390
|
+
l(f, {
|
1391
|
+
modelValue: s.module,
|
1392
|
+
"onUpdate:modelValue": u[0] || (u[0] = (q) => s.module = q),
|
1393
|
+
placeholder: e(a)("base.placeholder.input")
|
1394
|
+
}, null, 8, ["modelValue", "placeholder"])
|
1395
|
+
]),
|
1396
|
+
_: 1
|
1397
|
+
}, 8, ["label"])
|
1398
|
+
]),
|
1399
|
+
_: 1
|
1400
|
+
}),
|
1401
|
+
l(y, { span: 12 }, {
|
1402
|
+
default: t(() => [
|
1403
|
+
l(U, {
|
1404
|
+
label: e(a)("base.sort"),
|
1405
|
+
prop: "sort"
|
1406
|
+
}, {
|
1407
|
+
default: t(() => [
|
1408
|
+
l(_, {
|
1409
|
+
modelValue: s.sort,
|
1410
|
+
"onUpdate:modelValue": u[1] || (u[1] = (q) => s.sort = q),
|
1411
|
+
min: 0,
|
1412
|
+
placeholder: e(a)("base.placeholder.input")
|
1413
|
+
}, null, 8, ["modelValue", "placeholder"])
|
1414
|
+
]),
|
1415
|
+
_: 1
|
1416
|
+
}, 8, ["label"])
|
1417
|
+
]),
|
1418
|
+
_: 1
|
1419
|
+
})
|
1420
|
+
]),
|
1421
|
+
_: 1
|
1422
|
+
}),
|
1423
|
+
l(U, {
|
1424
|
+
label: e(a)("base.name"),
|
1425
|
+
prop: "name"
|
1426
|
+
}, {
|
1427
|
+
default: t(() => [
|
1428
|
+
l(f, {
|
1429
|
+
modelValue: s.name,
|
1430
|
+
"onUpdate:modelValue": u[2] || (u[2] = (q) => s.name = q),
|
1431
|
+
placeholder: e(a)("base.placeholder.input")
|
1432
|
+
}, null, 8, ["modelValue", "placeholder"])
|
1433
|
+
]),
|
1434
|
+
_: 1
|
1435
|
+
}, 8, ["label"]),
|
1436
|
+
l(U, {
|
1437
|
+
label: e(a)("base.en_name"),
|
1438
|
+
prop: "en_name"
|
1439
|
+
}, {
|
1440
|
+
default: t(() => [
|
1441
|
+
l(f, {
|
1442
|
+
modelValue: s.en_name,
|
1443
|
+
"onUpdate:modelValue": u[3] || (u[3] = (q) => s.en_name = q),
|
1444
|
+
placeholder: e(a)("base.placeholder.input")
|
1445
|
+
}, null, 8, ["modelValue", "placeholder"])
|
1446
|
+
]),
|
1447
|
+
_: 1
|
1448
|
+
}, 8, ["label"]),
|
1449
|
+
l(U, {
|
1450
|
+
label: e(a)("base.remark"),
|
1451
|
+
prop: "remark"
|
1452
|
+
}, {
|
1453
|
+
default: t(() => [
|
1454
|
+
l(f, {
|
1455
|
+
modelValue: s.remark,
|
1456
|
+
"onUpdate:modelValue": u[4] || (u[4] = (q) => s.remark = q),
|
1457
|
+
placeholder: e(a)("base.placeholder.input")
|
1458
|
+
}, null, 8, ["modelValue", "placeholder"])
|
1459
|
+
]),
|
1460
|
+
_: 1
|
1461
|
+
}, 8, ["label"]),
|
1462
|
+
l(U, {
|
1463
|
+
label: e(a)("base.rules"),
|
1464
|
+
prop: "rules"
|
1465
|
+
}, {
|
1466
|
+
default: t(() => [
|
1467
|
+
l(Ee, {
|
1468
|
+
ref_key: "rulesCheck",
|
1469
|
+
ref: o,
|
1470
|
+
modelValue: s.rules,
|
1471
|
+
"onUpdate:modelValue": u[5] || (u[5] = (q) => s.rules = q),
|
1472
|
+
disabled: e(w) || e(m)
|
1473
|
+
}, null, 8, ["modelValue", "disabled"])
|
1474
|
+
]),
|
1475
|
+
_: 1
|
1476
|
+
}, 8, ["label"])
|
1477
|
+
]),
|
1478
|
+
_: 1
|
1479
|
+
}, 8, ["model", "disabled"])
|
1480
|
+
]),
|
1481
|
+
_: 1
|
1482
|
+
}, 8, ["modelValue", "title", "executing", "onSubmit"]);
|
1483
|
+
};
|
1484
|
+
}
|
1485
|
+
}), ze = /* @__PURE__ */ z({
|
1486
|
+
__name: "index",
|
1487
|
+
setup(S) {
|
1488
|
+
const x = {
|
1489
|
+
keyword: ""
|
1490
|
+
}, v = [
|
1491
|
+
{
|
1492
|
+
label: a("base.sort"),
|
1493
|
+
prop: "sort",
|
1494
|
+
width: 80
|
1495
|
+
},
|
1496
|
+
{
|
1497
|
+
label: a("base.module"),
|
1498
|
+
prop: "module",
|
1499
|
+
width: 120
|
1500
|
+
},
|
1501
|
+
{
|
1502
|
+
label: a("base.name"),
|
1503
|
+
prop: "translate",
|
1504
|
+
width: 120
|
1505
|
+
},
|
1506
|
+
// name 字段优先查看实体内是否有 translate 无则使用name
|
1507
|
+
{
|
1508
|
+
label: a("base.remark"),
|
1509
|
+
prop: "remark",
|
1510
|
+
width: 0
|
1511
|
+
},
|
1512
|
+
{
|
1513
|
+
label: a("base.created_at"),
|
1514
|
+
prop: "created_at",
|
1515
|
+
width: 180
|
1516
|
+
},
|
1517
|
+
{
|
1518
|
+
prop: "action",
|
1519
|
+
label: a("base.action"),
|
1520
|
+
width: 60,
|
1521
|
+
align: "center",
|
1522
|
+
render: ({
|
1523
|
+
row: m
|
1524
|
+
}) => l(W, {
|
1525
|
+
onModify: () => w(m.key)
|
1526
|
+
}, null)
|
1527
|
+
}
|
1528
|
+
], {
|
1529
|
+
tableRef: M,
|
1530
|
+
infoRef: o,
|
1531
|
+
keyword: s,
|
1532
|
+
search: b,
|
1533
|
+
refresh: p,
|
1534
|
+
reset: h,
|
1535
|
+
openInfo: k,
|
1536
|
+
modifyInfo: w
|
1537
|
+
} = G(x);
|
1538
|
+
return (m, g) => {
|
1539
|
+
const V = d("el-input"), A = d("el-space"), O = d("el-card");
|
1540
|
+
return C(), L(O, {
|
1541
|
+
class: "basic-card flex-full",
|
1542
|
+
"body-class": "flex-1"
|
1543
|
+
}, {
|
1544
|
+
header: t(() => [l(A, {
|
1545
|
+
class: "search-bar"
|
1546
|
+
}, {
|
1547
|
+
default: t(() => [l(e($), {
|
1548
|
+
onRefresh: e(p)
|
1549
|
+
}, null, 8, ["onRefresh"]), l(e(Q), {
|
1550
|
+
onOpen: e(k)
|
1551
|
+
}, null, 8, ["onOpen"]), l(V, {
|
1552
|
+
class: "basic-search-input",
|
1553
|
+
modelValue: e(s).keyword,
|
1554
|
+
"onUpdate:modelValue": g[0] || (g[0] = (i) => e(s).keyword = i),
|
1555
|
+
placeholder: e(a)("base.placeholder.keyword"),
|
1556
|
+
clearable: "",
|
1557
|
+
onKeyup: P(e(b), ["enter"]),
|
1558
|
+
onClear: e(b)
|
1559
|
+
}, null, 8, ["modelValue", "placeholder", "onKeyup", "onClear"]), l(e(X), {
|
1560
|
+
onSearch: e(b)
|
1561
|
+
}, null, 8, ["onSearch"]), l(e(Z), {
|
1562
|
+
onReset: e(h)
|
1563
|
+
}, null, 8, ["onReset"])]),
|
582
1564
|
_: 1
|
583
1565
|
})]),
|
584
|
-
default:
|
585
|
-
ref_key: "
|
586
|
-
ref:
|
1566
|
+
default: t(() => [l(e(H), {
|
1567
|
+
ref_key: "tableRef",
|
1568
|
+
ref: M,
|
587
1569
|
size: "small",
|
588
1570
|
columns: v,
|
589
|
-
url:
|
590
|
-
"search-param":
|
1571
|
+
url: e(ne).urls[e(J)],
|
1572
|
+
"search-param": e(s),
|
591
1573
|
autoSearch: ""
|
592
|
-
}, null, 8, ["url", "search-param"]),
|
1574
|
+
}, null, 8, ["url", "search-param"]), l(Le, {
|
593
1575
|
ref_key: "infoRef",
|
594
|
-
ref:
|
595
|
-
onRefresh:
|
596
|
-
}, null,
|
1576
|
+
ref: o,
|
1577
|
+
onRefresh: e(h)
|
1578
|
+
}, null, 8, ["onRefresh"])]),
|
597
1579
|
_: 1
|
598
1580
|
});
|
599
1581
|
};
|
600
1582
|
}
|
601
|
-
}),
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
1583
|
+
}), Te = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
1584
|
+
__proto__: null,
|
1585
|
+
default: ze
|
1586
|
+
}, Symbol.toStringTag, { value: "Module" })), Ke = {
|
1587
|
+
install: (S, x) => {
|
1588
|
+
Reflect.ownKeys(S._context.provides).some((v) => String(v) === "Symbol(pinia)") || console.warn("Pinia is not provided. Please install and provide Pinia in your app."), console.log(Reflect.ownKeys(S._context.provides));
|
606
1589
|
},
|
607
1590
|
version: "__VERSION__"
|
608
|
-
};
|
1591
|
+
}, $e = /* @__PURE__ */ Object.assign({ "./views/admin/index.vue": we, "./views/language/index.vue": Re, "./views/menu/index.vue": Ae, "./views/role/index.vue": Te });
|
609
1592
|
export {
|
610
|
-
|
611
|
-
|
1593
|
+
Me as MenusPage,
|
1594
|
+
ze as RolesPage,
|
1595
|
+
$e as basicModules,
|
1596
|
+
Ke as default
|
612
1597
|
};
|