@skyfox2000/webui 1.4.21 → 1.4.23

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 (44) hide show
  1. package/lib/assets/modules/{baseLayout-Da4Ox7Lj.js → baseLayout-DiqAUz2h.js} +3 -3
  2. package/lib/assets/modules/{file-upload-Bu6FkNjZ.js → file-upload-CKMd0H11.js} +1 -1
  3. package/lib/assets/modules/{index-Ch3meKe4.js → index-BpsqYPCw.js} +1 -1
  4. package/lib/assets/modules/{index-BYVerdEw.js → index-DvozNhVM.js} +2 -2
  5. package/lib/assets/modules/{index-BysCt107.js → index-gmbMtZa2.js} +2 -2
  6. package/lib/assets/modules/{menuTabs-BqLT-YbD.js → menuTabs-CvAiSVNW.js} +2 -2
  7. package/lib/assets/modules/{toolIcon-Dd58W0UM.js → toolIcon-DWurTPaB.js} +1 -1
  8. package/lib/assets/modules/{upload-template-Csccple9.js → upload-template-BuaWOXY_.js} +435 -413
  9. package/lib/assets/modules/uploadList-De6KfTAV.js +466 -0
  10. package/lib/components/content/index.d.ts +4 -0
  11. package/lib/components/content/list/index.vue.d.ts +126 -0
  12. package/lib/components/content/list/listOperate.vue.d.ts +18 -0
  13. package/lib/components/form/switch/index.vue.d.ts +11 -1
  14. package/lib/components/form/upload/uploadList.vue.d.ts +448 -0
  15. package/lib/components/index.d.ts +1 -1
  16. package/lib/const/options.d.ts +4 -2
  17. package/lib/es/AceEditor/index.js +3 -3
  18. package/lib/es/BasicLayout/index.js +2 -2
  19. package/lib/es/Error403/index.js +1 -1
  20. package/lib/es/Error404/index.js +1 -1
  21. package/lib/es/ExcelForm/index.js +5 -5
  22. package/lib/es/MenuLayout/index.js +2 -2
  23. package/lib/es/TemplateFile/index.js +4 -4
  24. package/lib/es/UploadForm/index.js +70 -56
  25. package/lib/index.d.ts +1 -1
  26. package/lib/typings/upload.d.ts +10 -0
  27. package/lib/webui.css +1 -1
  28. package/lib/webui.es.js +1418 -1167
  29. package/package.json +2 -2
  30. package/src/components/content/dialog/uploadForm.vue +96 -13
  31. package/src/components/content/index.ts +5 -0
  32. package/src/components/content/list/index.vue +198 -0
  33. package/src/components/content/list/listOperate.vue +122 -0
  34. package/src/components/content/table/index.vue +1 -1
  35. package/src/components/content/table/tableOperate.vue +19 -37
  36. package/src/components/form/switch/index.vue +27 -14
  37. package/src/components/form/upload/uploadList.vue +46 -3
  38. package/src/components/index.ts +2 -0
  39. package/src/const/options.ts +11 -1
  40. package/src/index.ts +2 -0
  41. package/src/router/index.ts +3 -1
  42. package/src/typings/upload.d.ts +10 -0
  43. package/src/utils/menu.ts +1 -0
  44. package/lib/assets/modules/uploadList-D8scq04c.js +0 -423
package/lib/webui.es.js CHANGED
@@ -1,106 +1,106 @@
1
- import { u as $e, i as ie, a as Te, L as ft, c as vt, P as re, o as Ye, b as mt, d as ht, e as We, g as qe, r as ge, f as gt, h as bt, j as He, k as yt, l as Be, m as xt, _ as _t, n as kt, O as Qe, p as wt, q as Ge, s as Ct, t as St, v as V, w as $t, x as Tt, y as Ft, z as It, A as Et, B as Dt, C as Z, D as Pt, E as Ut, F as Lt, G as Je, M as Mt } from "./assets/modules/upload-template-Csccple9.js";
2
- import { ad as or, T as nr, U as ir, Y as ur, ac as cr, aa as dr, ab as pr, ae as fr, a0 as vr, W as mr, a8 as hr, a5 as gr, R as br, a7 as yr, X as xr, I as _r, a2 as kr, a6 as wr, a9 as Cr, S as Sr, V as $r, af as Tr, H as Fr, a4 as Ir, ag as Er, $ as Dr, a1 as Pr, Z as Ur, al as Lr, ak as Mr, ah as Br, J as Nr, K as Or, ai as Rr, Q as Ar, aj as zr, N as Kr, a3 as Vr } from "./assets/modules/upload-template-Csccple9.js";
3
- import { f as Bt, p as Ne } from "./assets/modules/file-upload-Bu6FkNjZ.js";
4
- import { A as Yr, U as Wr } from "./assets/modules/file-upload-Bu6FkNjZ.js";
5
- import { EnvConfig as Oe, isMicroApp as Nt } from "@skyfox2000/microbase";
6
- import { FrontCache as fe, httpPost as Fe, ResStatus as Ie, SERVER_HOST as Ot, fieldMapping as ve } from "@skyfox2000/fapi";
7
- import q from "vue-m-message";
8
- import { defineComponent as T, createBlock as b, openBlock as f, withModifiers as ce, unref as r, useAttrs as oe, withCtx as h, createElementVNode as I, createVNode as S, mergeProps as L, renderSlot as D, normalizeClass as U, toDisplayString as M, createCommentVNode as C, ref as y, provide as Ee, watch as F, onMounted as ee, createTextVNode as O, inject as me, resolveDirective as ne, withDirectives as X, computed as Y, createElementBlock as w, normalizeStyle as De, createSlots as Xe, useSlots as Rt, Fragment as A, renderList as H, resolveDynamicComponent as At, onActivated as Pe, shallowRef as zt, onUnmounted as Kt, withKeys as Re } from "vue";
1
+ import { u as Le, i as ce, a as Ue, L as xt, c as kt, P as ae, o as We, b as wt, d as Ct, e as qe, g as He, r as ue, f as Qe, h as Ge, j as Je, k as St, l as me, m as Xe, _ as Ze, n as et, O as Ne, p as $t, q as tt, s as Tt, t as It, v as q, w as Dt, x as Ft, y as Pt, z as Et, A as Lt, B as Ut, C as le, D as Nt, E as Bt, F as Mt, G as at, M as zt } from "./assets/modules/upload-template-BuaWOXY_.js";
2
+ import { ad as fr, T as vr, U as mr, Y as hr, ac as gr, aa as br, ab as yr, ae as _r, a0 as xr, W as kr, a8 as wr, a5 as Cr, R as Sr, a7 as $r, X as Tr, I as Ir, a2 as Dr, a6 as Fr, a9 as Pr, S as Er, V as Lr, af as Ur, H as Nr, a4 as Br, ag as Mr, $ as zr, a1 as Or, Z as Ar, al as Rr, ak as Kr, ah as jr, J as Vr, K as Yr, ai as Wr, Q as qr, aj as Hr, N as Qr, a3 as Gr } from "./assets/modules/upload-template-BuaWOXY_.js";
3
+ import { f as Ot, p as Oe } from "./assets/modules/file-upload-CKMd0H11.js";
4
+ import { A as Xr, U as Zr } from "./assets/modules/file-upload-CKMd0H11.js";
5
+ import { EnvConfig as Ae, isMicroApp as At } from "@skyfox2000/microbase";
6
+ import { FrontCache as ve, httpPost as Be, ResStatus as Me, SERVER_HOST as Rt, fieldMapping as he } from "@skyfox2000/fapi";
7
+ import G from "vue-m-message";
8
+ import { defineComponent as T, createBlock as b, openBlock as v, withModifiers as pe, unref as l, useAttrs as ne, withCtx as h, createElementVNode as D, createVNode as S, mergeProps as B, renderSlot as P, normalizeClass as E, toDisplayString as N, createCommentVNode as x, ref as y, provide as _e, watch as I, onMounted as X, createTextVNode as M, inject as ge, resolveDirective as re, withDirectives as W, computed as R, createElementBlock as w, normalizeStyle as ze, Fragment as L, renderList as V, resolveDynamicComponent as Kt, onActivated as xe, createSlots as lt, useSlots as jt, shallowRef as Vt, onUnmounted as Yt, withKeys as Re } from "vue";
9
9
  import "async-validator";
10
- import Ce from "dayjs";
11
- import { Popover as Vt, theme as Ze, Drawer as jt, Space as de, Form as et, message as Yt, FormItem as tt, ConfigProvider as Ae, Popconfirm as Wt, Button as at, DropdownButton as qt, Menu as Ue, MenuItem as Le, Dropdown as Se, Checkbox as Ht, Table as lt, Tree as Qt, Cascader as Gt, DatePicker as Jt, Input as ue, InputPassword as Xt, InputNumber as Zt, RangePicker as ea, Textarea as ta, TimePicker as aa, Transfer as la, TreeSelect as ra, Upload as sa, Image as oa, LayoutContent as na } from "ant-design-vue";
12
- import { VueDraggableNext as ia } from "vue-draggable-next";
13
- import { d as ua } from "./assets/modules/uploadList-D8scq04c.js";
14
- import { C as Hr, U as Qr, a as Gr, p as Jr } from "./assets/modules/uploadList-D8scq04c.js";
15
- import { c as rt } from "./assets/modules/index-BysCt107.js";
16
- import { _ as Zr, h as es, b as ts, a as as, d as ls, e as rs, g as ss, f as os, n as ns, p as is, t as us, v as cs } from "./assets/modules/index-BysCt107.js";
17
- import { _ as W } from "./assets/modules/index-Ch3meKe4.js";
18
- import { _ as K } from "./assets/modules/toolIcon-Dd58W0UM.js";
19
- import { a as ps } from "./assets/modules/toolIcon-Dd58W0UM.js";
20
- import { _ as vs, b as ms, c as hs, d as gs, e as bs, I as ys, f as xs, g as _s, a as ks } from "./assets/modules/menuTabs-BqLT-YbD.js";
21
- import { _ as Cs } from "./assets/modules/index-BYVerdEw.js";
22
- import { _ as te } from "./assets/modules/_plugin-vue_export-helper-CHgC5LLL.js";
23
- const ze = (l, a, e, t = "remove") => {
10
+ import Pe from "dayjs";
11
+ import { Popover as Wt, theme as rt, Drawer as qt, Space as ie, Form as st, message as Ht, FormItem as ot, ConfigProvider as be, Popconfirm as nt, DropdownButton as it, Menu as ke, MenuItem as we, Dropdown as Ee, Checkbox as Qt, List as Gt, ListItem as Jt, Card as Xt, Button as ut, Table as ct, Tree as Zt, Cascader as ea, DatePicker as ta, Input as de, InputPassword as aa, InputNumber as la, RangePicker as ra, Textarea as sa, TimePicker as oa, Transfer as na, TreeSelect as ia, Upload as ua, Image as ca, LayoutContent as da } from "ant-design-vue";
12
+ import { VueDraggableNext as pa } from "vue-draggable-next";
13
+ import { d as fa } from "./assets/modules/uploadList-De6KfTAV.js";
14
+ import { C as ts, U as as, a as ls, p as rs } from "./assets/modules/uploadList-De6KfTAV.js";
15
+ import { c as dt } from "./assets/modules/index-gmbMtZa2.js";
16
+ import { _ as os, h as ns, b as is, a as us, d as cs, e as ds, g as ps, f as fs, n as vs, p as ms, t as hs, v as gs } from "./assets/modules/index-gmbMtZa2.js";
17
+ import { _ as Q } from "./assets/modules/index-BpsqYPCw.js";
18
+ import { _ as K } from "./assets/modules/toolIcon-DWurTPaB.js";
19
+ import { a as ys } from "./assets/modules/toolIcon-DWurTPaB.js";
20
+ import { _ as xs, b as ks, c as ws, d as Cs, e as Ss, I as $s, f as Ts, g as Is, a as Ds } from "./assets/modules/menuTabs-CvAiSVNW.js";
21
+ import { _ as Ps } from "./assets/modules/index-DvozNhVM.js";
22
+ import { _ as se } from "./assets/modules/_plugin-vue_export-helper-CHgC5LLL.js";
23
+ const Ke = (r, a, e, t = "remove") => {
24
24
  if (!e)
25
25
  if (t === "disable") {
26
26
  const o = a.component;
27
- o ? o.props.disabled = !0 : (a.el, l.setAttribute("disabled", "disabled"), l.disabled = !0), l.classList.add("disabled");
27
+ o ? o.props.disabled = !0 : (a.el, r.setAttribute("disabled", "disabled"), r.disabled = !0), r.classList.add("disabled");
28
28
  } else {
29
- const o = document.createComment("No Permission"), n = l.parentNode;
29
+ const o = document.createComment("No Permission"), n = r.parentNode;
30
30
  if (n) {
31
31
  const i = a.component;
32
- i ? i.props.style = { display: "none" } : n.replaceChild(o, l);
32
+ i ? i.props.style = { display: "none" } : n.replaceChild(o, r);
33
33
  }
34
34
  }
35
- }, Ke = (l) => {
35
+ }, je = (r) => {
36
36
  var i, p;
37
- const a = $e(), { url: e, role: t, permit: o } = l;
38
- if (ie(t) && ie(o))
37
+ const a = Le(), { url: e, role: t, permit: o } = r;
38
+ if (ce(t) && ce(o))
39
39
  return !0;
40
40
  const n = e ?? ((p = (i = window.location.hash) == null ? void 0 : i.split("#")) == null ? void 0 : p[1]) ?? window.location.pathname;
41
- if (Oe.VITE_PERMISSION_MODE === "role")
42
- return ie(t) ? !0 : a.hasRole(t);
43
- if (Oe.VITE_PERMISSION_MODE === "permit") {
44
- let d = !1, u = !1;
45
- return ie(t) || (d = a.hasRole(t)), a.isAdmin() ? d : (ie(o) || (u = a.hasPermit(n, o)), d || u);
41
+ if (Ae.VITE_PERMISSION_MODE === "role")
42
+ return ce(t) ? !0 : a.hasRole(t);
43
+ if (Ae.VITE_PERMISSION_MODE === "permit") {
44
+ let c = !1, u = !1;
45
+ return ce(t) || (c = a.hasRole(t)), a.isAdmin() ? c : (ce(o) || (u = a.hasPermit(n, o)), c || u);
46
46
  }
47
47
  return !1;
48
- }, ca = {
49
- mounted(l, a, e) {
50
- const t = a.value || {}, o = a.arg || "remove", n = t.behavior || o, i = Ke(t);
51
- ze(l, e, i, n);
48
+ }, va = {
49
+ mounted(r, a, e) {
50
+ const t = a.value || {}, o = a.arg || "remove", n = t.behavior || o, i = je(t);
51
+ Ke(r, e, i, n);
52
52
  },
53
- updated(l, a, e) {
54
- const t = a.value || {}, o = a.arg || "remove", n = t.behavior || o, i = Ke(t);
55
- ze(l, e, i, n);
53
+ updated(r, a, e) {
54
+ const t = a.value || {}, o = a.arg || "remove", n = t.behavior || o, i = je(t);
55
+ Ke(r, e, i, n);
56
56
  }
57
- }, da = {
58
- mounted: (l, a) => {
59
- l.addEventListener("keydown", (e) => {
57
+ }, ma = {
58
+ mounted: (r, a) => {
59
+ r.addEventListener("keydown", (e) => {
60
60
  e.key === "Enter" && a.value();
61
61
  });
62
62
  },
63
- unmounted: (l) => {
64
- l.removeEventListener("keydown", () => {
63
+ unmounted: (r) => {
64
+ r.removeEventListener("keydown", () => {
65
65
  });
66
66
  }
67
- }, ke = {
68
- auth: ca,
69
- submit: da
70
- }, Tl = (l, a) => ((a || Object.keys(ke)).forEach((t) => {
71
- t in ke && l.directive(t, ke[t]);
72
- }), l), ae = (l, a) => {
73
- const e = l.find((t) => t.key === a);
67
+ }, De = {
68
+ auth: va,
69
+ submit: ma
70
+ }, Ll = (r, a) => ((a || Object.keys(De)).forEach((t) => {
71
+ t in De && r.directive(t, De[t]);
72
+ }), r), oe = (r, a) => {
73
+ const e = r.find((t) => t.key === a);
74
74
  if (e)
75
75
  return e;
76
- for (const t of l)
76
+ for (const t of r)
77
77
  if (t.children) {
78
- const o = ae(t.children, a);
78
+ const o = oe(t.children, a);
79
79
  if (o)
80
80
  return o;
81
81
  }
82
- }, Me = (l, a, e) => {
82
+ }, Ce = (r, a, e) => {
83
83
  const t = [], o = [];
84
- return e || (e = [...l]), e.length && e.forEach((n, i) => {
84
+ return e || (e = [...r]), e.length && e.forEach((n, i) => {
85
85
  let p;
86
86
  if (typeof n == "string") {
87
- const d = ae(l, n);
88
- p = d ? { ...d } : { key: n, label: n };
87
+ const c = oe(r, n);
88
+ p = c ? { ...c } : { key: n, label: n };
89
89
  } else {
90
- const d = ae(l, n.key);
91
- p = d ? { ...d, ...n } : { ...n };
90
+ const c = oe(r, n.key);
91
+ p = c ? { ...c, ...n } : { ...n };
92
92
  }
93
- p.click || (p.click = (d, u, v) => {
94
- u && (u.rowData.value = v), p.formVisible ? (p.formVisible.value = !1, setTimeout(() => {
93
+ p.click || (p.click = (c, u, f) => {
94
+ u && (u.rowData.value = f), p.formVisible ? (p.formVisible.value = !1, setTimeout(() => {
95
95
  p.formVisible.value = !0;
96
- }, 1)) : q.warning("未配置点击处理事件!");
96
+ }, 1)) : G.warning("未配置点击处理事件!");
97
97
  }), a === 0 || i < a ? t.push(p) : o.push(p);
98
98
  }), { buttons: t, menus: o };
99
- }, le = (l, a) => l.disabled && typeof l.disabled == "function" ? l.disabled(a) : l.disabled, se = (l, a) => l.visible && typeof l.visible == "function" ? l.visible(a) : l.visible ?? !0, pa = (l, a) => {
99
+ }, te = (r, a) => r.disabled && typeof r.disabled == "function" ? r.disabled(a) : r.disabled, J = (r, a) => r.visible && typeof r.visible == "function" ? r.visible(a) : r.visible ?? !0, ha = (r, a) => {
100
100
  a.reload.value = !0;
101
- }, fa = (l, a) => {
101
+ }, ga = (r, a) => {
102
102
  a.searchBar.value = !a.searchBar.value;
103
- }, va = (l, a) => {
103
+ }, ba = (r, a) => {
104
104
  switch (a.tableSize.value) {
105
105
  case "large":
106
106
  a.tableSize.value = "middle";
@@ -112,29 +112,29 @@ const ze = (l, a, e, t = "remove") => {
112
112
  a.tableSize.value = "large";
113
113
  break;
114
114
  }
115
- }, ma = (l, a) => {
115
+ }, ya = (r, a) => {
116
116
  a.selectable.value = !a.selectable.value, a.selectable.value || (a.selectKeys.value = [], a.selectRows.value = []);
117
- }, ha = (l, a) => {
117
+ }, _a = (r, a) => {
118
118
  a.rowExpand.value = !a.rowExpand.value;
119
- }, Ve = (l, a) => {
119
+ }, Ve = (r, a) => {
120
120
  a.selectable.value = !a.selectable.value;
121
- }, J = (l, a, e, t, o) => {
122
- (!l.confirm || o) && l.click && (a ? l.click(a, e, t) : l.click(null, e, t)), ba(l);
123
- }, ga = (l, a) => {
121
+ }, Y = (r, a, e, t, o) => {
122
+ (!r.confirm || o) && r.click && (a ? r.click(a, e, t) : r.click(null, e, t)), ka(r);
123
+ }, xa = (r, a) => {
124
124
  a.selectable.value = !a.selectable.value;
125
- }, st = () => {
126
- const l = Te();
127
- l.setFullscreen(!l.fullscreen);
128
- }, ba = (l, a) => {
129
- (l.icons || l.labels) && (l.iconStatus = l.iconStatus || 0, l.iconStatus += 1, l.labels && l.labels.length && (l.label = l.labels[l.iconStatus % l.labels.length]), l.icons && l.icons.length && (l.icon = l.icons[l.iconStatus % l.icons.length]));
130
- }, ya = (l, a) => {
131
- a ? delete l.visible : l.visible = !1;
132
- }, je = [
125
+ }, pt = () => {
126
+ const r = Ue();
127
+ r.setFullscreen(!r.fullscreen);
128
+ }, ka = (r, a) => {
129
+ (r.icons || r.labels) && (r.iconStatus = r.iconStatus || 0, r.iconStatus += 1, r.labels && r.labels.length && (r.label = r.labels[r.iconStatus % r.labels.length]), r.icons && r.icons.length && (r.icon = r.icons[r.iconStatus % r.icons.length]));
130
+ }, wa = (r, a) => {
131
+ a ? delete r.visible : r.visible = !1;
132
+ }, Ye = [
133
133
  {
134
134
  key: "Reload",
135
135
  label: "刷新表格",
136
136
  icon: "icon-reload",
137
- click: pa
137
+ click: ha
138
138
  },
139
139
  {
140
140
  key: "Query",
@@ -142,20 +142,20 @@ const ze = (l, a, e, t = "remove") => {
142
142
  labels: ["展开搜索栏", "折叠搜索栏"],
143
143
  icon: "icon-search",
144
144
  iconStatus: 0,
145
- click: fa
145
+ click: ga
146
146
  },
147
147
  {
148
148
  key: "RowHeight",
149
149
  label: "行高调整",
150
150
  icon: "icon-row-height",
151
- click: va
151
+ click: ba
152
152
  },
153
153
  {
154
154
  key: "tool.multiple.checkbox",
155
155
  label: "显示多选框",
156
156
  labels: ["显示多选框", "隐藏多选框"],
157
157
  icon: "icon-checkbox",
158
- click: ma
158
+ click: ya
159
159
  },
160
160
  {
161
161
  key: "tool.expand.rows",
@@ -164,7 +164,7 @@ const ze = (l, a, e, t = "remove") => {
164
164
  icon: "icon-row-collapse",
165
165
  iconStatus: 0,
166
166
  icons: ["icon-row-collapse", "icon-row-expand"],
167
- click: ha
167
+ click: _a
168
168
  },
169
169
  {
170
170
  key: "tool.export.excel",
@@ -191,7 +191,7 @@ const ze = (l, a, e, t = "remove") => {
191
191
  {
192
192
  key: "tool.export.pdf.selected",
193
193
  label: "选中的记录",
194
- click: ga
194
+ click: xa
195
195
  }
196
196
  ]
197
197
  },
@@ -211,19 +211,19 @@ const ze = (l, a, e, t = "remove") => {
211
211
  icon: "icon-fullscreen",
212
212
  iconStatus: 0,
213
213
  icons: ["icon-fullscreen", "icon-exitscreen"],
214
- click: st
214
+ click: pt
215
215
  }
216
- ], xa = (l) => {
217
- if (!l.tools || l.tools.length > 0) {
216
+ ], Ca = (r) => {
217
+ if (!r.tools || r.tools.length > 0) {
218
218
  const a = [];
219
- return l.tools ? a.push(...l.tools) : a.push(...je), { tools: Me(je, 0, a).buttons };
219
+ return r.tools ? a.push(...r.tools) : a.push(...Ye), { tools: Ce(Ye, 0, a).buttons };
220
220
  }
221
221
  return {
222
222
  tools: []
223
223
  };
224
224
  };
225
- var _a = /* @__PURE__ */ ((l) => (l.SYS_CONFIG = "SYS_CONFIG_", l.APP_MENU = "APP_MENU_", l.DICT_TYPE = "DICT_TYPE_", l.HOST_INFO = "HOST_INFO_", l.APP_PERMITS = "APP_PERMITS_", l.USER_SETTINGS = "USER_SETTINGS_", l.DICT_DATA = "DICT_DATA_", l.COMMON_OPTIONS = "COMMON_OPTIONS_", l))(_a || {});
226
- class ot {
225
+ var Sa = /* @__PURE__ */ ((r) => (r.SYS_CONFIG = "SYS_CONFIG_", r.APP_MENU = "APP_MENU_", r.DICT_TYPE = "DICT_TYPE_", r.HOST_INFO = "HOST_INFO_", r.APP_PERMITS = "APP_PERMITS_", r.USER_SETTINGS = "USER_SETTINGS_", r.DICT_DATA = "DICT_DATA_", r.COMMON_OPTIONS = "COMMON_OPTIONS_", r))(Sa || {});
226
+ class ft {
227
227
  /**
228
228
  * 设置缓存数据(带服务器时间)
229
229
  */
@@ -232,26 +232,26 @@ class ot {
232
232
  data: e,
233
233
  lastTime: t
234
234
  };
235
- fe.set({ key: a, storage: "local" }, o);
235
+ ve.set({ key: a, storage: "local" }, o);
236
236
  }
237
237
  /**
238
238
  * 设置缓存数据
239
239
  */
240
240
  static setData(a, e) {
241
- fe.set({ key: a, storage: "local" }, e);
241
+ ve.set({ key: a, storage: "local" }, e);
242
242
  }
243
243
  /**
244
244
  * 获取缓存数据
245
245
  */
246
246
  static getData(a) {
247
- const e = fe.get({ key: a, storage: "local" });
248
- return e && ot.isTimedData(e) ? e.data : e ?? null;
247
+ const e = ve.get({ key: a, storage: "local" });
248
+ return e && ft.isTimedData(e) ? e.data : e ?? null;
249
249
  }
250
250
  /**
251
251
  * 清除缓存
252
252
  */
253
253
  static remove(a) {
254
- fe.remove({ key: a, storage: "local" });
254
+ ve.remove({ key: a, storage: "local" });
255
255
  }
256
256
  /**
257
257
  * 清理指定前缀的缓存 (基于 localStorage 实现,因为 FrontCache 未提供此方法)
@@ -278,9 +278,9 @@ class ot {
278
278
  return a && typeof a == "object" && "data" in a && "lastTime" in a && typeof a.lastTime == "number";
279
279
  }
280
280
  }
281
- async function Fl() {
281
+ async function Ul() {
282
282
  try {
283
- const l = await Fe(
283
+ const r = await Be(
284
284
  {
285
285
  api: "PLATFORM_API",
286
286
  url: "/api/SysCacheSvr/getLastTime",
@@ -288,18 +288,18 @@ async function Fl() {
288
288
  },
289
289
  {}
290
290
  );
291
- if ((l == null ? void 0 : l.status) === Ie.SUCCESS) {
292
- const a = l.data;
291
+ if ((r == null ? void 0 : r.status) === Me.SUCCESS) {
292
+ const a = r.data;
293
293
  Object.keys(a).forEach((e) => {
294
294
  const t = a[e];
295
295
  ["local", "session"].forEach((n) => {
296
296
  const i = n === "local" ? localStorage : sessionStorage;
297
297
  for (let p = 0; p < i.length; p++) {
298
- const d = i.key(p);
299
- if (d && d.endsWith(e))
298
+ const c = i.key(p);
299
+ if (c && c.endsWith(e))
300
300
  try {
301
- const u = JSON.parse(i.getItem(d));
302
- u && typeof u == "object" && "lastTime" in u && typeof u.lastTime == "number" && u.lastTime !== t && i.removeItem(d);
301
+ const u = JSON.parse(i.getItem(c));
302
+ u && typeof u == "object" && "lastTime" in u && typeof u.lastTime == "number" && u.lastTime !== t && i.removeItem(c);
303
303
  } catch {
304
304
  continue;
305
305
  }
@@ -307,12 +307,12 @@ async function Fl() {
307
307
  });
308
308
  });
309
309
  }
310
- } catch (l) {
311
- console.error("检查缓存更新失败", l);
310
+ } catch (r) {
311
+ console.error("检查缓存更新失败", r);
312
312
  }
313
313
  }
314
- const Il = async (l, a) => {
315
- const e = await rt(l, a);
314
+ const Nl = async (r, a) => {
315
+ const e = await dt(r, a);
316
316
  if (e.success)
317
317
  return {
318
318
  blobUrl: e.blobUrl,
@@ -321,9 +321,9 @@ const Il = async (l, a) => {
321
321
  // 不再返回blob对象,使用URL即可
322
322
  };
323
323
  throw new Error(e.error || "CSV转Excel失败");
324
- }, El = async (l, a) => {
324
+ }, Bl = async (r, a) => {
325
325
  try {
326
- const t = new TextDecoder("utf-8").decode(l), o = await rt(t, a);
326
+ const t = new TextDecoder("utf-8").decode(r), o = await dt(t, a);
327
327
  return {
328
328
  success: o.success,
329
329
  blobUrl: o.blobUrl,
@@ -338,13 +338,13 @@ const Il = async (l, a) => {
338
338
  error: e instanceof Error ? e.message : "未知错误"
339
339
  };
340
340
  }
341
- }, nt = (l) => l ? Array.isArray(l) ? l.join(".") : l : "", it = (l) => l.map((a) => ({
341
+ }, vt = (r) => r ? Array.isArray(r) ? r.join(".") : r : "", mt = (r) => r.map((a) => ({
342
342
  label: a.title,
343
- value: nt(a.dataIndex) || a.key || ""
344
- })), ut = (l, a) => l.map((e, t) => {
343
+ value: vt(a.dataIndex) || a.key || ""
344
+ })), ht = (r, a) => r.map((e, t) => {
345
345
  const o = { ...e };
346
346
  return a.forEach((n) => {
347
- const i = nt(n.dataIndex) || n.key;
347
+ const i = vt(n.dataIndex) || n.key;
348
348
  i && n.customRender && (o[i] = n.customRender({
349
349
  text: e[i],
350
350
  record: e,
@@ -352,53 +352,53 @@ const Il = async (l, a) => {
352
352
  column: n
353
353
  }));
354
354
  }), o;
355
- }), ct = async (l, a, e) => {
355
+ }), gt = async (r, a, e) => {
356
356
  try {
357
357
  const o = (await import("@json2csv/plainjs")).Parser, i = new o({ fields: a }).parse(e), p = new Blob([`\uFEFF${i}`], { type: "text/csv" });
358
- ua(p, l);
358
+ fa(p, r);
359
359
  } catch (t) {
360
- console.error("导出失败:", t), q.error("文件导出失败,请稍后重试");
360
+ console.error("导出失败:", t), G.error("文件导出失败,请稍后重试");
361
361
  }
362
- }, Dl = async (l, a, e) => {
362
+ }, Ml = async (r, a, e) => {
363
363
  try {
364
- const t = dt(l), o = a.filter((p) => p.visible !== !1 && p.export !== !1), n = it(o), i = ut(e, o);
365
- await ct(t, n, i);
364
+ const t = bt(r), o = a.filter((p) => p.visible !== !1 && p.export !== !1), n = mt(o), i = ht(e, o);
365
+ await gt(t, n, i);
366
366
  } catch (t) {
367
- console.error("导出失败:", t), q.error("文件导出失败,请稍后重试");
367
+ console.error("导出失败:", t), G.error("文件导出失败,请稍后重试");
368
368
  }
369
- }, dt = (l) => {
369
+ }, bt = (r) => {
370
370
  const a = /\{([^}]+)\}/g;
371
- return l.replace(a, (e, t) => Ce().format(t));
372
- }, Pl = async (l, a, e, t) => {
371
+ return r.replace(a, (e, t) => Pe().format(t));
372
+ }, zl = async (r, a, e, t) => {
373
373
  try {
374
- const o = dt(l), n = a.filter((u) => u.visible !== !1), i = it(n);
375
- let p = e.page, d = e.gridQuery;
376
- return t.api || (t.api = p.api), t.authorize === void 0 && (t.authorize = p.authorize), e.isGridLoading.value = !0, Fe(t, d).then(async (u) => {
377
- if (e.isGridLoading.value = !1, (u == null ? void 0 : u.status) === Ie.SUCCESS) {
374
+ const o = bt(r), n = a.filter((u) => u.visible !== !1), i = mt(n);
375
+ let p = e.page, c = e.gridQuery;
376
+ return t.api || (t.api = p.api), t.authorize === void 0 && (t.authorize = p.authorize), e.isGridLoading.value = !0, Be(t, c).then(async (u) => {
377
+ if (e.isGridLoading.value = !1, (u == null ? void 0 : u.status) === Me.SUCCESS) {
378
378
  if (u.data) {
379
- let v = u.data;
380
- const s = ut(v, n);
381
- await ct(o, i, s);
379
+ let f = u.data;
380
+ const s = ht(f, n);
381
+ await gt(o, i, s);
382
382
  }
383
- } else if ((u == null ? void 0 : u.errno) == ft) {
384
- $e().logout(!1);
383
+ } else if ((u == null ? void 0 : u.errno) == xt) {
384
+ Le().logout(!1);
385
385
  return;
386
386
  }
387
387
  });
388
388
  } catch (o) {
389
- console.error("导出失败:", o), q.error("文件导出失败,请稍后重试");
389
+ console.error("导出失败:", o), G.error("文件导出失败,请稍后重试");
390
390
  }
391
- }, Ul = /* @__PURE__ */ T({
391
+ }, Ol = /* @__PURE__ */ T({
392
392
  __name: "fullscreen",
393
- setup(l) {
394
- const a = Te();
395
- return (e, t) => (f(), b(K, {
396
- onClick: ce(r(st), ["stop"]),
397
- icon: r(a).fullscreen ? "icon-exitscreen" : "icon-fullscreen",
393
+ setup(r) {
394
+ const a = Ue();
395
+ return (e, t) => (v(), b(K, {
396
+ onClick: pe(l(pt), ["stop"]),
397
+ icon: l(a).fullscreen ? "icon-exitscreen" : "icon-fullscreen",
398
398
  class: "w-[17px] h-[17px]"
399
399
  }, null, 8, ["onClick", "icon"]));
400
400
  }
401
- }), ka = { class: "ml-2" }, wa = /* @__PURE__ */ T({
401
+ }), $a = { class: "ml-2" }, Ta = /* @__PURE__ */ T({
402
402
  inheritAttrs: !1,
403
403
  __name: "helper",
404
404
  props: {
@@ -407,30 +407,30 @@ const Il = async (l, a) => {
407
407
  size: {},
408
408
  placement: {}
409
409
  },
410
- setup(l) {
411
- const a = oe();
412
- return (e, t) => (f(), b(r(Vt), {
410
+ setup(r) {
411
+ const a = ne();
412
+ return (e, t) => (v(), b(l(Wt), {
413
413
  placement: e.placement ?? "topRight"
414
414
  }, {
415
415
  content: h(() => [
416
- D(e.$slots, "default", {}, () => [
417
- I("div", {
418
- class: U(["text-[14px]", [e.maxWidth]])
419
- }, M(e.text), 3)
416
+ P(e.$slots, "default", {}, () => [
417
+ D("div", {
418
+ class: E(["text-[14px]", [e.maxWidth]])
419
+ }, N(e.text), 3)
420
420
  ])
421
421
  ]),
422
422
  default: h(() => [
423
- I("span", ka, [
424
- S(K, L({
423
+ D("span", $a, [
424
+ S(K, B({
425
425
  icon: "icon-question-circle",
426
426
  class: ["text-[#888]", [e.size ? "w-" + e.size + " h-" + e.size : "w-5 h-5"]]
427
- }, r(a)), null, 16, ["class"])
427
+ }, l(a)), null, 16, ["class"])
428
428
  ])
429
429
  ]),
430
430
  _: 3
431
431
  }, 8, ["placement"]));
432
432
  }
433
- }), Ll = /* @__PURE__ */ T({
433
+ }), Al = /* @__PURE__ */ T({
434
434
  __name: "layoutIcon",
435
435
  props: {
436
436
  icon: {
@@ -440,21 +440,21 @@ const Il = async (l, a) => {
440
440
  type: Array
441
441
  }
442
442
  },
443
- setup(l) {
444
- const a = l, t = vt({
445
- iconUrl: `${Ot.MICROLAYOUT_ICONS}`,
443
+ setup(r) {
444
+ const a = r, t = kt({
445
+ iconUrl: `${Rt.MICROLAYOUT_ICONS}`,
446
446
  monoColor: !0,
447
447
  icon: a.icon,
448
448
  icons: a.icons
449
449
  });
450
- return (o, n) => l.icon || l.icons ? (f(), b(r(t), L({
450
+ return (o, n) => r.icon || r.icons ? (v(), b(l(t), B({
451
451
  key: 0,
452
- icon: l.icon,
453
- icons: l.icons,
452
+ icon: r.icon,
453
+ icons: r.icons,
454
454
  class: ["align-middle"]
455
- }, o.$attrs), null, 16, ["icon", "icons"])) : C("", !0);
455
+ }, o.$attrs), null, 16, ["icon", "icons"])) : x("", !0);
456
456
  }
457
- }), Ca = { class: "hover:bg-gray-200 w-[24px] h-[24px] rounded-md" }, Ml = /* @__PURE__ */ T({
457
+ }), Ia = { class: "hover:bg-gray-200 w-[24px] h-[24px] rounded-md" }, Rl = /* @__PURE__ */ T({
458
458
  __name: "index",
459
459
  props: {
460
460
  saveText: {},
@@ -464,32 +464,32 @@ const Il = async (l, a) => {
464
464
  drawerSave: { type: Function },
465
465
  drawerSaveAs: { type: Function }
466
466
  },
467
- setup(l) {
468
- const { useToken: a } = Ze, { token: e } = a(), t = y(!1), o = l, n = o.editorCtrl;
469
- Ee(re.EditorControl, n), F(
467
+ setup(r) {
468
+ const { useToken: a } = rt, { token: e } = a(), t = y(!1), o = r, n = o.editorCtrl;
469
+ _e(ae.EditorControl, n), I(
470
470
  () => n.visible.value,
471
471
  (u) => {
472
472
  t.value = u ?? !1;
473
473
  }
474
- ), ee(() => {
474
+ ), X(() => {
475
475
  t.value = n.visible.value ?? !1;
476
476
  });
477
477
  const i = () => {
478
- o.drawerSave ? o.drawerSave() : n && Ye(n);
478
+ o.drawerSave ? o.drawerSave() : n && We(n);
479
479
  }, p = () => {
480
- o.drawerSaveAs ? o.drawerSaveAs() : n && mt(n);
481
- }, d = () => {
482
- ht(n);
480
+ o.drawerSaveAs ? o.drawerSaveAs() : n && wt(n);
481
+ }, c = () => {
482
+ Ct(n);
483
483
  };
484
- return (u, v) => (f(), b(r(jt), {
484
+ return (u, f) => (v(), b(l(qt), {
485
485
  open: t.value,
486
- "onUpdate:open": v[0] || (v[0] = (s) => t.value = s),
486
+ "onUpdate:open": f[0] || (f[0] = (s) => t.value = s),
487
487
  "get-container": !1,
488
488
  closable: !1,
489
489
  "header-style": {
490
490
  height: "40px",
491
491
  padding: "10px 6px 10px 16px",
492
- backgroundColor: r(e).colorBgLayout
492
+ backgroundColor: l(e).colorBgLayout
493
493
  },
494
494
  "body-style": {
495
495
  padding: "10px 16px"
@@ -502,12 +502,12 @@ const Il = async (l, a) => {
502
502
  boxShadow: "rgba(0, 0, 0, 0.3) -2px 0px 8px"
503
503
  },
504
504
  width: "420px",
505
- onClose: d
505
+ onClose: c
506
506
  }, {
507
507
  extra: h(() => [
508
- D(u.$slots, "extra", {}, () => [
509
- I("div", Ca, [
510
- S(r(K), {
508
+ P(u.$slots, "extra", {}, () => [
509
+ D("div", Ia, [
510
+ S(l(K), {
511
511
  class: "top-[-2px] left-[2px] w-6 h-6",
512
512
  icon: "icon-new",
513
513
  angle: 45,
@@ -515,49 +515,49 @@ const Il = async (l, a) => {
515
515
  clickable: "",
516
516
  color: "#666",
517
517
  position: [0, 0],
518
- onClick: d
518
+ onClick: c
519
519
  })
520
520
  ])
521
521
  ])
522
522
  ]),
523
523
  default: h(() => [
524
- D(u.$slots, "default")
524
+ P(u.$slots, "default")
525
525
  ]),
526
526
  footer: h(() => [
527
- D(u.$slots, "footer", {}, () => [
528
- S(r(de), null, {
527
+ P(u.$slots, "footer", {}, () => [
528
+ S(l(ie), null, {
529
529
  default: h(() => [
530
- u.cancelText !== "" ? (f(), b(r(W), {
530
+ u.cancelText !== "" ? (v(), b(l(Q), {
531
531
  key: 0,
532
- onClick: d
532
+ onClick: c
533
533
  }, {
534
534
  default: h(() => [
535
- O(M(u.cancelText ?? "取消"), 1)
535
+ M(N(u.cancelText ?? "取消"), 1)
536
536
  ]),
537
537
  _: 1
538
- })) : C("", !0),
539
- u.saveAsText !== "" && r(n).saveAsBtnVisible !== !1 ? (f(), b(r(W), {
538
+ })) : x("", !0),
539
+ u.saveAsText !== "" && l(n).saveAsBtnVisible !== !1 ? (v(), b(l(Q), {
540
540
  key: 1,
541
541
  onClick: p,
542
542
  type: "primary",
543
- loading: r(n).isFormSaving.value
543
+ loading: l(n).isFormSaving.value
544
544
  }, {
545
545
  default: h(() => [
546
- O(M(u.saveAsText ?? "另存为"), 1)
546
+ M(N(u.saveAsText ?? "另存为"), 1)
547
547
  ]),
548
548
  _: 1
549
- }, 8, ["loading"])) : C("", !0),
550
- u.saveText !== "" && r(n).saveBtnVisible !== !1 ? (f(), b(r(W), {
549
+ }, 8, ["loading"])) : x("", !0),
550
+ u.saveText !== "" && l(n).saveBtnVisible !== !1 ? (v(), b(l(Q), {
551
551
  key: 2,
552
552
  onClick: i,
553
553
  type: "primary",
554
- loading: r(n).isFormSaving.value
554
+ loading: l(n).isFormSaving.value
555
555
  }, {
556
556
  default: h(() => [
557
- O(M(u.saveText ?? "保存"), 1)
557
+ M(N(u.saveText ?? "保存"), 1)
558
558
  ]),
559
559
  _: 1
560
- }, 8, ["loading"])) : C("", !0)
560
+ }, 8, ["loading"])) : x("", !0)
561
561
  ]),
562
562
  _: 1
563
563
  })
@@ -566,18 +566,18 @@ const Il = async (l, a) => {
566
566
  _: 3
567
567
  }, 8, ["open", "header-style"]));
568
568
  }
569
- }), Bl = /* @__PURE__ */ T({
569
+ }), Kl = /* @__PURE__ */ T({
570
570
  __name: "index",
571
571
  props: {
572
572
  labelWidth: {},
573
573
  wrapperWidth: {},
574
574
  editorCtrl: {}
575
575
  },
576
- setup(l) {
577
- const a = l, e = a.editorCtrl ?? me(re.EditorControl, void 0);
578
- return Ee(re.LabelWidth, a.labelWidth), (t, o) => {
579
- const n = ne("submit");
580
- return X((f(), b(r(et), {
576
+ setup(r) {
577
+ const a = r, e = a.editorCtrl ?? ge(ae.EditorControl, void 0);
578
+ return _e(ae.LabelWidth, a.labelWidth), (t, o) => {
579
+ const n = re("submit");
580
+ return W((v(), b(l(st), {
581
581
  "label-col": { flex: a.labelWidth ?? "85px" },
582
582
  "wrapper-col": {
583
583
  flex: a.wrapperWidth ?? "1 0 280px"
@@ -588,23 +588,23 @@ const Il = async (l, a) => {
588
588
  }
589
589
  }, {
590
590
  default: h(() => [
591
- D(t.$slots, "default")
591
+ P(t.$slots, "default")
592
592
  ]),
593
593
  _: 3
594
594
  }, 8, ["label-col", "wrapper-col"])), [
595
595
  [
596
596
  n,
597
597
  () => {
598
- r(e) && r(Ye)(r(e));
598
+ l(e) && l(We)(l(e));
599
599
  }
600
600
  ]
601
601
  ]);
602
602
  };
603
603
  }
604
- }), Sa = {
604
+ }), Da = {
605
605
  key: 0,
606
606
  class: "flex-grow"
607
- }, $a = { class: "w-8 mt-[-2px]" }, Nl = /* @__PURE__ */ T({
607
+ }, Fa = { class: "w-8 mt-[-2px]" }, jl = /* @__PURE__ */ T({
608
608
  inheritAttrs: !1,
609
609
  __name: "formItem",
610
610
  props: {
@@ -615,294 +615,122 @@ const Il = async (l, a) => {
615
615
  nextLine: { type: Boolean },
616
616
  bottomMargin: {}
617
617
  },
618
- setup(l) {
619
- const a = l, e = oe(), t = me(re.EditorControl, void 0), o = me(re.LabelWidth, "85px") ?? "85px", n = We(a, t), i = y(!1);
618
+ setup(r) {
619
+ const a = r, e = ne(), t = ge(ae.EditorControl, void 0), o = ge(ae.LabelWidth, "85px") ?? "85px", n = qe(a, t), i = y(!1);
620
620
  setTimeout(() => {
621
621
  i.value = !0;
622
622
  }, 30);
623
- const p = Y(() => {
623
+ const p = R(() => {
624
624
  var u;
625
625
  if (!a.rule)
626
626
  return !1;
627
- const d = qe(a.rule.split("."), (u = t == null ? void 0 : t.formRules) == null ? void 0 : u.value);
628
- return d ? (d.required || (n.value.errClass = "", n.value.msg = ""), d.required ?? !0) : (Yt.error(`"${a.label}" 的验证规则 \`${a.rule}\` 不存在`), n.value.errClass = "text-[#ff4d4f]", n.value.msg = `规则 \`${a.rule}\` 不存在,请检查代码!`, !0);
627
+ const c = He(a.rule.split("."), (u = t == null ? void 0 : t.formRules) == null ? void 0 : u.value);
628
+ return c ? (c.required || (n.value.errClass = "", n.value.msg = ""), c.required ?? !0) : (Ht.error(`"${a.label}" 的验证规则 \`${a.rule}\` 不存在`), n.value.errClass = "text-[#ff4d4f]", n.value.msg = `规则 \`${a.rule}\` 不存在,请检查代码!`, !0);
629
629
  });
630
- return (d, u) => (f(), w("div", {
631
- class: U(["relative", d.bottomMargin ? d.bottomMargin : "mb-1"])
630
+ return (c, u) => (v(), w("div", {
631
+ class: E(["relative", c.bottomMargin ? c.bottomMargin : "mb-1"])
632
632
  }, [
633
- i.value ? (f(), b(r(tt), L({
633
+ i.value ? (v(), b(l(ot), B({
634
634
  key: 0,
635
635
  required: p.value,
636
- class: ["relative", [d.nextLine ? "mb-0" : d.rule ? "" : "mb-3"]]
637
- }, r(e)), {
636
+ class: ["relative", [c.nextLine ? "mb-0" : c.rule ? "" : "mb-3"]]
637
+ }, l(e)), {
638
638
  label: h(() => [
639
- I("span", {
640
- class: U([r(n).errClass ? "text-[#ff4d4f]" : "", "w-full"])
641
- }, M(d.label), 3)
639
+ D("span", {
640
+ class: E([l(n).errClass ? "text-[#ff4d4f]" : "", "w-full"])
641
+ }, N(c.label), 3)
642
642
  ]),
643
643
  default: h(() => [
644
- I("div", {
645
- class: U(["flex items-center", d.width ? d.width : "w-full"])
644
+ D("div", {
645
+ class: E(["flex items-center", c.width ? c.width : "w-full"])
646
646
  }, [
647
- d.nextLine ? C("", !0) : (f(), w("div", Sa, [
648
- D(d.$slots, "default")
647
+ c.nextLine ? x("", !0) : (v(), w("div", Da, [
648
+ P(c.$slots, "default")
649
649
  ])),
650
- I("div", $a, [
651
- D(d.$slots, "helper", {}, () => [
652
- d.helper ? (f(), b(r(wa), {
650
+ D("div", Fa, [
651
+ P(c.$slots, "helper", {}, () => [
652
+ c.helper ? (v(), b(l(Ta), {
653
653
  key: 0,
654
- text: d.helper
655
- }, null, 8, ["text"])) : C("", !0)
654
+ text: c.helper
655
+ }, null, 8, ["text"])) : x("", !0)
656
656
  ])
657
657
  ])
658
658
  ], 2)
659
659
  ]),
660
660
  _: 3
661
- }, 16, ["required", "class"])) : C("", !0),
662
- d.nextLine ? (f(), w("div", {
661
+ }, 16, ["required", "class"])) : x("", !0),
662
+ c.nextLine ? (v(), w("div", {
663
663
  key: 1,
664
- class: U(["w-[95%] flex items-center relative", [d.nextLine ? d.rule ? "mb-7" : "mb-3" : ""]])
664
+ class: E(["w-[95%] flex items-center relative", [c.nextLine ? c.rule ? "mb-7" : "mb-3" : ""]])
665
665
  }, [
666
- D(d.$slots, "default")
667
- ], 2)) : C("", !0),
668
- r(n).errClass ? (f(), w("span", {
666
+ P(c.$slots, "default")
667
+ ], 2)) : x("", !0),
668
+ l(n).errClass ? (v(), w("span", {
669
669
  key: 2,
670
- style: De({ left: d.nextLine ? "2px" : r(o) }),
670
+ style: ze({ left: c.nextLine ? "2px" : l(o) }),
671
671
  class: "absolute bottom-[3px] text-[12px] text-[#ff4d4fcc]"
672
- }, M(r(n).msg), 5)) : C("", !0)
672
+ }, N(l(n).msg), 5)) : x("", !0)
673
673
  ], 2));
674
674
  }
675
- }), Ta = { class: "w-1/3 relative mb-1" }, Fa = { class: "flex items-center w-[90%]" }, Ia = { class: "flex-grow pl-1" }, Ea = {
676
- key: 0,
677
- class: "absolute bottom-[3px] left-[85px] text-[12px] text-[#ff4d4fcc] block"
678
- }, we = /* @__PURE__ */ T({
679
- inheritAttrs: !1,
680
- __name: "searchItem",
681
- props: {
682
- label: {},
683
- width: {},
684
- rule: {}
685
- },
686
- setup(l) {
687
- const a = l, e = oe(), t = me(re.EditorControl, void 0), o = We(a, t), n = Y(() => {
688
- var p;
689
- if (!a.rule)
690
- return !1;
691
- const i = qe(a.rule.split("."), (p = t == null ? void 0 : t.formRules) == null ? void 0 : p.value);
692
- return i ? (i.required || (o.value.errClass = "", o.value.msg = ""), i.required ?? !0) : (q.error(`"${a.label}" 的验证规则 \`${a.rule}\` 不存在`), o.value.errClass = "text-[#ff4d4f]", o.value.msg = `规则 \`${a.rule}\` 不存在,请检查代码!`, !0);
693
- });
694
- return (i, p) => (f(), w("div", Ta, [
695
- S(r(tt), L({
696
- required: n.value,
697
- class: "w-[90%] relative"
698
- }, r(e), {
699
- class: [i.rule ? "" : "mb-3", i.width],
700
- labelCol: { span: 6 }
701
- }), Xe({
702
- default: h(() => [
703
- I("div", Fa, [
704
- I("div", Ia, [
705
- D(i.$slots, "default")
706
- ])
707
- ])
708
- ]),
709
- _: 2
710
- }, [
711
- i.label ? {
712
- name: "label",
713
- fn: h(() => [
714
- I("span", {
715
- class: U([r(o).errClass ? "text-[#ff4d4f]" : "", "w-full"])
716
- }, M(i.label), 3)
717
- ]),
718
- key: "0"
719
- } : void 0
720
- ]), 1040, ["required", "class"]),
721
- r(o).msg ? (f(), w("span", Ea, M(r(o).msg), 1)) : C("", !0)
722
- ]));
723
- }
724
- }), Ol = /* @__PURE__ */ T({
725
- __name: "index",
726
- props: {
727
- search: {},
728
- gridCtrl: {},
729
- likeFields: {}
730
- },
731
- emits: ["update:search", "onsearch", "onreset"],
732
- setup(l, { emit: a }) {
733
- const e = l, t = a, o = y(0), n = y(0), i = y(0), p = (c) => {
734
- let g = 0;
735
- for (let $ = 0; $ < c.length; $++)
736
- typeof c[$].type == "object" && g++;
737
- return g;
738
- }, d = Rt(), u = () => {
739
- n.value = 0, i.value = 0, d.default && (n.value = p(d.default({}))), e.gridCtrl && e.gridCtrl.searchBar && d.control && (i.value = p(d.control({}))), o.value = 2 - (n.value + i.value) % 3;
740
- };
741
- F(
742
- () => {
743
- var c;
744
- return (c = e.gridCtrl) == null ? void 0 : c.searchBar;
745
- },
746
- () => {
747
- u();
748
- }
749
- );
750
- const v = JSON.parse(JSON.stringify(e.search));
751
- ee(() => {
752
- var g;
753
- u();
754
- let c = { ...e.search };
755
- e.gridCtrl && (e.gridCtrl.gridQuery = {
756
- ...e.gridCtrl.gridQuery,
757
- Query: {
758
- ...(g = e.gridCtrl.gridQuery) == null ? void 0 : g.Query,
759
- ...c
760
- }
761
- });
762
- });
763
- const s = () => {
764
- var g;
765
- let c = { ...e.search };
766
- if (e.likeFields)
767
- for (const $ of e.likeFields)
768
- c[$] && (c[$] = { $like: "%" + c[$] + "%" });
769
- e.gridCtrl && (e.gridCtrl.gridQuery = {
770
- ...e.gridCtrl.gridQuery,
771
- Query: {
772
- ...(g = e.gridCtrl.gridQuery) == null ? void 0 : g.Query,
773
- ...c
774
- }
775
- }, e.gridCtrl.pageNo.value = 1, e.gridCtrl.reload.value = !0), t("onsearch", c);
776
- }, m = () => {
777
- const c = JSON.parse(JSON.stringify(v));
778
- for (const g in e.search)
779
- c[g] === void 0 && (c[g] = void 0);
780
- t("update:search", c), t("onreset");
781
- };
782
- return (c, g) => {
783
- const $ = ne("submit");
784
- return n.value + i.value > 0 ? X((f(), b(r(et), {
785
- key: 0,
786
- "label-col": { flex: "60px" },
787
- style: {
788
- flexWrap: "wrap",
789
- borderBottom: "1px solid #e9e9e9"
790
- },
791
- class: "flex mb-[10px]"
792
- }, {
793
- default: h(() => {
794
- var E, P;
795
- return [
796
- D(c.$slots, "default"),
797
- (E = c.gridCtrl) != null && E.searchBar ? D(c.$slots, "control", { key: 0 }) : C("", !0),
798
- o.value >= 1 ? (f(), b(we, {
799
- key: 1,
800
- class: "w-1/3"
801
- })) : C("", !0),
802
- o.value >= 2 ? (f(), b(we, {
803
- key: 2,
804
- class: "w-1/3"
805
- })) : C("", !0),
806
- n.value || (P = c.gridCtrl) != null && P.searchBar ? (f(), b(we, {
807
- key: 3,
808
- class: "w-1/3 flex justify-end text-right pr-5",
809
- "wrapper-col": { flex: "auto" }
810
- }, {
811
- default: h(() => [
812
- S(r(de), null, {
813
- default: h(() => [
814
- S(r(W), {
815
- type: "primary",
816
- onClick: s,
817
- icon: "icon-search"
818
- }, {
819
- default: h(() => g[0] || (g[0] = [
820
- O("搜索")
821
- ])),
822
- _: 1,
823
- __: [0]
824
- }),
825
- S(r(W), {
826
- onClick: m,
827
- icon: "icon-reset"
828
- }, {
829
- default: h(() => g[1] || (g[1] = [
830
- O("重置")
831
- ])),
832
- _: 1,
833
- __: [1]
834
- })
835
- ]),
836
- _: 1
837
- })
838
- ]),
839
- _: 1
840
- })) : C("", !0)
841
- ];
842
- }),
843
- _: 3
844
- })), [
845
- [$, s]
846
- ]) : C("", !0);
847
- };
848
- }
849
- }), Da = /* @__PURE__ */ T({
850
- __name: "tableOperate",
675
+ }), Pa = /* @__PURE__ */ T({
676
+ __name: "listOperate",
851
677
  props: {
852
678
  record: {},
853
679
  gridCtrl: {}
854
680
  },
855
- setup(l) {
856
- const a = l, e = a.gridCtrl, t = Y(() => ge.currentRoute.value.path), o = [
681
+ setup(r) {
682
+ const a = r, e = a.gridCtrl, t = R(() => ue.currentRoute.value.path), o = [
857
683
  {
858
684
  key: "Edit",
859
- label: "编辑",
860
- type: "primary",
685
+ label: "",
686
+ icon: "icon-edit",
687
+ type: "text",
861
688
  visible: !0,
862
689
  role: ["Super", "Admin"],
863
690
  permit: ":edit",
864
- click: () => gt(e, a.record)
691
+ click: () => Qe(e, a.record)
865
692
  },
866
693
  {
867
694
  key: "Delete",
868
- label: "删除",
869
- type: "primary",
695
+ label: "",
696
+ icon: "icon-delete",
697
+ type: "text",
870
698
  visible: !0,
871
699
  danger: !0,
872
700
  role: ["Super", "Admin"],
873
701
  permit: ":delete",
874
702
  confirm: !0,
875
703
  confirmText: "是否删除此记录?",
876
- click: () => bt(e, a.record)
704
+ click: () => Ge(e, a.record)
877
705
  }
878
- ], { buttons: n, menus: i } = Me(o, 0, e.operates), p = (d) => {
879
- if (typeof d.disabled == "boolean")
880
- return d.disabled;
881
- if (typeof d.disabled == "function")
882
- return le(d, a.record) ?? !1;
883
- if (a.record.hasOwnProperty("Enabled"))
884
- switch (d.key) {
706
+ ], { buttons: n, menus: i } = Ce(o, 0, e.operates), p = (c) => {
707
+ if (typeof c.disabled == "boolean")
708
+ return c.disabled;
709
+ if (typeof c.disabled == "function")
710
+ return te(c, a.record) ?? !1;
711
+ if (a.record.hasOwnProperty(e.statusKey))
712
+ switch (c.key) {
885
713
  case "Edit":
886
- return !a.record.Enabled;
714
+ return !a.record[e.statusKey];
887
715
  case "Delete":
888
- return !!a.record.Enabled;
716
+ return !!a.record[e.statusKey];
889
717
  }
890
718
  return !1;
891
719
  };
892
- return (d, u) => {
893
- const v = ne("auth");
894
- return f(), b(r(Ae), { theme: {
720
+ return (c, u) => {
721
+ const f = re("auth");
722
+ return v(), b(l(be), { theme: {
895
723
  token: {
896
724
  fontSize: 13
897
725
  }
898
726
  } }, {
899
727
  default: h(() => [
900
- S(r(de), null, {
728
+ S(l(ie), null, {
901
729
  default: h(() => [
902
- (f(!0), w(A, null, H(r(n), (s) => (f(), w(A, {
730
+ (v(!0), w(L, null, V(l(n), (s) => (v(), w(L, {
903
731
  key: s.key
904
732
  }, [
905
- r(se)(s, a.record) ? (f(), b(r(Wt), {
733
+ l(J)(s, a.record) ? (v(), b(l(nt), {
906
734
  key: 0,
907
735
  disabled: p(s) || !s.confirm,
908
736
  cancelText: "否",
@@ -910,72 +738,69 @@ const Il = async (l, a) => {
910
738
  title: s.confirmText,
911
739
  okButtonProps: { size: "small" },
912
740
  cancelButtonProps: { size: "small" },
913
- onConfirm: (m) => r(J)(s, r(e).page, r(e), a.record, !0)
741
+ onConfirm: (m) => l(Y)(s, l(e).page, l(e), a.record, !0)
914
742
  }, {
915
743
  default: h(() => [
916
- r(se)(s, a.record) ? X((f(), b(r(at), {
744
+ l(J)(s, a.record) ? W((v(), b(l(K), {
917
745
  key: s.key,
918
- type: s.type ?? "text",
746
+ icon: s.icon,
919
747
  danger: s.danger,
920
748
  disabled: p(s),
921
- onClick: (m) => r(J)(s, r(e).page, r(e), a.record),
922
- size: "small",
923
- style: De({
924
- padding: s.type ?? "0px 4px"
925
- })
926
- }, {
927
- default: h(() => [
928
- O(M(s.label), 1)
929
- ]),
930
- _: 2
931
- }, 1032, ["type", "danger", "disabled", "onClick", "style"])), [
932
- [v, { url: t.value, role: s.role, permit: s.permit }]
933
- ]) : C("", !0)
749
+ onClick: (m) => !p(s) && l(Y)(s, l(e).page, l(e), a.record),
750
+ clickable: !p(s),
751
+ class: E([
752
+ "w-4 h-4",
753
+ s.danger ? "text-red-500" : "text-gray-600",
754
+ p(s) ? "opacity-30 cursor-not-allowed" : "hover:text-gray-800"
755
+ ])
756
+ }, null, 8, ["icon", "danger", "disabled", "onClick", "clickable", "class"])), [
757
+ [f, { url: t.value, role: s.role, permit: s.permit }]
758
+ ]) : x("", !0)
934
759
  ]),
935
760
  _: 2
936
- }, 1032, ["disabled", "title", "onConfirm"])) : C("", !0)
761
+ }, 1032, ["disabled", "title", "onConfirm"])) : x("", !0)
937
762
  ], 64))), 128)),
938
- d.record.Enabled == 1 ? (f(), b(r(Ae), {
763
+ c.record[l(e).statusKey] == 1 ? (v(), b(l(be), {
939
764
  key: 0,
940
765
  autoInsertSpaceInButton: !1
941
766
  }, {
942
767
  default: h(() => [
943
- r(i).length > 0 ? (f(), b(r(qt), {
768
+ l(i).length > 0 ? (v(), b(l(it), {
944
769
  key: 0,
945
770
  size: "small"
946
771
  }, {
947
772
  overlay: h(() => [
948
- S(r(Ue), null, {
773
+ S(l(ke), null, {
949
774
  default: h(() => [
950
- (f(!0), w(A, null, H(r(i), (s) => (f(), w(A, {
775
+ (v(!0), w(L, null, V(l(i), (s) => (v(), w(L, {
951
776
  key: s.key
952
777
  }, [
953
- r(se)(s, a.record) ? X((f(), b(r(Le), {
778
+ l(J)(s, a.record) ? W((v(), b(l(we), {
954
779
  key: 0,
955
780
  disabled: p(s),
956
- onClick: (m) => r(J)(s, r(e).page, r(e), a.record)
781
+ onClick: (m) => l(Y)(s, l(e).page, l(e), a.record)
957
782
  }, {
958
783
  default: h(() => [
959
- O(M(s.label), 1)
784
+ M(N(s.label), 1)
960
785
  ]),
961
786
  _: 2
962
787
  }, 1032, ["disabled", "onClick"])), [
963
- [v, { url: t.value, role: s.role, permit: s.permit }]
964
- ]) : C("", !0)
788
+ [f, { url: t.value, role: s.role, permit: s.permit }]
789
+ ]) : x("", !0)
965
790
  ], 64))), 128))
966
791
  ]),
967
792
  _: 1
968
793
  })
969
794
  ]),
970
795
  default: h(() => [
971
- u[0] || (u[0] = O(" 更多 "))
796
+ u[0] || (u[0] = M(" 更多 "))
972
797
  ]),
973
798
  _: 1,
974
799
  __: [0]
975
- })) : C("", !0)
800
+ })) : x("", !0)
976
801
  ]),
977
802
  _: 1
978
- })) : C("", !0)
803
+ })) : x("", !0)
979
804
  ]),
980
805
  _: 1
981
806
  })
@@ -984,93 +809,93 @@ const Il = async (l, a) => {
984
809
  });
985
810
  };
986
811
  }
987
- }), Pa = { class: "inline-flex [&>div]:ml-[-1px] first:[&>div]:ml-0" }, Ua = /* @__PURE__ */ T({
812
+ }), Ea = { class: "inline-flex [&>div]:ml-[-1px] first:[&>div]:ml-0" }, La = /* @__PURE__ */ T({
988
813
  __name: "icontool",
989
814
  props: {
990
815
  gridCtrl: {}
991
816
  },
992
- setup(l) {
993
- const a = l, e = a.gridCtrl, { tools: t } = xa(a.gridCtrl), o = Te();
994
- F(
817
+ setup(r) {
818
+ const a = r, e = a.gridCtrl, { tools: t } = Ca(a.gridCtrl), o = Ue();
819
+ I(
995
820
  () => e.selectable.value,
996
821
  (p) => {
997
- ae(t, "tool.export.excel.selected") && (ae(t, "tool.export.excel.selected").disabled = !p), ae(t, "tool.export.pdf.selected") && (ae(t, "tool.export.pdf.selected").disabled = !p);
822
+ oe(t, "tool.export.excel.selected") && (oe(t, "tool.export.excel.selected").disabled = !p), oe(t, "tool.export.pdf.selected") && (oe(t, "tool.export.pdf.selected").disabled = !p);
998
823
  }
999
824
  );
1000
825
  const n = y([]);
1001
- F(
826
+ I(
1002
827
  () => e.columns.value,
1003
828
  (p) => {
1004
- n.value = He(p, !0);
829
+ n.value = Je(p, !0);
1005
830
  },
1006
831
  { deep: !0, immediate: !0 }
1007
832
  );
1008
833
  const i = () => {
1009
- e.columns.value.splice(0, e.columns.value.length, ...n.value), o.setTableColumns(ge.currentRoute.value.path, e.columns.value);
834
+ e.columns.value.splice(0, e.columns.value.length, ...n.value), o.setTableColumns(ue.currentRoute.value.path, e.columns.value);
1010
835
  };
1011
- return (p, d) => (f(), w("div", Pa, [
1012
- (f(!0), w(A, null, H(r(t), (u, v) => (f(), w(A, {
836
+ return (p, c) => (v(), w("div", Ea, [
837
+ (v(!0), w(L, null, V(l(t), (u, f) => (v(), w(L, {
1013
838
  key: u.key
1014
839
  }, [
1015
- r(se)(u) && u.dropdown ? (f(), b(r(Se), {
840
+ l(J)(u) && u.dropdown ? (v(), b(l(Ee), {
1016
841
  key: 0,
1017
842
  placement: "bottomRight",
1018
843
  class: "p-0 rounded-none"
1019
844
  }, {
1020
845
  overlay: h(() => [
1021
- I("div", {
1022
- class: U(["min-w-[100px] bg-white rounded shadow-md p-4", u.dropdownClass])
846
+ D("div", {
847
+ class: E(["min-w-[100px] bg-white rounded shadow-md p-4", u.dropdownClass])
1023
848
  }, [
1024
- u.dropdown === "headset" ? (f(), b(r(ia), {
849
+ u.dropdown === "headset" ? (v(), b(l(pa), {
1025
850
  key: 0,
1026
851
  modelValue: n.value,
1027
- "onUpdate:modelValue": d[1] || (d[1] = (s) => n.value = s),
852
+ "onUpdate:modelValue": c[1] || (c[1] = (s) => n.value = s),
1028
853
  "item-key": "dataIndex",
1029
854
  onEnd: i,
1030
855
  handle: ".drag-handle"
1031
856
  }, {
1032
857
  default: h(() => [
1033
- (f(!0), w(A, null, H(n.value, (s) => (f(), w("div", {
858
+ (v(!0), w(L, null, V(n.value, (s) => (v(), w("div", {
1034
859
  key: s.name,
1035
- onClick: d[0] || (d[0] = ce(() => {
860
+ onClick: c[0] || (c[0] = pe(() => {
1036
861
  }, ["stop"])),
1037
862
  class: "flex items-center mb-2 last:mb-0 select-none"
1038
863
  }, [
1039
- d[2] || (d[2] = I("span", { class: "drag-handle mr-2 text-gray-400 hover:text-gray-600 cursor-move" }, "⋮⋮", -1)),
1040
- S(r(Ht), {
864
+ c[2] || (c[2] = D("span", { class: "drag-handle mr-2 text-gray-400 hover:text-gray-600 cursor-move" }, "⋮⋮", -1)),
865
+ S(l(Qt), {
1041
866
  checked: s.visible !== !1,
1042
- onChange: ce(
867
+ onChange: pe(
1043
868
  (m) => {
1044
- r(ya)(s, m.target.checked);
869
+ l(wa)(s, m.target.checked);
1045
870
  },
1046
871
  ["stop", "prevent"]
1047
872
  ),
1048
873
  class: "text-gray-700 hover:text-gray-900 select-none"
1049
874
  }, {
1050
875
  default: h(() => [
1051
- O(M(s.title), 1)
876
+ M(N(s.title), 1)
1052
877
  ]),
1053
878
  _: 2
1054
879
  }, 1032, ["checked", "onChange"])
1055
880
  ]))), 128))
1056
881
  ]),
1057
882
  _: 1
1058
- }, 8, ["modelValue"])) : C("", !0)
883
+ }, 8, ["modelValue"])) : x("", !0)
1059
884
  ], 2)
1060
885
  ]),
1061
886
  default: h(() => [
1062
- S(r(W), {
1063
- class: U([
887
+ S(l(Q), {
888
+ class: E([
1064
889
  "px-[8px] py-[2px] relative border-[#ccc] bg-[#fcfcfc] rounded-none text-[#666] hover:z-10",
1065
- v === 0 ? "rounded-l-[5px]" : "",
1066
- v === r(t).length - 1 ? "rounded-r-[5px]" : ""
890
+ f === 0 ? "rounded-l-[5px]" : "",
891
+ f === l(t).length - 1 ? "rounded-r-[5px]" : ""
1067
892
  ]),
1068
- disabled: r(le)(u),
893
+ disabled: l(te)(u),
1069
894
  tiptext: u.label,
1070
- onClick: (s) => r(J)(u, r(e).page, r(e))
895
+ onClick: (s) => l(Y)(u, l(e).page, l(e))
1071
896
  }, {
1072
897
  default: h(() => [
1073
- S(r(K), {
898
+ S(l(K), {
1074
899
  icon: u.icon,
1075
900
  class: "w-[18px] h-[18.5px]",
1076
901
  clickable: ""
@@ -1080,39 +905,39 @@ const Il = async (l, a) => {
1080
905
  }, 1032, ["class", "disabled", "tiptext", "onClick"])
1081
906
  ]),
1082
907
  _: 2
1083
- }, 1024)) : !u.children && r(se)(u) ? (f(), b(r(W), {
908
+ }, 1024)) : !u.children && l(J)(u) ? (v(), b(l(Q), {
1084
909
  key: 1,
1085
- class: U([
910
+ class: E([
1086
911
  "px-[8px] py-[2px] relative border-[#ccc] bg-[#fcfcfc] rounded-none text-[#666] hover:z-10",
1087
- v === 0 ? "rounded-l-[5px]" : "",
1088
- v === r(t).length - 1 ? "rounded-r-[5px]" : ""
912
+ f === 0 ? "rounded-l-[5px]" : "",
913
+ f === l(t).length - 1 ? "rounded-r-[5px]" : ""
1089
914
  ]),
1090
- disabled: r(le)(u),
915
+ disabled: l(te)(u),
1091
916
  tiptext: u.label,
1092
- onClick: (s) => r(J)(u, r(e).page, r(e))
917
+ onClick: (s) => l(Y)(u, l(e).page, l(e))
1093
918
  }, {
1094
919
  default: h(() => [
1095
- S(r(K), {
920
+ S(l(K), {
1096
921
  icon: u.icon,
1097
922
  class: "w-[18px] h-[18.5px]",
1098
923
  clickable: ""
1099
924
  }, null, 8, ["icon"])
1100
925
  ]),
1101
926
  _: 2
1102
- }, 1032, ["class", "disabled", "tiptext", "onClick"])) : r(se)(u) ? (f(), b(r(Se), {
927
+ }, 1032, ["class", "disabled", "tiptext", "onClick"])) : l(J)(u) ? (v(), b(l(Ee), {
1103
928
  key: 2,
1104
929
  placement: "bottomRight",
1105
930
  class: "p-0 rounded-none"
1106
931
  }, {
1107
932
  overlay: h(() => [
1108
- S(r(Ue), null, {
933
+ S(l(ke), null, {
1109
934
  default: h(() => [
1110
- (f(!0), w(A, null, H(u.children, (s) => (f(), b(r(Le), {
935
+ (v(!0), w(L, null, V(u.children, (s) => (v(), b(l(we), {
1111
936
  key: s.key,
1112
- disabled: r(le)(s)
937
+ disabled: l(te)(s)
1113
938
  }, {
1114
939
  default: h(() => [
1115
- O(M(s.label), 1)
940
+ M(N(s.label), 1)
1116
941
  ]),
1117
942
  _: 2
1118
943
  }, 1032, ["disabled"]))), 128))
@@ -1121,19 +946,19 @@ const Il = async (l, a) => {
1121
946
  }, 1024)
1122
947
  ]),
1123
948
  default: h(() => [
1124
- S(r(W), {
1125
- class: U([
949
+ S(l(Q), {
950
+ class: E([
1126
951
  "!w-[46px] px-[5px] py-[2px] relative border-[#ccc] bg-[#fcfcfc] rounded-none text-[#666] hover:z-10",
1127
- v === 0 ? "rounded-l-[5px]" : ""
952
+ f === 0 ? "rounded-l-[5px]" : ""
1128
953
  ]),
1129
- disabled: r(le)(u),
954
+ disabled: l(te)(u),
1130
955
  tiptext: u.label,
1131
956
  icon: u.icon,
1132
957
  iconProps: { class: "w-[19px] h-[19px]" },
1133
- onClick: (s) => r(J)(u, r(e).page, r(e))
958
+ onClick: (s) => l(Y)(u, l(e).page, l(e))
1134
959
  }, {
1135
960
  default: h(() => [
1136
- S(r(K), {
961
+ S(l(K), {
1137
962
  icon: "icon-down-arrow",
1138
963
  class: "w-[12px] h-[12px]"
1139
964
  })
@@ -1142,18 +967,18 @@ const Il = async (l, a) => {
1142
967
  }, 1032, ["class", "disabled", "tiptext", "icon", "onClick"])
1143
968
  ]),
1144
969
  _: 2
1145
- }, 1024)) : C("", !0)
970
+ }, 1024)) : x("", !0)
1146
971
  ], 64))), 128))
1147
972
  ]));
1148
973
  }
1149
- }), La = { class: "flex justify-between mb-[10px]" }, Ma = { key: 1 }, Ba = 3, Na = /* @__PURE__ */ T({
974
+ }), Ua = { class: "flex justify-between mb-[10px]" }, Na = { key: 1 }, Ba = 3, yt = /* @__PURE__ */ T({
1150
975
  __name: "index",
1151
976
  props: {
1152
977
  gridCtrl: {},
1153
978
  editorCtrl: {}
1154
979
  },
1155
- setup(l) {
1156
- const a = l, e = a.gridCtrl, t = e.page, o = a.editorCtrl, n = Y(() => ge.currentRoute.value.path), i = [
980
+ setup(r) {
981
+ const a = r, e = a.gridCtrl, t = e.page, o = a.editorCtrl, n = R(() => ue.currentRoute.value.path), i = [
1157
982
  {
1158
983
  key: "New",
1159
984
  label: "新增",
@@ -1163,58 +988,58 @@ const Il = async (l, a) => {
1163
988
  role: ["Super", "Admin"],
1164
989
  permit: ":new",
1165
990
  // 默认仅受权限码控制
1166
- click: () => yt(o)
991
+ click: () => St(o)
1167
992
  }
1168
- ], p = y([]), d = y([]);
1169
- return F(
993
+ ], p = y([]), c = y([]);
994
+ return I(
1170
995
  () => {
1171
996
  var u;
1172
997
  return (u = e.buttons) == null ? void 0 : u.value;
1173
998
  },
1174
999
  () => {
1175
1000
  var s;
1176
- const { buttons: u, menus: v } = Me(
1001
+ const { buttons: u, menus: f } = Ce(
1177
1002
  i,
1178
1003
  e.flat !== void 0 ? e.flat : Ba,
1179
1004
  (s = e.buttons) == null ? void 0 : s.value
1180
1005
  );
1181
- p.value.splice(0, p.value.length, ...u), d.value.splice(0, d.value.length, ...v);
1006
+ p.value.splice(0, p.value.length, ...u), c.value.splice(0, c.value.length, ...f);
1182
1007
  },
1183
1008
  {
1184
1009
  deep: !0,
1185
1010
  immediate: !0
1186
1011
  }
1187
- ), (u, v) => {
1188
- const s = ne("auth");
1189
- return f(), w("div", La, [
1190
- S(r(de), null, {
1012
+ ), (u, f) => {
1013
+ const s = re("auth");
1014
+ return v(), w("div", Ua, [
1015
+ S(l(ie), null, {
1191
1016
  default: h(() => [
1192
- (f(!0), w(A, null, H(p.value, (m) => X((f(), b(r(W), {
1017
+ (v(!0), w(L, null, V(p.value, (m) => W((v(), b(l(Q), {
1193
1018
  key: m.key,
1194
1019
  type: m.type,
1195
1020
  danger: m.danger,
1196
- disabled: r(le)(m),
1021
+ disabled: l(te)(m),
1197
1022
  icon: m.icon,
1198
- onClick: (c) => r(J)(m, r(t), r(e))
1023
+ onClick: (d) => l(Y)(m, l(t), l(e))
1199
1024
  }, {
1200
1025
  default: h(() => [
1201
- O(M(m.label), 1)
1026
+ M(N(m.label), 1)
1202
1027
  ]),
1203
1028
  _: 2
1204
1029
  }, 1032, ["type", "danger", "disabled", "icon", "onClick"])), [
1205
1030
  [s, { url: n.value, role: m.role, permit: m.permit }]
1206
1031
  ])), 128)),
1207
- d.value.length > 0 ? (f(), b(r(Se), { key: 0 }, {
1032
+ c.value.length > 0 ? (v(), b(l(Ee), { key: 0 }, {
1208
1033
  overlay: h(() => [
1209
- S(r(Ue), null, {
1034
+ S(l(ke), null, {
1210
1035
  default: h(() => [
1211
- (f(!0), w(A, null, H(d.value, (m) => X((f(), b(r(Le), {
1036
+ (v(!0), w(L, null, V(c.value, (m) => W((v(), b(l(we), {
1212
1037
  key: m.key,
1213
- disabled: r(le)(m),
1214
- onClick: (c) => r(J)(m, r(t), r(e))
1038
+ disabled: l(te)(m),
1039
+ onClick: (d) => l(Y)(m, l(t), l(e))
1215
1040
  }, {
1216
1041
  default: h(() => [
1217
- O(M(m.label), 1)
1042
+ M(N(m.label), 1)
1218
1043
  ]),
1219
1044
  _: 2
1220
1045
  }, 1032, ["disabled", "onClick"])), [
@@ -1225,30 +1050,454 @@ const Il = async (l, a) => {
1225
1050
  })
1226
1051
  ]),
1227
1052
  default: h(() => [
1228
- S(r(W), null, {
1229
- default: h(() => v[0] || (v[0] = [
1230
- O(" 更多操作 ")
1053
+ S(l(Q), null, {
1054
+ default: h(() => f[0] || (f[0] = [
1055
+ M(" 更多操作 ")
1231
1056
  ])),
1232
1057
  _: 1,
1233
1058
  __: [0]
1234
1059
  })
1235
1060
  ]),
1236
1061
  _: 1
1237
- })) : C("", !0),
1238
- p.value.length === 0 && d.value.length === 0 ? (f(), w("span", Ma)) : C("", !0)
1062
+ })) : x("", !0),
1063
+ p.value.length === 0 && c.value.length === 0 ? (v(), w("span", Na)) : x("", !0)
1239
1064
  ]),
1240
1065
  _: 1
1241
1066
  }),
1242
- S(r(de), { class: "mr-1" }, {
1067
+ S(l(ie), { class: "mr-1" }, {
1243
1068
  default: h(() => [
1244
- (f(), b(At(Ua), { "grid-ctrl": r(e) }, null, 8, ["grid-ctrl"]))
1069
+ (v(), b(Kt(La), { "grid-ctrl": l(e) }, null, 8, ["grid-ctrl"]))
1245
1070
  ]),
1246
1071
  _: 1
1247
1072
  })
1248
1073
  ]);
1249
1074
  };
1250
1075
  }
1251
- }), Rl = /* @__PURE__ */ T({
1076
+ }), Ma = { class: "flex items-center justify-between" }, za = { class: "flex items-center space-x-2" }, Vl = /* @__PURE__ */ T({
1077
+ inheritAttrs: !1,
1078
+ __name: "index",
1079
+ props: {
1080
+ gridCtrl: {},
1081
+ primaryKey: {},
1082
+ listData: {},
1083
+ grid: { default: () => ({ gutter: 16, column: 4 }) },
1084
+ pagination: { type: [Boolean, Object], default: void 0 },
1085
+ titleField: { default: "Title" },
1086
+ statusDisabled: {}
1087
+ },
1088
+ setup(r) {
1089
+ const a = r, e = ne(), t = a.gridCtrl, o = R(() => ue.currentRoute.value.path);
1090
+ t && (t.pageNo.value = 1, t.total.value = 0, t.pageSize.value = t.pageSize.value);
1091
+ const n = y(t.pageSize.value), i = y(t.pageNo.value), p = y([]), c = y({
1092
+ total: 0,
1093
+ current: 1,
1094
+ pageSize: n.value,
1095
+ showTotal: (f) => `共 ${f} 条记录`,
1096
+ onChange: (f, s) => {
1097
+ c.value !== !1 && (c.value.current = f, c.value.pageSize = s), n.value = s, i.value = f, t && (t.pageNo.value = f, t.pageSize.value = s, t.remotePage && me(t));
1098
+ },
1099
+ ...a.pagination === !1 ? {} : a.pagination
1100
+ });
1101
+ a.pagination === !1 && (c.value = !1), I(
1102
+ () => t.tableData.value,
1103
+ (f) => {
1104
+ f && (p.value = f, c.value !== !1 && (c.value.total = t.total.value ?? 0, c.value.current = t.pageNo.value ?? 1, c.value.pageSize = t.pageSize.value ?? 10));
1105
+ },
1106
+ { immediate: !0 }
1107
+ ), I(
1108
+ () => a.listData,
1109
+ (f) => {
1110
+ f && (p.value = f, c.value !== !1 && (c.value.total = f.length, c.value.current = t.pageNo.value ?? 1, c.value.pageSize = t.pageSize.value ?? 10));
1111
+ },
1112
+ { immediate: !0 }
1113
+ );
1114
+ const u = y(!1);
1115
+ return xe(() => {
1116
+ u.value && t && t.autoload && (t.reload.value = !0);
1117
+ }), X(async () => {
1118
+ var f, s, m, d, g;
1119
+ _e(ae.GridControl, t), t.page && ((f = t.gridUrl) != null && f.url) && (((s = t.gridUrl) == null ? void 0 : s.url) === ((m = t.page.urls.list) == null ? void 0 : m.url) && (t.remotePage = !1), ((d = t.gridUrl) == null ? void 0 : d.url) === ((g = t.page.urls.find) == null ? void 0 : g.url) && (t.remotePage = !0)), t.tableData.value ? (p.value = t.tableData.value, t.total.value = p.value.length, c.value !== !1 && (c.value.total = t.total.value ?? 0)) : t.autoload !== !1 && (t.remotePage ? p.value = (await me(t)).rows : p.value = await Xe(t)), setTimeout(() => {
1120
+ u.value = !0;
1121
+ }, 50);
1122
+ }), (f, s) => {
1123
+ var d, g;
1124
+ const m = re("auth");
1125
+ return v(), w(L, null, [
1126
+ (d = l(t).buttons) != null && d.value.length || (g = l(t).tools) != null && g.length ? (v(), b(yt, {
1127
+ key: 0,
1128
+ "grid-ctrl": l(t),
1129
+ "editor-ctrl": l(t).editor
1130
+ }, null, 8, ["grid-ctrl", "editor-ctrl"])) : x("", !0),
1131
+ u.value ? (v(), b(l(Gt), B({
1132
+ key: 1,
1133
+ class: "w-full min-h-[480px]",
1134
+ grid: a.grid,
1135
+ "data-source": p.value,
1136
+ loading: l(t).isGridLoading.value,
1137
+ pagination: c.value
1138
+ }, l(e)), {
1139
+ renderItem: h(({ item: C }) => [
1140
+ S(l(Jt), { class: "!m-0 !p-0" }, {
1141
+ default: h(() => [
1142
+ S(l(Xt), {
1143
+ class: "!m-0",
1144
+ "head-style": { fontSize: "14px", padding: "8px", minHeight: "36px", height: "36px" },
1145
+ "body-style": { padding: "4px" }
1146
+ }, {
1147
+ title: h(() => [
1148
+ D("div", Ma, [
1149
+ D("span", null, N(C[a.titleField]), 1),
1150
+ D("div", za, [
1151
+ W(S(Ze, {
1152
+ checked: C[l(t).statusKey],
1153
+ "onUpdate:checked": (F) => C[l(t).statusKey] = F,
1154
+ disabled: f.statusDisabled ? f.statusDisabled(C) : !1,
1155
+ data: l(Ne).EnableDisable,
1156
+ onClick: (F) => l(et)(l(t), C),
1157
+ size: "small",
1158
+ class: E([
1159
+ "relative mt-[3px] transform scale-[1.1]",
1160
+ f.statusDisabled && f.statusDisabled(C) ? "cursor-not-allowed disabled" : ""
1161
+ ]),
1162
+ loading: C.isLoading
1163
+ }, null, 8, ["checked", "onUpdate:checked", "disabled", "data", "onClick", "class", "loading"]), [
1164
+ [m, { url: o.value, role: ["Super", "Admin"], permit: ":enabled" }, "disable"]
1165
+ ]),
1166
+ S(Pa, {
1167
+ record: C,
1168
+ "grid-ctrl": l(t)
1169
+ }, null, 8, ["record", "grid-ctrl"])
1170
+ ])
1171
+ ])
1172
+ ]),
1173
+ default: h(() => [
1174
+ P(f.$slots, "cardContent", { record: C })
1175
+ ]),
1176
+ _: 2
1177
+ }, 1024)
1178
+ ]),
1179
+ _: 2
1180
+ }, 1024)
1181
+ ]),
1182
+ _: 3
1183
+ }, 16, ["grid", "data-source", "loading", "pagination"])) : x("", !0)
1184
+ ], 64);
1185
+ };
1186
+ }
1187
+ }), Oa = { class: "w-1/3 relative mb-1" }, Aa = { class: "flex items-center w-[90%]" }, Ra = { class: "flex-grow pl-1" }, Ka = {
1188
+ key: 0,
1189
+ class: "absolute bottom-[3px] left-[85px] text-[12px] text-[#ff4d4fcc] block"
1190
+ }, Fe = /* @__PURE__ */ T({
1191
+ inheritAttrs: !1,
1192
+ __name: "searchItem",
1193
+ props: {
1194
+ label: {},
1195
+ width: {},
1196
+ rule: {}
1197
+ },
1198
+ setup(r) {
1199
+ const a = r, e = ne(), t = ge(ae.EditorControl, void 0), o = qe(a, t), n = R(() => {
1200
+ var p;
1201
+ if (!a.rule)
1202
+ return !1;
1203
+ const i = He(a.rule.split("."), (p = t == null ? void 0 : t.formRules) == null ? void 0 : p.value);
1204
+ return i ? (i.required || (o.value.errClass = "", o.value.msg = ""), i.required ?? !0) : (G.error(`"${a.label}" 的验证规则 \`${a.rule}\` 不存在`), o.value.errClass = "text-[#ff4d4f]", o.value.msg = `规则 \`${a.rule}\` 不存在,请检查代码!`, !0);
1205
+ });
1206
+ return (i, p) => (v(), w("div", Oa, [
1207
+ S(l(ot), B({
1208
+ required: n.value,
1209
+ class: "w-[90%] relative"
1210
+ }, l(e), {
1211
+ class: [i.rule ? "" : "mb-3", i.width],
1212
+ labelCol: { span: 6 }
1213
+ }), lt({
1214
+ default: h(() => [
1215
+ D("div", Aa, [
1216
+ D("div", Ra, [
1217
+ P(i.$slots, "default")
1218
+ ])
1219
+ ])
1220
+ ]),
1221
+ _: 2
1222
+ }, [
1223
+ i.label ? {
1224
+ name: "label",
1225
+ fn: h(() => [
1226
+ D("span", {
1227
+ class: E([l(o).errClass ? "text-[#ff4d4f]" : "", "w-full"])
1228
+ }, N(i.label), 3)
1229
+ ]),
1230
+ key: "0"
1231
+ } : void 0
1232
+ ]), 1040, ["required", "class"]),
1233
+ l(o).msg ? (v(), w("span", Ka, N(l(o).msg), 1)) : x("", !0)
1234
+ ]));
1235
+ }
1236
+ }), Yl = /* @__PURE__ */ T({
1237
+ __name: "index",
1238
+ props: {
1239
+ search: {},
1240
+ gridCtrl: {},
1241
+ likeFields: {}
1242
+ },
1243
+ emits: ["update:search", "onsearch", "onreset"],
1244
+ setup(r, { emit: a }) {
1245
+ const e = r, t = a, o = y(0), n = y(0), i = y(0), p = (d) => {
1246
+ let g = 0;
1247
+ for (let C = 0; C < d.length; C++)
1248
+ typeof d[C].type == "object" && g++;
1249
+ return g;
1250
+ }, c = jt(), u = () => {
1251
+ n.value = 0, i.value = 0, c.default && (n.value = p(c.default({}))), e.gridCtrl && e.gridCtrl.searchBar && c.control && (i.value = p(c.control({}))), o.value = 2 - (n.value + i.value) % 3;
1252
+ };
1253
+ I(
1254
+ () => {
1255
+ var d;
1256
+ return (d = e.gridCtrl) == null ? void 0 : d.searchBar;
1257
+ },
1258
+ () => {
1259
+ u();
1260
+ }
1261
+ );
1262
+ const f = JSON.parse(JSON.stringify(e.search));
1263
+ X(() => {
1264
+ var g;
1265
+ u();
1266
+ let d = { ...e.search };
1267
+ e.gridCtrl && (e.gridCtrl.gridQuery = {
1268
+ ...e.gridCtrl.gridQuery,
1269
+ Query: {
1270
+ ...(g = e.gridCtrl.gridQuery) == null ? void 0 : g.Query,
1271
+ ...d
1272
+ }
1273
+ });
1274
+ });
1275
+ const s = () => {
1276
+ var g;
1277
+ let d = { ...e.search };
1278
+ if (e.likeFields)
1279
+ for (const C of e.likeFields)
1280
+ d[C] && (d[C] = { $like: "%" + d[C] + "%" });
1281
+ e.gridCtrl && (e.gridCtrl.gridQuery = {
1282
+ ...e.gridCtrl.gridQuery,
1283
+ Query: {
1284
+ ...(g = e.gridCtrl.gridQuery) == null ? void 0 : g.Query,
1285
+ ...d
1286
+ }
1287
+ }, e.gridCtrl.pageNo.value = 1, e.gridCtrl.reload.value = !0), t("onsearch", d);
1288
+ }, m = () => {
1289
+ const d = JSON.parse(JSON.stringify(f));
1290
+ for (const g in e.search)
1291
+ d[g] === void 0 && (d[g] = void 0);
1292
+ t("update:search", d), t("onreset");
1293
+ };
1294
+ return (d, g) => {
1295
+ const C = re("submit");
1296
+ return n.value + i.value > 0 ? W((v(), b(l(st), {
1297
+ key: 0,
1298
+ "label-col": { flex: "60px" },
1299
+ style: {
1300
+ flexWrap: "wrap",
1301
+ borderBottom: "1px solid #e9e9e9"
1302
+ },
1303
+ class: "flex mb-[10px]"
1304
+ }, {
1305
+ default: h(() => {
1306
+ var F, U;
1307
+ return [
1308
+ P(d.$slots, "default"),
1309
+ (F = d.gridCtrl) != null && F.searchBar ? P(d.$slots, "control", { key: 0 }) : x("", !0),
1310
+ o.value >= 1 ? (v(), b(Fe, {
1311
+ key: 1,
1312
+ class: "w-1/3"
1313
+ })) : x("", !0),
1314
+ o.value >= 2 ? (v(), b(Fe, {
1315
+ key: 2,
1316
+ class: "w-1/3"
1317
+ })) : x("", !0),
1318
+ n.value || (U = d.gridCtrl) != null && U.searchBar ? (v(), b(Fe, {
1319
+ key: 3,
1320
+ class: "w-1/3 flex justify-end text-right pr-5",
1321
+ "wrapper-col": { flex: "auto" }
1322
+ }, {
1323
+ default: h(() => [
1324
+ S(l(ie), null, {
1325
+ default: h(() => [
1326
+ S(l(Q), {
1327
+ type: "primary",
1328
+ onClick: s,
1329
+ icon: "icon-search"
1330
+ }, {
1331
+ default: h(() => g[0] || (g[0] = [
1332
+ M("搜索")
1333
+ ])),
1334
+ _: 1,
1335
+ __: [0]
1336
+ }),
1337
+ S(l(Q), {
1338
+ onClick: m,
1339
+ icon: "icon-reset"
1340
+ }, {
1341
+ default: h(() => g[1] || (g[1] = [
1342
+ M("重置")
1343
+ ])),
1344
+ _: 1,
1345
+ __: [1]
1346
+ })
1347
+ ]),
1348
+ _: 1
1349
+ })
1350
+ ]),
1351
+ _: 1
1352
+ })) : x("", !0)
1353
+ ];
1354
+ }),
1355
+ _: 3
1356
+ })), [
1357
+ [C, s]
1358
+ ]) : x("", !0);
1359
+ };
1360
+ }
1361
+ }), ja = /* @__PURE__ */ T({
1362
+ __name: "tableOperate",
1363
+ props: {
1364
+ record: {},
1365
+ gridCtrl: {}
1366
+ },
1367
+ setup(r) {
1368
+ const a = r, e = a.gridCtrl, t = R(() => ue.currentRoute.value.path), o = [
1369
+ {
1370
+ key: "Edit",
1371
+ label: "编辑",
1372
+ type: "primary",
1373
+ visible: !0,
1374
+ role: ["Super", "Admin"],
1375
+ permit: ":edit",
1376
+ click: () => Qe(e, a.record)
1377
+ },
1378
+ {
1379
+ key: "Delete",
1380
+ label: "删除",
1381
+ type: "primary",
1382
+ visible: !0,
1383
+ danger: !0,
1384
+ role: ["Super", "Admin"],
1385
+ permit: ":delete",
1386
+ confirm: !0,
1387
+ confirmText: "是否删除此记录?",
1388
+ click: () => Ge(e, a.record)
1389
+ }
1390
+ ], { buttons: n, menus: i } = Ce(o, 0, e.operates), p = (c) => {
1391
+ if (typeof c.disabled == "boolean")
1392
+ return c.disabled;
1393
+ if (typeof c.disabled == "function")
1394
+ return te(c, a.record) ?? !1;
1395
+ if (a.record.hasOwnProperty(e.statusKey))
1396
+ switch (c.key) {
1397
+ case "Edit":
1398
+ return !a.record[e.statusKey];
1399
+ // 启用时可编辑,停用时不可编辑
1400
+ case "Delete":
1401
+ return !!a.record[e.statusKey];
1402
+ }
1403
+ return !1;
1404
+ };
1405
+ return (c, u) => {
1406
+ const f = re("auth");
1407
+ return v(), b(l(be), { theme: {
1408
+ token: {
1409
+ fontSize: 13
1410
+ }
1411
+ } }, {
1412
+ default: h(() => [
1413
+ S(l(ie), null, {
1414
+ default: h(() => [
1415
+ (v(!0), w(L, null, V(l(n), (s) => (v(), w(L, {
1416
+ key: s.key
1417
+ }, [
1418
+ l(J)(s, a.record) ? (v(), b(l(nt), {
1419
+ key: 0,
1420
+ disabled: p(s) || !s.confirm,
1421
+ cancelText: "否",
1422
+ okText: "是",
1423
+ title: s.confirmText,
1424
+ okButtonProps: { size: "small" },
1425
+ cancelButtonProps: { size: "small" },
1426
+ onConfirm: (m) => l(Y)(s, l(e).page, l(e), a.record, !0)
1427
+ }, {
1428
+ default: h(() => [
1429
+ l(J)(s, a.record) ? W((v(), b(l(ut), {
1430
+ key: s.key,
1431
+ type: s.type ?? "text",
1432
+ danger: s.danger,
1433
+ disabled: p(s),
1434
+ onClick: (m) => l(Y)(s, l(e).page, l(e), a.record),
1435
+ size: "small",
1436
+ style: ze({
1437
+ padding: s.type ?? "0px 4px"
1438
+ })
1439
+ }, {
1440
+ default: h(() => [
1441
+ M(N(s.label), 1)
1442
+ ]),
1443
+ _: 2
1444
+ }, 1032, ["type", "danger", "disabled", "onClick", "style"])), [
1445
+ [f, { url: t.value, role: s.role, permit: s.permit }]
1446
+ ]) : x("", !0)
1447
+ ]),
1448
+ _: 2
1449
+ }, 1032, ["disabled", "title", "onConfirm"])) : x("", !0)
1450
+ ], 64))), 128)),
1451
+ c.record[l(e).statusKey] == 1 ? (v(), b(l(be), {
1452
+ key: 0,
1453
+ autoInsertSpaceInButton: !1
1454
+ }, {
1455
+ default: h(() => [
1456
+ l(i).length > 0 ? (v(), b(l(it), {
1457
+ key: 0,
1458
+ size: "small"
1459
+ }, {
1460
+ overlay: h(() => [
1461
+ S(l(ke), null, {
1462
+ default: h(() => [
1463
+ (v(!0), w(L, null, V(l(i), (s) => (v(), w(L, {
1464
+ key: s.key
1465
+ }, [
1466
+ l(J)(s, a.record) ? W((v(), b(l(we), {
1467
+ key: 0,
1468
+ disabled: p(s),
1469
+ onClick: (m) => l(Y)(s, l(e).page, l(e), a.record)
1470
+ }, {
1471
+ default: h(() => [
1472
+ M(N(s.label), 1)
1473
+ ]),
1474
+ _: 2
1475
+ }, 1032, ["disabled", "onClick"])), [
1476
+ [f, { url: t.value, role: s.role, permit: s.permit }]
1477
+ ]) : x("", !0)
1478
+ ], 64))), 128))
1479
+ ]),
1480
+ _: 1
1481
+ })
1482
+ ]),
1483
+ default: h(() => [
1484
+ u[0] || (u[0] = M(" 更多 "))
1485
+ ]),
1486
+ _: 1,
1487
+ __: [0]
1488
+ })) : x("", !0)
1489
+ ]),
1490
+ _: 1
1491
+ })) : x("", !0)
1492
+ ]),
1493
+ _: 1
1494
+ })
1495
+ ]),
1496
+ _: 1
1497
+ });
1498
+ };
1499
+ }
1500
+ }), Wl = /* @__PURE__ */ T({
1252
1501
  inheritAttrs: !1,
1253
1502
  __name: "index",
1254
1503
  props: {
@@ -1260,124 +1509,124 @@ const Il = async (l, a) => {
1260
1509
  scroll: {},
1261
1510
  statusDisabled: {}
1262
1511
  },
1263
- setup(l) {
1264
- const a = l, e = oe(), t = a.gridCtrl, o = Y(() => ge.currentRoute.value.path);
1512
+ setup(r) {
1513
+ const a = r, e = ne(), t = a.gridCtrl, o = R(() => ue.currentRoute.value.path);
1265
1514
  t && (t.pageNo.value = 1, t.total.value = 0, t.pageSize.value = t.pageSize.value);
1266
- const n = y(t.pageSize.value), i = y(t.pageNo.value), p = y([]), d = y({
1515
+ const n = y(t.pageSize.value), i = y(t.pageNo.value), p = y([]), c = y({
1267
1516
  total: 0,
1268
1517
  current: 1,
1269
1518
  pageSize: n.value,
1270
- showTotal: (c) => `共 ${c} 条记录`,
1271
- onChange: (c, g) => {
1272
- d.value !== !1 && (d.value.current = c, d.value.pageSize = g), n.value = g, i.value = c, t && (t.pageNo.value = c, t.pageSize.value = g, t.remotePage && Be(t));
1519
+ showTotal: (d) => `共 ${d} 条记录`,
1520
+ onChange: (d, g) => {
1521
+ c.value !== !1 && (c.value.current = d, c.value.pageSize = g), n.value = g, i.value = d, t && (t.pageNo.value = d, t.pageSize.value = g, t.remotePage && me(t));
1273
1522
  },
1274
1523
  ...a.pagination === !1 ? {} : a.pagination
1275
1524
  });
1276
- a.pagination === !1 && (d.value = !1), F(
1525
+ a.pagination === !1 && (c.value = !1), I(
1277
1526
  () => t.tableData.value,
1278
- (c) => {
1279
- c && (p.value = c, d.value !== !1 && (d.value.total = t.total.value ?? 0, d.value.current = t.pageNo.value ?? 1, d.value.pageSize = t.pageSize.value ?? 10));
1527
+ (d) => {
1528
+ d && (p.value = d, c.value !== !1 && (c.value.total = t.total.value ?? 0, c.value.current = t.pageNo.value ?? 1, c.value.pageSize = t.pageSize.value ?? 10));
1280
1529
  },
1281
1530
  { immediate: !0 }
1282
- ), F(
1531
+ ), I(
1283
1532
  () => a.tableData,
1284
- (c) => {
1285
- c && (p.value = c, d.value !== !1 && (d.value.total = c.length, d.value.current = t.pageNo.value ?? 1, d.value.pageSize = t.pageSize.value ?? 10));
1533
+ (d) => {
1534
+ d && (p.value = d, c.value !== !1 && (c.value.total = d.length, c.value.current = t.pageNo.value ?? 1, c.value.pageSize = t.pageSize.value ?? 10));
1286
1535
  },
1287
1536
  { immediate: !0 }
1288
1537
  );
1289
- const u = y(t.columns.value), v = {
1290
- onChange: (c, g) => {
1291
- t && (t.selectKeys.value = c, t.selectRows.value = g);
1538
+ const u = y(t.columns.value), f = {
1539
+ onChange: (d, g) => {
1540
+ t && (t.selectKeys.value = d, t.selectRows.value = g);
1292
1541
  },
1293
1542
  columnWidth: "30px",
1294
- getCheckboxProps: (c) => ({
1295
- disabled: c.Enabled === 0
1543
+ getCheckboxProps: (d) => ({
1544
+ disabled: d.Enabled === 0
1296
1545
  }),
1297
1546
  ...a.rowSelection
1298
- }, s = y(v);
1299
- F(
1547
+ }, s = y(f);
1548
+ I(
1300
1549
  () => t.selectable.value,
1301
- (c) => {
1302
- t && (s.value = c ? v : void 0);
1550
+ (d) => {
1551
+ t && (s.value = d ? f : void 0);
1303
1552
  },
1304
1553
  { immediate: !0 }
1305
- ), F(
1554
+ ), I(
1306
1555
  () => t.columns.value,
1307
1556
  () => {
1308
- u.value = He(t.columns.value);
1557
+ u.value = Je(t.columns.value);
1309
1558
  },
1310
1559
  { deep: !0, immediate: !0 }
1311
1560
  );
1312
1561
  const m = y(!1);
1313
- return Pe(() => {
1562
+ return xe(() => {
1314
1563
  m.value && t && t.autoload && (t.reload.value = !0);
1315
- }), ee(async () => {
1316
- var c, g, $, E, P;
1317
- Ee(re.GridControl, t), t.page && ((c = t.gridUrl) != null && c.url) && (((g = t.gridUrl) == null ? void 0 : g.url) === (($ = t.page.urls.list) == null ? void 0 : $.url) && (t.remotePage = !1), ((E = t.gridUrl) == null ? void 0 : E.url) === ((P = t.page.urls.find) == null ? void 0 : P.url) && (t.remotePage = !0)), t.tableData.value ? (p.value = t.tableData.value, t.total.value = p.value.length, d.value !== !1 && (d.value.total = t.total.value ?? 0)) : t.autoload !== !1 && (t.remotePage ? p.value = (await Be(t)).rows : p.value = await xt(t)), setTimeout(() => {
1564
+ }), X(async () => {
1565
+ var d, g, C, F, U;
1566
+ _e(ae.GridControl, t), t.page && ((d = t.gridUrl) != null && d.url) && (((g = t.gridUrl) == null ? void 0 : g.url) === ((C = t.page.urls.list) == null ? void 0 : C.url) && (t.remotePage = !1), ((F = t.gridUrl) == null ? void 0 : F.url) === ((U = t.page.urls.find) == null ? void 0 : U.url) && (t.remotePage = !0)), t.tableData.value ? (p.value = t.tableData.value, t.total.value = p.value.length, c.value !== !1 && (c.value.total = t.total.value ?? 0)) : t.autoload !== !1 && (t.remotePage ? p.value = (await me(t)).rows : p.value = await Xe(t)), setTimeout(() => {
1318
1567
  m.value = !0;
1319
1568
  }, 50);
1320
- }), (c, g) => {
1321
- var E, P;
1322
- const $ = ne("auth");
1323
- return f(), w(A, null, [
1324
- (E = r(t).buttons) != null && E.value.length || (P = r(t).tools) != null && P.length ? (f(), b(Na, {
1569
+ }), (d, g) => {
1570
+ var F, U;
1571
+ const C = re("auth");
1572
+ return v(), w(L, null, [
1573
+ (F = l(t).buttons) != null && F.value.length || (U = l(t).tools) != null && U.length ? (v(), b(yt, {
1325
1574
  key: 0,
1326
- "grid-ctrl": r(t),
1327
- "editor-ctrl": r(t).editor
1328
- }, null, 8, ["grid-ctrl", "editor-ctrl"])) : C("", !0),
1329
- m.value ? (f(), b(r(lt), L({
1575
+ "grid-ctrl": l(t),
1576
+ "editor-ctrl": l(t).editor
1577
+ }, null, 8, ["grid-ctrl", "editor-ctrl"])) : x("", !0),
1578
+ m.value ? (v(), b(l(ct), B({
1330
1579
  key: 1,
1331
1580
  class: "w-full min-h-[480px]",
1332
- "row-key": a.primaryKey ?? r(t).primaryKey ?? "Id",
1581
+ "row-key": a.primaryKey ?? l(t).primaryKey ?? "Id",
1333
1582
  "data-source": p.value,
1334
- loading: r(t).isGridLoading.value,
1583
+ loading: l(t).isGridLoading.value,
1335
1584
  columns: u.value,
1336
- pagination: d.value,
1585
+ pagination: c.value,
1337
1586
  "row-selection": s.value,
1338
1587
  scroll: a.scroll || { x: 700 },
1339
- size: r(t).tableSize.value,
1588
+ size: l(t).tableSize.value,
1340
1589
  bordered: ""
1341
- }, r(e)), {
1342
- bodyCell: h((k) => {
1343
- var R, j;
1590
+ }, l(e)), {
1591
+ bodyCell: h(($) => {
1592
+ var A, H;
1344
1593
  return [
1345
- D(c.$slots, "bodyCell", {
1346
- column: k == null ? void 0 : k.column,
1347
- record: k == null ? void 0 : k.record
1594
+ P(d.$slots, "bodyCell", {
1595
+ column: $ == null ? void 0 : $.column,
1596
+ record: $ == null ? void 0 : $.record
1348
1597
  }),
1349
- r(t) && ((R = k == null ? void 0 : k.column) == null ? void 0 : R.dataIndex) === "enabled" ? X((f(), b(_t, {
1598
+ l(t) && ((A = $ == null ? void 0 : $.column) == null ? void 0 : A.dataIndex) === "enabled" ? W((v(), b(Ze, {
1350
1599
  key: 0,
1351
- checked: k.record.Enabled,
1352
- "onUpdate:checked": (Q) => k.record.Enabled = Q,
1353
- disabled: c.statusDisabled ? c.statusDisabled(k.record) : !1,
1354
- data: r(Qe).EnableDisable,
1355
- onClick: (Q) => r(kt)(r(t), k.record),
1356
- class: U([
1600
+ checked: $.record[l(t).statusKey],
1601
+ "onUpdate:checked": (Z) => $.record[l(t).statusKey] = Z,
1602
+ disabled: d.statusDisabled ? d.statusDisabled($.record) : !1,
1603
+ data: l(Ne).EnableDisable,
1604
+ onClick: (Z) => l(et)(l(t), $.record),
1605
+ class: E([
1357
1606
  "w-[58px]",
1358
- c.statusDisabled && c.statusDisabled(k.record) ? "cursor-not-allowed disabled" : ""
1607
+ d.statusDisabled && d.statusDisabled($.record) ? "cursor-not-allowed disabled" : ""
1359
1608
  ]),
1360
- loading: k == null ? void 0 : k.record.isLoading
1609
+ loading: $ == null ? void 0 : $.record.isLoading
1361
1610
  }, null, 8, ["checked", "onUpdate:checked", "disabled", "data", "onClick", "class", "loading"])), [
1362
- [$, { url: o.value, role: ["Super", "Admin"], permit: ":enabled" }, "disable"]
1363
- ]) : C("", !0),
1364
- r(t) && ((j = k == null ? void 0 : k.column) == null ? void 0 : j.dataIndex) === "operation" ? D(c.$slots, "operate", {
1611
+ [C, { url: o.value, role: ["Super", "Admin"], permit: ":enabled" }, "disable"]
1612
+ ]) : x("", !0),
1613
+ l(t) && ((H = $ == null ? void 0 : $.column) == null ? void 0 : H.dataIndex) === "operation" ? P(d.$slots, "operate", {
1365
1614
  key: 1,
1366
- record: k == null ? void 0 : k.record
1615
+ record: $ == null ? void 0 : $.record
1367
1616
  }, () => [
1368
- S(Da, {
1369
- record: k == null ? void 0 : k.record,
1370
- "grid-ctrl": r(t)
1617
+ S(ja, {
1618
+ record: $ == null ? void 0 : $.record,
1619
+ "grid-ctrl": l(t)
1371
1620
  }, null, 8, ["record", "grid-ctrl"])
1372
- ]) : C("", !0)
1621
+ ]) : x("", !0)
1373
1622
  ];
1374
1623
  }),
1375
1624
  _: 3
1376
- }, 16, ["row-key", "data-source", "loading", "columns", "pagination", "row-selection", "scroll", "size"])) : C("", !0)
1625
+ }, 16, ["row-key", "data-source", "loading", "columns", "pagination", "row-selection", "scroll", "size"])) : x("", !0)
1377
1626
  ], 64);
1378
1627
  };
1379
1628
  }
1380
- }), Oa = { class: "flex items-center gap-1" }, Ra = { class: "text-nowrap" }, Al = /* @__PURE__ */ T({
1629
+ }), Va = { class: "flex items-center gap-1" }, Ya = { class: "text-nowrap" }, ql = /* @__PURE__ */ T({
1381
1630
  __name: "index",
1382
1631
  props: {
1383
1632
  treeCtrl: {},
@@ -1385,14 +1634,14 @@ const Il = async (l, a) => {
1385
1634
  expandedKeys: {}
1386
1635
  },
1387
1636
  emits: ["select", "update:selectedKeys"],
1388
- setup(l, { emit: a }) {
1389
- const e = l, t = oe(), o = e.treeCtrl, n = y([]);
1390
- F(
1637
+ setup(r, { emit: a }) {
1638
+ const e = r, t = ne(), o = e.treeCtrl, n = y([]);
1639
+ I(
1391
1640
  () => o.data.value,
1392
- (v) => {
1393
- if (v) {
1394
- n.value = o.fieldMap ? ve(o.fieldMap, v) : v;
1395
- const s = wt(n.value, p.value[0]);
1641
+ (f) => {
1642
+ if (f) {
1643
+ n.value = o.fieldMap ? he(o.fieldMap, f) : f;
1644
+ const s = $t(n.value, p.value[0]);
1396
1645
  if (s) {
1397
1646
  const m = {
1398
1647
  event: "select",
@@ -1412,139 +1661,139 @@ const Il = async (l, a) => {
1412
1661
  }
1413
1662
  );
1414
1663
  const i = a, p = y([]);
1415
- F(
1664
+ I(
1416
1665
  () => e.selectedKeys,
1417
- (v) => {
1418
- v && (p.value = v);
1666
+ (f) => {
1667
+ f && (p.value = f);
1419
1668
  },
1420
1669
  { immediate: !0 }
1421
1670
  );
1422
- const d = y(["-"]);
1423
- F(
1671
+ const c = y(["-"]);
1672
+ I(
1424
1673
  () => e.expandedKeys,
1425
- (v) => {
1426
- v && (d.value = v);
1674
+ (f) => {
1675
+ f && (c.value = f);
1427
1676
  },
1428
1677
  { immediate: !0 }
1429
1678
  );
1430
- const u = (v, s) => {
1431
- v.length === 0 && v.push(...p.value), v.length > 0 && (o.node.value = s == null ? void 0 : s.node.dataRef), p.value = v, i("update:selectedKeys", v), i("select", v, s);
1679
+ const u = (f, s) => {
1680
+ f.length === 0 && f.push(...p.value), f.length > 0 && (o.node.value = s == null ? void 0 : s.node.dataRef), p.value = f, i("update:selectedKeys", f), i("select", f, s);
1432
1681
  };
1433
- return ee(() => {
1682
+ return X(() => {
1434
1683
  o.fieldMap || (o.fieldMap = {
1435
1684
  label: "Name",
1436
1685
  key: "Id",
1437
1686
  value: "Id",
1438
1687
  icon: "Icon"
1439
- }), o.data.value ? n.value = ve(o.fieldMap, o.data.value) : o.autoload && Ge(o);
1440
- }), (v, s) => (f(), b(r(Qt), L({
1688
+ }), o.data.value ? n.value = he(o.fieldMap, o.data.value) : o.autoload && tt(o);
1689
+ }), (f, s) => (v(), b(l(Zt), B({
1441
1690
  class: "w-full",
1442
1691
  "show-line": !0,
1443
1692
  "tree-data": n.value,
1444
- "expanded-keys": d.value,
1445
- "onUpdate:expandedKeys": s[0] || (s[0] = (m) => d.value = m),
1693
+ "expanded-keys": c.value,
1694
+ "onUpdate:expandedKeys": s[0] || (s[0] = (m) => c.value = m),
1446
1695
  "selected-keys": p.value,
1447
- loading: r(o).isTreeLoading,
1696
+ loading: l(o).isTreeLoading,
1448
1697
  onSelect: u
1449
- }, r(t)), {
1450
- title: h(({ key: m, label: c, icon: g }) => [
1451
- D(v.$slots, "title", {
1452
- label: c,
1698
+ }, l(t)), {
1699
+ title: h(({ key: m, label: d, icon: g }) => [
1700
+ P(f.$slots, "title", {
1701
+ label: d,
1453
1702
  key: m,
1454
1703
  icon: g
1455
1704
  }, () => [
1456
- I("div", Oa, [
1457
- S(r(K), { icon: g }, null, 8, ["icon"]),
1458
- I("span", Ra, M(c), 1)
1705
+ D("div", Va, [
1706
+ S(l(K), { icon: g }, null, 8, ["icon"]),
1707
+ D("span", Ya, N(d), 1)
1459
1708
  ])
1460
1709
  ])
1461
1710
  ]),
1462
1711
  _: 3
1463
1712
  }, 16, ["tree-data", "expanded-keys", "selected-keys", "loading"]));
1464
1713
  }
1465
- }), zl = /* @__PURE__ */ te(Ct, [["__scopeId", "data-v-87722b44"]]), Aa = { class: "relative w-[248px] max-w-[248px]" }, za = {
1714
+ }), Hl = /* @__PURE__ */ se(Tt, [["__scopeId", "data-v-87722b44"]]), Wa = { class: "relative w-[248px] max-w-[248px]" }, qa = {
1466
1715
  key: 0,
1467
1716
  class: "absolute z-10 mt-[5px] mr-[10px] text-[#999] flex items-center"
1468
- }, Ka = /* @__PURE__ */ T({
1717
+ }, Ha = /* @__PURE__ */ T({
1469
1718
  inheritAttrs: !1,
1470
1719
  __name: "index",
1471
- props: St,
1720
+ props: It,
1472
1721
  emits: ["change", "update:labels", "update:value"],
1473
- setup(l, { emit: a }) {
1474
- var $, E, P;
1475
- const e = l, t = oe(), o = V(), n = $t(e.url, e), i = e.optionCtrl ?? n.optionCtrl;
1476
- i.inputFactory = zt(o);
1722
+ setup(r, { emit: a }) {
1723
+ var C, F, U;
1724
+ const e = r, t = ne(), o = q(), n = Dt(e.url, e), i = e.optionCtrl ?? n.optionCtrl;
1725
+ i.inputFactory = Vt(o);
1477
1726
  const p = y({
1478
1727
  ...i == null ? void 0 : i.url,
1479
- url: (($ = i == null ? void 0 : i.url) == null ? void 0 : $.url) || "",
1480
- fieldMap: (i == null ? void 0 : i.fieldMap) || ((E = i == null ? void 0 : i.url) == null ? void 0 : E.fieldMap),
1481
- params: (i == null ? void 0 : i.params) || ((P = i == null ? void 0 : i.url) == null ? void 0 : P.params),
1728
+ url: ((C = i == null ? void 0 : i.url) == null ? void 0 : C.url) || "",
1729
+ fieldMap: (i == null ? void 0 : i.fieldMap) || ((F = i == null ? void 0 : i.url) == null ? void 0 : F.fieldMap),
1730
+ params: (i == null ? void 0 : i.params) || ((U = i == null ? void 0 : i.url) == null ? void 0 : U.params),
1482
1731
  loadingText: !1
1483
- }), { editorCtrl: d, errInfo: u, labelText: v } = o, s = y(t.placeholder);
1484
- F(
1732
+ }), { editorCtrl: c, errInfo: u, labelText: f } = o, s = y(t.placeholder);
1733
+ I(
1485
1734
  () => p.value.loading,
1486
- (k) => {
1487
- k ? s.value = "" : s.value || (s.value = "请选择" + v.value);
1735
+ ($) => {
1736
+ $ ? s.value = "" : s.value || (s.value = "请选择" + f.value);
1488
1737
  },
1489
1738
  { immediate: !0 }
1490
1739
  );
1491
1740
  const m = a;
1492
1741
  o.inputEmit = m;
1493
- const c = y((i == null ? void 0 : i.options.value) || []);
1494
- i && F(
1742
+ const d = y((i == null ? void 0 : i.options.value) || []);
1743
+ i && I(
1495
1744
  () => i.options.value,
1496
- (k) => {
1497
- c.value = k || [];
1745
+ ($) => {
1746
+ d.value = $ || [];
1498
1747
  },
1499
1748
  { immediate: !0, deep: !0 }
1500
1749
  );
1501
- const g = (k, R) => {
1502
- if (!R || R.length === 0) {
1750
+ const g = ($, A) => {
1751
+ if (!A || A.length === 0) {
1503
1752
  m("update:labels", []), m("update:value", []);
1504
1753
  return;
1505
1754
  }
1506
- const j = R.map((ye) => ye.value), Q = Et(i, e, j), pe = Dt(Q);
1507
- m("update:labels", pe), m("update:value", j), u != null && u.value.errClass && d && Z(d);
1755
+ const H = A.map(($e) => $e.value), Z = Lt(i, e, H), fe = Ut(Z);
1756
+ m("update:labels", fe), m("update:value", H), u != null && u.value.errClass && c && le(c);
1508
1757
  };
1509
- return Pe(() => {
1758
+ return xe(() => {
1510
1759
  i && i.autoload && (i.reload.value = !0);
1511
- }), ee(() => {
1760
+ }), X(() => {
1512
1761
  p.value && !p.value.fieldMap && (p.value.fieldMap = {
1513
1762
  title: "Name",
1514
1763
  label: "Name",
1515
1764
  value: "Id",
1516
1765
  key: "Id"
1517
- }), i && Tt(i.autoload, i, e);
1518
- }), Kt(() => {
1519
- i && Ft(i, e);
1520
- }), (k, R) => {
1521
- var j;
1522
- return f(), w("div", Aa, [
1523
- c.value.length ? C("", !0) : (f(), w("div", za, [
1524
- S(r(It), { class: "text-[#555] mx-[5px] !ml-[10px] !w-4 !h-4" }),
1525
- R[0] || (R[0] = I("span", null, "数据加载中...", -1))
1766
+ }), i && Ft(i.autoload, i, e);
1767
+ }), Yt(() => {
1768
+ i && Pt(i, e);
1769
+ }), ($, A) => {
1770
+ var H;
1771
+ return v(), w("div", Wa, [
1772
+ d.value.length ? x("", !0) : (v(), w("div", qa, [
1773
+ S(l(Et), { class: "text-[#555] mx-[5px] !ml-[10px] !w-4 !h-4" }),
1774
+ A[0] || (A[0] = D("span", null, "数据加载中...", -1))
1526
1775
  ])),
1527
- S(r(Gt), L({
1528
- options: c.value,
1529
- class: [(j = r(u)) == null ? void 0 : j.errClass],
1776
+ S(l(ea), B({
1777
+ options: d.value,
1778
+ class: [(H = l(u)) == null ? void 0 : H.errClass],
1530
1779
  "allow-clear": !0,
1531
- placeholder: c.value.length > 0 ? "请选择" + r(v) : "",
1780
+ placeholder: d.value.length > 0 ? "请选择" + l(f) : "",
1532
1781
  onChange: g
1533
- }, r(t)), null, 16, ["options", "class", "placeholder"])
1782
+ }, l(t)), null, 16, ["options", "class", "placeholder"])
1534
1783
  ]);
1535
1784
  };
1536
1785
  }
1537
- }), Kl = /* @__PURE__ */ te(Ka, [["__scopeId", "data-v-51ddfce3"]]), Vl = /* @__PURE__ */ te(Pt, [["__scopeId", "data-v-249ea772"]]);
1538
- function he() {
1539
- return he = Object.assign ? Object.assign.bind() : function(l) {
1786
+ }), Ql = /* @__PURE__ */ se(Ha, [["__scopeId", "data-v-51ddfce3"]]), Gl = /* @__PURE__ */ se(Nt, [["__scopeId", "data-v-249ea772"]]);
1787
+ function ye() {
1788
+ return ye = Object.assign ? Object.assign.bind() : function(r) {
1540
1789
  for (var a = 1; a < arguments.length; a++) {
1541
1790
  var e = arguments[a];
1542
- for (var t in e) ({}).hasOwnProperty.call(e, t) && (l[t] = e[t]);
1791
+ for (var t in e) ({}).hasOwnProperty.call(e, t) && (r[t] = e[t]);
1543
1792
  }
1544
- return l;
1545
- }, he.apply(null, arguments);
1793
+ return r;
1794
+ }, ye.apply(null, arguments);
1546
1795
  }
1547
- const Va = {
1796
+ const Qa = {
1548
1797
  locale: "zh_CN",
1549
1798
  today: "今天",
1550
1799
  now: "此刻",
@@ -1571,11 +1820,11 @@ const Va = {
1571
1820
  nextDecade: "下一年代",
1572
1821
  previousCentury: "上一世纪",
1573
1822
  nextCentury: "下一世纪"
1574
- }, ja = {
1823
+ }, Ga = {
1575
1824
  placeholder: "请选择时间",
1576
1825
  rangePlaceholder: ["开始时间", "结束时间"]
1577
- }, be = {
1578
- lang: he({
1826
+ }, Se = {
1827
+ lang: ye({
1579
1828
  placeholder: "请选择日期",
1580
1829
  yearPlaceholder: "请选择年份",
1581
1830
  quarterPlaceholder: "请选择季度",
@@ -1586,118 +1835,118 @@ const Va = {
1586
1835
  rangeMonthPlaceholder: ["开始月份", "结束月份"],
1587
1836
  rangeQuarterPlaceholder: ["开始季度", "结束季度"],
1588
1837
  rangeWeekPlaceholder: ["开始周", "结束周"]
1589
- }, Va),
1590
- timePickerLocale: he({}, ja)
1838
+ }, Qa),
1839
+ timePickerLocale: ye({}, Ga)
1591
1840
  };
1592
- be.lang.ok = "确定";
1593
- const jl = /* @__PURE__ */ T({
1841
+ Se.lang.ok = "确定";
1842
+ const Jl = /* @__PURE__ */ T({
1594
1843
  __name: "index",
1595
1844
  props: {
1596
1845
  valueFormat: {}
1597
1846
  },
1598
- setup(l) {
1599
- const a = l, { editorCtrl: e, labelText: t, errInfo: o } = V(), n = () => {
1600
- o != null && o.value.errClass && e && Z(e);
1847
+ setup(r) {
1848
+ const a = r, { editorCtrl: e, labelText: t, errInfo: o } = q(), n = () => {
1849
+ o != null && o.value.errClass && e && le(e);
1601
1850
  }, i = y(a.valueFormat ?? "YYYY-MM-DD");
1602
- return (p, d) => {
1851
+ return (p, c) => {
1603
1852
  var u;
1604
- return f(), b(r(Jt), {
1605
- class: U(["w-full", [((u = r(o)) == null ? void 0 : u.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""]]),
1606
- placeholder: "请选择" + r(t),
1607
- locale: r(be),
1853
+ return v(), b(l(ta), {
1854
+ class: E(["w-full", [((u = l(o)) == null ? void 0 : u.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""]]),
1855
+ placeholder: "请选择" + l(t),
1856
+ locale: l(Se),
1608
1857
  valueFormat: i.value,
1609
1858
  onBlur: n
1610
1859
  }, null, 8, ["class", "placeholder", "locale", "valueFormat"]);
1611
1860
  };
1612
1861
  }
1613
- }), Ya = /* @__PURE__ */ T({
1862
+ }), Ja = /* @__PURE__ */ T({
1614
1863
  __name: "index",
1615
1864
  props: {
1616
1865
  value: {},
1617
1866
  undefValue: { type: Boolean, default: !1 }
1618
1867
  },
1619
1868
  emits: ["update:value"],
1620
- setup(l, { emit: a }) {
1621
- const { editorCtrl: e, labelText: t, errInfo: o } = V(), n = () => {
1622
- o != null && o.value.errClass && e && Z(e);
1623
- }, i = l, p = i.value === void 0 ? !0 : i.undefValue, d = a, u = y(i.value);
1624
- F(
1869
+ setup(r, { emit: a }) {
1870
+ const { editorCtrl: e, labelText: t, errInfo: o } = q(), n = () => {
1871
+ o != null && o.value.errClass && e && le(e);
1872
+ }, i = r, p = i.value === void 0 ? !0 : i.undefValue, c = a, u = y(i.value);
1873
+ I(
1625
1874
  () => i.value,
1626
1875
  (s) => {
1627
1876
  u.value = s;
1628
1877
  },
1629
1878
  { immediate: !0 }
1630
1879
  // 立即同步初始值
1631
- ), F(
1880
+ ), I(
1632
1881
  () => u.value,
1633
1882
  (s) => {
1634
1883
  if (u.value === "") {
1635
- d("update:value", void 0);
1884
+ c("update:value", void 0);
1636
1885
  return;
1637
1886
  }
1638
- d("update:value", s);
1887
+ c("update:value", s);
1639
1888
  }
1640
1889
  );
1641
- const v = () => {
1890
+ const f = () => {
1642
1891
  u.value === "" && (u.value = p ? void 0 : null);
1643
1892
  };
1644
1893
  return (s, m) => {
1645
- var c, g;
1646
- return f(), b(r(ue), L({
1894
+ var d, g;
1895
+ return v(), b(l(de), B({
1647
1896
  class: [
1648
- (c = r(o)) == null ? void 0 : c.errClass,
1649
- ((g = r(o)) == null ? void 0 : g.errClass) === "error" && !s.$slots.addonBefore && !s.$slots.addonAfter ? "!border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""
1897
+ (d = l(o)) == null ? void 0 : d.errClass,
1898
+ ((g = l(o)) == null ? void 0 : g.errClass) === "error" && !s.$slots.addonBefore && !s.$slots.addonAfter ? "!border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""
1650
1899
  ],
1651
1900
  value: u.value,
1652
- "onUpdate:value": m[0] || (m[0] = ($) => u.value = $),
1901
+ "onUpdate:value": m[0] || (m[0] = (C) => u.value = C),
1653
1902
  autocomplete: "new-password",
1654
1903
  "allow-clear": !0,
1655
- placeholder: "请输入" + r(t),
1904
+ placeholder: "请输入" + l(t),
1656
1905
  onBlur: n,
1657
- onChange: v
1658
- }, s.$attrs), Xe({ _: 2 }, [
1906
+ onChange: f
1907
+ }, s.$attrs), lt({ _: 2 }, [
1659
1908
  s.$slots.addonBefore ? {
1660
1909
  name: "addonBefore",
1661
1910
  fn: h(() => [
1662
- D(s.$slots, "addonBefore")
1911
+ P(s.$slots, "addonBefore")
1663
1912
  ]),
1664
1913
  key: "0"
1665
1914
  } : void 0,
1666
1915
  s.$slots.addonAfter ? {
1667
1916
  name: "addonAfter",
1668
1917
  fn: h(() => [
1669
- D(s.$slots, "addonAfter")
1918
+ P(s.$slots, "addonAfter")
1670
1919
  ]),
1671
1920
  key: "1"
1672
1921
  } : void 0
1673
1922
  ]), 1040, ["class", "value", "placeholder"]);
1674
1923
  };
1675
1924
  }
1676
- }), Wa = /* @__PURE__ */ T({
1925
+ }), Xa = /* @__PURE__ */ T({
1677
1926
  __name: "inputIcon",
1678
1927
  props: {
1679
1928
  value: {}
1680
1929
  },
1681
1930
  emits: ["update:value"],
1682
- setup(l, { emit: a }) {
1683
- const e = l, t = a, o = y(void 0);
1684
- return F(
1931
+ setup(r, { emit: a }) {
1932
+ const e = r, t = a, o = y(void 0);
1933
+ return I(
1685
1934
  () => e.value,
1686
1935
  (n) => {
1687
1936
  o.value = n ?? void 0;
1688
1937
  },
1689
1938
  { immediate: !0 }
1690
- ), F(
1939
+ ), I(
1691
1940
  () => o.value,
1692
1941
  (n) => {
1693
1942
  t("update:value", n);
1694
1943
  }
1695
- ), (n, i) => (f(), b(Ya, L({
1944
+ ), (n, i) => (v(), b(Ja, B({
1696
1945
  value: o.value,
1697
1946
  "onUpdate:value": i[0] || (i[0] = (p) => o.value = p)
1698
1947
  }, n.$attrs), {
1699
1948
  addonBefore: h(() => [
1700
- S(r(K), {
1949
+ S(l(K), {
1701
1950
  class: "!w-4 !h-4",
1702
1951
  icon: o.value
1703
1952
  }, null, 8, ["icon"])
@@ -1705,40 +1954,40 @@ const jl = /* @__PURE__ */ T({
1705
1954
  _: 1
1706
1955
  }, 16, ["value"]));
1707
1956
  }
1708
- }), Yl = /* @__PURE__ */ te(Wa, [["__scopeId", "data-v-358b82ef"]]), Wl = /* @__PURE__ */ T({
1957
+ }), Xl = /* @__PURE__ */ se(Xa, [["__scopeId", "data-v-358b82ef"]]), Zl = /* @__PURE__ */ T({
1709
1958
  __name: "inputPassword",
1710
- setup(l) {
1711
- const { editorCtrl: a, labelText: e, errInfo: t } = V(), o = () => {
1712
- t != null && t.value.errClass && a && Z(a);
1959
+ setup(r) {
1960
+ const { editorCtrl: a, labelText: e, errInfo: t } = q(), o = () => {
1961
+ t != null && t.value.errClass && a && le(a);
1713
1962
  };
1714
1963
  return (n, i) => {
1715
1964
  var p;
1716
- return f(), b(r(Xt), L({
1717
- class: ((p = r(t)) == null ? void 0 : p.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
1965
+ return v(), b(l(aa), B({
1966
+ class: ((p = l(t)) == null ? void 0 : p.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
1718
1967
  "allow-clear": !0,
1719
1968
  autocomplete: "new-password",
1720
- placeholder: "请输入" + r(e),
1969
+ placeholder: "请输入" + l(e),
1721
1970
  onBlur: o
1722
1971
  }, n.$attrs), null, 16, ["class", "placeholder"]);
1723
1972
  };
1724
1973
  }
1725
- }), ql = /* @__PURE__ */ T({
1974
+ }), er = /* @__PURE__ */ T({
1726
1975
  __name: "inputNumber",
1727
- setup(l) {
1728
- const { editorCtrl: a, labelText: e, errInfo: t } = V(), o = () => {
1729
- t != null && t.value.errClass && a && Z(a);
1976
+ setup(r) {
1977
+ const { editorCtrl: a, labelText: e, errInfo: t } = q(), o = () => {
1978
+ t != null && t.value.errClass && a && le(a);
1730
1979
  };
1731
1980
  return (n, i) => {
1732
1981
  var p;
1733
- return f(), b(r(Zt), L({
1734
- class: [[((p = r(t)) == null ? void 0 : p.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""], "w-[50%]"],
1982
+ return v(), b(l(la), B({
1983
+ class: [[((p = l(t)) == null ? void 0 : p.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""], "w-[50%]"],
1735
1984
  onBlur: o,
1736
1985
  "allow-clear": !1,
1737
- placeholder: "请输入" + r(e)
1986
+ placeholder: "请输入" + l(e)
1738
1987
  }, n.$attrs), null, 16, ["class", "placeholder"]);
1739
1988
  };
1740
1989
  }
1741
- }), qa = { class: "flex flex-col gap-2" }, Ha = { key: 1 }, Hl = /* @__PURE__ */ T({
1990
+ }), Za = { class: "flex flex-col gap-2" }, el = { key: 1 }, tr = /* @__PURE__ */ T({
1742
1991
  __name: "index",
1743
1992
  props: {
1744
1993
  value: {},
@@ -1749,8 +1998,8 @@ const jl = /* @__PURE__ */ T({
1749
1998
  valueHolder: {}
1750
1999
  },
1751
2000
  emits: ["update:value"],
1752
- setup(l, { emit: a }) {
1753
- const e = l, t = a, o = y(!(e.selectList && e.selectList.length > 0)), n = y([]);
2001
+ setup(r, { emit: a }) {
2002
+ const e = r, t = a, o = y(!(e.selectList && e.selectList.length > 0)), n = y([]);
1754
2003
  let i = !1;
1755
2004
  const p = () => {
1756
2005
  e.selectList && e.selectList.length > 0 ? n.value = e.selectList.map((s) => ({
@@ -1765,19 +2014,19 @@ const jl = /* @__PURE__ */ T({
1765
2014
  value: m
1766
2015
  })) : n.value = [];
1767
2016
  };
1768
- F(
2017
+ I(
1769
2018
  () => e.value,
1770
2019
  () => {
1771
2020
  i || p(), i = !1;
1772
2021
  },
1773
2022
  { immediate: !0 }
1774
2023
  );
1775
- const d = () => {
2024
+ const c = () => {
1776
2025
  let s;
1777
2026
  e.selectList && e.selectList.length > 0 ? (s = { ...e.value }, n.value.forEach((m) => {
1778
2027
  m.field && (s[m.field] = m.value);
1779
2028
  })) : (s = n.value.reduce(
1780
- (m, c) => (c.field && (m[c.field] = c.value), m),
2029
+ (m, d) => (d.field && (m[d.field] = d.value), m),
1781
2030
  {}
1782
2031
  ), e.ignoreList && e.ignoreList.length > 0 && e.ignoreList.forEach((m) => {
1783
2032
  e.value[m] !== void 0 && (s[m] = e.value[m]);
@@ -1788,69 +2037,69 @@ const jl = /* @__PURE__ */ T({
1788
2037
  field: "",
1789
2038
  value: ""
1790
2039
  });
1791
- }, v = () => {
1792
- d();
2040
+ }, f = () => {
2041
+ c();
1793
2042
  };
1794
- return (s, m) => (f(), w("div", qa, [
1795
- (f(!0), w(A, null, H(n.value, (c) => (f(), w("div", {
1796
- key: c.id,
2043
+ return (s, m) => (v(), w("div", Za, [
2044
+ (v(!0), w(L, null, V(n.value, (d) => (v(), w("div", {
2045
+ key: d.id,
1797
2046
  class: "flex items-center gap-2"
1798
2047
  }, [
1799
- I("div", {
1800
- class: U([s.fieldWidth ? `w-[${s.fieldWidth}%]` : "w-[33%]"])
2048
+ D("div", {
2049
+ class: E([s.fieldWidth ? `w-[${s.fieldWidth}%]` : "w-[33%]"])
1801
2050
  }, [
1802
- !s.selectList || s.selectList.length === 0 ? (f(), b(r(ue), {
2051
+ !s.selectList || s.selectList.length === 0 ? (v(), b(l(de), {
1803
2052
  key: 0,
1804
- value: c.field,
1805
- "onUpdate:value": (g) => c.field = g,
1806
- title: c.text || c.field,
2053
+ value: d.field,
2054
+ "onUpdate:value": (g) => d.field = g,
2055
+ title: d.text || d.field,
1807
2056
  class: "w-full",
1808
- placeholder: c.text || s.labelHolder || "配置名",
1809
- onInput: v,
2057
+ placeholder: d.text || s.labelHolder || "配置名",
2058
+ onInput: f,
1810
2059
  disabled: !o.value
1811
- }, null, 8, ["value", "onUpdate:value", "title", "placeholder", "disabled"])) : (f(), w("div", Ha, [
1812
- S(r(ue), {
1813
- value: c.text,
1814
- "onUpdate:value": (g) => c.text = g,
1815
- title: c.text,
2060
+ }, null, 8, ["value", "onUpdate:value", "title", "placeholder", "disabled"])) : (v(), w("div", el, [
2061
+ S(l(de), {
2062
+ value: d.text,
2063
+ "onUpdate:value": (g) => d.text = g,
2064
+ title: d.text,
1816
2065
  disabled: !0,
1817
2066
  class: "w-[100%]"
1818
2067
  }, null, 8, ["value", "onUpdate:value", "title"]),
1819
- S(r(ue), {
2068
+ S(l(de), {
1820
2069
  type: "hidden",
1821
- value: c.field,
1822
- "onUpdate:value": (g) => c.field = g
2070
+ value: d.field,
2071
+ "onUpdate:value": (g) => d.field = g
1823
2072
  }, null, 8, ["value", "onUpdate:value"])
1824
2073
  ]))
1825
2074
  ], 2),
1826
- m[0] || (m[0] = I("div", { class: "w-[3%]" }, "=", -1)),
1827
- I("div", {
1828
- class: U([s.fieldWidth ? `w-[${97 - s.fieldWidth}%]` : "w-[64%]"])
2075
+ m[0] || (m[0] = D("div", { class: "w-[3%]" }, "=", -1)),
2076
+ D("div", {
2077
+ class: E([s.fieldWidth ? `w-[${97 - s.fieldWidth}%]` : "w-[64%]"])
1829
2078
  }, [
1830
- S(r(ue), {
1831
- value: c.value,
1832
- "onUpdate:value": (g) => c.value = g,
1833
- placeholder: s.valueHolder || "请输入" + c.text || "请输入配置值",
1834
- onInput: v,
1835
- title: c.value
2079
+ S(l(de), {
2080
+ value: d.value,
2081
+ "onUpdate:value": (g) => d.value = g,
2082
+ placeholder: s.valueHolder || "请输入" + d.text || "请输入配置值",
2083
+ onInput: f,
2084
+ title: d.value
1836
2085
  }, null, 8, ["value", "onUpdate:value", "placeholder", "title"])
1837
2086
  ], 2)
1838
2087
  ]))), 128)),
1839
- o.value ? (f(), b(r(at), {
2088
+ o.value ? (v(), b(l(ut), {
1840
2089
  key: 0,
1841
2090
  onClick: u,
1842
2091
  class: "mt-1 w-[80px] !text-[12px] text-[#666] bg-[#e6f7ff] border-[#b3e0ff] hover:bg-[#b3e0ff] hover:border-[#8abeff]",
1843
2092
  size: "small"
1844
2093
  }, {
1845
2094
  default: h(() => m[1] || (m[1] = [
1846
- O(" 新增配置行 ")
2095
+ M(" 新增配置行 ")
1847
2096
  ])),
1848
2097
  _: 1,
1849
2098
  __: [1]
1850
- })) : C("", !0)
2099
+ })) : x("", !0)
1851
2100
  ]));
1852
2101
  }
1853
- }), Qa = /* @__PURE__ */ te(Ut, [["__scopeId", "data-v-aa237552"]]), Ql = /* @__PURE__ */ T({
2102
+ }), tl = /* @__PURE__ */ se(Bt, [["__scopeId", "data-v-aa237552"]]), ar = /* @__PURE__ */ T({
1854
2103
  __name: "radioStatus",
1855
2104
  props: {
1856
2105
  /**
@@ -1877,14 +2126,14 @@ const jl = /* @__PURE__ */ T({
1877
2126
  required: !1
1878
2127
  }
1879
2128
  },
1880
- setup(l) {
1881
- const a = l, e = y(JSON.parse(JSON.stringify(Qe.getOptions(a.dataKey))));
2129
+ setup(r) {
2130
+ const a = r, e = y(JSON.parse(JSON.stringify(Ne.getOptions(a.dataKey))));
1882
2131
  return a.all === !0 && e.value.unshift({
1883
2132
  label: "全部",
1884
2133
  value: a.allValue || [0, 1]
1885
- }), (t, o) => (f(), b(Qa, { data: e.value }, null, 8, ["data"]));
2134
+ }), (t, o) => (v(), b(tl, { data: e.value }, null, 8, ["data"]));
1886
2135
  }
1887
- }), Gl = /* @__PURE__ */ T({
2136
+ }), lr = /* @__PURE__ */ T({
1888
2137
  __name: "index",
1889
2138
  props: {
1890
2139
  startDate: {},
@@ -1892,75 +2141,75 @@ const jl = /* @__PURE__ */ T({
1892
2141
  valueFormat: { default: "YYYY-MM-DD" }
1893
2142
  },
1894
2143
  emits: ["update:startDate", "update:endDate"],
1895
- setup(l, { emit: a }) {
1896
- const e = l, t = a, o = V(), { errInfo: n } = o, i = Y(() => e.valueFormat), p = Y(() => {
1897
- const u = e.startDate, v = e.endDate;
1898
- if (!(!u || !v))
2144
+ setup(r, { emit: a }) {
2145
+ const e = r, t = a, o = q(), { errInfo: n } = o, i = R(() => e.valueFormat), p = R(() => {
2146
+ const u = e.startDate, f = e.endDate;
2147
+ if (!(!u || !f))
1899
2148
  try {
1900
- const s = Ce(u), m = Ce(v);
2149
+ const s = Pe(u), m = Pe(f);
1901
2150
  return !s.isValid() || !m.isValid() ? void 0 : [s, m];
1902
2151
  } catch {
1903
2152
  return;
1904
2153
  }
1905
- }), d = (u, v) => {
1906
- if (!u || !v || v.length !== 2) {
2154
+ }), c = (u, f) => {
2155
+ if (!u || !f || f.length !== 2) {
1907
2156
  t("update:startDate", null), t("update:endDate", null);
1908
2157
  return;
1909
2158
  }
1910
- t("update:startDate", v[0] || null), t("update:endDate", v[1] || null);
2159
+ t("update:startDate", f[0] || null), t("update:endDate", f[1] || null);
1911
2160
  };
1912
- return (u, v) => {
2161
+ return (u, f) => {
1913
2162
  var s;
1914
- return f(), b(r(ea), {
1915
- class: U([((s = r(n)) == null ? void 0 : s.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "", "w-full"]),
1916
- locale: r(be),
2163
+ return v(), b(l(ra), {
2164
+ class: E([((s = l(n)) == null ? void 0 : s.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "", "w-full"]),
2165
+ locale: l(Se),
1917
2166
  "value-format": i.value,
1918
2167
  value: p.value,
1919
- onChange: d
2168
+ onChange: c
1920
2169
  }, null, 8, ["class", "locale", "value-format", "value"]);
1921
2170
  };
1922
2171
  }
1923
- }), Jl = /* @__PURE__ */ te(Lt, [["__scopeId", "data-v-b33df95f"]]), Xl = /* @__PURE__ */ T({
2172
+ }), rr = /* @__PURE__ */ se(Mt, [["__scopeId", "data-v-b33df95f"]]), sr = /* @__PURE__ */ T({
1924
2173
  __name: "index",
1925
- setup(l) {
1926
- const { editorCtrl: a, labelText: e, errInfo: t } = V(), o = () => {
1927
- t != null && t.value.errClass && a && Z(a);
2174
+ setup(r) {
2175
+ const { editorCtrl: a, labelText: e, errInfo: t } = q(), o = () => {
2176
+ t != null && t.value.errClass && a && le(a);
1928
2177
  };
1929
2178
  return (n, i) => {
1930
2179
  var p;
1931
- return f(), b(r(ta), L({
1932
- class: ((p = r(t)) == null ? void 0 : p.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
2180
+ return v(), b(l(sa), B({
2181
+ class: ((p = l(t)) == null ? void 0 : p.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
1933
2182
  "allow-clear": !0,
1934
- placeholder: "请输入" + r(e),
2183
+ placeholder: "请输入" + l(e),
1935
2184
  onBlur: o,
1936
- onKeyup: i[0] || (i[0] = Re(ce(() => {
2185
+ onKeyup: i[0] || (i[0] = Re(pe(() => {
1937
2186
  }, ["stop"]), ["enter", "native"])),
1938
- onKeydown: i[1] || (i[1] = Re(ce(() => {
2187
+ onKeydown: i[1] || (i[1] = Re(pe(() => {
1939
2188
  }, ["stop"]), ["enter", "native"]))
1940
2189
  }, n.$attrs), null, 16, ["class", "placeholder"]);
1941
2190
  };
1942
2191
  }
1943
- }), Zl = /* @__PURE__ */ T({
2192
+ }), or = /* @__PURE__ */ T({
1944
2193
  __name: "index",
1945
2194
  props: {
1946
2195
  valueFormat: {}
1947
2196
  },
1948
- setup(l) {
1949
- const a = l, { editorCtrl: e, labelText: t, errInfo: o } = V(), n = () => {
1950
- o != null && o.value.errClass && e && Z(e);
2197
+ setup(r) {
2198
+ const a = r, { editorCtrl: e, labelText: t, errInfo: o } = q(), n = () => {
2199
+ o != null && o.value.errClass && e && le(e);
1951
2200
  }, i = y(a.valueFormat ?? "HH:mm");
1952
- return (p, d) => {
2201
+ return (p, c) => {
1953
2202
  var u;
1954
- return f(), b(r(aa), {
1955
- class: U(["w-full", [((u = r(o)) == null ? void 0 : u.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""]]),
1956
- placeholder: "请选择" + r(t),
1957
- locale: r(be),
2203
+ return v(), b(l(oa), {
2204
+ class: E(["w-full", [((u = l(o)) == null ? void 0 : u.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""]]),
2205
+ placeholder: "请选择" + l(t),
2206
+ locale: l(Se),
1958
2207
  valueFormat: i.value,
1959
2208
  onBlur: n
1960
2209
  }, null, 8, ["class", "placeholder", "locale", "valueFormat"]);
1961
2210
  };
1962
2211
  }
1963
- }), Ga = /* @__PURE__ */ T({
2212
+ }), al = /* @__PURE__ */ T({
1964
2213
  __name: "index",
1965
2214
  props: {
1966
2215
  autoload: { type: Boolean },
@@ -1969,55 +2218,55 @@ const jl = /* @__PURE__ */ T({
1969
2218
  value: {}
1970
2219
  },
1971
2220
  emits: ["change", "update:value"],
1972
- setup(l, { emit: a }) {
1973
- const e = l, t = y({ ...e.url }), { editorCtrl: o, labelText: n, errInfo: i } = V(), p = a, d = y([]), u = y([]);
2221
+ setup(r, { emit: a }) {
2222
+ const e = r, t = y({ ...e.url }), { editorCtrl: o, labelText: n, errInfo: i } = q(), p = a, c = y([]), u = y([]);
1974
2223
  e.value && e.value.every((s) => {
1975
2224
  u.value.push(s.toString());
1976
- }), F(
2225
+ }), I(
1977
2226
  () => e.value,
1978
2227
  (s) => {
1979
2228
  s && (u.value = s);
1980
2229
  }
1981
2230
  );
1982
- const v = (s) => {
1983
- p("update:value", s), p("change", s), u.value = s, i != null && i.value.errClass && o && Z(o);
2231
+ const f = (s) => {
2232
+ p("update:value", s), p("change", s), u.value = s, i != null && i.value.errClass && o && le(o);
1984
2233
  };
1985
- return ee(async () => {
2234
+ return X(async () => {
1986
2235
  if (t.value) {
1987
2236
  const s = o == null ? void 0 : o.page;
1988
2237
  if (t.value.api || (t.value.api = s == null ? void 0 : s.api), t.value.authorize === void 0 && (t.value.authorize = s == null ? void 0 : s.authorize), e.autoload) {
1989
- const m = await Je(o, {
2238
+ const m = await at(o, {
1990
2239
  urlKey: "list",
1991
2240
  url: { ...t.value, url: t.value.url },
1992
2241
  loadingText: !1,
1993
2242
  params: e.params
1994
2243
  });
1995
- d.value = (m == null ? void 0 : m.data) ?? [];
2244
+ c.value = (m == null ? void 0 : m.data) ?? [];
1996
2245
  }
1997
2246
  }
1998
2247
  }), (s, m) => {
1999
- var c;
2000
- return f(), b(r(la), L({
2001
- class: ((c = r(i)) == null ? void 0 : c.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
2002
- placeholder: "请输入" + r(n),
2248
+ var d;
2249
+ return v(), b(l(na), B({
2250
+ class: ((d = l(i)) == null ? void 0 : d.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
2251
+ placeholder: "请输入" + l(n),
2003
2252
  targetKeys: u.value,
2004
- onChange: v
2253
+ onChange: f
2005
2254
  }, s.$attrs), {
2006
- children: h(({ direction: g, disabled: $, filteredItems: E, onItemSelectAll: P, onItemSelect: k, selectedKeys: R }) => [
2007
- D(s.$slots, "children", {
2255
+ children: h(({ direction: g, disabled: C, filteredItems: F, onItemSelectAll: U, onItemSelect: $, selectedKeys: A }) => [
2256
+ P(s.$slots, "children", {
2008
2257
  direction: g,
2009
- disabled: $,
2010
- filteredItems: E,
2011
- onItemSelectAll: P,
2012
- onItemSelect: k,
2013
- selectedKeys: R
2258
+ disabled: C,
2259
+ filteredItems: F,
2260
+ onItemSelectAll: U,
2261
+ onItemSelect: $,
2262
+ selectedKeys: A
2014
2263
  })
2015
2264
  ]),
2016
2265
  _: 3
2017
2266
  }, 16, ["class", "placeholder", "targetKeys"]);
2018
2267
  };
2019
2268
  }
2020
- }), er = /* @__PURE__ */ T({
2269
+ }), nr = /* @__PURE__ */ T({
2021
2270
  __name: "transferTable",
2022
2271
  props: {
2023
2272
  /**
@@ -2043,48 +2292,48 @@ const jl = /* @__PURE__ */ T({
2043
2292
  }
2044
2293
  },
2045
2294
  emits: ["update:value"],
2046
- setup(l, { emit: a }) {
2047
- const e = l, t = a, o = y(e.autoload), n = y(e.value), i = y(e.gridCtrl.primaryKey);
2048
- F(
2295
+ setup(r, { emit: a }) {
2296
+ const e = r, t = a, o = y(e.autoload), n = y(e.value), i = y(e.gridCtrl.primaryKey);
2297
+ I(
2049
2298
  () => n.value,
2050
2299
  (u) => {
2051
2300
  t("update:value", u);
2052
2301
  }
2053
- ), F(
2302
+ ), I(
2054
2303
  () => e.value,
2055
2304
  (u) => {
2056
2305
  u && (n.value = u);
2057
2306
  }
2058
2307
  ), e.gridCtrl.autoload = !1, e.gridCtrl.remotePage = !1, e.gridCtrl.selectable = y(!0), e.gridCtrl.buttons = y([]), e.gridCtrl.tools = [];
2059
- const p = ({ disabled: u, selectedKeys: v, onItemSelectAll: s, onItemSelect: m }) => ({
2060
- getCheckboxProps: (c) => ({
2308
+ const p = ({ disabled: u, selectedKeys: f, onItemSelectAll: s, onItemSelect: m }) => ({
2309
+ getCheckboxProps: (d) => ({
2061
2310
  // 控制是否禁止
2062
- disabled: u || c.disabled
2311
+ disabled: u || d.disabled
2063
2312
  }),
2064
- onSelectAll(c, g) {
2065
- const $ = g.filter((E) => !E.disabled).map(({ [i.value]: E }) => E);
2066
- s($, c);
2313
+ onSelectAll(d, g) {
2314
+ const C = g.filter((F) => !F.disabled).map(({ [i.value]: F }) => F);
2315
+ s(C, d);
2067
2316
  },
2068
- onSelect({ [i.value]: c }, g) {
2069
- m(c, g);
2317
+ onSelect({ [i.value]: d }, g) {
2318
+ m(d, g);
2070
2319
  },
2071
- selectedRowKeys: v
2072
- }), d = y([]);
2073
- return ee(async () => {
2320
+ selectedRowKeys: f
2321
+ }), c = y([]);
2322
+ return X(async () => {
2074
2323
  if (o.value) {
2075
- const u = await Je(e.gridCtrl, {
2324
+ const u = await at(e.gridCtrl, {
2076
2325
  urlKey: "list",
2077
2326
  url: { ...e.gridCtrl.gridUrl, url: e.gridCtrl.gridUrl.url },
2078
2327
  params: e.gridCtrl.gridQuery,
2079
2328
  loadingText: !1
2080
2329
  });
2081
- d.value = (u == null ? void 0 : u.data) ?? [];
2330
+ c.value = (u == null ? void 0 : u.data) ?? [];
2082
2331
  }
2083
- }), (u, v) => (f(), b(Ga, L({
2084
- "data-source": d.value,
2332
+ }), (u, f) => (v(), b(al, B({
2333
+ "data-source": c.value,
2085
2334
  "row-key": (s) => s[i.value],
2086
2335
  value: n.value,
2087
- "onUpdate:value": v[0] || (v[0] = (s) => n.value = s),
2336
+ "onUpdate:value": f[0] || (f[0] = (s) => n.value = s),
2088
2337
  "list-style": {
2089
2338
  width: "300px",
2090
2339
  height: "500px"
@@ -2092,30 +2341,30 @@ const jl = /* @__PURE__ */ T({
2092
2341
  "show-select-all": !1,
2093
2342
  "show-search": !0,
2094
2343
  "filter-option": (s, m) => {
2095
- for (const c of e.gridCtrl.columns.value)
2096
- if (m[c.dataIndex].toString().indexOf(s) !== -1)
2344
+ for (const d of e.gridCtrl.columns.value)
2345
+ if (m[d.dataIndex].toString().indexOf(s) !== -1)
2097
2346
  return !0;
2098
2347
  return !1;
2099
2348
  }
2100
2349
  }, u.$attrs), {
2101
- children: h(({ filteredItems: s, onItemSelectAll: m, onItemSelect: c, selectedKeys: g }) => [
2102
- S(r(lt), {
2103
- columns: l.gridCtrl.columns.value,
2350
+ children: h(({ filteredItems: s, onItemSelectAll: m, onItemSelect: d, selectedKeys: g }) => [
2351
+ S(l(ct), {
2352
+ columns: r.gridCtrl.columns.value,
2104
2353
  "row-key": i.value,
2105
2354
  "row-selection": p({
2106
2355
  disabled: !1,
2107
2356
  selectedKeys: g,
2108
2357
  onItemSelectAll: m,
2109
- onItemSelect: c
2358
+ onItemSelect: d
2110
2359
  }),
2111
2360
  bordered: !1,
2112
2361
  size: "small",
2113
2362
  "data-source": s,
2114
2363
  scroll: { x: 300 },
2115
- "custom-row": ($) => ({
2364
+ "custom-row": (C) => ({
2116
2365
  onClick: () => {
2117
- const E = $[i.value];
2118
- c(E, !g.includes(E));
2366
+ const F = C[i.value];
2367
+ d(F, !g.includes(F));
2119
2368
  }
2120
2369
  })
2121
2370
  }, null, 8, ["columns", "row-key", "row-selection", "data-source", "custom-row"])
@@ -2123,7 +2372,7 @@ const jl = /* @__PURE__ */ T({
2123
2372
  _: 1
2124
2373
  }, 16, ["data-source", "row-key", "value", "filter-option"]));
2125
2374
  }
2126
- }), Ja = /* @__PURE__ */ T({
2375
+ }), ll = /* @__PURE__ */ T({
2127
2376
  __name: "index",
2128
2377
  props: {
2129
2378
  multiple: {
@@ -2149,66 +2398,66 @@ const jl = /* @__PURE__ */ T({
2149
2398
  }
2150
2399
  },
2151
2400
  emits: ["change", "update:value"],
2152
- setup(l, { emit: a }) {
2153
- const e = l, t = e.value === void 0 ? !0 : e.undefValue, o = e.treeCtrl, n = V(), { errInfo: i, labelText: p } = n, d = a;
2154
- n.inputEmit = d;
2155
- const u = y([]), v = y();
2156
- F(
2401
+ setup(r, { emit: a }) {
2402
+ const e = r, t = e.value === void 0 ? !0 : e.undefValue, o = e.treeCtrl, n = q(), { errInfo: i, labelText: p } = n, c = a;
2403
+ n.inputEmit = c;
2404
+ const u = y([]), f = y();
2405
+ I(
2157
2406
  () => e.value,
2158
- (c) => {
2159
- v.value = c;
2407
+ (d) => {
2408
+ f.value = d;
2160
2409
  },
2161
2410
  { immediate: !0 }
2162
- ), F(
2163
- () => v.value,
2164
- (c) => {
2165
- d("update:value", c);
2411
+ ), I(
2412
+ () => f.value,
2413
+ (d) => {
2414
+ c("update:value", d);
2166
2415
  }
2167
- ), F(
2416
+ ), I(
2168
2417
  () => o.data.value,
2169
- (c) => {
2170
- c && (u.value = o.fieldMap ? ve(o.fieldMap, c) : c);
2418
+ (d) => {
2419
+ d && (u.value = o.fieldMap ? he(o.fieldMap, d) : d);
2171
2420
  },
2172
2421
  { immediate: !0 }
2173
2422
  );
2174
- const s = (c) => {
2175
- e.multiple ? v.value = c ?? [] : c == null ? v.value = t ? void 0 : null : v.value = c, d("change", v.value);
2423
+ const s = (d) => {
2424
+ e.multiple ? f.value = d ?? [] : d == null ? f.value = t ? void 0 : null : f.value = d, c("change", f.value);
2176
2425
  };
2177
- Pe(() => {
2426
+ xe(() => {
2178
2427
  e.treeCtrl && e.treeCtrl.autoload && (e.treeCtrl.reload.value = !0);
2179
- }), ee(() => {
2428
+ }), X(() => {
2180
2429
  o.fieldMap || (o.fieldMap = {
2181
2430
  label: "Name",
2182
2431
  key: "Id",
2183
2432
  value: "Id"
2184
- }), o.data.value ? u.value = o.fieldMap ? ve(o.fieldMap, o.data.value) : o.data.value : e.treeCtrl.autoload && Ge(e.treeCtrl);
2433
+ }), o.data.value ? u.value = o.fieldMap ? he(o.fieldMap, o.data.value) : o.data.value : e.treeCtrl.autoload && tt(e.treeCtrl);
2185
2434
  });
2186
2435
  const m = () => {
2187
- v.value = t ? void 0 : null;
2436
+ f.value = t ? void 0 : null;
2188
2437
  };
2189
- return (c, g) => {
2190
- var $;
2191
- return f(), b(r(ra), L({
2192
- class: [[($ = r(i)) == null ? void 0 : $.errClass], "w-full"],
2438
+ return (d, g) => {
2439
+ var C;
2440
+ return v(), b(l(ia), B({
2441
+ class: [[(C = l(i)) == null ? void 0 : C.errClass], "w-full"],
2193
2442
  "tree-line": "",
2194
- multiple: l.multiple,
2443
+ multiple: r.multiple,
2195
2444
  "tree-default-expanded-keys": ["-"],
2196
- value: v.value,
2197
- "onUpdate:value": g[0] || (g[0] = (E) => v.value = E),
2445
+ value: f.value,
2446
+ "onUpdate:value": g[0] || (g[0] = (F) => f.value = F),
2198
2447
  "tree-data": u.value,
2199
- placeholder: "请选择" + r(p),
2448
+ placeholder: "请选择" + l(p),
2200
2449
  onChange: s,
2201
2450
  onClear: m
2202
- }, c.$attrs), null, 16, ["class", "multiple", "value", "tree-data", "placeholder"]);
2451
+ }, d.$attrs), null, 16, ["class", "multiple", "value", "tree-data", "placeholder"]);
2203
2452
  };
2204
2453
  }
2205
- }), tr = /* @__PURE__ */ te(Ja, [["__scopeId", "data-v-71d50074"]]), Xa = { class: "w-full mt-1" }, Za = { class: "flex flex-wrap gap-2" }, el = ["onMouseenter"], tl = { class: "w-16 h-16 border border-solid border-gray-200 rounded overflow-hidden" }, al = ["src"], ll = {
2454
+ }), ir = /* @__PURE__ */ se(ll, [["__scopeId", "data-v-71d50074"]]), rl = { class: "w-full mt-1" }, sl = { class: "flex flex-wrap gap-2" }, ol = ["onMouseenter"], nl = { class: "w-16 h-16 border border-solid border-gray-200 rounded overflow-hidden" }, il = ["src"], ul = {
2206
2455
  key: 0,
2207
2456
  class: "absolute inset-0 bg-black bg-opacity-50 flex items-center justify-center gap-4 rounded"
2208
- }, rl = ["onClick"], sl = ["onClick"], ol = {
2457
+ }, cl = ["onClick"], dl = ["onClick"], pl = {
2209
2458
  key: 0,
2210
2459
  class: "w-16 h-16"
2211
- }, nl = /* @__PURE__ */ T({
2460
+ }, fl = /* @__PURE__ */ T({
2212
2461
  __name: "imageList",
2213
2462
  props: {
2214
2463
  autoUpload: { type: Boolean, default: !1 },
@@ -2227,172 +2476,172 @@ const jl = /* @__PURE__ */ T({
2227
2476
  showDelete: { type: Boolean, default: !0 }
2228
2477
  },
2229
2478
  emits: ["update:file-list"],
2230
- setup(l, { emit: a }) {
2231
- const e = l, t = V(), { errInfo: o } = t, n = y(e.fileList), i = y([]), p = y(), d = a, u = Y(() => {
2232
- var x;
2233
- return (x = e.fileExt) != null && x.length ? e.fileExt.map((_) => `.${_}`).join(",") : "";
2234
- }), v = (x) => {
2479
+ setup(r, { emit: a }) {
2480
+ const e = r, t = q(), { errInfo: o } = t, n = y(e.fileList), i = y([]), p = y(), c = a, u = R(() => {
2235
2481
  var _;
2482
+ return (_ = e.fileExt) != null && _.length ? e.fileExt.map((k) => `.${k}`).join(",") : "";
2483
+ }), f = (_) => {
2484
+ var k;
2236
2485
  if (e.fileExt && e.fileExt.length > 0) {
2237
- const B = ((_ = x.name.split(".").pop()) == null ? void 0 : _.toLowerCase()) || "";
2238
- if (!e.fileExt.includes(B))
2239
- return q.error("文件类型不支持"), !1;
2486
+ const z = ((k = _.name.split(".").pop()) == null ? void 0 : k.toLowerCase()) || "";
2487
+ if (!e.fileExt.includes(z))
2488
+ return G.error("文件类型不支持"), !1;
2240
2489
  }
2241
- return x.size / 1024 / 1024 > e.maxFileSize ? (q.error(`文件大小超过 ${e.maxFileSize}MB 限制`), !1) : !0;
2242
- }, s = () => e.maxCount > 1 && n.value.length >= e.maxCount, m = (x) => {
2243
- const _ = x;
2244
- return _.params || (_.params = {}), _.params.FileKey = _.name, e.parentPath && (_.params.FileKey = Ne.join("/", e.parentPath, _.name)), _;
2245
- }, c = (x) => v(x) && e.autoUpload, g = async (x) => {
2246
- if (x.length === 0) return;
2247
- const _ = [...n.value];
2248
- let B = !1;
2249
- for (const z of x) {
2250
- if (!v(z)) {
2251
- B = !0;
2490
+ return _.size / 1024 / 1024 > e.maxFileSize ? (G.error(`文件大小超过 ${e.maxFileSize}MB 限制`), !1) : !0;
2491
+ }, s = () => e.maxCount > 1 && n.value.length >= e.maxCount, m = (_) => {
2492
+ const k = _;
2493
+ return k.params || (k.params = {}), k.params.FileKey = k.name, e.parentPath && (k.params.FileKey = Oe.join("/", e.parentPath, k.name)), k;
2494
+ }, d = (_) => f(_) && e.autoUpload, g = async (_) => {
2495
+ if (_.length === 0) return;
2496
+ const k = [...n.value];
2497
+ let z = !1;
2498
+ for (const j of _) {
2499
+ if (!f(j)) {
2500
+ z = !0;
2252
2501
  continue;
2253
2502
  }
2254
- const N = m(z);
2503
+ const O = m(j);
2255
2504
  if (e.maxCount === 1) {
2256
- _.length = 0, _.push(N);
2505
+ k.length = 0, k.push(O);
2257
2506
  break;
2258
2507
  }
2259
2508
  if (s()) {
2260
- q.error(`最多上传 ${e.maxCount} 个文件`), B = !0;
2509
+ G.error(`最多上传 ${e.maxCount} 个文件`), z = !0;
2261
2510
  break;
2262
2511
  }
2263
- const G = _.findIndex((_e) => _e.name === N.name);
2264
- G > -1 ? _[G] = N : _.push(N);
2512
+ const ee = k.findIndex((Ie) => Ie.name === O.name);
2513
+ ee > -1 ? k[ee] = O : k.push(O);
2265
2514
  }
2266
- (!B || _.length > 0) && (n.value = _), i.value = [];
2267
- }, $ = (x) => {
2268
- i.value = x, g(x);
2269
- }, E = Y(() => ({
2515
+ (!z || k.length > 0) && (n.value = k), i.value = [];
2516
+ }, C = (_) => {
2517
+ i.value = _, g(_);
2518
+ }, F = R(() => ({
2270
2519
  accept: u.value,
2271
2520
  multiple: e.maxCount !== 1,
2272
2521
  fileList: i.value,
2273
- "onUpdate:fileList": $,
2274
- beforeUpload: c,
2522
+ "onUpdate:fileList": C,
2523
+ beforeUpload: d,
2275
2524
  listType: "text",
2276
2525
  showUploadList: !1,
2277
2526
  customRequest: async () => {
2278
2527
  if (e.autoUpload && e.uploadUrl)
2279
- for (const x of n.value)
2280
- x.percent === 0 && await Bt(e.uploadUrl, x);
2528
+ for (const _ of n.value)
2529
+ _.percent === 0 && await Ot(e.uploadUrl, _);
2281
2530
  }
2282
2531
  }));
2283
- F(
2532
+ I(
2284
2533
  () => e.fileList,
2285
- (x) => {
2286
- n.value = x;
2534
+ (_) => {
2535
+ n.value = _;
2287
2536
  },
2288
2537
  { deep: !0, immediate: !0 }
2289
- ), F(
2538
+ ), I(
2290
2539
  () => n.value,
2291
- (x) => {
2292
- d("update:file-list", x);
2540
+ (_) => {
2541
+ c("update:file-list", _);
2293
2542
  },
2294
2543
  { deep: !0 }
2295
- ), F(
2544
+ ), I(
2296
2545
  () => e.parentPath,
2297
- (x) => {
2298
- x && n.value.forEach((_) => {
2299
- _.params.FileKey = Ne.join("/", x, _.fileName);
2546
+ (_) => {
2547
+ _ && n.value.forEach((k) => {
2548
+ k.params.FileKey = Oe.join("/", _, k.fileName);
2300
2549
  });
2301
2550
  }
2302
2551
  );
2303
- const P = y(!1), k = y(""), R = (x) => {
2304
- const _ = n.value[x];
2305
- k.value = pe(_), P.value = !0;
2306
- }, j = (x) => {
2307
- const _ = n.value[x];
2308
- e.deleteUrl && _.minioFile && _.minioFile.Key ? Fe(e.deleteUrl, {
2552
+ const U = y(!1), $ = y(""), A = (_) => {
2553
+ const k = n.value[_];
2554
+ $.value = fe(k), U.value = !0;
2555
+ }, H = (_) => {
2556
+ const k = n.value[_];
2557
+ e.deleteUrl && k.minioFile && k.minioFile.Key ? Be(e.deleteUrl, {
2309
2558
  Query: {
2310
- FileKey: _.minioFile.Key
2559
+ FileKey: k.minioFile.Key
2311
2560
  }
2312
- }).then((B) => {
2313
- B && B.status === Ie.SUCCESS && (q.success("删除文件成功!"), n.value.splice(x, 1));
2314
- }) : n.value.splice(x, 1);
2315
- }, Q = y(/* @__PURE__ */ new Map()), pe = (x) => {
2316
- if (x.originFileObj)
2317
- return URL.createObjectURL(x.originFileObj);
2318
- if (x.minioFile) {
2319
- const _ = x.minioFile.Key;
2320
- return Q.value.has(_) ? Q.value.get(_) : (ye(x), "");
2561
+ }).then((z) => {
2562
+ z && z.status === Me.SUCCESS && (G.success("删除文件成功!"), n.value.splice(_, 1));
2563
+ }) : n.value.splice(_, 1);
2564
+ }, Z = y(/* @__PURE__ */ new Map()), fe = (_) => {
2565
+ if (_.originFileObj)
2566
+ return URL.createObjectURL(_.originFileObj);
2567
+ if (_.minioFile) {
2568
+ const k = _.minioFile.Key;
2569
+ return Z.value.has(k) ? Z.value.get(k) : ($e(_), "");
2321
2570
  }
2322
2571
  return "";
2323
- }, ye = async (x) => {
2324
- if (!x.minioFile || !e.previewUrl) return;
2325
- const _ = x.minioFile.Key;
2572
+ }, $e = async (_) => {
2573
+ if (!_.minioFile || !e.previewUrl) return;
2574
+ const k = _.minioFile.Key;
2326
2575
  try {
2327
- const B = `${e.previewUrl.url}?FileKey=${encodeURIComponent(x.minioFile.Key)}`, z = Nt() ? await Mt.getToken() : $e().getToken(), N = await fetch(B, {
2576
+ const z = `${e.previewUrl.url}?FileKey=${encodeURIComponent(_.minioFile.Key)}`, j = At() ? await zt.getToken() : Le().getToken(), O = await fetch(z, {
2328
2577
  method: "GET",
2329
2578
  headers: {
2330
- Authorization: `Bearer ${z}`
2579
+ Authorization: `Bearer ${j}`
2331
2580
  }
2332
2581
  });
2333
- if (N.ok) {
2334
- const G = await N.blob(), _e = URL.createObjectURL(G);
2335
- Q.value.set(_, _e);
2582
+ if (O.ok) {
2583
+ const ee = await O.blob(), Ie = URL.createObjectURL(ee);
2584
+ Z.value.set(k, Ie);
2336
2585
  } else
2337
- console.error("加载图片失败:", N.status);
2338
- } catch (B) {
2339
- console.error("加载图片失败:", B);
2586
+ console.error("加载图片失败:", O.status);
2587
+ } catch (z) {
2588
+ console.error("加载图片失败:", z);
2340
2589
  }
2341
- }, pt = Y(() => n.value.length < e.maxCount), xe = y(-1);
2342
- return (x, _) => {
2343
- const B = ne("auth");
2344
- return f(), w("div", Xa, [
2345
- I("div", Za, [
2346
- (f(!0), w(A, null, H(n.value, (z, N) => (f(), w("div", {
2347
- key: N,
2590
+ }, _t = R(() => n.value.length < e.maxCount), Te = y(-1);
2591
+ return (_, k) => {
2592
+ const z = re("auth");
2593
+ return v(), w("div", rl, [
2594
+ D("div", sl, [
2595
+ (v(!0), w(L, null, V(n.value, (j, O) => (v(), w("div", {
2596
+ key: O,
2348
2597
  class: "relative image-item",
2349
- onMouseenter: (G) => xe.value = N,
2350
- onMouseleave: _[0] || (_[0] = (G) => xe.value = -1)
2598
+ onMouseenter: (ee) => Te.value = O,
2599
+ onMouseleave: k[0] || (k[0] = (ee) => Te.value = -1)
2351
2600
  }, [
2352
- I("div", tl, [
2353
- I("img", {
2354
- src: pe(z),
2601
+ D("div", nl, [
2602
+ D("img", {
2603
+ src: fe(j),
2355
2604
  class: "w-full h-full object-cover"
2356
- }, null, 8, al)
2605
+ }, null, 8, il)
2357
2606
  ]),
2358
- xe.value === N ? (f(), w("div", ll, [
2359
- x.previewUrl ? (f(), w("div", {
2607
+ Te.value === O ? (v(), w("div", ul, [
2608
+ _.previewUrl ? (v(), w("div", {
2360
2609
  key: 0,
2361
2610
  class: "flex items-center text-white cursor-pointer hover:text-blue-400",
2362
- onClick: (G) => R(N)
2611
+ onClick: (ee) => A(O)
2363
2612
  }, [
2364
- S(r(K), {
2613
+ S(l(K), {
2365
2614
  icon: "icon-eye",
2366
2615
  clickable: ""
2367
2616
  }),
2368
- _[1] || (_[1] = I("span", { class: "text-sm ml-1" }, "预览", -1))
2369
- ], 8, rl)) : C("", !0),
2370
- x.showDelete !== !1 ? (f(), w("div", {
2617
+ k[1] || (k[1] = D("span", { class: "text-sm ml-1" }, "预览", -1))
2618
+ ], 8, cl)) : x("", !0),
2619
+ _.showDelete !== !1 ? (v(), w("div", {
2371
2620
  key: 1,
2372
2621
  class: "flex items-center text-white cursor-pointer hover:text-red-400",
2373
- onClick: (G) => j(N)
2622
+ onClick: (ee) => H(O)
2374
2623
  }, [
2375
- S(r(K), {
2624
+ S(l(K), {
2376
2625
  icon: "icon-new",
2377
2626
  angle: 45,
2378
2627
  clickable: ""
2379
2628
  }),
2380
- _[2] || (_[2] = I("span", { class: "text-sm ml-1" }, "删除", -1))
2381
- ], 8, sl)) : C("", !0)
2382
- ])) : C("", !0)
2383
- ], 40, el))), 128)),
2384
- pt.value ? (f(), w("div", ol, [
2385
- X((f(), b(r(sa), L({
2629
+ k[2] || (k[2] = D("span", { class: "text-sm ml-1" }, "删除", -1))
2630
+ ], 8, dl)) : x("", !0)
2631
+ ])) : x("", !0)
2632
+ ], 40, ol))), 128)),
2633
+ _t.value ? (v(), w("div", pl, [
2634
+ W((v(), b(l(ua), B({
2386
2635
  ref_key: "fileUploader",
2387
2636
  ref: p
2388
- }, E.value), {
2637
+ }, F.value), {
2389
2638
  default: h(() => {
2390
- var z;
2639
+ var j;
2391
2640
  return [
2392
- I("div", {
2393
- class: U(["w-16 h-16 border border-dashed border-gray-300 rounded flex items-center justify-center cursor-pointer hover:border-blue-500 transition-colors", [(z = r(o)) == null ? void 0 : z.errClass]])
2641
+ D("div", {
2642
+ class: E(["w-16 h-16 border border-dashed border-gray-300 rounded flex items-center justify-center cursor-pointer hover:border-blue-500 transition-colors", [(j = l(o)) == null ? void 0 : j.errClass]])
2394
2643
  }, [
2395
- S(r(K), {
2644
+ S(l(K), {
2396
2645
  icon: "icon-new",
2397
2646
  class: "text-gray-400 w-10 h-10"
2398
2647
  })
@@ -2401,42 +2650,42 @@ const jl = /* @__PURE__ */ T({
2401
2650
  }),
2402
2651
  _: 1
2403
2652
  }, 16)), [
2404
- [B, { role: ["Super", "Admin"], permit: ":imagelist:upload" }]
2653
+ [z, { role: ["Super", "Admin"], permit: ":imagelist:upload" }]
2405
2654
  ])
2406
- ])) : C("", !0)
2655
+ ])) : x("", !0)
2407
2656
  ]),
2408
- S(r(oa), {
2409
- preview: { visible: P.value, onVisibleChange: (z) => P.value = z },
2410
- src: k.value,
2657
+ S(l(ca), {
2658
+ preview: { visible: U.value, onVisibleChange: (j) => U.value = j },
2659
+ src: $.value,
2411
2660
  style: { display: "none" }
2412
2661
  }, null, 8, ["preview", "src"])
2413
2662
  ]);
2414
2663
  };
2415
2664
  }
2416
- }), ar = /* @__PURE__ */ te(nl, [["__scopeId", "data-v-26d707cc"]]), il = { class: "relative h-[calc(100vh-80px)] overflow-y-auto" }, ul = { class: "flex w-full h-full min-h-full" }, cl = {
2665
+ }), ur = /* @__PURE__ */ se(fl, [["__scopeId", "data-v-26d707cc"]]), vl = { class: "relative h-[calc(100vh-80px)] overflow-y-auto" }, ml = { class: "flex w-full h-full min-h-full" }, hl = {
2417
2666
  key: 0,
2418
2667
  class: "w-1/4 pr-4 min-h-full min-w-[170px] max-w-[200px]"
2419
- }, dl = { class: "flex-1 h-full overflow-y-auto" }, lr = /* @__PURE__ */ T({
2668
+ }, gl = { class: "flex-1 h-full overflow-y-auto" }, cr = /* @__PURE__ */ T({
2420
2669
  __name: "index",
2421
2670
  props: {
2422
2671
  left: { type: Boolean }
2423
2672
  },
2424
- setup(l) {
2425
- const { useToken: a } = Ze, { token: e } = a();
2426
- return (t, o) => (f(), w("div", il, [
2427
- S(r(na), {
2673
+ setup(r) {
2674
+ const { useToken: a } = rt, { token: e } = a();
2675
+ return (t, o) => (v(), w("div", vl, [
2676
+ S(l(da), {
2428
2677
  class: "m-[10px] p-[10px] h-[calc(100vh-100px)] !min-h-[calc(100vh-100px)]",
2429
- style: De({
2430
- backgroundColor: r(e).colorBgContainer
2678
+ style: ze({
2679
+ backgroundColor: l(e).colorBgContainer
2431
2680
  })
2432
2681
  }, {
2433
2682
  default: h(() => [
2434
- I("div", ul, [
2435
- t.left ? (f(), w("div", cl, [
2436
- D(t.$slots, "left")
2437
- ])) : C("", !0),
2438
- I("div", dl, [
2439
- D(t.$slots, "default")
2683
+ D("div", ml, [
2684
+ t.left ? (v(), w("div", hl, [
2685
+ P(t.$slots, "left")
2686
+ ])) : x("", !0),
2687
+ D("div", gl, [
2688
+ P(t.$slots, "default")
2440
2689
  ])
2441
2690
  ])
2442
2691
  ]),
@@ -2446,158 +2695,160 @@ const jl = /* @__PURE__ */ T({
2446
2695
  }
2447
2696
  });
2448
2697
  export {
2449
- Zr as Alert,
2450
- vs as AppIcon,
2451
- ge as AppRouter,
2452
- Yr as AsyncUploader,
2453
- zl as AutoComplete,
2454
- ms as Breadcrumb,
2455
- W as Button,
2456
- ot as Cache,
2457
- _a as CacheKeys,
2458
- Hr as CanPreviewFileExt,
2459
- Kl as Cascader,
2460
- Vl as Checkbox,
2461
- lr as Content,
2462
- jl as DatePicker,
2463
- hs as Datetime,
2464
- Cs as Dialog,
2465
- Ml as Drawer,
2466
- or as EventPrefix,
2467
- Bl as Form,
2468
- Nl as FormItem,
2469
- Ul as Fullscreen,
2470
- gs as Header,
2471
- bs as HeaderExits,
2472
- wa as Helper,
2473
- nr as ICONS_LIB,
2474
- ys as Icon,
2475
- Ua as Icontool,
2476
- ar as ImageList,
2477
- Ya as Input,
2478
- Yl as InputIcon,
2479
- ql as InputNumber,
2480
- Wl as InputPassword,
2481
- Ll as LayoutIcon,
2482
- es as Loading,
2483
- xs as Menu,
2484
- _s as MenuTabs,
2485
- Mt as MicroOpenApis,
2486
- Qe as OPTIONS,
2487
- St as OptionCommProps,
2488
- ks as ProjectIcon,
2489
- Hl as PropEditor,
2490
- re as ProviderKeys,
2491
- Qa as Radio,
2492
- Ql as RadioStatus,
2493
- Gl as RangePicker,
2494
- Ol as Search,
2495
- we as SearchItem,
2496
- Jl as Select,
2497
- _t as Switch,
2498
- Rl as Table,
2499
- Da as TableOperate,
2500
- Xl as Textarea,
2501
- Zl as TimePicker,
2698
+ os as Alert,
2699
+ xs as AppIcon,
2700
+ ue as AppRouter,
2701
+ Xr as AsyncUploader,
2702
+ Hl as AutoComplete,
2703
+ ks as Breadcrumb,
2704
+ Q as Button,
2705
+ ft as Cache,
2706
+ Sa as CacheKeys,
2707
+ ts as CanPreviewFileExt,
2708
+ Ql as Cascader,
2709
+ Gl as Checkbox,
2710
+ cr as Content,
2711
+ Jl as DatePicker,
2712
+ ws as Datetime,
2713
+ Ps as Dialog,
2714
+ Rl as Drawer,
2715
+ fr as EventPrefix,
2716
+ Kl as Form,
2717
+ jl as FormItem,
2718
+ Ol as Fullscreen,
2719
+ Cs as Header,
2720
+ Ss as HeaderExits,
2721
+ Ta as Helper,
2722
+ vr as ICONS_LIB,
2723
+ $s as Icon,
2724
+ La as Icontool,
2725
+ ur as ImageList,
2726
+ Ja as Input,
2727
+ Xl as InputIcon,
2728
+ er as InputNumber,
2729
+ Zl as InputPassword,
2730
+ Al as LayoutIcon,
2731
+ Vl as List,
2732
+ Pa as ListOperate,
2733
+ ns as Loading,
2734
+ Ts as Menu,
2735
+ Is as MenuTabs,
2736
+ zt as MicroOpenApis,
2737
+ Ne as OPTIONS,
2738
+ It as OptionCommProps,
2739
+ Ds as ProjectIcon,
2740
+ tr as PropEditor,
2741
+ ae as ProviderKeys,
2742
+ tl as Radio,
2743
+ ar as RadioStatus,
2744
+ lr as RangePicker,
2745
+ Yl as Search,
2746
+ Fe as SearchItem,
2747
+ rr as Select,
2748
+ Ze as Switch,
2749
+ Wl as Table,
2750
+ ja as TableOperate,
2751
+ sr as Textarea,
2752
+ or as TimePicker,
2502
2753
  K as ToolIcon,
2503
- Na as Toolbar,
2504
- ps as Tooltip,
2505
- Ga as Transfer,
2506
- er as TransferTable,
2507
- Al as Tree,
2508
- tr as TreeSelect,
2509
- Qr as UploadList,
2510
- Wr as UploadStatus,
2511
- ts as appendExcelData,
2512
- as as checkExcelDuplicates,
2513
- ir as checkIconsExpired,
2514
- It as circleLoading,
2515
- vt as createFromIconfont,
2516
- ls as createMarkedExcelView,
2517
- ur as crumbs,
2518
- Il as csvToExcelBlob,
2519
- rt as csvToExcelView,
2520
- rs as csvToNormalized,
2521
- je as defaultTools,
2522
- cr as doDelete,
2523
- dr as doExecute,
2524
- Je as doQuery,
2525
- pr as doSave,
2526
- Gr as donwloadFromMinio,
2527
- ua as downloadBlob,
2528
- fr as eventBus,
2529
- ss as excelToExcelView,
2530
- os as excelToNormalized,
2531
- Pl as exportResults,
2532
- Dl as exportSelectedRows,
2533
- He as filterColumns,
2534
- Z as formValidate,
2535
- vr as getFormDetail,
2536
- mr as getIconTransform,
2537
- hr as getRecordDetail,
2538
- gr as getRuleTexts,
2539
- Dt as getSelectedLabels,
2540
- br as getSelectedValues,
2541
- ae as getToolByKey,
2542
- Me as getToolGroup,
2543
- le as getToolStatus,
2544
- se as getToolVisible,
2545
- Be as gridQueryFind,
2546
- xt as gridQueryList,
2547
- yr as gridRowUpdate,
2548
- kt as gridStatusUpdate,
2549
- Fl as initCacheCheck,
2550
- Tl as initDirective,
2551
- xr as initMenu,
2552
- _r as initPageFactory,
2553
- kr as initValidate,
2554
- ie as isEmpty,
2555
- Tt as loadOption,
2556
- wr as mergeColumns,
2557
- ns as normalizedToExcelView,
2558
- ya as onColumnVisibleChanged,
2559
- ht as onFormClose,
2560
- Ye as onFormSave,
2561
- mt as onFormSaveAs,
2562
- st as onFullscreenClick,
2563
- bt as onGridRowDelete,
2564
- gt as onGridRowEdit,
2565
- Cr as onGridRowExpand,
2566
- Et as onOptionChanged,
2567
- pa as onReloadClick,
2568
- J as onToolClicked,
2569
- yt as openNewForm,
2570
- Sr as outFormDataFields,
2571
- $r as parseIcons,
2572
- Ne as path,
2573
- Tr as pendingNavigation,
2574
- Fr as pinia,
2575
- Jr as previewFromMinio,
2576
- El as processCsvFile,
2577
- is as processExcelFile,
2578
- Ge as queryTree,
2579
- Ir as resetRules,
2580
- Er as routes,
2581
- Dr as saveForm,
2582
- Pr as setFormData,
2583
- Ur as showBreadcrumb,
2584
- us as toExcel,
2585
- Ft as unloadOption,
2586
- Lr as uploadTempBtn,
2587
- Mr as uploadTempOpener,
2588
- Br as useAppInfo,
2589
- Nr as useEditorFactory,
2590
- We as useFormItemFactory,
2591
- Or as useGridFactory,
2592
- Rr as useHostInfo,
2593
- V as useInputFactory,
2594
- $t as useOptionFactory,
2595
- Ar as usePageFactory,
2596
- zr as usePageInfo,
2597
- Te as useSettingInfo,
2598
- xa as useToolFactory,
2599
- Kr as useTreeFactory,
2600
- $e as useUserInfo,
2601
- Vr as validateData,
2602
- cs as validateExcel
2754
+ yt as Toolbar,
2755
+ ys as Tooltip,
2756
+ al as Transfer,
2757
+ nr as TransferTable,
2758
+ ql as Tree,
2759
+ ir as TreeSelect,
2760
+ as as UploadList,
2761
+ Zr as UploadStatus,
2762
+ is as appendExcelData,
2763
+ us as checkExcelDuplicates,
2764
+ mr as checkIconsExpired,
2765
+ Et as circleLoading,
2766
+ kt as createFromIconfont,
2767
+ cs as createMarkedExcelView,
2768
+ hr as crumbs,
2769
+ Nl as csvToExcelBlob,
2770
+ dt as csvToExcelView,
2771
+ ds as csvToNormalized,
2772
+ Ye as defaultTools,
2773
+ gr as doDelete,
2774
+ br as doExecute,
2775
+ at as doQuery,
2776
+ yr as doSave,
2777
+ ls as donwloadFromMinio,
2778
+ fa as downloadBlob,
2779
+ _r as eventBus,
2780
+ ps as excelToExcelView,
2781
+ fs as excelToNormalized,
2782
+ zl as exportResults,
2783
+ Ml as exportSelectedRows,
2784
+ Je as filterColumns,
2785
+ le as formValidate,
2786
+ xr as getFormDetail,
2787
+ kr as getIconTransform,
2788
+ wr as getRecordDetail,
2789
+ Cr as getRuleTexts,
2790
+ Ut as getSelectedLabels,
2791
+ Sr as getSelectedValues,
2792
+ oe as getToolByKey,
2793
+ Ce as getToolGroup,
2794
+ te as getToolStatus,
2795
+ J as getToolVisible,
2796
+ me as gridQueryFind,
2797
+ Xe as gridQueryList,
2798
+ $r as gridRowUpdate,
2799
+ et as gridStatusUpdate,
2800
+ Ul as initCacheCheck,
2801
+ Ll as initDirective,
2802
+ Tr as initMenu,
2803
+ Ir as initPageFactory,
2804
+ Dr as initValidate,
2805
+ ce as isEmpty,
2806
+ Ft as loadOption,
2807
+ Fr as mergeColumns,
2808
+ vs as normalizedToExcelView,
2809
+ wa as onColumnVisibleChanged,
2810
+ Ct as onFormClose,
2811
+ We as onFormSave,
2812
+ wt as onFormSaveAs,
2813
+ pt as onFullscreenClick,
2814
+ Ge as onGridRowDelete,
2815
+ Qe as onGridRowEdit,
2816
+ Pr as onGridRowExpand,
2817
+ Lt as onOptionChanged,
2818
+ ha as onReloadClick,
2819
+ Y as onToolClicked,
2820
+ St as openNewForm,
2821
+ Er as outFormDataFields,
2822
+ Lr as parseIcons,
2823
+ Oe as path,
2824
+ Ur as pendingNavigation,
2825
+ Nr as pinia,
2826
+ rs as previewFromMinio,
2827
+ Bl as processCsvFile,
2828
+ ms as processExcelFile,
2829
+ tt as queryTree,
2830
+ Br as resetRules,
2831
+ Mr as routes,
2832
+ zr as saveForm,
2833
+ Or as setFormData,
2834
+ Ar as showBreadcrumb,
2835
+ hs as toExcel,
2836
+ Pt as unloadOption,
2837
+ Rr as uploadTempBtn,
2838
+ Kr as uploadTempOpener,
2839
+ jr as useAppInfo,
2840
+ Vr as useEditorFactory,
2841
+ qe as useFormItemFactory,
2842
+ Yr as useGridFactory,
2843
+ Wr as useHostInfo,
2844
+ q as useInputFactory,
2845
+ Dt as useOptionFactory,
2846
+ qr as usePageFactory,
2847
+ Hr as usePageInfo,
2848
+ Ue as useSettingInfo,
2849
+ Ca as useToolFactory,
2850
+ Qr as useTreeFactory,
2851
+ Le as useUserInfo,
2852
+ Gr as validateData,
2853
+ gs as validateExcel
2603
2854
  };