xto-fronted 0.8.0 → 0.8.1

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.
Files changed (93) hide show
  1. package/dist/assets/404-CY9lyBR9.css +1 -0
  2. package/dist/assets/404-CrEsfqtj.js +1 -0
  3. package/dist/assets/_plugin-vue_export-helper-DlAUqK2U.js +1 -0
  4. package/dist/assets/index-B8nBpy4E.js +1 -0
  5. package/dist/assets/index-BRR97dc6.js +1 -0
  6. package/dist/assets/index-BchLHHD-.css +1 -0
  7. package/dist/assets/index-BgU3HbjQ.css +1 -0
  8. package/dist/assets/index-BqdOxC5B.css +1 -0
  9. package/dist/assets/index-CLoZtSK2.js +1 -0
  10. package/dist/assets/index-CkkPiTqE.css +1 -0
  11. package/dist/assets/index-Cpnd7UnC.js +1 -0
  12. package/dist/assets/index-Cv0DrTS-.js +1 -0
  13. package/dist/assets/index-D2kfHtV2.css +1 -0
  14. package/dist/assets/index-DZHiLIP4.css +1 -0
  15. package/dist/assets/index-DqSiKlWQ.js +1 -0
  16. package/dist/assets/index-MvUmFZ7W.css +1 -0
  17. package/dist/assets/index-tlMkJQ1U.js +2 -0
  18. package/dist/assets/index-yH64PBmh.js +1 -0
  19. package/dist/assets/vendor-CWD9azq9.js +16 -0
  20. package/dist/assets/vue-vendor-DPUDwD81.js +29 -0
  21. package/dist/assets/xto-base-CzY-OLba.css +1 -0
  22. package/dist/assets/xto-base-S7v-4JRL.js +1 -0
  23. package/dist/assets/xto-business-ClDUYOqW.css +1 -0
  24. package/dist/assets/xto-core-CYfxJQ6k.js +1 -0
  25. package/dist/assets/xto-data-CAFnD72s.js +1 -0
  26. package/dist/assets/xto-data-D9f39fBv.css +1 -0
  27. package/dist/assets/xto-feedback-CgD78aUG.js +1 -0
  28. package/dist/assets/xto-feedback-a2I9QN4T.css +1 -0
  29. package/dist/assets/xto-form-DK8siTEV.css +1 -0
  30. package/dist/assets/xto-form-DjKbHEb9.js +1 -0
  31. package/dist/assets/xto-layout-Bh9dSMYc.css +1 -0
  32. package/dist/assets/xto-navigation-S9LTvyP5.css +1 -0
  33. package/dist/assets/xto-navigation-p1HtLM39.js +1 -0
  34. package/dist/index.html +28 -0
  35. package/package.json +1 -1
  36. package/src/components/Layout/MixTopMenu.vue +17 -17
  37. package/src/components/Layout/Sidebar.vue +1 -1
  38. package/src/components/Layout/TopMenu.vue +17 -17
  39. package/dist/App.vue.d.ts +0 -2
  40. package/dist/api/auth.d.ts +0 -8
  41. package/dist/api/index.d.ts +0 -6
  42. package/dist/api/index.js +0 -26
  43. package/dist/api/system.d.ts +0 -16
  44. package/dist/api/user.d.ts +0 -13
  45. package/dist/api.d.ts +0 -2
  46. package/dist/components/Layout/Footer.vue.d.ts +0 -2
  47. package/dist/components/Layout/Header.vue.d.ts +0 -5
  48. package/dist/components/Layout/MixTopMenu.vue.d.ts +0 -10
  49. package/dist/components/Layout/Sidebar.vue.d.ts +0 -13
  50. package/dist/components/Layout/SidebarMenuItem.vue.d.ts +0 -5
  51. package/dist/components/Layout/Tabs.vue.d.ts +0 -2
  52. package/dist/components/Layout/TopMenu.vue.d.ts +0 -10
  53. package/dist/components/Layout/index.vue.d.ts +0 -7
  54. package/dist/composables/useApp.d.ts +0 -30
  55. package/dist/composables/useAuth.d.ts +0 -6
  56. package/dist/composables/useForm.d.ts +0 -20
  57. package/dist/composables/useI18n.d.ts +0 -30
  58. package/dist/composables/useTable.d.ts +0 -29
  59. package/dist/directives/permission.d.ts +0 -4
  60. package/dist/enums/index.d.ts +0 -32
  61. package/dist/index-D73_-C9m.js +0 -515
  62. package/dist/index-DBjV4kzh.js +0 -249
  63. package/dist/index-DJ1oHe08.js +0 -3233
  64. package/dist/index-D_TGEwDg.js +0 -693
  65. package/dist/index-DauAWAHG.js +0 -479
  66. package/dist/index.d.ts +0 -63
  67. package/dist/index.js +0 -99
  68. package/dist/main.d.ts +0 -0
  69. package/dist/router/dynamicRoutes.d.ts +0 -30
  70. package/dist/router/guards.d.ts +0 -17
  71. package/dist/router/index.d.ts +0 -6
  72. package/dist/router/layoutRoute.d.ts +0 -23
  73. package/dist/router/staticRoutes.d.ts +0 -2
  74. package/dist/stores/app.d.ts +0 -99
  75. package/dist/stores/auth.d.ts +0 -41
  76. package/dist/stores/index.d.ts +0 -10
  77. package/dist/stores/locale.d.ts +0 -42
  78. package/dist/stores/menu.d.ts +0 -83
  79. package/dist/stores/user.d.ts +0 -101
  80. package/dist/style.css +0 -1
  81. package/dist/user-77I_qZ8j.js +0 -1186
  82. package/dist/utils/auth.d.ts +0 -27
  83. package/dist/utils/config.d.ts +0 -51
  84. package/dist/utils/permission.d.ts +0 -17
  85. package/dist/utils/request.d.ts +0 -34
  86. package/dist/utils/storage.d.ts +0 -24
  87. package/dist/views/dashboard/index.vue.d.ts +0 -2
  88. package/dist/views/error/403.vue.d.ts +0 -2
  89. package/dist/views/error/404.vue.d.ts +0 -2
  90. package/dist/views/login/index.vue.d.ts +0 -4
  91. package/dist/views/system/menu/index.vue.d.ts +0 -4
  92. package/dist/views/system/role/index.vue.d.ts +0 -4
  93. package/dist/views/system/user/index.vue.d.ts +0 -4
@@ -1,693 +0,0 @@
1
- import { defineComponent as $, ref as V, computed as j, reactive as F, onMounted as H, openBlock as p, createElementBlock as c, createElementVNode as e, createVNode as o, unref as s, withCtx as a, createTextVNode as v, toDisplayString as i, Fragment as x, renderList as U, createCommentVNode as O } from "vue";
2
- import { Form as Z, FormItem as m, Input as h, Select as q, InputNumber as Y, Switch as w } from "@xto/form";
3
- import { Tag as E } from "@xto/data";
4
- import { Modal as G, Message as J } from "@xto/feedback";
5
- import { Button as y, Space as C } from "@xto/base";
6
- import { S as r, M as f, b as K, _ as P } from "./index-DJ1oHe08.js";
7
- const Q = { class: "menu-page" }, W = { class: "table-section" }, X = { class: "table-toolbar" }, ee = { class: "toolbar-left" }, te = { class: "toolbar-right" }, se = { class: "table-count" }, le = { class: "table-wrapper" }, oe = { class: "data-table" }, ae = { key: 0 }, ne = { key: 1 }, de = { class: "data-row tree-row--level-0" }, ie = { class: "col-name" }, re = { class: "menu-info" }, ue = { class: "menu-icon-wrapper" }, pe = {
8
- viewBox: "0 0 24 24",
9
- fill: "none",
10
- stroke: "currentColor",
11
- "stroke-width": "1.8",
12
- "stroke-linecap": "round",
13
- "stroke-linejoin": "round"
14
- }, ce = ["d"], me = ["onClick"], fe = { class: "col-icon" }, ve = { class: "icon-text" }, _e = {
15
- viewBox: "0 0 24 24",
16
- fill: "none",
17
- stroke: "currentColor",
18
- "stroke-width": "1.8",
19
- "stroke-linecap": "round",
20
- "stroke-linejoin": "round"
21
- }, he = ["d"], ye = { class: "col-path" }, ke = { class: "path-code" }, ge = { class: "col-type" }, be = { class: "col-sort" }, Ve = { class: "sort-badge" }, Ee = { class: "col-status" }, Me = { class: "col-actions" }, xe = { class: "col-name" }, we = { class: "menu-info" }, Ce = { class: "menu-icon-wrapper" }, Ae = {
22
- viewBox: "0 0 24 24",
23
- fill: "none",
24
- stroke: "currentColor",
25
- "stroke-width": "1.8",
26
- "stroke-linecap": "round",
27
- "stroke-linejoin": "round"
28
- }, Be = ["d"], Ne = ["onClick"], De = { class: "col-icon" }, Le = { class: "icon-text" }, Ue = {
29
- viewBox: "0 0 24 24",
30
- fill: "none",
31
- stroke: "currentColor",
32
- "stroke-width": "1.8",
33
- "stroke-linecap": "round",
34
- "stroke-linejoin": "round"
35
- }, Ie = ["d"], Te = { class: "col-path" }, ze = { class: "path-code" }, Se = { class: "col-type" }, Re = { class: "col-sort" }, $e = { class: "sort-badge" }, je = { class: "col-status" }, Fe = { class: "col-actions" }, He = { class: "form-grid" }, Oe = { class: "status-field" }, Ze = { class: "status-label" }, qe = { class: "status-field" }, Ye = { class: "status-label" }, Ge = { class: "status-field" }, Je = { class: "status-label" }, Ke = /* @__PURE__ */ $({
36
- __name: "index",
37
- setup(Pe) {
38
- const I = [
39
- {
40
- id: 1,
41
- parentId: null,
42
- name: "Dashboard",
43
- path: "/dashboard",
44
- component: "dashboard/index",
45
- redirect: "",
46
- icon: "dashboard",
47
- title: "仪表盘",
48
- type: f.MENU,
49
- sort: 1,
50
- status: r.ENABLED,
51
- hidden: !1,
52
- keepAlive: !0
53
- },
54
- {
55
- id: 2,
56
- parentId: null,
57
- name: "System",
58
- path: "/system",
59
- component: "",
60
- redirect: "/system/user",
61
- icon: "setting",
62
- title: "系统管理",
63
- type: f.DIRECTORY,
64
- sort: 2,
65
- status: r.ENABLED,
66
- hidden: !1,
67
- keepAlive: !1,
68
- children: [
69
- {
70
- id: 21,
71
- parentId: 2,
72
- name: "SystemUser",
73
- path: "/system/user",
74
- component: "system/user/index",
75
- redirect: "",
76
- icon: "user",
77
- title: "用户管理",
78
- type: f.MENU,
79
- sort: 1,
80
- status: r.ENABLED,
81
- hidden: !1,
82
- keepAlive: !0
83
- },
84
- {
85
- id: 22,
86
- parentId: 2,
87
- name: "SystemRole",
88
- path: "/system/role",
89
- component: "system/role/index",
90
- redirect: "",
91
- icon: "role",
92
- title: "角色管理",
93
- type: f.MENU,
94
- sort: 2,
95
- status: r.ENABLED,
96
- hidden: !1,
97
- keepAlive: !0
98
- },
99
- {
100
- id: 23,
101
- parentId: 2,
102
- name: "SystemMenu",
103
- path: "/system/menu",
104
- component: "system/menu/index",
105
- redirect: "",
106
- icon: "menu",
107
- title: "菜单管理",
108
- type: f.MENU,
109
- sort: 3,
110
- status: r.ENABLED,
111
- hidden: !1,
112
- keepAlive: !0
113
- }
114
- ]
115
- }
116
- ], M = V(!1), k = V([]), _ = V(!1), T = j(() => n.id ? "编辑菜单" : "新增菜单"), n = F({
117
- id: 0,
118
- parentId: null,
119
- name: "",
120
- path: "",
121
- component: "",
122
- redirect: "",
123
- icon: "",
124
- title: "",
125
- type: f.MENU,
126
- sort: 0,
127
- status: r.ENABLED,
128
- hidden: !1,
129
- keepAlive: !0
130
- }), z = {
131
- name: [
132
- { required: !0, message: "请输入菜单名称", trigger: "blur" }
133
- ],
134
- path: [
135
- { required: !0, message: "请输入路由路径", trigger: "blur" }
136
- ],
137
- title: [
138
- { required: !0, message: "请输入菜单标题", trigger: "blur" }
139
- ]
140
- }, A = V(), B = () => {
141
- M.value = !0, setTimeout(() => {
142
- k.value = I, M.value = !1;
143
- }, 300);
144
- }, N = (u = null) => {
145
- Object.assign(n, {
146
- id: 0,
147
- parentId: u,
148
- name: "",
149
- path: "",
150
- component: "",
151
- redirect: "",
152
- icon: "",
153
- title: "",
154
- type: f.MENU,
155
- sort: 0,
156
- status: r.ENABLED,
157
- hidden: !1,
158
- keepAlive: !0
159
- }), _.value = !0;
160
- }, g = (u) => {
161
- Object.assign(n, u), _.value = !0;
162
- }, S = async () => {
163
- var u;
164
- try {
165
- await ((u = A.value) == null ? void 0 : u.validate()), J.success(n.id ? "编辑成功" : "新增成功"), _.value = !1, B();
166
- } catch (t) {
167
- console.error(t);
168
- }
169
- }, b = (u) => ({
170
- dashboard: "M4 5h16v11H4zM9 20h6M12 16v4",
171
- system: "M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6Zm7.4-3c0-.4 0-.8-.1-1.2l2-1.6-2-3.4-2.4 1a7.6 7.6 0 0 0-2-1.2L14.5 3h-5l-.4 2.6a7.6 7.6 0 0 0-2 1.2l-2.4-1-2 3.4 2 1.6a7.4 7.4 0 0 0 0 2.4l-2 1.6 2 3.4 2.4-1a7.6 7.6 0 0 0 2 1.2l.4 2.6h5l.4-2.6a7.6 7.6 0 0 0 2-1.2l2.4 1 2-3.4-2-1.6c.1-.4.1-.8.1-1.2Z",
172
- user: "M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8Zm-7 8a7 7 0 0 1 14 0",
173
- role: "M8 11a3 3 0 1 0 0-6 3 3 0 0 0 0 6Zm8 0a3 3 0 1 0 0-6 3 3 0 0 0 0 6ZM2 19a6 6 0 0 1 12 0m2-6a6 6 0 0 1 6 6",
174
- menu: "M4 6h16M4 12h16M4 18h10",
175
- setting: "M4 6h16M4 12h16M4 18h16"
176
- })[u || ""] || "M4 6h16M4 12h16M4 18h10", D = (u) => {
177
- switch (u) {
178
- case f.DIRECTORY:
179
- return "primary";
180
- case f.MENU:
181
- return "success";
182
- default:
183
- return "warning";
184
- }
185
- }, L = (u) => {
186
- switch (u) {
187
- case f.DIRECTORY:
188
- return "目录";
189
- case f.MENU:
190
- return "菜单";
191
- default:
192
- return "按钮";
193
- }
194
- };
195
- return H(() => {
196
- B();
197
- }), (u, t) => (p(), c("div", Q, [
198
- e("div", W, [
199
- e("div", X, [
200
- e("div", ee, [
201
- o(s(y), {
202
- type: "primary",
203
- onClick: t[0] || (t[0] = (l) => N())
204
- }, {
205
- icon: a(() => [...t[14] || (t[14] = [
206
- e("svg", {
207
- viewBox: "0 0 24 24",
208
- fill: "none",
209
- stroke: "currentColor",
210
- "stroke-width": "2"
211
- }, [
212
- e("line", {
213
- x1: "12",
214
- y1: "5",
215
- x2: "12",
216
- y2: "19"
217
- }),
218
- e("line", {
219
- x1: "5",
220
- y1: "12",
221
- x2: "19",
222
- y2: "12"
223
- })
224
- ], -1)
225
- ])]),
226
- default: a(() => [
227
- t[15] || (t[15] = v(" 新增菜单 ", -1))
228
- ]),
229
- _: 1
230
- })
231
- ]),
232
- e("div", te, [
233
- e("span", se, "共 " + i(k.value.length) + " 个菜单", 1)
234
- ])
235
- ]),
236
- e("div", le, [
237
- e("table", oe, [
238
- t[26] || (t[26] = e("thead", null, [
239
- e("tr", null, [
240
- e("th", { class: "col-name" }, "菜单名称"),
241
- e("th", { class: "col-icon" }, "图标"),
242
- e("th", { class: "col-path" }, "路由路径"),
243
- e("th", { class: "col-type" }, "类型"),
244
- e("th", { class: "col-sort" }, "排序"),
245
- e("th", { class: "col-status" }, "状态"),
246
- e("th", { class: "col-actions" }, "操作")
247
- ])
248
- ], -1)),
249
- e("tbody", null, [
250
- M.value ? (p(), c("tr", ae, [...t[16] || (t[16] = [
251
- e("td", {
252
- colspan: "7",
253
- class: "loading-cell"
254
- }, [
255
- e("div", { class: "loading-content" }, [
256
- e("div", { class: "loading-spinner" }),
257
- e("span", null, "加载中...")
258
- ])
259
- ], -1)
260
- ])])) : k.value.length === 0 ? (p(), c("tr", ne, [...t[17] || (t[17] = [
261
- e("td", {
262
- colspan: "7",
263
- class: "empty-cell"
264
- }, [
265
- e("div", { class: "empty-content" }, [
266
- e("svg", {
267
- viewBox: "0 0 64 41",
268
- fill: "none"
269
- }, [
270
- e("g", { transform: "translate(0 1)" }, [
271
- e("ellipse", {
272
- fill: "#f5f5f5",
273
- cx: "32",
274
- cy: "33",
275
- rx: "32",
276
- ry: "7"
277
- }),
278
- e("g", {
279
- stroke: "var(--xto-color-text-placeholder, #A9AEB8)",
280
- "stroke-width": "2"
281
- }, [
282
- e("path", { d: "M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z" }),
283
- e("path", {
284
- d: "M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35H11.95C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",
285
- fill: "var(--xto-fill-color, #F2F3F5)"
286
- })
287
- ])
288
- ])
289
- ]),
290
- e("span", null, "暂无数据")
291
- ])
292
- ], -1)
293
- ])])) : (p(!0), c(x, { key: 2 }, U(k.value, (l) => (p(), c(x, {
294
- key: l.id
295
- }, [
296
- e("tr", de, [
297
- e("td", ie, [
298
- e("div", re, [
299
- e("span", ue, [
300
- (p(), c("svg", pe, [
301
- e("path", {
302
- d: b(l.icon)
303
- }, null, 8, ce)
304
- ]))
305
- ]),
306
- e("span", {
307
- class: "menu-title",
308
- onClick: (d) => g(l)
309
- }, i(l.title), 9, me)
310
- ])
311
- ]),
312
- e("td", fe, [
313
- e("span", ve, [
314
- (p(), c("svg", _e, [
315
- e("path", {
316
- d: b(l.icon)
317
- }, null, 8, he)
318
- ]))
319
- ])
320
- ]),
321
- e("td", ye, [
322
- e("code", ke, i(l.path), 1)
323
- ]),
324
- e("td", ge, [
325
- o(s(E), {
326
- type: D(l.type),
327
- size: "small"
328
- }, {
329
- default: a(() => [
330
- v(i(L(l.type)), 1)
331
- ]),
332
- _: 2
333
- }, 1032, ["type"])
334
- ]),
335
- e("td", be, [
336
- e("span", Ve, i(l.sort), 1)
337
- ]),
338
- e("td", Ee, [
339
- o(s(E), {
340
- type: l.status === s(r).ENABLED ? "success" : "danger",
341
- size: "small"
342
- }, {
343
- default: a(() => [
344
- v(i(l.status === s(r).ENABLED ? "启用" : "禁用"), 1)
345
- ]),
346
- _: 2
347
- }, 1032, ["type"])
348
- ]),
349
- e("td", Me, [
350
- o(s(C), { class: "action-buttons" }, {
351
- default: a(() => [
352
- o(s(y), {
353
- type: "primary",
354
- link: "",
355
- size: "small",
356
- onClick: (d) => N(l.id)
357
- }, {
358
- icon: a(() => [...t[18] || (t[18] = [
359
- e("svg", {
360
- viewBox: "0 0 24 24",
361
- fill: "none",
362
- stroke: "currentColor",
363
- "stroke-width": "2"
364
- }, [
365
- e("line", {
366
- x1: "12",
367
- y1: "5",
368
- x2: "12",
369
- y2: "19"
370
- }),
371
- e("line", {
372
- x1: "5",
373
- y1: "12",
374
- x2: "19",
375
- y2: "12"
376
- })
377
- ], -1)
378
- ])]),
379
- default: a(() => [
380
- t[19] || (t[19] = v(" 新增 ", -1))
381
- ]),
382
- _: 1
383
- }, 8, ["onClick"]),
384
- o(s(y), {
385
- type: "primary",
386
- link: "",
387
- size: "small",
388
- onClick: (d) => g(l)
389
- }, {
390
- icon: a(() => [...t[20] || (t[20] = [
391
- e("svg", {
392
- viewBox: "0 0 24 24",
393
- fill: "none",
394
- stroke: "currentColor",
395
- "stroke-width": "2"
396
- }, [
397
- e("path", { d: "M11 4H4a2 2 0 00-2 2v14a2 2 0 002 2h14a2 2 0 002-2v-7" }),
398
- e("path", { d: "M18.5 2.5a2.121 2.121 0 013 3L12 15l-4 1 1-4 9.5-9.5z" })
399
- ], -1)
400
- ])]),
401
- default: a(() => [
402
- t[21] || (t[21] = v(" 编辑 ", -1))
403
- ]),
404
- _: 1
405
- }, 8, ["onClick"])
406
- ]),
407
- _: 2
408
- }, 1024)
409
- ])
410
- ]),
411
- l.children ? (p(!0), c(x, { key: 0 }, U(l.children, (d) => (p(), c("tr", {
412
- key: d.id,
413
- class: "data-row tree-row--level-1"
414
- }, [
415
- e("td", xe, [
416
- e("div", we, [
417
- t[22] || (t[22] = e("span", { class: "tree-indent" }, null, -1)),
418
- t[23] || (t[23] = e("span", { class: "tree-line" }, null, -1)),
419
- e("span", Ce, [
420
- (p(), c("svg", Ae, [
421
- e("path", {
422
- d: b(d.icon)
423
- }, null, 8, Be)
424
- ]))
425
- ]),
426
- e("span", {
427
- class: "menu-title",
428
- onClick: (R) => g(d)
429
- }, i(d.title), 9, Ne)
430
- ])
431
- ]),
432
- e("td", De, [
433
- e("span", Le, [
434
- (p(), c("svg", Ue, [
435
- e("path", {
436
- d: b(d.icon)
437
- }, null, 8, Ie)
438
- ]))
439
- ])
440
- ]),
441
- e("td", Te, [
442
- e("code", ze, i(d.path), 1)
443
- ]),
444
- e("td", Se, [
445
- o(s(E), {
446
- type: D(d.type),
447
- size: "small"
448
- }, {
449
- default: a(() => [
450
- v(i(L(d.type)), 1)
451
- ]),
452
- _: 2
453
- }, 1032, ["type"])
454
- ]),
455
- e("td", Re, [
456
- e("span", $e, i(d.sort), 1)
457
- ]),
458
- e("td", je, [
459
- o(s(E), {
460
- type: d.status === s(r).ENABLED ? "success" : "danger",
461
- size: "small"
462
- }, {
463
- default: a(() => [
464
- v(i(d.status === s(r).ENABLED ? "启用" : "禁用"), 1)
465
- ]),
466
- _: 2
467
- }, 1032, ["type"])
468
- ]),
469
- e("td", Fe, [
470
- o(s(C), { class: "action-buttons" }, {
471
- default: a(() => [
472
- o(s(y), {
473
- type: "primary",
474
- link: "",
475
- size: "small",
476
- onClick: (R) => g(d)
477
- }, {
478
- icon: a(() => [...t[24] || (t[24] = [
479
- e("svg", {
480
- viewBox: "0 0 24 24",
481
- fill: "none",
482
- stroke: "currentColor",
483
- "stroke-width": "2"
484
- }, [
485
- e("path", { d: "M11 4H4a2 2 0 00-2 2v14a2 2 0 002 2h14a2 2 0 002-2v-7" }),
486
- e("path", { d: "M18.5 2.5a2.121 2.121 0 013 3L12 15l-4 1 1-4 9.5-9.5z" })
487
- ], -1)
488
- ])]),
489
- default: a(() => [
490
- t[25] || (t[25] = v(" 编辑 ", -1))
491
- ]),
492
- _: 1
493
- }, 8, ["onClick"])
494
- ]),
495
- _: 2
496
- }, 1024)
497
- ])
498
- ]))), 128)) : O("", !0)
499
- ], 64))), 128))
500
- ])
501
- ])
502
- ])
503
- ]),
504
- o(s(G), {
505
- modelValue: _.value,
506
- "onUpdate:modelValue": t[13] || (t[13] = (l) => _.value = l),
507
- title: T.value,
508
- width: "600px",
509
- class: "menu-modal"
510
- }, {
511
- footer: a(() => [
512
- o(s(C), null, {
513
- default: a(() => [
514
- o(s(y), {
515
- onClick: t[12] || (t[12] = (l) => _.value = !1)
516
- }, {
517
- default: a(() => [...t[27] || (t[27] = [
518
- v("取消", -1)
519
- ])]),
520
- _: 1
521
- }),
522
- o(s(y), {
523
- type: "primary",
524
- onClick: S
525
- }, {
526
- default: a(() => [...t[28] || (t[28] = [
527
- v("确定", -1)
528
- ])]),
529
- _: 1
530
- })
531
- ]),
532
- _: 1
533
- })
534
- ]),
535
- default: a(() => [
536
- o(s(Z), {
537
- ref_key: "formRef",
538
- ref: A,
539
- model: n,
540
- rules: z,
541
- "label-width": "80px",
542
- class: "menu-form"
543
- }, {
544
- default: a(() => [
545
- e("div", He, [
546
- o(s(m), {
547
- label: "上级菜单",
548
- class: "form-item-full"
549
- }, {
550
- default: a(() => [
551
- o(s(h), {
552
- modelValue: n.parentId,
553
- "onUpdate:modelValue": t[1] || (t[1] = (l) => n.parentId = l),
554
- placeholder: "上级菜单ID",
555
- disabled: ""
556
- }, null, 8, ["modelValue"])
557
- ]),
558
- _: 1
559
- }),
560
- o(s(m), { label: "菜单类型" }, {
561
- default: a(() => [
562
- o(s(q), {
563
- modelValue: n.type,
564
- "onUpdate:modelValue": t[2] || (t[2] = (l) => n.type = l),
565
- options: s(K)
566
- }, null, 8, ["modelValue", "options"])
567
- ]),
568
- _: 1
569
- }),
570
- o(s(m), { label: "排序" }, {
571
- default: a(() => [
572
- o(s(Y), {
573
- modelValue: n.sort,
574
- "onUpdate:modelValue": t[3] || (t[3] = (l) => n.sort = l),
575
- min: 0
576
- }, null, 8, ["modelValue"])
577
- ]),
578
- _: 1
579
- }),
580
- o(s(m), {
581
- label: "菜单名称",
582
- prop: "name"
583
- }, {
584
- default: a(() => [
585
- o(s(h), {
586
- modelValue: n.name,
587
- "onUpdate:modelValue": t[4] || (t[4] = (l) => n.name = l),
588
- placeholder: "请输入菜单名称(路由name)"
589
- }, null, 8, ["modelValue"])
590
- ]),
591
- _: 1
592
- }),
593
- o(s(m), {
594
- label: "菜单标题",
595
- prop: "title"
596
- }, {
597
- default: a(() => [
598
- o(s(h), {
599
- modelValue: n.title,
600
- "onUpdate:modelValue": t[5] || (t[5] = (l) => n.title = l),
601
- placeholder: "请输入菜单标题"
602
- }, null, 8, ["modelValue"])
603
- ]),
604
- _: 1
605
- }),
606
- o(s(m), {
607
- label: "路由路径",
608
- prop: "path",
609
- class: "form-item-full"
610
- }, {
611
- default: a(() => [
612
- o(s(h), {
613
- modelValue: n.path,
614
- "onUpdate:modelValue": t[6] || (t[6] = (l) => n.path = l),
615
- placeholder: "请输入路由路径"
616
- }, null, 8, ["modelValue"])
617
- ]),
618
- _: 1
619
- }),
620
- o(s(m), {
621
- label: "组件路径",
622
- class: "form-item-full"
623
- }, {
624
- default: a(() => [
625
- o(s(h), {
626
- modelValue: n.component,
627
- "onUpdate:modelValue": t[7] || (t[7] = (l) => n.component = l),
628
- placeholder: "请输入组件路径"
629
- }, null, 8, ["modelValue"])
630
- ]),
631
- _: 1
632
- }),
633
- o(s(m), { label: "图标" }, {
634
- default: a(() => [
635
- o(s(h), {
636
- modelValue: n.icon,
637
- "onUpdate:modelValue": t[8] || (t[8] = (l) => n.icon = l),
638
- placeholder: "请输入图标名称"
639
- }, null, 8, ["modelValue"])
640
- ]),
641
- _: 1
642
- }),
643
- o(s(m), { label: "状态" }, {
644
- default: a(() => [
645
- e("div", Oe, [
646
- o(s(w), {
647
- modelValue: n.status,
648
- "onUpdate:modelValue": t[9] || (t[9] = (l) => n.status = l),
649
- "active-value": s(r).ENABLED,
650
- "inactive-value": s(r).DISABLED
651
- }, null, 8, ["modelValue", "active-value", "inactive-value"]),
652
- e("span", Ze, i(n.status === s(r).ENABLED ? "启用" : "禁用"), 1)
653
- ])
654
- ]),
655
- _: 1
656
- }),
657
- o(s(m), { label: "隐藏" }, {
658
- default: a(() => [
659
- e("div", qe, [
660
- o(s(w), {
661
- modelValue: n.hidden,
662
- "onUpdate:modelValue": t[10] || (t[10] = (l) => n.hidden = l)
663
- }, null, 8, ["modelValue"]),
664
- e("span", Ye, i(n.hidden ? "隐藏" : "显示"), 1)
665
- ])
666
- ]),
667
- _: 1
668
- }),
669
- o(s(m), { label: "缓存" }, {
670
- default: a(() => [
671
- e("div", Ge, [
672
- o(s(w), {
673
- modelValue: n.keepAlive,
674
- "onUpdate:modelValue": t[11] || (t[11] = (l) => n.keepAlive = l)
675
- }, null, 8, ["modelValue"]),
676
- e("span", Je, i(n.keepAlive ? "开启" : "关闭"), 1)
677
- ])
678
- ]),
679
- _: 1
680
- })
681
- ])
682
- ]),
683
- _: 1
684
- }, 8, ["model"])
685
- ]),
686
- _: 1
687
- }, 8, ["modelValue", "title"])
688
- ]));
689
- }
690
- }), lt = /* @__PURE__ */ P(Ke, [["__scopeId", "data-v-f29bada8"]]);
691
- export {
692
- lt as default
693
- };