@skyfox2000/webui 1.2.7 → 1.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/assets/modules/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
- package/lib/assets/modules/file-upload-BYIvmkmy.js +204 -0
- package/lib/assets/modules/form-excel-BUX2QW11.js +235 -0
- package/lib/assets/modules/{index-BZvwPKou.js → index-DcRkhkn2.js} +1 -1
- package/lib/assets/modules/index-jl5Ie2tZ.js +112 -0
- package/lib/assets/modules/{menuTabs-izaFx0kk.js → menuTabs-DY1XBq16.js} +134 -139
- package/lib/assets/modules/{toolIcon-66dclHit.js → toolIcon-BDIOj_3l.js} +1 -1
- package/lib/assets/modules/uploadList-BPG5whz7.js +369 -0
- package/lib/assets/modules/{index-CKMDsqve.js → uploadList-D2Ux4h1N.js} +553 -513
- package/lib/components/common/index.d.ts +2 -0
- package/lib/components/common/loading/index.vue.d.ts +3 -0
- package/lib/components/content/dialog/index.vue.d.ts +1 -0
- package/lib/components/content/drawer/index.vue.d.ts +2 -0
- package/lib/components/content/form/formItem.vue.d.ts +2 -0
- package/lib/components/form/autoComplete/index.vue.d.ts +41 -4
- package/lib/components/form/cascader/index.vue.d.ts +13 -2
- package/lib/components/form/checkbox/index.vue.d.ts +13 -2
- package/lib/components/form/index.d.ts +1 -0
- package/lib/components/form/propEditor/index.vue.d.ts +10 -1
- package/lib/components/form/radio/index.vue.d.ts +13 -2
- package/lib/components/form/select/index.vue.d.ts +13 -2
- package/lib/components/form/upload/uploadList.vue.d.ts +14 -3
- package/lib/components/index.d.ts +2 -2
- package/lib/es/AceEditor/index.js +3 -3
- package/lib/es/BasicLayout/index.js +15 -15
- package/lib/es/Error403/index.js +1 -1
- package/lib/es/Error404/index.js +1 -1
- package/lib/es/ExcelForm/index.js +4 -4
- package/lib/es/UploadForm/index.js +60 -87
- package/lib/index.d.ts +3 -3
- package/lib/typings/form.d.ts +18 -2
- package/lib/typings/option.d.ts +16 -2
- package/lib/typings/page.d.ts +1 -0
- package/lib/utils/file-upload.d.ts +4 -2
- package/lib/utils/form-excel.d.ts +3 -0
- package/lib/utils/main-openapis.d.ts +0 -1
- package/lib/webui.css +1 -1
- package/lib/webui.es.js +1088 -1064
- package/package.json +1 -1
- package/scripts/userInput.py +2 -0
- package/src/components/common/index.ts +3 -0
- package/src/components/common/loading/index.vue +11 -0
- package/src/components/content/dialog/index.vue +15 -8
- package/src/components/content/dialog/uploadForm.vue +38 -79
- package/src/components/content/drawer/index.vue +26 -6
- package/src/components/content/form/formItem.vue +21 -5
- package/src/components/content/form/index.vue +4 -2
- package/src/components/content/search/searchItem.vue +1 -1
- package/src/components/form/autoComplete/index.vue +12 -4
- package/src/components/form/cascader/index.vue +1 -1
- package/src/components/form/datePicker/index.vue +1 -1
- package/src/components/form/index.ts +1 -0
- package/src/components/form/input/inputIcon.vue +1 -1
- package/src/components/form/propEditor/index.vue +113 -33
- package/src/components/form/select/index.vue +27 -17
- package/src/components/form/upload/uploadList.vue +174 -34
- package/src/components/index.ts +13 -1
- package/src/directives/permission.ts +11 -11
- package/src/index.ts +4 -10
- package/src/stores/appInfo.ts +6 -6
- package/src/typings/form.d.ts +18 -2
- package/src/typings/option.d.ts +16 -2
- package/src/typings/page.d.ts +1 -0
- package/src/utils/download.ts +1 -1
- package/src/utils/eventbus.ts +1 -1
- package/src/utils/file-upload.ts +75 -14
- package/src/utils/form-excel.ts +50 -1
- package/src/utils/form-validate.ts +18 -1
- package/src/utils/form.ts +3 -1
- package/src/utils/options.ts +38 -12
- package/lib/assets/modules/file-upload-D4bA7go8.js +0 -179
- package/lib/assets/modules/form-excel-DL2_SNiS.js +0 -211
- package/lib/assets/modules/index-D16E7UbH.js +0 -111
- package/lib/assets/modules/uploadList-Dw6eRrJT.js +0 -210
package/lib/webui.es.js
CHANGED
|
@@ -1,100 +1,104 @@
|
|
|
1
|
-
import { u as
|
|
2
|
-
import { a7 as
|
|
3
|
-
import { A as
|
|
1
|
+
import { u as Qe, i as Z, a as ve, c as qe, P as V, o as Pe, b as Ge, d as Je, e as Ee, r as ie, f as Xe, g as Ze, h as Fe, j as et, k as ke, l as tt, m as at, O as Me, q as Ne, _ as lt, n as st, p as O, s as rt, t as ot, v as nt, w as H, x as it, y as ct, z as ut, A as Re } from "./assets/modules/uploadList-D2Ux4h1N.js";
|
|
2
|
+
import { a7 as _l, L as bl, M as xl, S as yl, a6 as kl, a4 as wl, a5 as Sl, a8 as Cl, V as $l, Q as Tl, a2 as Il, $ as Dl, K as Pl, H as El, a1 as Fl, R as Ml, C as Nl, X as Rl, a0 as Al, a3 as Bl, J as Ol, I as Ll, N as zl, a9 as Ul, B as Yl, Z as Wl, aa as Kl, U as Vl, W as jl, T as Hl, ab as Ql, D as ql, E as Gl, ac as Jl, G as Xl, ad as Zl, F as es, Y as ts } from "./assets/modules/uploadList-D2Ux4h1N.js";
|
|
3
|
+
import { A as ls, U as ss, a as rs, g as os, c as ns, d as is, p as cs, u as us, b as ds } from "./assets/modules/file-upload-BYIvmkmy.js";
|
|
4
4
|
import { EnvConfig as we } from "@skyfox2000/microbase";
|
|
5
|
-
import { FrontCache as
|
|
6
|
-
import
|
|
7
|
-
import { defineComponent as
|
|
5
|
+
import { FrontCache as se, httpPost as Ae, ResStatus as Be, SERVER_HOST as dt, fieldMapping as re } from "@skyfox2000/fapi";
|
|
6
|
+
import me from "vue-m-message";
|
|
7
|
+
import { defineComponent as S, createBlock as _, openBlock as m, withModifiers as te, unref as l, useAttrs as Q, withCtx as g, createElementVNode as T, createVNode as y, mergeProps as E, renderSlot as D, normalizeStyle as ce, toDisplayString as F, createCommentVNode as k, createElementBlock as w, ref as b, provide as he, watch as $, onMounted as Y, createTextVNode as N, inject as oe, resolveDirective as le, withDirectives as j, computed as X, normalizeClass as M, createSlots as Oe, useSlots as pt, Fragment as A, renderList as L, resolveDynamicComponent as ft, onActivated as vt, onUnmounted as mt, withKeys as Se } from "vue";
|
|
8
8
|
import "async-validator";
|
|
9
|
-
import
|
|
10
|
-
import { Popover as ht, theme as
|
|
11
|
-
import { VueDraggableNext as
|
|
12
|
-
import { d as
|
|
13
|
-
import {
|
|
14
|
-
import { c as
|
|
15
|
-
import { _ as
|
|
16
|
-
import { _ as
|
|
17
|
-
import { a as
|
|
18
|
-
import { _ as
|
|
19
|
-
import {
|
|
20
|
-
import { _ as
|
|
21
|
-
const $e = (
|
|
22
|
-
if (!
|
|
23
|
-
if (
|
|
24
|
-
const
|
|
25
|
-
|
|
9
|
+
import pe from "dayjs";
|
|
10
|
+
import { Popover as ht, Spin as gt, theme as Le, Drawer as _t, Space as ae, Form as ze, message as bt, FormItem as Ue, ConfigProvider as Ce, Popconfirm as xt, Button as Ye, DropdownButton as yt, Menu as ge, MenuItem as _e, Dropdown as fe, Checkbox as kt, Table as We, Tree as wt, Cascader as St, DatePicker as Ct, Input as ee, InputPassword as $t, InputNumber as Tt, RangePicker as It, Textarea as Dt, Transfer as Pt, TreeSelect as Et, LayoutContent as Ft } from "ant-design-vue";
|
|
11
|
+
import { VueDraggableNext as Mt } from "vue-draggable-next";
|
|
12
|
+
import { d as Ke, _ as Nt } from "./assets/modules/uploadList-BPG5whz7.js";
|
|
13
|
+
import { U as fs, a as vs } from "./assets/modules/uploadList-BPG5whz7.js";
|
|
14
|
+
import { a as hs, c as gs, p as _s, v as bs } from "./assets/modules/form-excel-BUX2QW11.js";
|
|
15
|
+
import { _ as B } from "./assets/modules/index-DcRkhkn2.js";
|
|
16
|
+
import { _ as z } from "./assets/modules/toolIcon-BDIOj_3l.js";
|
|
17
|
+
import { a as ys } from "./assets/modules/toolIcon-BDIOj_3l.js";
|
|
18
|
+
import { _ as ws, b as Ss, c as Cs, d as $s, e as Ts, I as Is, f as Ds, g as Ps, a as Es } from "./assets/modules/menuTabs-DY1XBq16.js";
|
|
19
|
+
import { _ as Ms } from "./assets/modules/index-jl5Ie2tZ.js";
|
|
20
|
+
import { _ as q } from "./assets/modules/_plugin-vue_export-helper-CHgC5LLL.js";
|
|
21
|
+
const $e = (s, a, e, t = "remove") => {
|
|
22
|
+
if (!e)
|
|
23
|
+
if (t === "disable") {
|
|
24
|
+
const n = a.component;
|
|
25
|
+
n ? n.props.disabled = !0 : (a.el, s.setAttribute("disabled", "disabled"), s.disabled = !0), s.classList.add("disabled");
|
|
26
26
|
} else {
|
|
27
|
-
const
|
|
28
|
-
if (
|
|
29
|
-
const
|
|
30
|
-
|
|
27
|
+
const n = document.createComment("No Permission"), i = s.parentNode;
|
|
28
|
+
if (i) {
|
|
29
|
+
const f = a.component;
|
|
30
|
+
f ? f.props.style = { display: "none" } : i.replaceChild(n, s);
|
|
31
31
|
}
|
|
32
32
|
}
|
|
33
|
-
}, Te = (
|
|
34
|
-
|
|
33
|
+
}, Te = (s) => {
|
|
34
|
+
var f, p;
|
|
35
|
+
const a = Qe(), { url: e, role: t, permit: n } = s;
|
|
36
|
+
if (Z(t) && Z(n))
|
|
37
|
+
return !0;
|
|
38
|
+
const i = e ?? ((p = (f = window.location.hash) == null ? void 0 : f.split("#")) == null ? void 0 : p[1]) ?? window.location.pathname;
|
|
35
39
|
if (we.VITE_PERMISSION_MODE === "role")
|
|
36
|
-
return
|
|
40
|
+
return Z(t) ? !0 : a.hasRole(t);
|
|
37
41
|
if (we.VITE_PERMISSION_MODE === "permit") {
|
|
38
|
-
let
|
|
39
|
-
return
|
|
42
|
+
let d = !1, o = !1;
|
|
43
|
+
return Z(t) || (d = a.hasRole(t)), a.isAdmin() ? d : (Z(n) || (o = a.hasPermit(i, n)), d || o);
|
|
40
44
|
}
|
|
41
45
|
return !1;
|
|
42
46
|
}, Rt = {
|
|
43
|
-
mounted(
|
|
44
|
-
const
|
|
45
|
-
$e(
|
|
47
|
+
mounted(s, a, e) {
|
|
48
|
+
const t = a.value || {}, n = a.arg || "remove", i = t.behavior || n, f = Te(t);
|
|
49
|
+
$e(s, e, f, i);
|
|
46
50
|
},
|
|
47
|
-
updated(
|
|
48
|
-
const
|
|
49
|
-
$e(
|
|
51
|
+
updated(s, a, e) {
|
|
52
|
+
const t = a.value || {}, n = a.arg || "remove", i = t.behavior || n, f = Te(t);
|
|
53
|
+
$e(s, e, f, i);
|
|
50
54
|
}
|
|
51
|
-
},
|
|
52
|
-
mounted: (
|
|
53
|
-
|
|
54
|
-
|
|
55
|
+
}, At = {
|
|
56
|
+
mounted: (s, a) => {
|
|
57
|
+
s.addEventListener("keydown", (e) => {
|
|
58
|
+
e.key === "Enter" && a.value();
|
|
55
59
|
});
|
|
56
60
|
},
|
|
57
|
-
unmounted: (
|
|
58
|
-
|
|
61
|
+
unmounted: (s) => {
|
|
62
|
+
s.removeEventListener("keydown", () => {
|
|
59
63
|
});
|
|
60
64
|
}
|
|
61
|
-
},
|
|
65
|
+
}, ue = {
|
|
62
66
|
auth: Rt,
|
|
63
|
-
submit:
|
|
64
|
-
}, Ya = (
|
|
65
|
-
|
|
66
|
-
}),
|
|
67
|
-
const
|
|
68
|
-
if (
|
|
69
|
-
return
|
|
70
|
-
for (const
|
|
71
|
-
if (
|
|
72
|
-
const
|
|
73
|
-
if (
|
|
74
|
-
return
|
|
67
|
+
submit: At
|
|
68
|
+
}, Ya = (s, a) => ((a || Object.keys(ue)).forEach((t) => {
|
|
69
|
+
t in ue && s.directive(t, ue[t]);
|
|
70
|
+
}), s), W = (s, a) => {
|
|
71
|
+
const e = s.find((t) => t.key === a);
|
|
72
|
+
if (e)
|
|
73
|
+
return e;
|
|
74
|
+
for (const t of s)
|
|
75
|
+
if (t.children) {
|
|
76
|
+
const n = W(t.children, a);
|
|
77
|
+
if (n)
|
|
78
|
+
return n;
|
|
75
79
|
}
|
|
76
|
-
}, be = (
|
|
77
|
-
const
|
|
78
|
-
return
|
|
79
|
-
let
|
|
80
|
-
if (typeof
|
|
81
|
-
const
|
|
82
|
-
|
|
80
|
+
}, be = (s, a, e) => {
|
|
81
|
+
const t = [], n = [];
|
|
82
|
+
return e || (e = [...s]), e.length && e.forEach((i, f) => {
|
|
83
|
+
let p;
|
|
84
|
+
if (typeof i == "string") {
|
|
85
|
+
const d = W(s, i);
|
|
86
|
+
p = d ? { ...d } : { key: i, label: i };
|
|
83
87
|
} else {
|
|
84
|
-
const
|
|
85
|
-
|
|
88
|
+
const d = W(s, i.key);
|
|
89
|
+
p = d ? { ...d, ...i } : { ...i };
|
|
86
90
|
}
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
}, 1)) :
|
|
91
|
-
}), a === 0 ||
|
|
92
|
-
}), { buttons:
|
|
93
|
-
},
|
|
91
|
+
p.click || (p.click = (d, o, u) => {
|
|
92
|
+
o && (o.rowData.value = u), p.formVisible ? (p.formVisible.value = !1, setTimeout(() => {
|
|
93
|
+
p.formVisible.value = !0;
|
|
94
|
+
}, 1)) : me.warning("未配置点击处理事件!");
|
|
95
|
+
}), a === 0 || f < a ? t.push(p) : n.push(p);
|
|
96
|
+
}), { buttons: t, menus: n };
|
|
97
|
+
}, K = (s, a) => s.disabled && typeof s.disabled == "function" ? s.disabled(a) : s.disabled, J = (s, a) => s.visible && typeof s.visible == "function" ? s.visible(a) : s.visible ?? !0, Bt = (s, a) => {
|
|
94
98
|
a.reload.value = !0;
|
|
95
|
-
},
|
|
99
|
+
}, Ot = (s, a) => {
|
|
96
100
|
a.searchBar.value = !a.searchBar.value;
|
|
97
|
-
},
|
|
101
|
+
}, Lt = (s, a) => {
|
|
98
102
|
switch (a.tableSize.value) {
|
|
99
103
|
case "large":
|
|
100
104
|
a.tableSize.value = "middle";
|
|
@@ -106,29 +110,29 @@ const $e = (r, a, t, e = "remove") => {
|
|
|
106
110
|
a.tableSize.value = "large";
|
|
107
111
|
break;
|
|
108
112
|
}
|
|
109
|
-
}, zt = (
|
|
113
|
+
}, zt = (s, a) => {
|
|
110
114
|
a.selectable.value = !a.selectable.value, a.selectable.value || (a.selectKeys.value = [], a.selectRows.value = []);
|
|
111
|
-
}, Ut = (
|
|
115
|
+
}, Ut = (s, a) => {
|
|
112
116
|
a.rowExpand.value = !a.rowExpand.value;
|
|
113
|
-
}, Ie = (
|
|
117
|
+
}, Ie = (s, a) => {
|
|
114
118
|
a.selectable.value = !a.selectable.value;
|
|
115
|
-
},
|
|
116
|
-
(!
|
|
117
|
-
},
|
|
119
|
+
}, U = (s, a, e, t, n) => {
|
|
120
|
+
(!s.confirm || n) && s.click && (a ? s.click(a, e, t) : s.click(null, e, t)), Wt(s);
|
|
121
|
+
}, Yt = (s, a) => {
|
|
118
122
|
a.selectable.value = !a.selectable.value;
|
|
119
|
-
},
|
|
120
|
-
const
|
|
121
|
-
|
|
122
|
-
},
|
|
123
|
-
(
|
|
124
|
-
},
|
|
125
|
-
a ? delete
|
|
126
|
-
},
|
|
123
|
+
}, Ve = () => {
|
|
124
|
+
const s = ve();
|
|
125
|
+
s.setFullscreen(!s.fullscreen);
|
|
126
|
+
}, Wt = (s, a) => {
|
|
127
|
+
(s.icons || s.labels) && (s.iconStatus = s.iconStatus || 0, s.iconStatus += 1, s.labels && s.labels.length && (s.label = s.labels[s.iconStatus % s.labels.length]), s.icons && s.icons.length && (s.icon = s.icons[s.iconStatus % s.icons.length]));
|
|
128
|
+
}, Kt = (s, a) => {
|
|
129
|
+
a ? delete s.visible : s.visible = !1;
|
|
130
|
+
}, De = [
|
|
127
131
|
{
|
|
128
132
|
key: "Reload",
|
|
129
133
|
label: "刷新表格",
|
|
130
134
|
icon: "icon-reload",
|
|
131
|
-
click:
|
|
135
|
+
click: Bt
|
|
132
136
|
},
|
|
133
137
|
{
|
|
134
138
|
key: "Query",
|
|
@@ -136,13 +140,13 @@ const $e = (r, a, t, e = "remove") => {
|
|
|
136
140
|
labels: ["展开搜索栏", "折叠搜索栏"],
|
|
137
141
|
icon: "icon-search",
|
|
138
142
|
iconStatus: 0,
|
|
139
|
-
click:
|
|
143
|
+
click: Ot
|
|
140
144
|
},
|
|
141
145
|
{
|
|
142
146
|
key: "RowHeight",
|
|
143
147
|
label: "行高调整",
|
|
144
148
|
icon: "icon-row-height",
|
|
145
|
-
click:
|
|
149
|
+
click: Lt
|
|
146
150
|
},
|
|
147
151
|
{
|
|
148
152
|
key: "tool.multiple.checkbox",
|
|
@@ -185,7 +189,7 @@ const $e = (r, a, t, e = "remove") => {
|
|
|
185
189
|
{
|
|
186
190
|
key: "tool.export.pdf.selected",
|
|
187
191
|
label: "选中的记录",
|
|
188
|
-
click:
|
|
192
|
+
click: Yt
|
|
189
193
|
}
|
|
190
194
|
]
|
|
191
195
|
},
|
|
@@ -205,55 +209,55 @@ const $e = (r, a, t, e = "remove") => {
|
|
|
205
209
|
icon: "icon-fullscreen",
|
|
206
210
|
iconStatus: 0,
|
|
207
211
|
icons: ["icon-fullscreen", "icon-exitscreen"],
|
|
208
|
-
click:
|
|
212
|
+
click: Ve
|
|
209
213
|
}
|
|
210
|
-
],
|
|
211
|
-
if (!
|
|
214
|
+
], Vt = (s) => {
|
|
215
|
+
if (!s.tools || s.tools.length > 0) {
|
|
212
216
|
const a = [];
|
|
213
|
-
return
|
|
217
|
+
return s.tools ? a.push(...s.tools) : a.push(...De), { tools: be(De, 0, a).buttons };
|
|
214
218
|
}
|
|
215
219
|
return {
|
|
216
220
|
tools: []
|
|
217
221
|
};
|
|
218
222
|
};
|
|
219
|
-
var
|
|
220
|
-
class
|
|
223
|
+
var jt = /* @__PURE__ */ ((s) => (s.SYS_CONFIG = "SYS_CONFIG_", s.APP_MENU = "APP_MENU_", s.DICT_TYPE = "DICT_TYPE_", s.HOST_INFO = "HOST_INFO_", s.APP_PERMITS = "APP_PERMITS_", s.USER_SETTINGS = "USER_SETTINGS_", s.DICT_DATA = "DICT_DATA_", s.COMMON_OPTIONS = "COMMON_OPTIONS_", s))(jt || {});
|
|
224
|
+
class je {
|
|
221
225
|
/**
|
|
222
226
|
* 设置缓存数据(带服务器时间)
|
|
223
227
|
*/
|
|
224
|
-
static setWithServerTime(a,
|
|
225
|
-
const
|
|
226
|
-
data:
|
|
227
|
-
lastTime:
|
|
228
|
+
static setWithServerTime(a, e, t) {
|
|
229
|
+
const n = {
|
|
230
|
+
data: e,
|
|
231
|
+
lastTime: t
|
|
228
232
|
};
|
|
229
|
-
|
|
233
|
+
se.set({ key: a, storage: "local" }, n);
|
|
230
234
|
}
|
|
231
235
|
/**
|
|
232
236
|
* 设置缓存数据
|
|
233
237
|
*/
|
|
234
|
-
static setData(a,
|
|
235
|
-
|
|
238
|
+
static setData(a, e) {
|
|
239
|
+
se.set({ key: a, storage: "local" }, e);
|
|
236
240
|
}
|
|
237
241
|
/**
|
|
238
242
|
* 获取缓存数据
|
|
239
243
|
*/
|
|
240
244
|
static getData(a) {
|
|
241
|
-
const
|
|
242
|
-
return
|
|
245
|
+
const e = se.get({ key: a, storage: "local" });
|
|
246
|
+
return e && je.isTimedData(e) ? e.data : e ?? null;
|
|
243
247
|
}
|
|
244
248
|
/**
|
|
245
249
|
* 清除缓存
|
|
246
250
|
*/
|
|
247
251
|
static remove(a) {
|
|
248
|
-
|
|
252
|
+
se.remove({ key: a, storage: "local" });
|
|
249
253
|
}
|
|
250
254
|
/**
|
|
251
255
|
* 清理指定前缀的缓存 (基于 localStorage 实现,因为 FrontCache 未提供此方法)
|
|
252
256
|
*/
|
|
253
257
|
static clearByPrefix(a) {
|
|
254
|
-
for (let
|
|
255
|
-
const
|
|
256
|
-
|
|
258
|
+
for (let e = 0; e < localStorage.length; e++) {
|
|
259
|
+
const t = localStorage.key(e);
|
|
260
|
+
t && t.startsWith("frontCache::" + a) && localStorage.removeItem(t);
|
|
257
261
|
}
|
|
258
262
|
}
|
|
259
263
|
/**
|
|
@@ -261,8 +265,8 @@ class Ge {
|
|
|
261
265
|
*/
|
|
262
266
|
static clearAll() {
|
|
263
267
|
for (let a = localStorage.length - 1; a >= 0; a--) {
|
|
264
|
-
const
|
|
265
|
-
|
|
268
|
+
const e = localStorage.key(a);
|
|
269
|
+
e && e.startsWith("frontCache::") && localStorage.removeItem(e);
|
|
266
270
|
}
|
|
267
271
|
}
|
|
268
272
|
/**
|
|
@@ -272,9 +276,9 @@ class Ge {
|
|
|
272
276
|
return a && typeof a == "object" && "data" in a && "lastTime" in a && typeof a.lastTime == "number";
|
|
273
277
|
}
|
|
274
278
|
}
|
|
275
|
-
async function
|
|
279
|
+
async function Wa() {
|
|
276
280
|
try {
|
|
277
|
-
const
|
|
281
|
+
const s = await Ae(
|
|
278
282
|
{
|
|
279
283
|
api: "PLATFORM_API",
|
|
280
284
|
url: "/api/SysCacheSvr/getLastTime",
|
|
@@ -282,18 +286,18 @@ async function Va() {
|
|
|
282
286
|
},
|
|
283
287
|
{}
|
|
284
288
|
);
|
|
285
|
-
if ((
|
|
286
|
-
const a =
|
|
287
|
-
Object.keys(a).forEach((
|
|
288
|
-
const
|
|
289
|
-
["local", "session"].forEach((
|
|
290
|
-
const
|
|
291
|
-
for (let
|
|
292
|
-
const
|
|
293
|
-
if (
|
|
289
|
+
if ((s == null ? void 0 : s.status) === Be.SUCCESS) {
|
|
290
|
+
const a = s.data;
|
|
291
|
+
Object.keys(a).forEach((e) => {
|
|
292
|
+
const t = a[e];
|
|
293
|
+
["local", "session"].forEach((i) => {
|
|
294
|
+
const f = i === "local" ? localStorage : sessionStorage;
|
|
295
|
+
for (let p = 0; p < f.length; p++) {
|
|
296
|
+
const d = f.key(p);
|
|
297
|
+
if (d && d.endsWith(e))
|
|
294
298
|
try {
|
|
295
|
-
const
|
|
296
|
-
|
|
299
|
+
const o = JSON.parse(f.getItem(d));
|
|
300
|
+
o && typeof o == "object" && "lastTime" in o && typeof o.lastTime == "number" && o.lastTime !== t && f.removeItem(d);
|
|
297
301
|
} catch {
|
|
298
302
|
continue;
|
|
299
303
|
}
|
|
@@ -301,82 +305,82 @@ async function Va() {
|
|
|
301
305
|
});
|
|
302
306
|
});
|
|
303
307
|
}
|
|
304
|
-
} catch (
|
|
305
|
-
console.error("检查缓存更新失败",
|
|
308
|
+
} catch (s) {
|
|
309
|
+
console.error("检查缓存更新失败", s);
|
|
306
310
|
}
|
|
307
311
|
}
|
|
308
|
-
const Ka = async (
|
|
312
|
+
const Ka = async (s, a, e) => {
|
|
309
313
|
try {
|
|
310
|
-
const
|
|
314
|
+
const n = (await import("@json2csv/plainjs")).Parser, i = He(s), f = a.filter((v) => v.visible !== !1 && v.export !== !1), p = f.map((v) => ({
|
|
311
315
|
label: v.title,
|
|
312
316
|
value: v.dataIndex || v.key || ""
|
|
313
|
-
})),
|
|
314
|
-
const
|
|
315
|
-
return
|
|
316
|
-
const C =
|
|
317
|
-
C &&
|
|
318
|
-
}),
|
|
319
|
-
}),
|
|
320
|
-
|
|
321
|
-
} catch (
|
|
322
|
-
console.error("导出失败:",
|
|
317
|
+
})), d = e.map((v) => {
|
|
318
|
+
const c = { ...v };
|
|
319
|
+
return f.forEach((h) => {
|
|
320
|
+
const C = h.dataIndex || h.key;
|
|
321
|
+
C && h.customRender && (c[C] = h.customRender(v[C], v));
|
|
322
|
+
}), c;
|
|
323
|
+
}), u = new n({ fields: p }).parse(d), r = new Blob([`\uFEFF${u}`], { type: "text/csv" });
|
|
324
|
+
Ke(r, i);
|
|
325
|
+
} catch (t) {
|
|
326
|
+
console.error("导出失败:", t), me.error("文件导出失败,请稍后重试");
|
|
323
327
|
}
|
|
324
|
-
},
|
|
328
|
+
}, He = (s) => {
|
|
325
329
|
const a = /\{([^}]+)\}/g;
|
|
326
|
-
return
|
|
327
|
-
},
|
|
330
|
+
return s.replace(a, (e, t) => pe().format(t));
|
|
331
|
+
}, Va = async (s, a, e, t) => {
|
|
328
332
|
try {
|
|
329
|
-
const
|
|
330
|
-
label:
|
|
331
|
-
value:
|
|
333
|
+
const i = (await import("@json2csv/plainjs")).Parser, f = He(s), p = a.filter((r) => r.visible !== !1), d = p.map((r) => ({
|
|
334
|
+
label: r.title,
|
|
335
|
+
value: r.dataIndex || r.key || ""
|
|
332
336
|
}));
|
|
333
|
-
let
|
|
334
|
-
return
|
|
335
|
-
if (
|
|
336
|
-
const
|
|
337
|
+
let o = e.page, u = e.gridQuery;
|
|
338
|
+
return t.api || (t.api = o.api), t.authorize === void 0 && (t.authorize = o.authorize), e.isGridLoading.value = !0, Ae(t, u).then((r) => {
|
|
339
|
+
if (e.isGridLoading.value = !1, (r == null ? void 0 : r.status) === Be.SUCCESS && r.data) {
|
|
340
|
+
const c = r.data.map((P) => {
|
|
337
341
|
const x = { ...P };
|
|
338
|
-
return
|
|
339
|
-
const
|
|
340
|
-
|
|
342
|
+
return p.forEach((R) => {
|
|
343
|
+
const G = R.dataIndex || R.key;
|
|
344
|
+
G && R.customRender && (x[G] = R.customRender(P[G], P));
|
|
341
345
|
}), x;
|
|
342
|
-
}), C = new
|
|
343
|
-
|
|
346
|
+
}), C = new i({ fields: d }).parse(c), I = new Blob([`\uFEFF${C}`], { type: "text/csv" });
|
|
347
|
+
Ke(I, f);
|
|
344
348
|
}
|
|
345
349
|
});
|
|
346
|
-
} catch (
|
|
347
|
-
console.error("导出失败:",
|
|
350
|
+
} catch (n) {
|
|
351
|
+
console.error("导出失败:", n), me.error("文件导出失败,请稍后重试");
|
|
348
352
|
}
|
|
349
|
-
}, ja = /* @__PURE__ */
|
|
353
|
+
}, ja = /* @__PURE__ */ S({
|
|
350
354
|
__name: "fullscreen",
|
|
351
|
-
setup(
|
|
355
|
+
setup(s) {
|
|
352
356
|
const a = ve();
|
|
353
|
-
return (
|
|
354
|
-
onClick:
|
|
357
|
+
return (e, t) => (m(), _(z, {
|
|
358
|
+
onClick: te(l(Ve), ["stop"]),
|
|
355
359
|
icon: l(a).fullscreen ? "icon-exitscreen" : "icon-fullscreen",
|
|
356
360
|
class: "w-[17px] h-[17px]"
|
|
357
361
|
}, null, 8, ["onClick", "icon"]));
|
|
358
362
|
}
|
|
359
|
-
}),
|
|
363
|
+
}), Ht = { class: "ml-2" }, Qt = /* @__PURE__ */ S({
|
|
360
364
|
inheritAttrs: !1,
|
|
361
365
|
__name: "helper",
|
|
362
366
|
props: {
|
|
363
367
|
text: {},
|
|
364
368
|
maxWidth: {}
|
|
365
369
|
},
|
|
366
|
-
setup(
|
|
367
|
-
const a =
|
|
368
|
-
return (
|
|
369
|
-
content:
|
|
370
|
-
D(
|
|
370
|
+
setup(s) {
|
|
371
|
+
const a = Q();
|
|
372
|
+
return (e, t) => (m(), _(l(ht), { placement: "topRight" }, {
|
|
373
|
+
content: g(() => [
|
|
374
|
+
D(e.$slots, "default", {}, () => [
|
|
371
375
|
T("div", {
|
|
372
376
|
class: "text-[14px]",
|
|
373
|
-
style:
|
|
374
|
-
}, F(
|
|
377
|
+
style: ce({ maxWidth: e.maxWidth })
|
|
378
|
+
}, F(e.text), 5)
|
|
375
379
|
])
|
|
376
380
|
]),
|
|
377
|
-
default:
|
|
378
|
-
T("span",
|
|
379
|
-
y(
|
|
381
|
+
default: g(() => [
|
|
382
|
+
T("span", Ht, [
|
|
383
|
+
y(z, E({
|
|
380
384
|
icon: "icon-question-circle",
|
|
381
385
|
class: "text-[#888] w-4 h-4"
|
|
382
386
|
}, l(a)), null, 16)
|
|
@@ -385,7 +389,7 @@ const Ka = async (r, a, t) => {
|
|
|
385
389
|
_: 3
|
|
386
390
|
}));
|
|
387
391
|
}
|
|
388
|
-
}),
|
|
392
|
+
}), Ha = /* @__PURE__ */ S({
|
|
389
393
|
__name: "layoutIcon",
|
|
390
394
|
props: {
|
|
391
395
|
icon: {
|
|
@@ -395,50 +399,64 @@ const Ka = async (r, a, t) => {
|
|
|
395
399
|
type: Array
|
|
396
400
|
}
|
|
397
401
|
},
|
|
398
|
-
setup(
|
|
399
|
-
const a =
|
|
400
|
-
iconUrl: `${
|
|
402
|
+
setup(s) {
|
|
403
|
+
const a = s, t = qe({
|
|
404
|
+
iconUrl: `${dt.MICROLAYOUT_ICONS}`,
|
|
401
405
|
monoColor: !0,
|
|
402
406
|
icon: a.icon,
|
|
403
407
|
icons: a.icons
|
|
404
408
|
});
|
|
405
|
-
return (
|
|
409
|
+
return (n, i) => s.icon || s.icons ? (m(), _(l(t), E({
|
|
406
410
|
key: 0,
|
|
407
|
-
icon:
|
|
408
|
-
icons:
|
|
411
|
+
icon: s.icon,
|
|
412
|
+
icons: s.icons,
|
|
409
413
|
class: ["align-middle"]
|
|
410
|
-
},
|
|
414
|
+
}, n.$attrs), null, 16, ["icon", "icons"])) : k("", !0);
|
|
415
|
+
}
|
|
416
|
+
}), qt = { class: "absolute z-999 w-full h-full top-0 flex flex-flow row items-center justify-center" }, Qa = /* @__PURE__ */ S({
|
|
417
|
+
__name: "index",
|
|
418
|
+
setup(s) {
|
|
419
|
+
const a = Q();
|
|
420
|
+
return (e, t) => (m(), w("div", qt, [
|
|
421
|
+
y(l(gt), E({ style: { "margin-top": "-10%" } }, l(a)), null, 16)
|
|
422
|
+
]));
|
|
411
423
|
}
|
|
412
|
-
}),
|
|
424
|
+
}), Gt = { class: "hover:bg-gray-200 w-[24px] h-[24px] rounded-md" }, qa = /* @__PURE__ */ S({
|
|
413
425
|
__name: "index",
|
|
414
426
|
props: {
|
|
415
427
|
saveText: {},
|
|
416
428
|
saveAsText: {},
|
|
417
429
|
cancelText: {},
|
|
418
|
-
editorCtrl: {}
|
|
430
|
+
editorCtrl: {},
|
|
431
|
+
drawerSave: { type: Function },
|
|
432
|
+
drawerSaveAs: { type: Function }
|
|
419
433
|
},
|
|
420
|
-
setup(
|
|
421
|
-
const { useToken: a } =
|
|
422
|
-
|
|
423
|
-
() =>
|
|
424
|
-
(
|
|
425
|
-
|
|
434
|
+
setup(s) {
|
|
435
|
+
const { useToken: a } = Le, { token: e } = a(), t = b(!1), n = s, i = n.editorCtrl;
|
|
436
|
+
he(V.EditorControl, i), $(
|
|
437
|
+
() => i.visible.value,
|
|
438
|
+
(o) => {
|
|
439
|
+
t.value = o ?? !1;
|
|
426
440
|
}
|
|
427
|
-
),
|
|
428
|
-
|
|
441
|
+
), Y(() => {
|
|
442
|
+
t.value = i.visible.value ?? !1;
|
|
429
443
|
});
|
|
430
|
-
const
|
|
431
|
-
|
|
444
|
+
const f = () => {
|
|
445
|
+
n.drawerSave ? n.drawerSave() : i && Pe(i);
|
|
446
|
+
}, p = () => {
|
|
447
|
+
n.drawerSaveAs ? n.drawerSaveAs() : i && Ge(i);
|
|
448
|
+
}, d = () => {
|
|
449
|
+
Je(i);
|
|
432
450
|
};
|
|
433
|
-
return (
|
|
434
|
-
open:
|
|
435
|
-
"onUpdate:open":
|
|
451
|
+
return (o, u) => (m(), _(l(_t), {
|
|
452
|
+
open: t.value,
|
|
453
|
+
"onUpdate:open": u[0] || (u[0] = (r) => t.value = r),
|
|
436
454
|
"get-container": !1,
|
|
437
455
|
closable: !1,
|
|
438
456
|
"header-style": {
|
|
439
457
|
height: "40px",
|
|
440
458
|
padding: "10px 6px 10px 16px",
|
|
441
|
-
backgroundColor: l(
|
|
459
|
+
backgroundColor: l(e).colorBgLayout
|
|
442
460
|
},
|
|
443
461
|
"body-style": {
|
|
444
462
|
padding: "10px 16px"
|
|
@@ -451,11 +469,11 @@ const Ka = async (r, a, t) => {
|
|
|
451
469
|
boxShadow: "rgba(0, 0, 0, 0.3) -2px 0px 8px"
|
|
452
470
|
},
|
|
453
471
|
width: "420px",
|
|
454
|
-
onClose:
|
|
472
|
+
onClose: d
|
|
455
473
|
}, {
|
|
456
|
-
extra:
|
|
457
|
-
T("div",
|
|
458
|
-
y(l(
|
|
474
|
+
extra: g(() => [
|
|
475
|
+
T("div", Gt, [
|
|
476
|
+
y(l(z), {
|
|
459
477
|
class: "top-[-2px] left-[2px] w-6 h-6",
|
|
460
478
|
icon: "icon-new",
|
|
461
479
|
angle: 45,
|
|
@@ -463,44 +481,44 @@ const Ka = async (r, a, t) => {
|
|
|
463
481
|
clickable: "",
|
|
464
482
|
color: "#666",
|
|
465
483
|
position: [0, 0],
|
|
466
|
-
onClick:
|
|
484
|
+
onClick: d
|
|
467
485
|
})
|
|
468
486
|
])
|
|
469
487
|
]),
|
|
470
|
-
default:
|
|
471
|
-
D(
|
|
488
|
+
default: g(() => [
|
|
489
|
+
D(o.$slots, "default")
|
|
472
490
|
]),
|
|
473
|
-
footer:
|
|
474
|
-
y(l(
|
|
475
|
-
default:
|
|
476
|
-
|
|
491
|
+
footer: g(() => [
|
|
492
|
+
y(l(ae), null, {
|
|
493
|
+
default: g(() => [
|
|
494
|
+
o.cancelText !== "" ? (m(), _(l(B), {
|
|
477
495
|
key: 0,
|
|
478
|
-
onClick:
|
|
496
|
+
onClick: d
|
|
479
497
|
}, {
|
|
480
|
-
default:
|
|
481
|
-
N(F(
|
|
498
|
+
default: g(() => [
|
|
499
|
+
N(F(o.cancelText ?? "取消"), 1)
|
|
482
500
|
]),
|
|
483
501
|
_: 1
|
|
484
502
|
})) : k("", !0),
|
|
485
|
-
|
|
503
|
+
o.saveAsText !== "" && l(i).saveAsBtnVisible !== !1 ? (m(), _(l(B), {
|
|
486
504
|
key: 1,
|
|
487
|
-
onClick:
|
|
505
|
+
onClick: p,
|
|
488
506
|
type: "primary",
|
|
489
|
-
loading: l(
|
|
507
|
+
loading: l(i).isFormSaving.value
|
|
490
508
|
}, {
|
|
491
|
-
default:
|
|
492
|
-
N(F(
|
|
509
|
+
default: g(() => [
|
|
510
|
+
N(F(o.saveAsText ?? "另存为"), 1)
|
|
493
511
|
]),
|
|
494
512
|
_: 1
|
|
495
513
|
}, 8, ["loading"])) : k("", !0),
|
|
496
|
-
|
|
514
|
+
o.saveText !== "" && l(i).saveBtnVisible !== !1 ? (m(), _(l(B), {
|
|
497
515
|
key: 2,
|
|
498
|
-
onClick:
|
|
516
|
+
onClick: f,
|
|
499
517
|
type: "primary",
|
|
500
|
-
loading: l(
|
|
518
|
+
loading: l(i).isFormSaving.value
|
|
501
519
|
}, {
|
|
502
|
-
default:
|
|
503
|
-
N(F(
|
|
520
|
+
default: g(() => [
|
|
521
|
+
N(F(o.saveText ?? "保存"), 1)
|
|
504
522
|
]),
|
|
505
523
|
_: 1
|
|
506
524
|
}, 8, ["loading"])) : k("", !0)
|
|
@@ -511,109 +529,120 @@ const Ka = async (r, a, t) => {
|
|
|
511
529
|
_: 3
|
|
512
530
|
}, 8, ["open", "header-style"]));
|
|
513
531
|
}
|
|
514
|
-
}),
|
|
532
|
+
}), Ga = /* @__PURE__ */ S({
|
|
515
533
|
__name: "index",
|
|
516
534
|
props: {
|
|
517
535
|
labelWidth: {},
|
|
518
536
|
wrapperWidth: {},
|
|
519
537
|
editorCtrl: {}
|
|
520
538
|
},
|
|
521
|
-
setup(
|
|
522
|
-
const a =
|
|
523
|
-
return (
|
|
524
|
-
const
|
|
525
|
-
return j((m(), _(l(
|
|
539
|
+
setup(s) {
|
|
540
|
+
const a = s, e = a.editorCtrl ?? oe(V.EditorControl, void 0);
|
|
541
|
+
return he(V.LabelWidth, a.labelWidth), (t, n) => {
|
|
542
|
+
const i = le("submit");
|
|
543
|
+
return j((m(), _(l(ze), {
|
|
526
544
|
"label-col": { flex: a.labelWidth ?? "85px" },
|
|
527
545
|
"wrapper-col": {
|
|
528
|
-
flex: a.wrapperWidth ?? "1"
|
|
546
|
+
flex: a.wrapperWidth ?? "1 0 280px"
|
|
529
547
|
},
|
|
530
548
|
style: {
|
|
531
549
|
display: "flex",
|
|
532
550
|
flexWrap: "wrap"
|
|
533
551
|
}
|
|
534
552
|
}, {
|
|
535
|
-
default:
|
|
536
|
-
D(
|
|
553
|
+
default: g(() => [
|
|
554
|
+
D(t.$slots, "default")
|
|
537
555
|
]),
|
|
538
556
|
_: 3
|
|
539
557
|
}, 8, ["label-col", "wrapper-col"])), [
|
|
540
558
|
[
|
|
541
|
-
|
|
559
|
+
i,
|
|
542
560
|
() => {
|
|
543
|
-
l(
|
|
561
|
+
l(e) && l(Pe)(l(e));
|
|
544
562
|
}
|
|
545
563
|
]
|
|
546
564
|
]);
|
|
547
565
|
};
|
|
548
566
|
}
|
|
549
|
-
}),
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
}, Ga = /* @__PURE__ */ w({
|
|
567
|
+
}), Jt = {
|
|
568
|
+
class: /* @__PURE__ */ M(["relative mb-1"])
|
|
569
|
+
}, Xt = { class: "flex-grow" }, Zt = { class: "w-8 mt-[-2px]" }, Ja = /* @__PURE__ */ S({
|
|
553
570
|
inheritAttrs: !1,
|
|
554
571
|
__name: "formItem",
|
|
555
572
|
props: {
|
|
556
573
|
label: {},
|
|
557
574
|
rule: {},
|
|
558
575
|
helper: {},
|
|
559
|
-
width: {}
|
|
576
|
+
width: {},
|
|
577
|
+
nextLine: { type: Boolean }
|
|
560
578
|
},
|
|
561
|
-
setup(
|
|
562
|
-
const a =
|
|
579
|
+
setup(s) {
|
|
580
|
+
const a = s, e = Q(), t = oe(V.EditorControl, void 0), n = oe(V.LabelWidth, "85px"), i = Ee(a, t), f = b(!1);
|
|
563
581
|
setTimeout(() => {
|
|
564
|
-
|
|
582
|
+
f.value = !0;
|
|
565
583
|
}, 30);
|
|
566
|
-
const p = (
|
|
567
|
-
if (!
|
|
584
|
+
const p = (o, u) => {
|
|
585
|
+
if (!u)
|
|
568
586
|
return;
|
|
569
|
-
const [
|
|
570
|
-
return
|
|
571
|
-
},
|
|
572
|
-
var
|
|
587
|
+
const [r, ...v] = o;
|
|
588
|
+
return o.length === 1 ? u[r] : p(v, u[r].fields);
|
|
589
|
+
}, d = X(() => {
|
|
590
|
+
var u;
|
|
573
591
|
if (!a.rule)
|
|
574
592
|
return !1;
|
|
575
|
-
const
|
|
576
|
-
return
|
|
593
|
+
const o = p(a.rule.split("."), (u = t == null ? void 0 : t.formRules) == null ? void 0 : u.value);
|
|
594
|
+
return o ? o.required ?? !0 : (bt.error(`"${a.label}" 的验证规则 \`${a.rule}\` 不存在`), i.value.errClass = "text-[#ff4d4f]", i.value.msg = `规则 \`${a.rule}\` 不存在,请检查代码!`, !0);
|
|
577
595
|
});
|
|
578
|
-
return (
|
|
579
|
-
|
|
580
|
-
}, [
|
|
581
|
-
n.value ? (m(), _(l(He), E({
|
|
596
|
+
return (o, u) => (m(), w("div", Jt, [
|
|
597
|
+
f.value ? (m(), _(l(Ue), E({
|
|
582
598
|
key: 0,
|
|
583
|
-
required:
|
|
584
|
-
class: "
|
|
585
|
-
}, l(
|
|
586
|
-
class: [
|
|
599
|
+
required: d.value,
|
|
600
|
+
class: "relative"
|
|
601
|
+
}, l(e), {
|
|
602
|
+
class: [o.nextLine ? "mb-0" : o.rule ? "" : "mb-3"]
|
|
587
603
|
}), {
|
|
588
|
-
label:
|
|
604
|
+
label: g(() => [
|
|
589
605
|
T("span", {
|
|
590
|
-
class: M([l(
|
|
591
|
-
}, F(
|
|
606
|
+
class: M([l(i).errClass ? "text-[#ff4d4f]" : "", "w-full"])
|
|
607
|
+
}, F(o.label), 3)
|
|
592
608
|
]),
|
|
593
|
-
default:
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
609
|
+
default: g(() => [
|
|
610
|
+
o.nextLine ? k("", !0) : (m(), w("div", {
|
|
611
|
+
key: 0,
|
|
612
|
+
class: M(["flex items-center", o.width ? o.width : "w-full"])
|
|
613
|
+
}, [
|
|
614
|
+
T("div", Xt, [
|
|
615
|
+
D(o.$slots, "default")
|
|
597
616
|
]),
|
|
598
|
-
T("div",
|
|
599
|
-
D(
|
|
600
|
-
|
|
617
|
+
T("div", Zt, [
|
|
618
|
+
D(o.$slots, "helper", {}, () => [
|
|
619
|
+
o.helper ? (m(), _(l(Qt), {
|
|
601
620
|
key: 0,
|
|
602
|
-
text:
|
|
621
|
+
text: o.helper
|
|
603
622
|
}, null, 8, ["text"])) : k("", !0)
|
|
604
623
|
])
|
|
605
624
|
])
|
|
606
|
-
])
|
|
625
|
+
], 2))
|
|
607
626
|
]),
|
|
608
627
|
_: 3
|
|
609
628
|
}, 16, ["required", "class"])) : k("", !0),
|
|
610
|
-
|
|
611
|
-
|
|
629
|
+
o.nextLine ? (m(), w("div", {
|
|
630
|
+
key: 1,
|
|
631
|
+
class: M(["w-[95%] flex items-center relative", [o.nextLine ? o.rule ? "mb-7" : "mb-3" : ""]])
|
|
632
|
+
}, [
|
|
633
|
+
D(o.$slots, "default")
|
|
634
|
+
], 2)) : k("", !0),
|
|
635
|
+
l(i).errClass ? (m(), w("span", {
|
|
636
|
+
key: 2,
|
|
637
|
+
style: ce({ left: l(n) }),
|
|
638
|
+
class: "absolute bottom-[3px] text-[12px] text-[#ff4d4fcc]"
|
|
639
|
+
}, F(l(i).msg), 5)) : k("", !0)
|
|
640
|
+
]));
|
|
612
641
|
}
|
|
613
|
-
}),
|
|
642
|
+
}), ea = { class: "w-1/3 relative mb-1" }, ta = { class: "flex items-center w-[90%]" }, aa = { class: "flex-grow pl-1" }, la = {
|
|
614
643
|
key: 0,
|
|
615
644
|
class: "absolute bottom-[3px] left-[85px] text-[12px] text-[#ff4d4fcc] block"
|
|
616
|
-
},
|
|
645
|
+
}, de = /* @__PURE__ */ S({
|
|
617
646
|
inheritAttrs: !1,
|
|
618
647
|
__name: "searchItem",
|
|
619
648
|
props: {
|
|
@@ -621,39 +650,39 @@ const Ka = async (r, a, t) => {
|
|
|
621
650
|
width: {},
|
|
622
651
|
rule: {}
|
|
623
652
|
},
|
|
624
|
-
setup(
|
|
625
|
-
const a =
|
|
626
|
-
return (
|
|
627
|
-
y(l(
|
|
628
|
-
required:
|
|
653
|
+
setup(s) {
|
|
654
|
+
const a = s, e = Q(), t = oe(V.EditorControl, void 0), n = Ee(a, t);
|
|
655
|
+
return (i, f) => (m(), w("div", ea, [
|
|
656
|
+
y(l(Ue), E({
|
|
657
|
+
required: i.rule !== void 0,
|
|
629
658
|
class: "w-[90%] relative"
|
|
630
|
-
}, l(
|
|
631
|
-
class: [
|
|
659
|
+
}, l(e), {
|
|
660
|
+
class: [i.rule ? "" : "mb-3", i.width],
|
|
632
661
|
labelCol: { span: 6 }
|
|
633
|
-
}),
|
|
634
|
-
default:
|
|
635
|
-
T("div",
|
|
636
|
-
T("div",
|
|
637
|
-
D(
|
|
662
|
+
}), Oe({
|
|
663
|
+
default: g(() => [
|
|
664
|
+
T("div", ta, [
|
|
665
|
+
T("div", aa, [
|
|
666
|
+
D(i.$slots, "default")
|
|
638
667
|
])
|
|
639
668
|
])
|
|
640
669
|
]),
|
|
641
670
|
_: 2
|
|
642
671
|
}, [
|
|
643
|
-
|
|
672
|
+
i.label ? {
|
|
644
673
|
name: "label",
|
|
645
|
-
fn:
|
|
674
|
+
fn: g(() => [
|
|
646
675
|
T("span", {
|
|
647
|
-
class: M([l(
|
|
648
|
-
}, F(
|
|
676
|
+
class: M([l(n).errClass ? "text-[#ff4d4f]" : "", "w-full"])
|
|
677
|
+
}, F(i.label), 3)
|
|
649
678
|
]),
|
|
650
679
|
key: "0"
|
|
651
680
|
} : void 0
|
|
652
681
|
]), 1040, ["required", "class"]),
|
|
653
|
-
l(
|
|
682
|
+
l(n).msg ? (m(), w("span", la, F(l(n).msg), 1)) : k("", !0)
|
|
654
683
|
]));
|
|
655
684
|
}
|
|
656
|
-
}),
|
|
685
|
+
}), Xa = /* @__PURE__ */ S({
|
|
657
686
|
__name: "index",
|
|
658
687
|
props: {
|
|
659
688
|
search: {},
|
|
@@ -661,56 +690,56 @@ const Ka = async (r, a, t) => {
|
|
|
661
690
|
likeFields: {}
|
|
662
691
|
},
|
|
663
692
|
emits: ["update:search"],
|
|
664
|
-
setup(
|
|
665
|
-
const
|
|
666
|
-
let
|
|
667
|
-
for (let C = 0; C <
|
|
668
|
-
typeof
|
|
669
|
-
return
|
|
670
|
-
},
|
|
671
|
-
|
|
693
|
+
setup(s, { emit: a }) {
|
|
694
|
+
const e = s, t = a, n = b(0), i = b(0), f = b(0), p = (c) => {
|
|
695
|
+
let h = 0;
|
|
696
|
+
for (let C = 0; C < c.length; C++)
|
|
697
|
+
typeof c[C].type == "object" && h++;
|
|
698
|
+
return h;
|
|
699
|
+
}, d = pt(), o = () => {
|
|
700
|
+
i.value = 0, f.value = 0, d.default && (i.value = p(d.default({}))), e.gridCtrl.searchBar && d.control && (f.value = p(d.control({}))), n.value = 2 - (i.value + f.value) % 3;
|
|
672
701
|
};
|
|
673
702
|
$(
|
|
674
|
-
() =>
|
|
703
|
+
() => e.gridCtrl.searchBar,
|
|
675
704
|
() => {
|
|
676
|
-
|
|
705
|
+
o();
|
|
677
706
|
}
|
|
678
707
|
);
|
|
679
|
-
const
|
|
680
|
-
|
|
681
|
-
var
|
|
682
|
-
|
|
683
|
-
let
|
|
684
|
-
|
|
685
|
-
...
|
|
708
|
+
const u = JSON.parse(JSON.stringify(e.search));
|
|
709
|
+
Y(() => {
|
|
710
|
+
var h;
|
|
711
|
+
o();
|
|
712
|
+
let c = { ...e.search };
|
|
713
|
+
e.gridCtrl.gridQuery = {
|
|
714
|
+
...e.gridCtrl.gridQuery,
|
|
686
715
|
Query: {
|
|
687
|
-
...(
|
|
688
|
-
...
|
|
716
|
+
...(h = e.gridCtrl.gridQuery) == null ? void 0 : h.Query,
|
|
717
|
+
...c
|
|
689
718
|
}
|
|
690
719
|
};
|
|
691
720
|
});
|
|
692
|
-
const
|
|
693
|
-
var
|
|
694
|
-
let
|
|
695
|
-
if (
|
|
696
|
-
for (const C of
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
...
|
|
721
|
+
const r = () => {
|
|
722
|
+
var h;
|
|
723
|
+
let c = { ...e.search };
|
|
724
|
+
if (e.likeFields)
|
|
725
|
+
for (const C of e.likeFields)
|
|
726
|
+
c[C] && (c[C] = { $like: "%" + c[C] + "%" });
|
|
727
|
+
e.gridCtrl.gridQuery = {
|
|
728
|
+
...e.gridCtrl.gridQuery,
|
|
700
729
|
Query: {
|
|
701
|
-
...(
|
|
702
|
-
...
|
|
730
|
+
...(h = e.gridCtrl.gridQuery) == null ? void 0 : h.Query,
|
|
731
|
+
...c
|
|
703
732
|
}
|
|
704
|
-
},
|
|
733
|
+
}, e.gridCtrl.pageNo.value = 1, e.gridCtrl.reload.value = !0;
|
|
705
734
|
}, v = () => {
|
|
706
|
-
const
|
|
707
|
-
for (const
|
|
708
|
-
|
|
709
|
-
|
|
735
|
+
const c = JSON.parse(JSON.stringify(u));
|
|
736
|
+
for (const h in e.search)
|
|
737
|
+
c[h] === void 0 && (c[h] = void 0);
|
|
738
|
+
t("update:search", c);
|
|
710
739
|
};
|
|
711
|
-
return (
|
|
712
|
-
const C =
|
|
713
|
-
return
|
|
740
|
+
return (c, h) => {
|
|
741
|
+
const C = le("submit");
|
|
742
|
+
return i.value + f.value > 0 ? j((m(), _(l(ze), {
|
|
714
743
|
key: 0,
|
|
715
744
|
"label-col": { flex: "60px" },
|
|
716
745
|
style: {
|
|
@@ -719,41 +748,41 @@ const Ka = async (r, a, t) => {
|
|
|
719
748
|
},
|
|
720
749
|
class: "flex mb-[10px]"
|
|
721
750
|
}, {
|
|
722
|
-
default:
|
|
723
|
-
D(
|
|
724
|
-
|
|
725
|
-
|
|
751
|
+
default: g(() => [
|
|
752
|
+
D(c.$slots, "default"),
|
|
753
|
+
c.gridCtrl.searchBar ? D(c.$slots, "control", { key: 0 }) : k("", !0),
|
|
754
|
+
n.value >= 1 ? (m(), _(de, {
|
|
726
755
|
key: 1,
|
|
727
756
|
class: "w-1/3"
|
|
728
757
|
})) : k("", !0),
|
|
729
|
-
|
|
758
|
+
n.value >= 2 ? (m(), _(de, {
|
|
730
759
|
key: 2,
|
|
731
760
|
class: "w-1/3"
|
|
732
761
|
})) : k("", !0),
|
|
733
|
-
|
|
762
|
+
i.value || c.gridCtrl.searchBar ? (m(), _(de, {
|
|
734
763
|
key: 3,
|
|
735
764
|
class: "w-1/3 flex justify-end text-right pr-5",
|
|
736
765
|
"wrapper-col": { flex: "auto" }
|
|
737
766
|
}, {
|
|
738
|
-
default:
|
|
739
|
-
y(l(
|
|
740
|
-
default:
|
|
741
|
-
y(l(
|
|
767
|
+
default: g(() => [
|
|
768
|
+
y(l(ae), null, {
|
|
769
|
+
default: g(() => [
|
|
770
|
+
y(l(B), {
|
|
742
771
|
type: "primary",
|
|
743
|
-
onClick:
|
|
772
|
+
onClick: r,
|
|
744
773
|
icon: "icon-search"
|
|
745
774
|
}, {
|
|
746
|
-
default:
|
|
775
|
+
default: g(() => h[0] || (h[0] = [
|
|
747
776
|
N("搜索")
|
|
748
777
|
])),
|
|
749
778
|
_: 1,
|
|
750
779
|
__: [0]
|
|
751
780
|
}),
|
|
752
|
-
y(l(
|
|
781
|
+
y(l(B), {
|
|
753
782
|
onClick: v,
|
|
754
783
|
icon: "icon-reset"
|
|
755
784
|
}, {
|
|
756
|
-
default:
|
|
785
|
+
default: g(() => h[1] || (h[1] = [
|
|
757
786
|
N("重置")
|
|
758
787
|
])),
|
|
759
788
|
_: 1,
|
|
@@ -768,18 +797,18 @@ const Ka = async (r, a, t) => {
|
|
|
768
797
|
]),
|
|
769
798
|
_: 3
|
|
770
799
|
})), [
|
|
771
|
-
[C,
|
|
800
|
+
[C, r]
|
|
772
801
|
]) : k("", !0);
|
|
773
802
|
};
|
|
774
803
|
}
|
|
775
|
-
}),
|
|
804
|
+
}), sa = /* @__PURE__ */ S({
|
|
776
805
|
__name: "tableOperate",
|
|
777
806
|
props: {
|
|
778
807
|
record: {},
|
|
779
808
|
gridCtrl: {}
|
|
780
809
|
},
|
|
781
|
-
setup(
|
|
782
|
-
const a =
|
|
810
|
+
setup(s) {
|
|
811
|
+
const a = s, e = a.gridCtrl, t = X(() => ie.currentRoute.value.path), n = [
|
|
783
812
|
{
|
|
784
813
|
key: "Edit",
|
|
785
814
|
label: "编辑",
|
|
@@ -787,7 +816,7 @@ const Ka = async (r, a, t) => {
|
|
|
787
816
|
visible: !0,
|
|
788
817
|
role: ["Super", "Admin"],
|
|
789
818
|
permit: ":edit",
|
|
790
|
-
click: () =>
|
|
819
|
+
click: () => Xe(e, a.record)
|
|
791
820
|
},
|
|
792
821
|
{
|
|
793
822
|
key: "Delete",
|
|
@@ -799,15 +828,15 @@ const Ka = async (r, a, t) => {
|
|
|
799
828
|
permit: ":delete",
|
|
800
829
|
confirm: !0,
|
|
801
830
|
confirmText: "是否删除此记录?",
|
|
802
|
-
click: () =>
|
|
831
|
+
click: () => Ze(e, a.record)
|
|
803
832
|
}
|
|
804
|
-
], { buttons:
|
|
805
|
-
if (typeof
|
|
806
|
-
return
|
|
807
|
-
if (typeof
|
|
808
|
-
return
|
|
833
|
+
], { buttons: i, menus: f } = be(n, 0, e.operates), p = (d) => {
|
|
834
|
+
if (typeof d.disabled == "boolean")
|
|
835
|
+
return d.disabled;
|
|
836
|
+
if (typeof d.disabled == "function")
|
|
837
|
+
return K(d, a.record) ?? !1;
|
|
809
838
|
if (a.record.hasOwnProperty("Enabled"))
|
|
810
|
-
switch (
|
|
839
|
+
switch (d.key) {
|
|
811
840
|
case "Edit":
|
|
812
841
|
return !a.record.Enabled;
|
|
813
842
|
case "Delete":
|
|
@@ -815,86 +844,86 @@ const Ka = async (r, a, t) => {
|
|
|
815
844
|
}
|
|
816
845
|
return !1;
|
|
817
846
|
};
|
|
818
|
-
return (
|
|
819
|
-
const
|
|
820
|
-
return m(), _(l(
|
|
847
|
+
return (d, o) => {
|
|
848
|
+
const u = le("auth");
|
|
849
|
+
return m(), _(l(Ce), { theme: {
|
|
821
850
|
token: {
|
|
822
851
|
fontSize: 13
|
|
823
852
|
}
|
|
824
853
|
} }, {
|
|
825
|
-
default:
|
|
826
|
-
y(l(
|
|
827
|
-
default:
|
|
828
|
-
(m(!0),
|
|
829
|
-
key:
|
|
854
|
+
default: g(() => [
|
|
855
|
+
y(l(ae), null, {
|
|
856
|
+
default: g(() => [
|
|
857
|
+
(m(!0), w(A, null, L(l(i), (r) => (m(), w(A, {
|
|
858
|
+
key: r.key
|
|
830
859
|
}, [
|
|
831
|
-
l(
|
|
860
|
+
l(J)(r, a.record) ? (m(), _(l(xt), {
|
|
832
861
|
key: 0,
|
|
833
|
-
disabled:
|
|
862
|
+
disabled: p(r) || !r.confirm,
|
|
834
863
|
cancelText: "否",
|
|
835
864
|
okText: "是",
|
|
836
|
-
title:
|
|
865
|
+
title: r.confirmText,
|
|
837
866
|
okButtonProps: { size: "small" },
|
|
838
867
|
cancelButtonProps: { size: "small" },
|
|
839
|
-
onConfirm: (v) => l(
|
|
868
|
+
onConfirm: (v) => l(U)(r, l(e).page, l(e), a.record, !0)
|
|
840
869
|
}, {
|
|
841
|
-
default:
|
|
842
|
-
l(
|
|
843
|
-
key:
|
|
844
|
-
type:
|
|
845
|
-
danger:
|
|
846
|
-
disabled:
|
|
847
|
-
onClick: (v) => l(
|
|
870
|
+
default: g(() => [
|
|
871
|
+
l(J)(r, a.record) ? j((m(), _(l(Ye), {
|
|
872
|
+
key: r.key,
|
|
873
|
+
type: r.type ?? "text",
|
|
874
|
+
danger: r.danger,
|
|
875
|
+
disabled: p(r),
|
|
876
|
+
onClick: (v) => l(U)(r, l(e).page, l(e), a.record),
|
|
848
877
|
size: "small",
|
|
849
|
-
style:
|
|
850
|
-
padding:
|
|
878
|
+
style: ce({
|
|
879
|
+
padding: r.type ?? "0px 4px"
|
|
851
880
|
})
|
|
852
881
|
}, {
|
|
853
|
-
default:
|
|
854
|
-
N(F(
|
|
882
|
+
default: g(() => [
|
|
883
|
+
N(F(r.label), 1)
|
|
855
884
|
]),
|
|
856
885
|
_: 2
|
|
857
886
|
}, 1032, ["type", "danger", "disabled", "onClick", "style"])), [
|
|
858
|
-
[
|
|
887
|
+
[u, { url: t.value, role: r.role, permit: r.permit }]
|
|
859
888
|
]) : k("", !0)
|
|
860
889
|
]),
|
|
861
890
|
_: 2
|
|
862
891
|
}, 1032, ["disabled", "title", "onConfirm"])) : k("", !0)
|
|
863
892
|
], 64))), 128)),
|
|
864
|
-
|
|
893
|
+
d.record.Enabled == 1 ? (m(), _(l(Ce), {
|
|
865
894
|
key: 0,
|
|
866
895
|
autoInsertSpaceInButton: !1
|
|
867
896
|
}, {
|
|
868
|
-
default:
|
|
869
|
-
l(
|
|
897
|
+
default: g(() => [
|
|
898
|
+
l(f).length > 0 ? (m(), _(l(yt), {
|
|
870
899
|
key: 0,
|
|
871
900
|
size: "small"
|
|
872
901
|
}, {
|
|
873
|
-
overlay:
|
|
902
|
+
overlay: g(() => [
|
|
874
903
|
y(l(ge), null, {
|
|
875
|
-
default:
|
|
876
|
-
(m(!0),
|
|
877
|
-
key:
|
|
904
|
+
default: g(() => [
|
|
905
|
+
(m(!0), w(A, null, L(l(f), (r) => (m(), w(A, {
|
|
906
|
+
key: r.key
|
|
878
907
|
}, [
|
|
879
|
-
l(
|
|
908
|
+
l(J)(r, a.record) ? j((m(), _(l(_e), {
|
|
880
909
|
key: 0,
|
|
881
|
-
disabled:
|
|
882
|
-
onClick: (v) => l(
|
|
910
|
+
disabled: p(r),
|
|
911
|
+
onClick: (v) => l(U)(r, l(e).page, l(e), a.record)
|
|
883
912
|
}, {
|
|
884
|
-
default:
|
|
885
|
-
N(F(
|
|
913
|
+
default: g(() => [
|
|
914
|
+
N(F(r.label), 1)
|
|
886
915
|
]),
|
|
887
916
|
_: 2
|
|
888
917
|
}, 1032, ["disabled", "onClick"])), [
|
|
889
|
-
[
|
|
918
|
+
[u, { url: t.value, role: r.role, permit: r.permit }]
|
|
890
919
|
]) : k("", !0)
|
|
891
920
|
], 64))), 128))
|
|
892
921
|
]),
|
|
893
922
|
_: 1
|
|
894
923
|
})
|
|
895
924
|
]),
|
|
896
|
-
default:
|
|
897
|
-
|
|
925
|
+
default: g(() => [
|
|
926
|
+
o[0] || (o[0] = N(" 更多 "))
|
|
898
927
|
]),
|
|
899
928
|
_: 1,
|
|
900
929
|
__: [0]
|
|
@@ -910,71 +939,71 @@ const Ka = async (r, a, t) => {
|
|
|
910
939
|
});
|
|
911
940
|
};
|
|
912
941
|
}
|
|
913
|
-
}), ra = { class: "inline-flex [&>div]:ml-[-1px] first:[&>div]:ml-0" },
|
|
942
|
+
}), ra = { class: "inline-flex [&>div]:ml-[-1px] first:[&>div]:ml-0" }, oa = /* @__PURE__ */ S({
|
|
914
943
|
__name: "icontool",
|
|
915
944
|
props: {
|
|
916
945
|
gridCtrl: {}
|
|
917
946
|
},
|
|
918
|
-
setup(
|
|
919
|
-
const a =
|
|
947
|
+
setup(s) {
|
|
948
|
+
const a = s, e = a.gridCtrl, { tools: t } = Vt(a.gridCtrl), n = ve();
|
|
920
949
|
$(
|
|
921
|
-
() =>
|
|
922
|
-
(
|
|
923
|
-
|
|
950
|
+
() => e.selectable.value,
|
|
951
|
+
(p) => {
|
|
952
|
+
W(t, "tool.export.excel.selected") && (W(t, "tool.export.excel.selected").disabled = !p), W(t, "tool.export.pdf.selected") && (W(t, "tool.export.pdf.selected").disabled = !p);
|
|
924
953
|
}
|
|
925
954
|
);
|
|
926
|
-
const
|
|
955
|
+
const i = b([]);
|
|
927
956
|
$(
|
|
928
|
-
() =>
|
|
929
|
-
(
|
|
930
|
-
|
|
957
|
+
() => e.columns.value,
|
|
958
|
+
(p) => {
|
|
959
|
+
i.value = Fe(p, !0);
|
|
931
960
|
},
|
|
932
961
|
{ deep: !0, immediate: !0 }
|
|
933
962
|
);
|
|
934
|
-
const
|
|
935
|
-
|
|
963
|
+
const f = () => {
|
|
964
|
+
e.columns.value.splice(0, e.columns.value.length, ...i.value), n.setTableColumns(ie.currentRoute.value.path, e.columns.value);
|
|
936
965
|
};
|
|
937
|
-
return (
|
|
938
|
-
(m(!0),
|
|
939
|
-
key:
|
|
966
|
+
return (p, d) => (m(), w("div", ra, [
|
|
967
|
+
(m(!0), w(A, null, L(l(t), (o, u) => (m(), w(A, {
|
|
968
|
+
key: o.key
|
|
940
969
|
}, [
|
|
941
|
-
l(
|
|
970
|
+
l(J)(o) && o.dropdown ? (m(), _(l(fe), {
|
|
942
971
|
key: 0,
|
|
943
972
|
placement: "bottomRight",
|
|
944
973
|
class: "p-0 rounded-none"
|
|
945
974
|
}, {
|
|
946
|
-
overlay:
|
|
975
|
+
overlay: g(() => [
|
|
947
976
|
T("div", {
|
|
948
|
-
class: M(["min-w-[100px] bg-white rounded shadow-md p-4",
|
|
977
|
+
class: M(["min-w-[100px] bg-white rounded shadow-md p-4", o.dropdownClass])
|
|
949
978
|
}, [
|
|
950
|
-
|
|
979
|
+
o.dropdown === "headset" ? (m(), _(l(Mt), {
|
|
951
980
|
key: 0,
|
|
952
|
-
modelValue:
|
|
953
|
-
"onUpdate:modelValue":
|
|
981
|
+
modelValue: i.value,
|
|
982
|
+
"onUpdate:modelValue": d[1] || (d[1] = (r) => i.value = r),
|
|
954
983
|
"item-key": "dataIndex",
|
|
955
|
-
onEnd:
|
|
984
|
+
onEnd: f,
|
|
956
985
|
handle: ".drag-handle"
|
|
957
986
|
}, {
|
|
958
|
-
default:
|
|
959
|
-
(m(!0),
|
|
960
|
-
key:
|
|
961
|
-
onClick:
|
|
987
|
+
default: g(() => [
|
|
988
|
+
(m(!0), w(A, null, L(i.value, (r) => (m(), w("div", {
|
|
989
|
+
key: r.name,
|
|
990
|
+
onClick: d[0] || (d[0] = te(() => {
|
|
962
991
|
}, ["stop"])),
|
|
963
992
|
class: "flex items-center mb-2 last:mb-0 select-none"
|
|
964
993
|
}, [
|
|
965
|
-
|
|
966
|
-
y(l(
|
|
967
|
-
checked:
|
|
968
|
-
onChange:
|
|
994
|
+
d[2] || (d[2] = T("span", { class: "drag-handle mr-2 text-gray-400 hover:text-gray-600 cursor-move" }, "⋮⋮", -1)),
|
|
995
|
+
y(l(kt), {
|
|
996
|
+
checked: r.visible !== !1,
|
|
997
|
+
onChange: te(
|
|
969
998
|
(v) => {
|
|
970
|
-
l(
|
|
999
|
+
l(Kt)(r, v.target.checked);
|
|
971
1000
|
},
|
|
972
1001
|
["stop", "prevent"]
|
|
973
1002
|
),
|
|
974
1003
|
class: "text-gray-700 hover:text-gray-900 select-none"
|
|
975
1004
|
}, {
|
|
976
|
-
default:
|
|
977
|
-
N(F(
|
|
1005
|
+
default: g(() => [
|
|
1006
|
+
N(F(r.title), 1)
|
|
978
1007
|
]),
|
|
979
1008
|
_: 2
|
|
980
1009
|
}, 1032, ["checked", "onChange"])
|
|
@@ -984,20 +1013,20 @@ const Ka = async (r, a, t) => {
|
|
|
984
1013
|
}, 8, ["modelValue"])) : k("", !0)
|
|
985
1014
|
], 2)
|
|
986
1015
|
]),
|
|
987
|
-
default:
|
|
988
|
-
y(l(
|
|
1016
|
+
default: g(() => [
|
|
1017
|
+
y(l(B), {
|
|
989
1018
|
class: M([
|
|
990
1019
|
"px-[8px] py-[2px] relative border-[#ccc] bg-[#fcfcfc] rounded-none text-[#666] hover:z-10",
|
|
991
|
-
|
|
992
|
-
|
|
1020
|
+
u === 0 ? "rounded-l-[5px]" : "",
|
|
1021
|
+
u === l(t).length - 1 ? "rounded-r-[5px]" : ""
|
|
993
1022
|
]),
|
|
994
|
-
disabled: l(
|
|
995
|
-
tiptext:
|
|
996
|
-
onClick: (
|
|
1023
|
+
disabled: l(K)(o),
|
|
1024
|
+
tiptext: o.label,
|
|
1025
|
+
onClick: (r) => l(U)(o, l(e).page, l(e))
|
|
997
1026
|
}, {
|
|
998
|
-
default:
|
|
999
|
-
y(l(
|
|
1000
|
-
icon:
|
|
1027
|
+
default: g(() => [
|
|
1028
|
+
y(l(z), {
|
|
1029
|
+
icon: o.icon,
|
|
1001
1030
|
class: "w-[18px] h-[18.5px]",
|
|
1002
1031
|
clickable: ""
|
|
1003
1032
|
}, null, 8, ["icon"])
|
|
@@ -1006,39 +1035,39 @@ const Ka = async (r, a, t) => {
|
|
|
1006
1035
|
}, 1032, ["class", "disabled", "tiptext", "onClick"])
|
|
1007
1036
|
]),
|
|
1008
1037
|
_: 2
|
|
1009
|
-
}, 1024)) : !
|
|
1038
|
+
}, 1024)) : !o.children && l(J)(o) ? (m(), _(l(B), {
|
|
1010
1039
|
key: 1,
|
|
1011
1040
|
class: M([
|
|
1012
1041
|
"px-[8px] py-[2px] relative border-[#ccc] bg-[#fcfcfc] rounded-none text-[#666] hover:z-10",
|
|
1013
|
-
|
|
1014
|
-
|
|
1042
|
+
u === 0 ? "rounded-l-[5px]" : "",
|
|
1043
|
+
u === l(t).length - 1 ? "rounded-r-[5px]" : ""
|
|
1015
1044
|
]),
|
|
1016
|
-
disabled: l(
|
|
1017
|
-
tiptext:
|
|
1018
|
-
onClick: (
|
|
1045
|
+
disabled: l(K)(o),
|
|
1046
|
+
tiptext: o.label,
|
|
1047
|
+
onClick: (r) => l(U)(o, l(e).page, l(e))
|
|
1019
1048
|
}, {
|
|
1020
|
-
default:
|
|
1021
|
-
y(l(
|
|
1022
|
-
icon:
|
|
1049
|
+
default: g(() => [
|
|
1050
|
+
y(l(z), {
|
|
1051
|
+
icon: o.icon,
|
|
1023
1052
|
class: "w-[18px] h-[18.5px]",
|
|
1024
1053
|
clickable: ""
|
|
1025
1054
|
}, null, 8, ["icon"])
|
|
1026
1055
|
]),
|
|
1027
1056
|
_: 2
|
|
1028
|
-
}, 1032, ["class", "disabled", "tiptext", "onClick"])) : l(
|
|
1057
|
+
}, 1032, ["class", "disabled", "tiptext", "onClick"])) : l(J)(o) ? (m(), _(l(fe), {
|
|
1029
1058
|
key: 2,
|
|
1030
1059
|
placement: "bottomRight",
|
|
1031
1060
|
class: "p-0 rounded-none"
|
|
1032
1061
|
}, {
|
|
1033
|
-
overlay:
|
|
1062
|
+
overlay: g(() => [
|
|
1034
1063
|
y(l(ge), null, {
|
|
1035
|
-
default:
|
|
1036
|
-
(m(!0),
|
|
1037
|
-
key:
|
|
1038
|
-
disabled: l(
|
|
1064
|
+
default: g(() => [
|
|
1065
|
+
(m(!0), w(A, null, L(o.children, (r) => (m(), _(l(_e), {
|
|
1066
|
+
key: r.key,
|
|
1067
|
+
disabled: l(K)(r)
|
|
1039
1068
|
}, {
|
|
1040
|
-
default:
|
|
1041
|
-
N(F(
|
|
1069
|
+
default: g(() => [
|
|
1070
|
+
N(F(r.label), 1)
|
|
1042
1071
|
]),
|
|
1043
1072
|
_: 2
|
|
1044
1073
|
}, 1032, ["disabled"]))), 128))
|
|
@@ -1046,20 +1075,20 @@ const Ka = async (r, a, t) => {
|
|
|
1046
1075
|
_: 2
|
|
1047
1076
|
}, 1024)
|
|
1048
1077
|
]),
|
|
1049
|
-
default:
|
|
1050
|
-
y(l(
|
|
1078
|
+
default: g(() => [
|
|
1079
|
+
y(l(B), {
|
|
1051
1080
|
class: M([
|
|
1052
1081
|
"!w-[46px] px-[5px] py-[2px] relative border-[#ccc] bg-[#fcfcfc] rounded-none text-[#666] hover:z-10",
|
|
1053
|
-
|
|
1082
|
+
u === 0 ? "rounded-l-[5px]" : ""
|
|
1054
1083
|
]),
|
|
1055
|
-
disabled: l(
|
|
1056
|
-
tiptext:
|
|
1057
|
-
icon:
|
|
1084
|
+
disabled: l(K)(o),
|
|
1085
|
+
tiptext: o.label,
|
|
1086
|
+
icon: o.icon,
|
|
1058
1087
|
iconProps: { class: "w-[19px] h-[19px]" },
|
|
1059
|
-
onClick: (
|
|
1088
|
+
onClick: (r) => l(U)(o, l(e).page, l(e))
|
|
1060
1089
|
}, {
|
|
1061
|
-
default:
|
|
1062
|
-
y(l(
|
|
1090
|
+
default: g(() => [
|
|
1091
|
+
y(l(z), {
|
|
1063
1092
|
icon: "icon-down-arrow",
|
|
1064
1093
|
class: "w-[12px] h-[12px]"
|
|
1065
1094
|
})
|
|
@@ -1072,14 +1101,14 @@ const Ka = async (r, a, t) => {
|
|
|
1072
1101
|
], 64))), 128))
|
|
1073
1102
|
]));
|
|
1074
1103
|
}
|
|
1075
|
-
}),
|
|
1104
|
+
}), na = { class: "flex justify-between mb-[10px]" }, ia = { key: 1 }, ca = 3, ua = /* @__PURE__ */ S({
|
|
1076
1105
|
__name: "index",
|
|
1077
1106
|
props: {
|
|
1078
1107
|
gridCtrl: {},
|
|
1079
1108
|
editorCtrl: {}
|
|
1080
1109
|
},
|
|
1081
|
-
setup(
|
|
1082
|
-
const a =
|
|
1110
|
+
setup(s) {
|
|
1111
|
+
const a = s, e = a.gridCtrl, t = e.page, n = a.editorCtrl, i = X(() => ie.currentRoute.value.path), f = [
|
|
1083
1112
|
{
|
|
1084
1113
|
key: "New",
|
|
1085
1114
|
label: "新增",
|
|
@@ -1089,70 +1118,70 @@ const Ka = async (r, a, t) => {
|
|
|
1089
1118
|
role: ["Super", "Admin"],
|
|
1090
1119
|
permit: ":new",
|
|
1091
1120
|
// 默认仅受权限码控制
|
|
1092
|
-
click: () =>
|
|
1121
|
+
click: () => et(n)
|
|
1093
1122
|
}
|
|
1094
|
-
],
|
|
1123
|
+
], p = b([]), d = b([]);
|
|
1095
1124
|
return $(
|
|
1096
1125
|
() => {
|
|
1097
|
-
var
|
|
1098
|
-
return (
|
|
1126
|
+
var o;
|
|
1127
|
+
return (o = e.buttons) == null ? void 0 : o.value;
|
|
1099
1128
|
},
|
|
1100
1129
|
() => {
|
|
1101
|
-
var
|
|
1102
|
-
const { buttons:
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
(
|
|
1130
|
+
var r;
|
|
1131
|
+
const { buttons: o, menus: u } = be(
|
|
1132
|
+
f,
|
|
1133
|
+
e.flat !== void 0 ? e.flat : ca,
|
|
1134
|
+
(r = e.buttons) == null ? void 0 : r.value
|
|
1106
1135
|
);
|
|
1107
|
-
|
|
1136
|
+
p.value.splice(0, p.value.length, ...o), d.value.splice(0, d.value.length, ...u);
|
|
1108
1137
|
},
|
|
1109
1138
|
{
|
|
1110
1139
|
deep: !0,
|
|
1111
1140
|
immediate: !0
|
|
1112
1141
|
}
|
|
1113
|
-
), (
|
|
1114
|
-
const
|
|
1115
|
-
return m(),
|
|
1116
|
-
y(l(
|
|
1117
|
-
default:
|
|
1118
|
-
(m(!0),
|
|
1142
|
+
), (o, u) => {
|
|
1143
|
+
const r = le("auth");
|
|
1144
|
+
return m(), w("div", na, [
|
|
1145
|
+
y(l(ae), null, {
|
|
1146
|
+
default: g(() => [
|
|
1147
|
+
(m(!0), w(A, null, L(p.value, (v) => j((m(), _(l(B), {
|
|
1119
1148
|
key: v.key,
|
|
1120
1149
|
type: v.type,
|
|
1121
1150
|
danger: v.danger,
|
|
1122
|
-
disabled: l(
|
|
1151
|
+
disabled: l(K)(v),
|
|
1123
1152
|
icon: v.icon,
|
|
1124
|
-
onClick: (
|
|
1153
|
+
onClick: (c) => l(U)(v, l(t), l(e))
|
|
1125
1154
|
}, {
|
|
1126
|
-
default:
|
|
1155
|
+
default: g(() => [
|
|
1127
1156
|
N(F(v.label), 1)
|
|
1128
1157
|
]),
|
|
1129
1158
|
_: 2
|
|
1130
1159
|
}, 1032, ["type", "danger", "disabled", "icon", "onClick"])), [
|
|
1131
|
-
[
|
|
1160
|
+
[r, { url: i.value, role: v.role, permit: v.permit }]
|
|
1132
1161
|
])), 128)),
|
|
1133
|
-
|
|
1134
|
-
overlay:
|
|
1162
|
+
d.value.length > 0 ? (m(), _(l(fe), { key: 0 }, {
|
|
1163
|
+
overlay: g(() => [
|
|
1135
1164
|
y(l(ge), null, {
|
|
1136
|
-
default:
|
|
1137
|
-
(m(!0),
|
|
1165
|
+
default: g(() => [
|
|
1166
|
+
(m(!0), w(A, null, L(d.value, (v) => j((m(), _(l(_e), {
|
|
1138
1167
|
key: v.key,
|
|
1139
|
-
disabled: l(
|
|
1140
|
-
onClick: (
|
|
1168
|
+
disabled: l(K)(v),
|
|
1169
|
+
onClick: (c) => l(U)(v, l(t), l(e))
|
|
1141
1170
|
}, {
|
|
1142
|
-
default:
|
|
1171
|
+
default: g(() => [
|
|
1143
1172
|
N(F(v.label), 1)
|
|
1144
1173
|
]),
|
|
1145
1174
|
_: 2
|
|
1146
1175
|
}, 1032, ["disabled", "onClick"])), [
|
|
1147
|
-
[
|
|
1176
|
+
[r, { url: i.value, role: v.role, permit: v.permit }]
|
|
1148
1177
|
])), 128))
|
|
1149
1178
|
]),
|
|
1150
1179
|
_: 1
|
|
1151
1180
|
})
|
|
1152
1181
|
]),
|
|
1153
|
-
default:
|
|
1154
|
-
y(l(
|
|
1155
|
-
default:
|
|
1182
|
+
default: g(() => [
|
|
1183
|
+
y(l(B), null, {
|
|
1184
|
+
default: g(() => u[0] || (u[0] = [
|
|
1156
1185
|
N(" 更多操作 ")
|
|
1157
1186
|
])),
|
|
1158
1187
|
_: 1,
|
|
@@ -1161,61 +1190,20 @@ const Ka = async (r, a, t) => {
|
|
|
1161
1190
|
]),
|
|
1162
1191
|
_: 1
|
|
1163
1192
|
})) : k("", !0),
|
|
1164
|
-
|
|
1193
|
+
p.value.length === 0 && d.value.length === 0 ? (m(), w("span", ia)) : k("", !0)
|
|
1165
1194
|
]),
|
|
1166
1195
|
_: 1
|
|
1167
1196
|
}),
|
|
1168
|
-
y(l(
|
|
1169
|
-
default:
|
|
1170
|
-
(m(), _(
|
|
1197
|
+
y(l(ae), { class: "mr-1" }, {
|
|
1198
|
+
default: g(() => [
|
|
1199
|
+
(m(), _(ft(oa), { "grid-ctrl": l(e) }, null, 8, ["grid-ctrl"]))
|
|
1171
1200
|
]),
|
|
1172
1201
|
_: 1
|
|
1173
1202
|
})
|
|
1174
1203
|
]);
|
|
1175
1204
|
};
|
|
1176
1205
|
}
|
|
1177
|
-
}),
|
|
1178
|
-
__name: "index",
|
|
1179
|
-
props: {
|
|
1180
|
-
/**
|
|
1181
|
-
* 选择项数据
|
|
1182
|
-
*/
|
|
1183
|
-
data: {
|
|
1184
|
-
type: Array,
|
|
1185
|
-
required: !0
|
|
1186
|
-
}
|
|
1187
|
-
},
|
|
1188
|
-
emits: ["change"],
|
|
1189
|
-
setup(r, { emit: a }) {
|
|
1190
|
-
const t = r, e = b([]), o = a, { editorCtrl: n, errInfo: p } = B(), u = (i) => {
|
|
1191
|
-
p != null && p.value.errClass && n && V(n), o("change", i);
|
|
1192
|
-
};
|
|
1193
|
-
return z(() => {
|
|
1194
|
-
if (!t.data || t.data.length != 2) {
|
|
1195
|
-
console.error("Switch组件: ", t.data), ne.error("Switch组件必须有且只有两个选项");
|
|
1196
|
-
return;
|
|
1197
|
-
}
|
|
1198
|
-
Ne(!1, t, e);
|
|
1199
|
-
}), Ye(() => {
|
|
1200
|
-
Re(t);
|
|
1201
|
-
}), (i, c) => {
|
|
1202
|
-
var d;
|
|
1203
|
-
return e.value.length === 2 ? (m(), _(l(kt), E({
|
|
1204
|
-
key: 0,
|
|
1205
|
-
class: [
|
|
1206
|
-
((d = l(p)) == null ? void 0 : d.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : "",
|
|
1207
|
-
"bg-blue-300",
|
|
1208
|
-
"w-[58px]"
|
|
1209
|
-
],
|
|
1210
|
-
checkedChildren: e.value[0].label,
|
|
1211
|
-
checkedValue: e.value[0].value,
|
|
1212
|
-
unCheckedChildren: e.value[1].label,
|
|
1213
|
-
unCheckedValue: e.value[1].value,
|
|
1214
|
-
onChange: u
|
|
1215
|
-
}, i.$attrs), null, 16, ["class", "checkedChildren", "checkedValue", "unCheckedChildren", "unCheckedValue"])) : k("", !0);
|
|
1216
|
-
};
|
|
1217
|
-
}
|
|
1218
|
-
}), Xa = /* @__PURE__ */ w({
|
|
1206
|
+
}), Za = /* @__PURE__ */ S({
|
|
1219
1207
|
inheritAttrs: !1,
|
|
1220
1208
|
__name: "index",
|
|
1221
1209
|
props: {
|
|
@@ -1227,113 +1215,113 @@ const Ka = async (r, a, t) => {
|
|
|
1227
1215
|
scroll: {},
|
|
1228
1216
|
statusDisabled: { type: Function }
|
|
1229
1217
|
},
|
|
1230
|
-
setup(
|
|
1231
|
-
const a =
|
|
1232
|
-
|
|
1233
|
-
const
|
|
1218
|
+
setup(s) {
|
|
1219
|
+
const a = s, e = Q(), t = a.gridCtrl, n = X(() => ie.currentRoute.value.path);
|
|
1220
|
+
t && (t.pageNo.value = 1, t.total.value = 0, t.pageSize.value = t.pageSize.value);
|
|
1221
|
+
const i = b(t.pageSize.value), f = b(t.pageNo.value), p = b([]), d = b({
|
|
1234
1222
|
total: 0,
|
|
1235
1223
|
current: 1,
|
|
1236
|
-
pageSize:
|
|
1237
|
-
showTotal: (
|
|
1238
|
-
onChange: (
|
|
1239
|
-
|
|
1224
|
+
pageSize: i.value,
|
|
1225
|
+
showTotal: (c) => `共 ${c} 条记录`,
|
|
1226
|
+
onChange: (c, h) => {
|
|
1227
|
+
d.value.current = c, d.value.pageSize = h, i.value = h, f.value = c, t && (t.pageNo.value = c, t.pageSize.value = h, t.remotePage && ke(t));
|
|
1240
1228
|
},
|
|
1241
1229
|
...a.pagination
|
|
1242
1230
|
});
|
|
1243
1231
|
$(
|
|
1244
|
-
() =>
|
|
1245
|
-
(
|
|
1246
|
-
|
|
1232
|
+
() => t.tableData.value,
|
|
1233
|
+
(c) => {
|
|
1234
|
+
c && (p.value = c, d.value.total = t.total.value ?? 0, d.value.current = t.pageNo.value ?? 1, d.value.pageSize = t.pageSize.value ?? 10);
|
|
1247
1235
|
},
|
|
1248
1236
|
{ immediate: !0 }
|
|
1249
1237
|
), $(
|
|
1250
1238
|
() => a.tableData,
|
|
1251
|
-
(
|
|
1252
|
-
|
|
1239
|
+
(c) => {
|
|
1240
|
+
c && (p.value = c, d.value.total = c.length, d.value.current = t.pageNo.value ?? 1, d.value.pageSize = t.pageSize.value ?? 10);
|
|
1253
1241
|
},
|
|
1254
1242
|
{ immediate: !0 }
|
|
1255
1243
|
);
|
|
1256
|
-
const
|
|
1257
|
-
onChange: (
|
|
1258
|
-
|
|
1244
|
+
const o = b(t.columns.value), u = {
|
|
1245
|
+
onChange: (c, h) => {
|
|
1246
|
+
t && (t.selectKeys.value = c, t.selectRows.value = h);
|
|
1259
1247
|
},
|
|
1260
1248
|
columnWidth: "30px",
|
|
1261
|
-
getCheckboxProps: (
|
|
1262
|
-
disabled:
|
|
1249
|
+
getCheckboxProps: (c) => ({
|
|
1250
|
+
disabled: c.Enabled === 0
|
|
1263
1251
|
}),
|
|
1264
1252
|
...a.rowSelection
|
|
1265
|
-
},
|
|
1253
|
+
}, r = b(u);
|
|
1266
1254
|
$(
|
|
1267
|
-
() =>
|
|
1268
|
-
(
|
|
1269
|
-
|
|
1255
|
+
() => t.selectable.value,
|
|
1256
|
+
(c) => {
|
|
1257
|
+
t && (r.value = c ? u : void 0);
|
|
1270
1258
|
},
|
|
1271
1259
|
{ immediate: !0 }
|
|
1272
1260
|
), $(
|
|
1273
|
-
() =>
|
|
1261
|
+
() => t.columns.value,
|
|
1274
1262
|
() => {
|
|
1275
|
-
|
|
1263
|
+
o.value = Fe(t.columns.value);
|
|
1276
1264
|
},
|
|
1277
1265
|
{ deep: !0, immediate: !0 }
|
|
1278
1266
|
);
|
|
1279
1267
|
const v = b(!1);
|
|
1280
|
-
return
|
|
1281
|
-
v.value &&
|
|
1282
|
-
}),
|
|
1283
|
-
|
|
1268
|
+
return vt(() => {
|
|
1269
|
+
v.value && t && (t.reload.value = !0);
|
|
1270
|
+
}), Y(async () => {
|
|
1271
|
+
he(V.GridControl, t), t.tableData.value ? (p.value = t.tableData.value, t.total.value = p.value.length, d.value.total = t.total.value ?? 0) : t.autoload !== !1 && (t.remotePage ? p.value = (await ke(t)).rows : p.value = await tt(t)), setTimeout(() => {
|
|
1284
1272
|
v.value = !0;
|
|
1285
1273
|
}, 50);
|
|
1286
|
-
}), (
|
|
1274
|
+
}), (c, h) => {
|
|
1287
1275
|
var I, P;
|
|
1288
|
-
const C =
|
|
1289
|
-
return m(),
|
|
1290
|
-
(I = l(
|
|
1276
|
+
const C = le("auth");
|
|
1277
|
+
return m(), w(A, null, [
|
|
1278
|
+
(I = l(t).buttons) != null && I.value.length || (P = l(t).tools) != null && P.length ? (m(), _(ua, {
|
|
1291
1279
|
key: 0,
|
|
1292
|
-
"grid-ctrl": l(
|
|
1293
|
-
"editor-ctrl": l(
|
|
1280
|
+
"grid-ctrl": l(t),
|
|
1281
|
+
"editor-ctrl": l(t).editor
|
|
1294
1282
|
}, null, 8, ["grid-ctrl", "editor-ctrl"])) : k("", !0),
|
|
1295
|
-
v.value ? (m(), _(l(
|
|
1283
|
+
v.value ? (m(), _(l(We), E({
|
|
1296
1284
|
key: 1,
|
|
1297
1285
|
class: "w-full",
|
|
1298
|
-
"row-key": a.primaryKey ?? l(
|
|
1299
|
-
"data-source":
|
|
1300
|
-
loading: l(
|
|
1301
|
-
columns:
|
|
1302
|
-
pagination:
|
|
1303
|
-
"row-selection":
|
|
1286
|
+
"row-key": a.primaryKey ?? l(t).primaryKey ?? "Id",
|
|
1287
|
+
"data-source": p.value,
|
|
1288
|
+
loading: l(t).isGridLoading.value,
|
|
1289
|
+
columns: o.value,
|
|
1290
|
+
pagination: d.value,
|
|
1291
|
+
"row-selection": r.value,
|
|
1304
1292
|
scroll: a.scroll || { x: 700, y: 1e3 },
|
|
1305
|
-
size: l(
|
|
1293
|
+
size: l(t).tableSize.value,
|
|
1306
1294
|
bordered: ""
|
|
1307
|
-
}, l(
|
|
1308
|
-
bodyCell:
|
|
1309
|
-
var R,
|
|
1295
|
+
}, l(e)), {
|
|
1296
|
+
bodyCell: g((x) => {
|
|
1297
|
+
var R, G;
|
|
1310
1298
|
return [
|
|
1311
|
-
D(
|
|
1299
|
+
D(c.$slots, "bodyCell", {
|
|
1312
1300
|
column: x == null ? void 0 : x.column,
|
|
1313
1301
|
record: x == null ? void 0 : x.record
|
|
1314
1302
|
}),
|
|
1315
|
-
l(
|
|
1303
|
+
l(t) && ((R = x == null ? void 0 : x.column) == null ? void 0 : R.dataIndex) === "enabled" ? j((m(), _(Nt, {
|
|
1316
1304
|
key: 0,
|
|
1317
1305
|
checked: x.record.Enabled,
|
|
1318
1306
|
"onUpdate:checked": (ye) => x.record.Enabled = ye,
|
|
1319
|
-
disabled:
|
|
1320
|
-
data: l(
|
|
1321
|
-
onClick: (ye) => l(
|
|
1307
|
+
disabled: c.statusDisabled ? c.statusDisabled(x.record) : !1,
|
|
1308
|
+
data: l(Me).EnableDisable,
|
|
1309
|
+
onClick: (ye) => l(at)(l(t), x.record),
|
|
1322
1310
|
class: M([
|
|
1323
1311
|
"w-[58px]",
|
|
1324
|
-
|
|
1312
|
+
c.statusDisabled && c.statusDisabled(x.record) ? "cursor-not-allowed disabled" : ""
|
|
1325
1313
|
]),
|
|
1326
1314
|
loading: x == null ? void 0 : x.record.isLoading
|
|
1327
1315
|
}, null, 8, ["checked", "onUpdate:checked", "disabled", "data", "onClick", "class", "loading"])), [
|
|
1328
|
-
[C, { url:
|
|
1316
|
+
[C, { url: n.value, role: ["Super", "Admin"], permit: ":enabled" }, "disable"]
|
|
1329
1317
|
]) : k("", !0),
|
|
1330
|
-
l(
|
|
1318
|
+
l(t) && ((G = x == null ? void 0 : x.column) == null ? void 0 : G.dataIndex) === "operation" ? D(c.$slots, "operate", {
|
|
1331
1319
|
key: 1,
|
|
1332
1320
|
record: x == null ? void 0 : x.record
|
|
1333
1321
|
}, () => [
|
|
1334
|
-
y(
|
|
1322
|
+
y(sa, {
|
|
1335
1323
|
record: x == null ? void 0 : x.record,
|
|
1336
|
-
"grid-ctrl": l(
|
|
1324
|
+
"grid-ctrl": l(t)
|
|
1337
1325
|
}, null, 8, ["record", "grid-ctrl"])
|
|
1338
1326
|
]) : k("", !0)
|
|
1339
1327
|
];
|
|
@@ -1343,7 +1331,7 @@ const Ka = async (r, a, t) => {
|
|
|
1343
1331
|
], 64);
|
|
1344
1332
|
};
|
|
1345
1333
|
}
|
|
1346
|
-
}), da = { class: "flex items-center gap-1" }, pa = { class: "text-nowrap" },
|
|
1334
|
+
}), da = { class: "flex items-center gap-1" }, pa = { class: "text-nowrap" }, el = /* @__PURE__ */ S({
|
|
1347
1335
|
__name: "index",
|
|
1348
1336
|
props: {
|
|
1349
1337
|
treeCtrl: {},
|
|
@@ -1351,139 +1339,139 @@ const Ka = async (r, a, t) => {
|
|
|
1351
1339
|
expandedKeys: {}
|
|
1352
1340
|
},
|
|
1353
1341
|
emits: ["select", "update:selectedKeys"],
|
|
1354
|
-
setup(
|
|
1355
|
-
const
|
|
1342
|
+
setup(s, { emit: a }) {
|
|
1343
|
+
const e = s, t = Q(), n = e.treeCtrl, i = b([]);
|
|
1356
1344
|
$(
|
|
1357
|
-
() =>
|
|
1358
|
-
(
|
|
1359
|
-
|
|
1345
|
+
() => n.data.value,
|
|
1346
|
+
(u) => {
|
|
1347
|
+
u && (i.value = n.fieldMap ? re(n.fieldMap, u) : u, o(e.selectedKeys ?? []));
|
|
1360
1348
|
}
|
|
1361
1349
|
);
|
|
1362
|
-
const
|
|
1350
|
+
const f = a, p = b([]);
|
|
1363
1351
|
$(
|
|
1364
|
-
() =>
|
|
1365
|
-
(
|
|
1366
|
-
|
|
1352
|
+
() => e.selectedKeys,
|
|
1353
|
+
(u) => {
|
|
1354
|
+
u && (p.value = u);
|
|
1367
1355
|
},
|
|
1368
1356
|
{ immediate: !0 }
|
|
1369
1357
|
);
|
|
1370
|
-
const
|
|
1358
|
+
const d = b(["-"]);
|
|
1371
1359
|
$(
|
|
1372
|
-
() =>
|
|
1373
|
-
(
|
|
1374
|
-
|
|
1360
|
+
() => e.expandedKeys,
|
|
1361
|
+
(u) => {
|
|
1362
|
+
u && (d.value = u);
|
|
1375
1363
|
},
|
|
1376
1364
|
{ immediate: !0 }
|
|
1377
1365
|
);
|
|
1378
|
-
const
|
|
1379
|
-
|
|
1366
|
+
const o = (u, r) => {
|
|
1367
|
+
u.length === 0 && u.push(...p.value), u.length > 0 && (n.node.value = r == null ? void 0 : r.node.dataRef), p.value = u, f("update:selectedKeys", u), f("select", u, r);
|
|
1380
1368
|
};
|
|
1381
|
-
return
|
|
1382
|
-
|
|
1369
|
+
return Y(() => {
|
|
1370
|
+
n.fieldMap || (n.fieldMap = {
|
|
1383
1371
|
label: "Name",
|
|
1384
1372
|
key: "Id",
|
|
1385
1373
|
value: "Id",
|
|
1386
1374
|
icon: "Icon"
|
|
1387
|
-
}),
|
|
1388
|
-
}), (
|
|
1375
|
+
}), n.data.value ? i.value = re(n.fieldMap, n.data.value) : n.autoload && Ne(n);
|
|
1376
|
+
}), (u, r) => (m(), _(l(wt), E({
|
|
1389
1377
|
class: "w-full",
|
|
1390
1378
|
"show-line": !0,
|
|
1391
|
-
"tree-data":
|
|
1392
|
-
"expanded-keys":
|
|
1393
|
-
"onUpdate:expandedKeys":
|
|
1394
|
-
"selected-keys":
|
|
1395
|
-
loading: l(
|
|
1396
|
-
onSelect:
|
|
1397
|
-
}, l(
|
|
1398
|
-
title:
|
|
1399
|
-
D(
|
|
1400
|
-
label:
|
|
1379
|
+
"tree-data": i.value,
|
|
1380
|
+
"expanded-keys": d.value,
|
|
1381
|
+
"onUpdate:expandedKeys": r[0] || (r[0] = (v) => d.value = v),
|
|
1382
|
+
"selected-keys": p.value,
|
|
1383
|
+
loading: l(n).isTreeLoading,
|
|
1384
|
+
onSelect: o
|
|
1385
|
+
}, l(t)), {
|
|
1386
|
+
title: g(({ key: v, label: c, icon: h }) => [
|
|
1387
|
+
D(u.$slots, "title", {
|
|
1388
|
+
label: c,
|
|
1401
1389
|
key: v,
|
|
1402
|
-
icon:
|
|
1390
|
+
icon: h
|
|
1403
1391
|
}, () => [
|
|
1404
1392
|
T("div", da, [
|
|
1405
|
-
y(l(
|
|
1406
|
-
T("span", pa, F(
|
|
1393
|
+
y(l(z), { icon: h }, null, 8, ["icon"]),
|
|
1394
|
+
T("span", pa, F(c), 1)
|
|
1407
1395
|
])
|
|
1408
1396
|
])
|
|
1409
1397
|
]),
|
|
1410
1398
|
_: 3
|
|
1411
1399
|
}, 16, ["tree-data", "expanded-keys", "selected-keys", "loading"]));
|
|
1412
1400
|
}
|
|
1413
|
-
}),
|
|
1401
|
+
}), tl = /* @__PURE__ */ q(lt, [["__scopeId", "data-v-4e4de7b2"]]), fa = { class: "relative w-[248px] max-w-[248px]" }, va = {
|
|
1414
1402
|
key: 0,
|
|
1415
1403
|
class: "absolute z-10 mt-[5px] mr-[10px] text-[#999] flex items-center"
|
|
1416
|
-
},
|
|
1404
|
+
}, ma = /* @__PURE__ */ S({
|
|
1417
1405
|
inheritAttrs: !1,
|
|
1418
1406
|
__name: "index",
|
|
1419
|
-
props:
|
|
1407
|
+
props: st,
|
|
1420
1408
|
emits: ["change", "update:labels", "update:value"],
|
|
1421
|
-
setup(
|
|
1422
|
-
var
|
|
1423
|
-
const
|
|
1424
|
-
...
|
|
1425
|
-
url: ((
|
|
1426
|
-
fieldMap:
|
|
1427
|
-
params:
|
|
1409
|
+
setup(s, { emit: a }) {
|
|
1410
|
+
var c, h, C;
|
|
1411
|
+
const e = s, t = Q(), n = b({
|
|
1412
|
+
...e.url,
|
|
1413
|
+
url: ((c = e.url) == null ? void 0 : c.url) || "",
|
|
1414
|
+
fieldMap: e.fieldMap || ((h = e.url) == null ? void 0 : h.fieldMap),
|
|
1415
|
+
params: e.params || ((C = e.url) == null ? void 0 : C.params),
|
|
1428
1416
|
loadingText: !1
|
|
1429
|
-
}),
|
|
1417
|
+
}), i = O(), { editorCtrl: f, errInfo: p, labelText: d } = i, o = b(t.placeholder);
|
|
1430
1418
|
$(
|
|
1431
|
-
() =>
|
|
1419
|
+
() => n.value.loading,
|
|
1432
1420
|
(I) => {
|
|
1433
|
-
I ?
|
|
1421
|
+
I ? o.value = "" : o.value || (o.value = "请选择" + d.value);
|
|
1434
1422
|
},
|
|
1435
1423
|
{ immediate: !0 }
|
|
1436
1424
|
);
|
|
1437
|
-
const
|
|
1438
|
-
|
|
1439
|
-
const
|
|
1425
|
+
const u = a;
|
|
1426
|
+
i.inputEmit = u;
|
|
1427
|
+
const r = b([]), v = (I, P) => {
|
|
1440
1428
|
if (!P || P.length === 0) {
|
|
1441
|
-
|
|
1429
|
+
u("update:labels", []), u("update:value", []);
|
|
1442
1430
|
return;
|
|
1443
1431
|
}
|
|
1444
1432
|
const x = P.map((R) => R.label);
|
|
1445
|
-
|
|
1433
|
+
u("update:labels", x), u(
|
|
1446
1434
|
"update:value",
|
|
1447
1435
|
P.map((R) => R.value)
|
|
1448
|
-
),
|
|
1436
|
+
), p != null && p.value.errClass && f && H(f);
|
|
1449
1437
|
};
|
|
1450
|
-
return
|
|
1451
|
-
|
|
1438
|
+
return Y(() => {
|
|
1439
|
+
n.value && !n.value.fieldMap && (n.value.fieldMap = {
|
|
1452
1440
|
title: "Name",
|
|
1453
1441
|
label: "Name",
|
|
1454
1442
|
value: "Id",
|
|
1455
1443
|
key: "Id"
|
|
1456
|
-
}),
|
|
1457
|
-
}),
|
|
1458
|
-
|
|
1444
|
+
}), rt(e.autoload, e, r, i, n.value, n.value.params);
|
|
1445
|
+
}), mt(() => {
|
|
1446
|
+
ot(e, i);
|
|
1459
1447
|
}), (I, P) => {
|
|
1460
1448
|
var x;
|
|
1461
|
-
return m(),
|
|
1462
|
-
|
|
1463
|
-
y(l(
|
|
1449
|
+
return m(), w("div", fa, [
|
|
1450
|
+
r.value.length ? k("", !0) : (m(), w("div", va, [
|
|
1451
|
+
y(l(nt), { class: "text-[#555] mx-[5px] !ml-[10px] !w-4 !h-4" }),
|
|
1464
1452
|
P[0] || (P[0] = T("span", null, "数据加载中...", -1))
|
|
1465
1453
|
])),
|
|
1466
|
-
y(l(
|
|
1467
|
-
options:
|
|
1468
|
-
class: [(x = l(
|
|
1454
|
+
y(l(St), E({
|
|
1455
|
+
options: r.value,
|
|
1456
|
+
class: [(x = l(p)) == null ? void 0 : x.errClass],
|
|
1469
1457
|
"allow-clear": !0,
|
|
1470
|
-
placeholder:
|
|
1458
|
+
placeholder: r.value.length > 0 ? "请选择" + l(d) : "",
|
|
1471
1459
|
onChange: v
|
|
1472
|
-
}, l(
|
|
1460
|
+
}, l(t)), null, 16, ["options", "class", "placeholder"])
|
|
1473
1461
|
]);
|
|
1474
1462
|
};
|
|
1475
1463
|
}
|
|
1476
|
-
}),
|
|
1477
|
-
function
|
|
1478
|
-
return
|
|
1464
|
+
}), al = /* @__PURE__ */ q(ma, [["__scopeId", "data-v-9e842af9"]]), ll = /* @__PURE__ */ q(it, [["__scopeId", "data-v-602494f4"]]);
|
|
1465
|
+
function ne() {
|
|
1466
|
+
return ne = Object.assign ? Object.assign.bind() : function(s) {
|
|
1479
1467
|
for (var a = 1; a < arguments.length; a++) {
|
|
1480
|
-
var
|
|
1481
|
-
for (var
|
|
1468
|
+
var e = arguments[a];
|
|
1469
|
+
for (var t in e) ({}).hasOwnProperty.call(e, t) && (s[t] = e[t]);
|
|
1482
1470
|
}
|
|
1483
|
-
return
|
|
1484
|
-
},
|
|
1471
|
+
return s;
|
|
1472
|
+
}, ne.apply(null, arguments);
|
|
1485
1473
|
}
|
|
1486
|
-
const
|
|
1474
|
+
const ha = {
|
|
1487
1475
|
locale: "zh_CN",
|
|
1488
1476
|
today: "今天",
|
|
1489
1477
|
now: "此刻",
|
|
@@ -1510,11 +1498,11 @@ const ma = {
|
|
|
1510
1498
|
nextDecade: "下一年代",
|
|
1511
1499
|
previousCentury: "上一世纪",
|
|
1512
1500
|
nextCentury: "下一世纪"
|
|
1513
|
-
},
|
|
1501
|
+
}, ga = {
|
|
1514
1502
|
placeholder: "请选择时间",
|
|
1515
1503
|
rangePlaceholder: ["开始时间", "结束时间"]
|
|
1516
1504
|
}, xe = {
|
|
1517
|
-
lang:
|
|
1505
|
+
lang: ne({
|
|
1518
1506
|
placeholder: "请选择日期",
|
|
1519
1507
|
yearPlaceholder: "请选择年份",
|
|
1520
1508
|
quarterPlaceholder: "请选择季度",
|
|
@@ -1525,231 +1513,266 @@ const ma = {
|
|
|
1525
1513
|
rangeMonthPlaceholder: ["开始月份", "结束月份"],
|
|
1526
1514
|
rangeQuarterPlaceholder: ["开始季度", "结束季度"],
|
|
1527
1515
|
rangeWeekPlaceholder: ["开始周", "结束周"]
|
|
1528
|
-
},
|
|
1529
|
-
timePickerLocale:
|
|
1516
|
+
}, ha),
|
|
1517
|
+
timePickerLocale: ne({}, ga)
|
|
1530
1518
|
};
|
|
1531
1519
|
xe.lang.ok = "确定";
|
|
1532
|
-
const
|
|
1520
|
+
const sl = /* @__PURE__ */ S({
|
|
1533
1521
|
__name: "index",
|
|
1534
1522
|
props: {
|
|
1535
1523
|
valueFormat: {}
|
|
1536
1524
|
},
|
|
1537
|
-
setup(
|
|
1538
|
-
const a =
|
|
1539
|
-
|
|
1540
|
-
},
|
|
1541
|
-
return (
|
|
1542
|
-
var
|
|
1543
|
-
return m(), _(l(
|
|
1544
|
-
class: M([[((
|
|
1545
|
-
placeholder: "请选择" + l(
|
|
1525
|
+
setup(s) {
|
|
1526
|
+
const a = s, { editorCtrl: e, labelText: t, errInfo: n } = O(), i = () => {
|
|
1527
|
+
n != null && n.value.errClass && e && H(e);
|
|
1528
|
+
}, f = b(a.valueFormat ?? "YYYY-MM-DD");
|
|
1529
|
+
return (p, d) => {
|
|
1530
|
+
var o;
|
|
1531
|
+
return m(), _(l(Ct), {
|
|
1532
|
+
class: M(["w-full", [((o = l(n)) == null ? void 0 : o.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""]]),
|
|
1533
|
+
placeholder: "请选择" + l(t),
|
|
1546
1534
|
locale: l(xe),
|
|
1547
|
-
valueFormat:
|
|
1548
|
-
onBlur:
|
|
1535
|
+
valueFormat: f.value,
|
|
1536
|
+
onBlur: i
|
|
1549
1537
|
}, null, 8, ["class", "placeholder", "locale", "valueFormat"]);
|
|
1550
1538
|
};
|
|
1551
1539
|
}
|
|
1552
|
-
}),
|
|
1540
|
+
}), _a = /* @__PURE__ */ S({
|
|
1553
1541
|
__name: "index",
|
|
1554
1542
|
props: {
|
|
1555
1543
|
value: {}
|
|
1556
1544
|
},
|
|
1557
1545
|
emits: ["update:value"],
|
|
1558
|
-
setup(
|
|
1559
|
-
const { editorCtrl:
|
|
1560
|
-
|
|
1561
|
-
},
|
|
1546
|
+
setup(s, { emit: a }) {
|
|
1547
|
+
const { editorCtrl: e, labelText: t, errInfo: n } = O(), i = () => {
|
|
1548
|
+
n != null && n.value.errClass && e && H(e);
|
|
1549
|
+
}, f = s, p = a, d = b(f.value);
|
|
1562
1550
|
$(
|
|
1563
|
-
() =>
|
|
1564
|
-
(
|
|
1565
|
-
|
|
1551
|
+
() => f.value,
|
|
1552
|
+
(u) => {
|
|
1553
|
+
d.value = u;
|
|
1566
1554
|
},
|
|
1567
1555
|
{ immediate: !0 }
|
|
1568
1556
|
// 立即同步初始值
|
|
1569
1557
|
), $(
|
|
1570
|
-
() =>
|
|
1571
|
-
(
|
|
1572
|
-
if (
|
|
1573
|
-
|
|
1558
|
+
() => d.value,
|
|
1559
|
+
(u) => {
|
|
1560
|
+
if (d.value === "") {
|
|
1561
|
+
p("update:value", void 0);
|
|
1574
1562
|
return;
|
|
1575
1563
|
}
|
|
1576
|
-
|
|
1564
|
+
p("update:value", u);
|
|
1577
1565
|
}
|
|
1578
1566
|
);
|
|
1579
|
-
const
|
|
1580
|
-
|
|
1567
|
+
const o = () => {
|
|
1568
|
+
d.value === "" && (d.value = void 0);
|
|
1581
1569
|
};
|
|
1582
|
-
return (
|
|
1583
|
-
var v,
|
|
1584
|
-
return m(), _(l(
|
|
1570
|
+
return (u, r) => {
|
|
1571
|
+
var v, c;
|
|
1572
|
+
return m(), _(l(ee), E({
|
|
1585
1573
|
class: [
|
|
1586
|
-
(v = l(
|
|
1587
|
-
((
|
|
1574
|
+
(v = l(n)) == null ? void 0 : v.errClass,
|
|
1575
|
+
((c = l(n)) == null ? void 0 : c.errClass) === "error" && !u.$slots.addonBefore && !u.$slots.addonAfter ? "!border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""
|
|
1588
1576
|
],
|
|
1589
|
-
value:
|
|
1590
|
-
"onUpdate:value":
|
|
1577
|
+
value: d.value,
|
|
1578
|
+
"onUpdate:value": r[0] || (r[0] = (h) => d.value = h),
|
|
1591
1579
|
autocomplete: "new-password",
|
|
1592
1580
|
"allow-clear": !0,
|
|
1593
|
-
placeholder: "请输入" + l(
|
|
1594
|
-
onBlur:
|
|
1595
|
-
onChange:
|
|
1596
|
-
},
|
|
1597
|
-
|
|
1581
|
+
placeholder: "请输入" + l(t),
|
|
1582
|
+
onBlur: i,
|
|
1583
|
+
onChange: o
|
|
1584
|
+
}, u.$attrs), Oe({ _: 2 }, [
|
|
1585
|
+
u.$slots.addonBefore ? {
|
|
1598
1586
|
name: "addonBefore",
|
|
1599
|
-
fn:
|
|
1600
|
-
D(
|
|
1587
|
+
fn: g(() => [
|
|
1588
|
+
D(u.$slots, "addonBefore")
|
|
1601
1589
|
]),
|
|
1602
1590
|
key: "0"
|
|
1603
1591
|
} : void 0,
|
|
1604
|
-
|
|
1592
|
+
u.$slots.addonAfter ? {
|
|
1605
1593
|
name: "addonAfter",
|
|
1606
|
-
fn:
|
|
1607
|
-
D(
|
|
1594
|
+
fn: g(() => [
|
|
1595
|
+
D(u.$slots, "addonAfter")
|
|
1608
1596
|
]),
|
|
1609
1597
|
key: "1"
|
|
1610
1598
|
} : void 0
|
|
1611
1599
|
]), 1040, ["class", "value", "placeholder"]);
|
|
1612
1600
|
};
|
|
1613
1601
|
}
|
|
1614
|
-
}),
|
|
1602
|
+
}), ba = /* @__PURE__ */ S({
|
|
1615
1603
|
__name: "inputIcon",
|
|
1616
1604
|
props: {
|
|
1617
1605
|
value: {}
|
|
1618
1606
|
},
|
|
1619
1607
|
emits: ["update:value"],
|
|
1620
|
-
setup(
|
|
1621
|
-
const
|
|
1608
|
+
setup(s, { emit: a }) {
|
|
1609
|
+
const e = s, t = a, n = b(void 0);
|
|
1622
1610
|
return $(
|
|
1623
|
-
() =>
|
|
1624
|
-
(
|
|
1625
|
-
|
|
1611
|
+
() => e.value,
|
|
1612
|
+
(i) => {
|
|
1613
|
+
n.value = i ?? void 0;
|
|
1626
1614
|
},
|
|
1627
1615
|
{ immediate: !0 }
|
|
1628
1616
|
), $(
|
|
1629
|
-
() =>
|
|
1630
|
-
(
|
|
1631
|
-
|
|
1617
|
+
() => n.value,
|
|
1618
|
+
(i) => {
|
|
1619
|
+
t("update:value", i);
|
|
1632
1620
|
}
|
|
1633
|
-
), (
|
|
1634
|
-
|
|
1635
|
-
value:
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
y(l(L), {
|
|
1621
|
+
), (i, f) => (m(), _(_a, E({
|
|
1622
|
+
value: n.value,
|
|
1623
|
+
"onUpdate:value": f[0] || (f[0] = (p) => n.value = p)
|
|
1624
|
+
}, i.$attrs), {
|
|
1625
|
+
addonBefore: g(() => [
|
|
1626
|
+
y(l(z), {
|
|
1640
1627
|
class: "!w-4 !h-4",
|
|
1641
|
-
icon:
|
|
1628
|
+
icon: n.value
|
|
1642
1629
|
}, null, 8, ["icon"])
|
|
1643
1630
|
]),
|
|
1644
1631
|
_: 1
|
|
1645
1632
|
}, 16, ["value"]));
|
|
1646
1633
|
}
|
|
1647
|
-
}), rl = /* @__PURE__ */
|
|
1634
|
+
}), rl = /* @__PURE__ */ q(ba, [["__scopeId", "data-v-358b82ef"]]), ol = /* @__PURE__ */ S({
|
|
1648
1635
|
__name: "inputPassword",
|
|
1649
|
-
setup(
|
|
1650
|
-
const { editorCtrl: a, labelText:
|
|
1651
|
-
|
|
1636
|
+
setup(s) {
|
|
1637
|
+
const { editorCtrl: a, labelText: e, errInfo: t } = O(), n = () => {
|
|
1638
|
+
t != null && t.value.errClass && a && H(a);
|
|
1652
1639
|
};
|
|
1653
|
-
return (
|
|
1654
|
-
var
|
|
1640
|
+
return (i, f) => {
|
|
1641
|
+
var p;
|
|
1655
1642
|
return m(), _(l($t), E({
|
|
1656
|
-
class: ((
|
|
1643
|
+
class: ((p = l(t)) == null ? void 0 : p.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
|
|
1657
1644
|
"allow-clear": !0,
|
|
1658
1645
|
autocomplete: "new-password",
|
|
1659
|
-
placeholder: "请输入" + l(
|
|
1660
|
-
onBlur:
|
|
1661
|
-
},
|
|
1646
|
+
placeholder: "请输入" + l(e),
|
|
1647
|
+
onBlur: n
|
|
1648
|
+
}, i.$attrs), null, 16, ["class", "placeholder"]);
|
|
1662
1649
|
};
|
|
1663
1650
|
}
|
|
1664
|
-
}),
|
|
1651
|
+
}), nl = /* @__PURE__ */ S({
|
|
1665
1652
|
__name: "inputNumber",
|
|
1666
|
-
setup(
|
|
1667
|
-
const { editorCtrl: a, labelText:
|
|
1668
|
-
|
|
1653
|
+
setup(s) {
|
|
1654
|
+
const { editorCtrl: a, labelText: e, errInfo: t } = O(), n = () => {
|
|
1655
|
+
t != null && t.value.errClass && a && H(a);
|
|
1669
1656
|
};
|
|
1670
|
-
return (
|
|
1671
|
-
var
|
|
1657
|
+
return (i, f) => {
|
|
1658
|
+
var p;
|
|
1672
1659
|
return m(), _(l(Tt), E({
|
|
1673
|
-
class: [[((
|
|
1674
|
-
onBlur:
|
|
1660
|
+
class: [[((p = l(t)) == null ? void 0 : p.errClass) === "error" ? "error !border-red-300 shadow-[0_0_3px_0px_#ff4d4f]" : ""], "w-[50%]"],
|
|
1661
|
+
onBlur: n,
|
|
1675
1662
|
"allow-clear": !1,
|
|
1676
|
-
placeholder: "请输入" + l(
|
|
1677
|
-
},
|
|
1663
|
+
placeholder: "请输入" + l(e)
|
|
1664
|
+
}, i.$attrs), null, 16, ["class", "placeholder"]);
|
|
1678
1665
|
};
|
|
1679
1666
|
}
|
|
1680
|
-
}),
|
|
1667
|
+
}), xa = { class: "flex flex-col gap-2" }, ya = { key: 1 }, il = /* @__PURE__ */ S({
|
|
1681
1668
|
__name: "index",
|
|
1682
1669
|
props: {
|
|
1683
1670
|
value: {},
|
|
1671
|
+
selectList: {},
|
|
1672
|
+
fieldWidth: {},
|
|
1684
1673
|
labelHolder: {},
|
|
1685
|
-
valueHolder: {}
|
|
1674
|
+
valueHolder: {},
|
|
1675
|
+
addMore: { type: Boolean }
|
|
1686
1676
|
},
|
|
1687
1677
|
emits: ["update:value"],
|
|
1688
|
-
setup(
|
|
1689
|
-
const
|
|
1690
|
-
let
|
|
1678
|
+
setup(s, { emit: a }) {
|
|
1679
|
+
const e = s, t = a, n = b(e.selectList && e.selectList.length > 0 ? !1 : e.addMore ?? !0), i = b([]);
|
|
1680
|
+
let f = !1;
|
|
1691
1681
|
const p = () => {
|
|
1692
|
-
|
|
1682
|
+
e.selectList && e.selectList.length > 0 ? i.value = e.selectList.map((r) => ({
|
|
1683
|
+
id: Date.now() + Math.random(),
|
|
1684
|
+
text: r.text,
|
|
1685
|
+
field: r.field,
|
|
1686
|
+
// 如果value中有对应的field,使用value中的值,否则使用selectList中的默认值
|
|
1687
|
+
value: e.value[r.field] ?? r.value
|
|
1688
|
+
})) : e.value && Object.keys(e.value).length > 0 ? i.value = Object.entries(e.value).map(([r, v]) => ({
|
|
1693
1689
|
id: Date.now() + Math.random(),
|
|
1694
|
-
field:
|
|
1695
|
-
value:
|
|
1696
|
-
}));
|
|
1690
|
+
field: r,
|
|
1691
|
+
value: v
|
|
1692
|
+
})) : i.value = [];
|
|
1697
1693
|
};
|
|
1698
|
-
$(
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1694
|
+
$(
|
|
1695
|
+
() => e.value,
|
|
1696
|
+
() => {
|
|
1697
|
+
f || p(), f = !1;
|
|
1698
|
+
},
|
|
1699
|
+
{ immediate: !0 }
|
|
1700
|
+
);
|
|
1701
|
+
const d = () => {
|
|
1702
|
+
const r = i.value.reduce(
|
|
1703
|
+
(v, c) => (c.field && (v[c.field] = c.value), v),
|
|
1704
|
+
{}
|
|
1705
|
+
);
|
|
1706
|
+
f = !0, t("update:value", r);
|
|
1707
|
+
}, o = () => {
|
|
1708
|
+
i.value.push({
|
|
1706
1709
|
id: Date.now() + Math.random(),
|
|
1707
1710
|
field: "",
|
|
1708
1711
|
value: ""
|
|
1709
1712
|
});
|
|
1710
|
-
},
|
|
1711
|
-
|
|
1713
|
+
}, u = () => {
|
|
1714
|
+
d();
|
|
1712
1715
|
};
|
|
1713
|
-
return (
|
|
1714
|
-
(m(!0),
|
|
1715
|
-
key:
|
|
1716
|
+
return (r, v) => (m(), w("div", xa, [
|
|
1717
|
+
(m(!0), w(A, null, L(i.value, (c) => (m(), w("div", {
|
|
1718
|
+
key: c.id,
|
|
1716
1719
|
class: "flex items-center gap-2"
|
|
1717
1720
|
}, [
|
|
1718
|
-
T("div",
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1721
|
+
T("div", {
|
|
1722
|
+
class: M([r.fieldWidth ? `w-[${r.fieldWidth}%]` : "w-[33%]"])
|
|
1723
|
+
}, [
|
|
1724
|
+
!r.selectList || r.selectList.length === 0 ? (m(), _(l(ee), {
|
|
1725
|
+
key: 0,
|
|
1726
|
+
value: c.field,
|
|
1727
|
+
"onUpdate:value": (h) => c.field = h,
|
|
1728
|
+
title: c.text || c.field,
|
|
1723
1729
|
class: "w-full",
|
|
1724
|
-
placeholder:
|
|
1725
|
-
onInput:
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1730
|
+
placeholder: c.text || r.labelHolder || "配置名",
|
|
1731
|
+
onInput: u,
|
|
1732
|
+
disabled: !n.value
|
|
1733
|
+
}, null, 8, ["value", "onUpdate:value", "title", "placeholder", "disabled"])) : (m(), w("div", ya, [
|
|
1734
|
+
y(l(ee), {
|
|
1735
|
+
value: c.text,
|
|
1736
|
+
"onUpdate:value": (h) => c.text = h,
|
|
1737
|
+
title: c.text,
|
|
1738
|
+
disabled: !0,
|
|
1739
|
+
class: "w-[100%]"
|
|
1740
|
+
}, null, 8, ["value", "onUpdate:value", "title"]),
|
|
1741
|
+
y(l(ee), {
|
|
1742
|
+
type: "hidden",
|
|
1743
|
+
value: c.field,
|
|
1744
|
+
"onUpdate:value": (h) => c.field = h
|
|
1745
|
+
}, null, 8, ["value", "onUpdate:value"])
|
|
1746
|
+
]))
|
|
1747
|
+
], 2),
|
|
1748
|
+
v[0] || (v[0] = T("div", { class: "w-[3%]" }, "=", -1)),
|
|
1749
|
+
T("div", {
|
|
1750
|
+
class: M([r.fieldWidth ? `w-[${97 - r.fieldWidth}%]` : "w-[64%]"])
|
|
1751
|
+
}, [
|
|
1752
|
+
y(l(ee), {
|
|
1753
|
+
value: c.value,
|
|
1754
|
+
"onUpdate:value": (h) => c.value = h,
|
|
1755
|
+
placeholder: r.valueHolder || "请输入" + c.text || "请输入配置值",
|
|
1756
|
+
onInput: u,
|
|
1757
|
+
title: c.value
|
|
1736
1758
|
}, null, 8, ["value", "onUpdate:value", "placeholder", "title"])
|
|
1737
|
-
])
|
|
1759
|
+
], 2)
|
|
1738
1760
|
]))), 128)),
|
|
1739
|
-
|
|
1740
|
-
|
|
1761
|
+
n.value ? (m(), _(l(Ye), {
|
|
1762
|
+
key: 0,
|
|
1763
|
+
onClick: o,
|
|
1741
1764
|
class: "mt-1 w-[80px] !text-[12px] text-[#666] bg-[#e6f7ff] border-[#b3e0ff] hover:bg-[#b3e0ff] hover:border-[#8abeff]",
|
|
1742
1765
|
size: "small"
|
|
1743
1766
|
}, {
|
|
1744
|
-
default:
|
|
1767
|
+
default: g(() => v[1] || (v[1] = [
|
|
1745
1768
|
N(" 新增配置行 ")
|
|
1746
1769
|
])),
|
|
1747
1770
|
_: 1,
|
|
1748
1771
|
__: [1]
|
|
1749
|
-
})
|
|
1772
|
+
})) : k("", !0)
|
|
1750
1773
|
]));
|
|
1751
1774
|
}
|
|
1752
|
-
}), ka = /* @__PURE__ */
|
|
1775
|
+
}), ka = /* @__PURE__ */ q(ct, [["__scopeId", "data-v-08c7f643"]]), cl = /* @__PURE__ */ S({
|
|
1753
1776
|
__name: "radioStatus",
|
|
1754
1777
|
props: {
|
|
1755
1778
|
/**
|
|
@@ -1776,14 +1799,14 @@ const ll = /* @__PURE__ */ w({
|
|
|
1776
1799
|
required: !1
|
|
1777
1800
|
}
|
|
1778
1801
|
},
|
|
1779
|
-
setup(
|
|
1780
|
-
const a =
|
|
1781
|
-
return a.all === !0 &&
|
|
1802
|
+
setup(s) {
|
|
1803
|
+
const a = s, e = b(JSON.parse(JSON.stringify(Me.getOptions(a.dataKey))));
|
|
1804
|
+
return a.all === !0 && e.value.unshift({
|
|
1782
1805
|
label: "全部",
|
|
1783
1806
|
value: a.allValue || [0, 1]
|
|
1784
|
-
}), (
|
|
1807
|
+
}), (t, n) => (m(), _(ka, { data: e.value }, null, 8, ["data"]));
|
|
1785
1808
|
}
|
|
1786
|
-
}),
|
|
1809
|
+
}), ul = /* @__PURE__ */ S({
|
|
1787
1810
|
__name: "index",
|
|
1788
1811
|
props: {
|
|
1789
1812
|
startDate: {},
|
|
@@ -1791,55 +1814,55 @@ const ll = /* @__PURE__ */ w({
|
|
|
1791
1814
|
valueFormat: { default: "YYYY-MM-DD" }
|
|
1792
1815
|
},
|
|
1793
1816
|
emits: ["update:startDate", "update:endDate"],
|
|
1794
|
-
setup(
|
|
1795
|
-
const
|
|
1796
|
-
const
|
|
1797
|
-
if (!(!
|
|
1817
|
+
setup(s, { emit: a }) {
|
|
1818
|
+
const e = s, t = a, n = O(), { errInfo: i } = n, f = X(() => e.valueFormat), p = X(() => {
|
|
1819
|
+
const o = e.startDate, u = e.endDate;
|
|
1820
|
+
if (!(!o || !u))
|
|
1798
1821
|
try {
|
|
1799
|
-
const
|
|
1800
|
-
return !
|
|
1822
|
+
const r = pe(o), v = pe(u);
|
|
1823
|
+
return !r.isValid() || !v.isValid() ? void 0 : [r, v];
|
|
1801
1824
|
} catch {
|
|
1802
1825
|
return;
|
|
1803
1826
|
}
|
|
1804
|
-
}),
|
|
1805
|
-
if (!
|
|
1806
|
-
|
|
1827
|
+
}), d = (o, u) => {
|
|
1828
|
+
if (!o || !u || u.length !== 2) {
|
|
1829
|
+
t("update:startDate", null), t("update:endDate", null);
|
|
1807
1830
|
return;
|
|
1808
1831
|
}
|
|
1809
|
-
|
|
1832
|
+
t("update:startDate", u[0] || null), t("update:endDate", u[1] || null);
|
|
1810
1833
|
};
|
|
1811
|
-
return (
|
|
1812
|
-
var
|
|
1834
|
+
return (o, u) => {
|
|
1835
|
+
var r;
|
|
1813
1836
|
return m(), _(l(It), {
|
|
1814
|
-
class: M([((
|
|
1837
|
+
class: M([((r = l(i)) == null ? void 0 : r.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "", "w-full"]),
|
|
1815
1838
|
locale: l(xe),
|
|
1816
|
-
"value-format":
|
|
1817
|
-
value:
|
|
1818
|
-
onChange:
|
|
1839
|
+
"value-format": f.value,
|
|
1840
|
+
value: p.value,
|
|
1841
|
+
onChange: d
|
|
1819
1842
|
}, null, 8, ["class", "locale", "value-format", "value"]);
|
|
1820
1843
|
};
|
|
1821
1844
|
}
|
|
1822
|
-
}),
|
|
1845
|
+
}), dl = /* @__PURE__ */ q(ut, [["__scopeId", "data-v-806f87b8"]]), pl = /* @__PURE__ */ S({
|
|
1823
1846
|
__name: "index",
|
|
1824
|
-
setup(
|
|
1825
|
-
const { editorCtrl: a, labelText:
|
|
1826
|
-
|
|
1847
|
+
setup(s) {
|
|
1848
|
+
const { editorCtrl: a, labelText: e, errInfo: t } = O(), n = () => {
|
|
1849
|
+
t != null && t.value.errClass && a && H(a);
|
|
1827
1850
|
};
|
|
1828
|
-
return (
|
|
1829
|
-
var
|
|
1830
|
-
return m(), _(l(
|
|
1831
|
-
class: ((
|
|
1851
|
+
return (i, f) => {
|
|
1852
|
+
var p;
|
|
1853
|
+
return m(), _(l(Dt), E({
|
|
1854
|
+
class: ((p = l(t)) == null ? void 0 : p.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
|
|
1832
1855
|
"allow-clear": !0,
|
|
1833
|
-
placeholder: "请输入" + l(
|
|
1834
|
-
onBlur:
|
|
1835
|
-
onKeyup:
|
|
1856
|
+
placeholder: "请输入" + l(e),
|
|
1857
|
+
onBlur: n,
|
|
1858
|
+
onKeyup: f[0] || (f[0] = Se(te(() => {
|
|
1836
1859
|
}, ["stop"]), ["enter", "native"])),
|
|
1837
|
-
onKeydown:
|
|
1860
|
+
onKeydown: f[1] || (f[1] = Se(te(() => {
|
|
1838
1861
|
}, ["stop"]), ["enter", "native"]))
|
|
1839
|
-
},
|
|
1862
|
+
}, i.$attrs), null, 16, ["class", "placeholder"]);
|
|
1840
1863
|
};
|
|
1841
1864
|
}
|
|
1842
|
-
}), wa = /* @__PURE__ */
|
|
1865
|
+
}), wa = /* @__PURE__ */ S({
|
|
1843
1866
|
__name: "index",
|
|
1844
1867
|
props: {
|
|
1845
1868
|
autoload: { type: Boolean },
|
|
@@ -1848,43 +1871,43 @@ const ll = /* @__PURE__ */ w({
|
|
|
1848
1871
|
value: {}
|
|
1849
1872
|
},
|
|
1850
1873
|
emits: ["change", "update:value"],
|
|
1851
|
-
setup(
|
|
1852
|
-
const
|
|
1853
|
-
|
|
1854
|
-
|
|
1874
|
+
setup(s, { emit: a }) {
|
|
1875
|
+
const e = s, t = b({ ...e.url }), { editorCtrl: n, labelText: i, errInfo: f } = O(), p = a, d = b([]), o = b([]);
|
|
1876
|
+
e.value && e.value.every((r) => {
|
|
1877
|
+
o.value.push(r.toString());
|
|
1855
1878
|
}), $(
|
|
1856
|
-
() =>
|
|
1857
|
-
(
|
|
1858
|
-
|
|
1879
|
+
() => e.value,
|
|
1880
|
+
(r) => {
|
|
1881
|
+
r && (o.value = r);
|
|
1859
1882
|
}
|
|
1860
1883
|
);
|
|
1861
|
-
const
|
|
1862
|
-
|
|
1884
|
+
const u = (r) => {
|
|
1885
|
+
p("update:value", r), p("change", r), o.value = r, f != null && f.value.errClass && n && H(n);
|
|
1863
1886
|
};
|
|
1864
|
-
return
|
|
1865
|
-
if (
|
|
1866
|
-
const
|
|
1867
|
-
if (
|
|
1868
|
-
const v = await
|
|
1887
|
+
return Y(async () => {
|
|
1888
|
+
if (t.value) {
|
|
1889
|
+
const r = n == null ? void 0 : n.page;
|
|
1890
|
+
if (t.value.api || (t.value.api = r == null ? void 0 : r.api), t.value.authorize === void 0 && (t.value.authorize = r == null ? void 0 : r.authorize), e.autoload) {
|
|
1891
|
+
const v = await Re(n, {
|
|
1869
1892
|
urlKey: "list",
|
|
1870
|
-
url: { ...
|
|
1893
|
+
url: { ...t.value, url: t.value.url },
|
|
1871
1894
|
loadingText: !1,
|
|
1872
|
-
params:
|
|
1895
|
+
params: e.params
|
|
1873
1896
|
});
|
|
1874
|
-
|
|
1897
|
+
d.value = (v == null ? void 0 : v.data) ?? [];
|
|
1875
1898
|
}
|
|
1876
1899
|
}
|
|
1877
|
-
}), (
|
|
1878
|
-
var
|
|
1879
|
-
return m(), _(l(
|
|
1880
|
-
class: ((
|
|
1881
|
-
placeholder: "请输入" + l(
|
|
1882
|
-
targetKeys:
|
|
1883
|
-
onChange:
|
|
1884
|
-
},
|
|
1885
|
-
children:
|
|
1886
|
-
D(
|
|
1887
|
-
direction:
|
|
1900
|
+
}), (r, v) => {
|
|
1901
|
+
var c;
|
|
1902
|
+
return m(), _(l(Pt), E({
|
|
1903
|
+
class: ((c = l(f)) == null ? void 0 : c.errClass) === "error" ? ["error", "!border-red-300", "shadow-[0_0_3px_0px_#ff4d4f]"] : "",
|
|
1904
|
+
placeholder: "请输入" + l(i),
|
|
1905
|
+
targetKeys: o.value,
|
|
1906
|
+
onChange: u
|
|
1907
|
+
}, r.$attrs), {
|
|
1908
|
+
children: g(({ direction: h, disabled: C, filteredItems: I, onItemSelectAll: P, onItemSelect: x, selectedKeys: R }) => [
|
|
1909
|
+
D(r.$slots, "children", {
|
|
1910
|
+
direction: h,
|
|
1888
1911
|
disabled: C,
|
|
1889
1912
|
filteredItems: I,
|
|
1890
1913
|
onItemSelectAll: P,
|
|
@@ -1896,7 +1919,7 @@ const ll = /* @__PURE__ */ w({
|
|
|
1896
1919
|
}, 16, ["class", "placeholder", "targetKeys"]);
|
|
1897
1920
|
};
|
|
1898
1921
|
}
|
|
1899
|
-
}),
|
|
1922
|
+
}), fl = /* @__PURE__ */ S({
|
|
1900
1923
|
__name: "transferTable",
|
|
1901
1924
|
props: {
|
|
1902
1925
|
/**
|
|
@@ -1922,79 +1945,79 @@ const ll = /* @__PURE__ */ w({
|
|
|
1922
1945
|
}
|
|
1923
1946
|
},
|
|
1924
1947
|
emits: ["update:value"],
|
|
1925
|
-
setup(
|
|
1926
|
-
const
|
|
1948
|
+
setup(s, { emit: a }) {
|
|
1949
|
+
const e = s, t = a, n = b(e.autoload), i = b(e.value), f = b(e.gridCtrl.primaryKey);
|
|
1927
1950
|
$(
|
|
1928
|
-
() =>
|
|
1929
|
-
(
|
|
1930
|
-
|
|
1951
|
+
() => i.value,
|
|
1952
|
+
(o) => {
|
|
1953
|
+
t("update:value", o);
|
|
1931
1954
|
}
|
|
1932
1955
|
), $(
|
|
1933
|
-
() =>
|
|
1934
|
-
(
|
|
1935
|
-
|
|
1956
|
+
() => e.value,
|
|
1957
|
+
(o) => {
|
|
1958
|
+
o && (i.value = o);
|
|
1936
1959
|
}
|
|
1937
|
-
),
|
|
1938
|
-
const
|
|
1939
|
-
getCheckboxProps: (
|
|
1960
|
+
), e.gridCtrl.autoload = !1, e.gridCtrl.remotePage = !1, e.gridCtrl.selectable = b(!0), e.gridCtrl.buttons = b([]), e.gridCtrl.tools = [];
|
|
1961
|
+
const p = ({ disabled: o, selectedKeys: u, onItemSelectAll: r, onItemSelect: v }) => ({
|
|
1962
|
+
getCheckboxProps: (c) => ({
|
|
1940
1963
|
// 控制是否禁止
|
|
1941
|
-
disabled:
|
|
1964
|
+
disabled: o || c.disabled
|
|
1942
1965
|
}),
|
|
1943
|
-
onSelectAll(
|
|
1944
|
-
const C =
|
|
1945
|
-
|
|
1966
|
+
onSelectAll(c, h) {
|
|
1967
|
+
const C = h.filter((I) => !I.disabled).map(({ [f.value]: I }) => I);
|
|
1968
|
+
r(C, c);
|
|
1946
1969
|
},
|
|
1947
|
-
onSelect({ [
|
|
1948
|
-
v(
|
|
1970
|
+
onSelect({ [f.value]: c }, h) {
|
|
1971
|
+
v(c, h);
|
|
1949
1972
|
},
|
|
1950
|
-
selectedRowKeys:
|
|
1951
|
-
}),
|
|
1952
|
-
return
|
|
1953
|
-
if (
|
|
1954
|
-
const
|
|
1973
|
+
selectedRowKeys: u
|
|
1974
|
+
}), d = b([]);
|
|
1975
|
+
return Y(async () => {
|
|
1976
|
+
if (n.value) {
|
|
1977
|
+
const o = await Re(e.gridCtrl, {
|
|
1955
1978
|
urlKey: "list",
|
|
1956
|
-
url: { ...
|
|
1957
|
-
params:
|
|
1979
|
+
url: { ...e.gridCtrl.gridUrl, url: e.gridCtrl.gridUrl.url },
|
|
1980
|
+
params: e.gridCtrl.gridQuery,
|
|
1958
1981
|
loadingText: !1
|
|
1959
1982
|
});
|
|
1960
|
-
|
|
1983
|
+
d.value = (o == null ? void 0 : o.data) ?? [];
|
|
1961
1984
|
}
|
|
1962
|
-
}), (
|
|
1963
|
-
"data-source":
|
|
1964
|
-
"row-key": (
|
|
1965
|
-
value:
|
|
1966
|
-
"onUpdate:value":
|
|
1985
|
+
}), (o, u) => (m(), _(wa, E({
|
|
1986
|
+
"data-source": d.value,
|
|
1987
|
+
"row-key": (r) => r[f.value],
|
|
1988
|
+
value: i.value,
|
|
1989
|
+
"onUpdate:value": u[0] || (u[0] = (r) => i.value = r),
|
|
1967
1990
|
"list-style": {
|
|
1968
1991
|
width: "300px",
|
|
1969
1992
|
height: "500px"
|
|
1970
1993
|
},
|
|
1971
1994
|
"show-select-all": !1,
|
|
1972
1995
|
"show-search": !0,
|
|
1973
|
-
"filter-option": (
|
|
1974
|
-
for (const
|
|
1975
|
-
if (v[
|
|
1996
|
+
"filter-option": (r, v) => {
|
|
1997
|
+
for (const c of e.gridCtrl.columns.value)
|
|
1998
|
+
if (v[c.dataIndex].toString().indexOf(r) !== -1)
|
|
1976
1999
|
return !0;
|
|
1977
2000
|
return !1;
|
|
1978
2001
|
}
|
|
1979
|
-
},
|
|
1980
|
-
children:
|
|
1981
|
-
y(l(
|
|
1982
|
-
columns:
|
|
1983
|
-
"row-key":
|
|
1984
|
-
"row-selection":
|
|
2002
|
+
}, o.$attrs), {
|
|
2003
|
+
children: g(({ filteredItems: r, onItemSelectAll: v, onItemSelect: c, selectedKeys: h }) => [
|
|
2004
|
+
y(l(We), {
|
|
2005
|
+
columns: s.gridCtrl.columns.value,
|
|
2006
|
+
"row-key": f.value,
|
|
2007
|
+
"row-selection": p({
|
|
1985
2008
|
disabled: !1,
|
|
1986
|
-
selectedKeys:
|
|
2009
|
+
selectedKeys: h,
|
|
1987
2010
|
onItemSelectAll: v,
|
|
1988
|
-
onItemSelect:
|
|
2011
|
+
onItemSelect: c
|
|
1989
2012
|
}),
|
|
1990
2013
|
bordered: !1,
|
|
1991
2014
|
size: "small",
|
|
1992
|
-
"data-source":
|
|
2015
|
+
"data-source": r,
|
|
1993
2016
|
scroll: { x: 300 },
|
|
1994
2017
|
"custom-row": (C) => ({
|
|
1995
2018
|
onClick: () => {
|
|
1996
|
-
const I = C[
|
|
1997
|
-
|
|
2019
|
+
const I = C[f.value];
|
|
2020
|
+
c(I, !h.includes(I));
|
|
1998
2021
|
}
|
|
1999
2022
|
})
|
|
2000
2023
|
}, null, 8, ["columns", "row-key", "row-selection", "data-source", "custom-row"])
|
|
@@ -2002,7 +2025,7 @@ const ll = /* @__PURE__ */ w({
|
|
|
2002
2025
|
_: 1
|
|
2003
2026
|
}, 16, ["data-source", "row-key", "value", "filter-option"]));
|
|
2004
2027
|
}
|
|
2005
|
-
}),
|
|
2028
|
+
}), Sa = /* @__PURE__ */ S({
|
|
2006
2029
|
__name: "index",
|
|
2007
2030
|
props: {
|
|
2008
2031
|
multiple: {
|
|
@@ -2019,72 +2042,72 @@ const ll = /* @__PURE__ */ w({
|
|
|
2019
2042
|
}
|
|
2020
2043
|
},
|
|
2021
2044
|
emits: ["change", "update:value"],
|
|
2022
|
-
setup(
|
|
2023
|
-
const
|
|
2024
|
-
|
|
2025
|
-
const
|
|
2045
|
+
setup(s, { emit: a }) {
|
|
2046
|
+
const e = s, t = e.treeCtrl, n = O(), { errInfo: i, labelText: f } = n, p = a;
|
|
2047
|
+
n.inputEmit = p;
|
|
2048
|
+
const d = b([]), o = b();
|
|
2026
2049
|
$(
|
|
2027
|
-
() =>
|
|
2028
|
-
(
|
|
2029
|
-
|
|
2050
|
+
() => e.value,
|
|
2051
|
+
(r) => {
|
|
2052
|
+
o.value = r ?? null;
|
|
2030
2053
|
},
|
|
2031
2054
|
{ immediate: !0 }
|
|
2032
2055
|
), $(
|
|
2033
|
-
() =>
|
|
2034
|
-
(
|
|
2035
|
-
|
|
2056
|
+
() => t.data.value,
|
|
2057
|
+
(r) => {
|
|
2058
|
+
r && (d.value = t.fieldMap ? re(t.fieldMap, r) : r);
|
|
2036
2059
|
},
|
|
2037
2060
|
{ immediate: !0 }
|
|
2038
2061
|
);
|
|
2039
|
-
const
|
|
2040
|
-
|
|
2062
|
+
const u = (r) => {
|
|
2063
|
+
e.multiple ? o.value = r ?? [] : o.value = r ?? "", p("change", o.value), p("update:value", o.value);
|
|
2041
2064
|
};
|
|
2042
|
-
return
|
|
2043
|
-
|
|
2065
|
+
return Y(() => {
|
|
2066
|
+
t.fieldMap || (t.fieldMap = {
|
|
2044
2067
|
label: "Name",
|
|
2045
2068
|
key: "Id",
|
|
2046
2069
|
value: "Id"
|
|
2047
|
-
}),
|
|
2048
|
-
}), (
|
|
2049
|
-
var
|
|
2070
|
+
}), t.data.value ? d.value = t.fieldMap ? re(t.fieldMap, t.data.value) : t.data.value : e.treeCtrl.autoload && Ne(e.treeCtrl);
|
|
2071
|
+
}), (r, v) => {
|
|
2072
|
+
var c;
|
|
2050
2073
|
return m(), _(l(Et), E({
|
|
2051
|
-
class: [[(
|
|
2074
|
+
class: [[(c = l(i)) == null ? void 0 : c.errClass], "w-full"],
|
|
2052
2075
|
"tree-line": "",
|
|
2053
|
-
multiple:
|
|
2076
|
+
multiple: s.multiple,
|
|
2054
2077
|
"tree-default-expanded-keys": ["-"],
|
|
2055
|
-
value:
|
|
2056
|
-
"onUpdate:value": v[0] || (v[0] = (
|
|
2057
|
-
"tree-data":
|
|
2058
|
-
placeholder: "请选择" + l(
|
|
2078
|
+
value: o.value,
|
|
2079
|
+
"onUpdate:value": v[0] || (v[0] = (h) => o.value = h),
|
|
2080
|
+
"tree-data": d.value,
|
|
2081
|
+
placeholder: "请选择" + l(f),
|
|
2059
2082
|
"allow-clear": !0,
|
|
2060
|
-
onChange:
|
|
2061
|
-
},
|
|
2083
|
+
onChange: u
|
|
2084
|
+
}, r.$attrs), null, 16, ["class", "multiple", "value", "tree-data", "placeholder"]);
|
|
2062
2085
|
};
|
|
2063
2086
|
}
|
|
2064
|
-
}),
|
|
2087
|
+
}), vl = /* @__PURE__ */ q(Sa, [["__scopeId", "data-v-f000d1d0"]]), Ca = { class: "relative h-[calc(100vh-80px)] overflow-y-auto" }, $a = { class: "flex w-full h-full min-h-full" }, Ta = {
|
|
2065
2088
|
key: 0,
|
|
2066
2089
|
class: "w-1/4 pr-4 min-h-full min-w-[170px] max-w-[200px]"
|
|
2067
|
-
}, Ia = { class: "flex-1 h-full overflow-y-auto" },
|
|
2090
|
+
}, Ia = { class: "flex-1 h-full overflow-y-auto" }, ml = /* @__PURE__ */ S({
|
|
2068
2091
|
__name: "index",
|
|
2069
2092
|
props: {
|
|
2070
2093
|
left: { type: Boolean }
|
|
2071
2094
|
},
|
|
2072
|
-
setup(
|
|
2073
|
-
const { useToken: a } =
|
|
2074
|
-
return (
|
|
2095
|
+
setup(s) {
|
|
2096
|
+
const { useToken: a } = Le, { token: e } = a();
|
|
2097
|
+
return (t, n) => (m(), w("div", Ca, [
|
|
2075
2098
|
y(l(Ft), {
|
|
2076
2099
|
class: "m-[10px] p-[10px] h-[calc(100vh-100px)] !min-h-[calc(100vh-100px)]",
|
|
2077
|
-
style:
|
|
2078
|
-
backgroundColor: l(
|
|
2100
|
+
style: ce({
|
|
2101
|
+
backgroundColor: l(e).colorBgContainer
|
|
2079
2102
|
})
|
|
2080
2103
|
}, {
|
|
2081
|
-
default:
|
|
2104
|
+
default: g(() => [
|
|
2082
2105
|
T("div", $a, [
|
|
2083
|
-
|
|
2084
|
-
D(
|
|
2106
|
+
t.left ? (m(), w("div", Ta, [
|
|
2107
|
+
D(t.$slots, "left")
|
|
2085
2108
|
])) : k("", !0),
|
|
2086
2109
|
T("div", Ia, [
|
|
2087
|
-
D(
|
|
2110
|
+
D(t.$slots, "default")
|
|
2088
2111
|
])
|
|
2089
2112
|
])
|
|
2090
2113
|
]),
|
|
@@ -2094,145 +2117,146 @@ const ll = /* @__PURE__ */ w({
|
|
|
2094
2117
|
}
|
|
2095
2118
|
});
|
|
2096
2119
|
export {
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2120
|
+
ws as AppIcon,
|
|
2121
|
+
ie as AppRouter,
|
|
2122
|
+
ls as AsyncUploader,
|
|
2123
|
+
tl as AutoComplete,
|
|
2124
|
+
Ss as Breadcrumb,
|
|
2125
|
+
B as Button,
|
|
2126
|
+
je as Cache,
|
|
2127
|
+
jt as CacheKeys,
|
|
2128
|
+
al as Cascader,
|
|
2129
|
+
ll as Checkbox,
|
|
2130
|
+
ml as Content,
|
|
2131
|
+
sl as DatePicker,
|
|
2132
|
+
Cs as Datetime,
|
|
2133
|
+
Ms as Dialog,
|
|
2111
2134
|
qa as Drawer,
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2135
|
+
_l as EventPrefix,
|
|
2136
|
+
Ga as Form,
|
|
2137
|
+
Ja as FormItem,
|
|
2115
2138
|
ja as Fullscreen,
|
|
2116
|
-
|
|
2117
|
-
|
|
2139
|
+
$s as Header,
|
|
2140
|
+
Ts as HeaderExits,
|
|
2118
2141
|
Qt as Helper,
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2142
|
+
bl as ICONS_LIB,
|
|
2143
|
+
Is as Icon,
|
|
2144
|
+
oa as Icontool,
|
|
2145
|
+
_a as Input,
|
|
2123
2146
|
rl as InputIcon,
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2147
|
+
nl as InputNumber,
|
|
2148
|
+
ol as InputPassword,
|
|
2149
|
+
Ha as LayoutIcon,
|
|
2150
|
+
Qa as Loading,
|
|
2151
|
+
Ds as Menu,
|
|
2152
|
+
Ps as MenuTabs,
|
|
2153
|
+
Me as OPTIONS,
|
|
2154
|
+
st as OptionCommProps,
|
|
2155
|
+
Es as ProjectIcon,
|
|
2156
|
+
il as PropEditor,
|
|
2157
|
+
V as ProviderKeys,
|
|
2134
2158
|
ka as Radio,
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2159
|
+
cl as RadioStatus,
|
|
2160
|
+
ul as RangePicker,
|
|
2161
|
+
Xa as Search,
|
|
2162
|
+
de as SearchItem,
|
|
2163
|
+
dl as Select,
|
|
2164
|
+
Nt as Switch,
|
|
2165
|
+
Za as Table,
|
|
2166
|
+
sa as TableOperate,
|
|
2167
|
+
pl as Textarea,
|
|
2168
|
+
z as ToolIcon,
|
|
2169
|
+
ua as Toolbar,
|
|
2170
|
+
ys as Tooltip,
|
|
2147
2171
|
wa as Transfer,
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
kl as
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2172
|
+
fl as TransferTable,
|
|
2173
|
+
el as Tree,
|
|
2174
|
+
vl as TreeSelect,
|
|
2175
|
+
fs as UploadList,
|
|
2176
|
+
ss as UploadStatus,
|
|
2177
|
+
hs as appendExcelData,
|
|
2178
|
+
gs as checkExcelDuplicates,
|
|
2179
|
+
xl as checkIconsExpired,
|
|
2180
|
+
nt as circleLoading,
|
|
2181
|
+
qe as createFromIconfont,
|
|
2182
|
+
yl as crumbs,
|
|
2183
|
+
De as defaultTools,
|
|
2184
|
+
kl as doDelete,
|
|
2185
|
+
wl as doExecute,
|
|
2186
|
+
Re as doQuery,
|
|
2187
|
+
Sl as doSave,
|
|
2188
|
+
vs as donwloadFromMinio,
|
|
2189
|
+
Ke as downloadBlob,
|
|
2165
2190
|
Cl as eventBus,
|
|
2166
|
-
|
|
2191
|
+
Va as exportResults,
|
|
2167
2192
|
Ka as exportSelectedRows,
|
|
2168
2193
|
Fe as filterColumns,
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2194
|
+
H as formValidate,
|
|
2195
|
+
rs as getAppInfo,
|
|
2196
|
+
$l as getFormDetail,
|
|
2197
|
+
os as getHostInfo,
|
|
2198
|
+
Tl as getIconTransform,
|
|
2199
|
+
Il as getRecordDetail,
|
|
2200
|
+
Dl as getRuleTexts,
|
|
2176
2201
|
Pl as getSelectedLabels,
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2202
|
+
El as getSelectedValues,
|
|
2203
|
+
ns as getToken,
|
|
2204
|
+
W as getToolByKey,
|
|
2180
2205
|
be as getToolGroup,
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
|
|
2206
|
+
K as getToolStatus,
|
|
2207
|
+
J as getToolVisible,
|
|
2208
|
+
is as getUserInfo,
|
|
2184
2209
|
ke as gridQueryFind,
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2210
|
+
tt as gridQueryList,
|
|
2211
|
+
Fl as gridRowUpdate,
|
|
2212
|
+
at as gridStatusUpdate,
|
|
2213
|
+
Wa as initCacheCheck,
|
|
2189
2214
|
Ya as initDirective,
|
|
2190
|
-
|
|
2215
|
+
Ml as initMenu,
|
|
2191
2216
|
Nl as initPageFactory,
|
|
2192
2217
|
Rl as initValidate,
|
|
2193
|
-
|
|
2194
|
-
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
Bl as outFormDataFields,
|
|
2218
|
+
Z as isEmpty,
|
|
2219
|
+
rt as loadOption,
|
|
2220
|
+
Al as mergeColumns,
|
|
2221
|
+
Kt as onColumnVisibleChanged,
|
|
2222
|
+
Je as onFormClose,
|
|
2223
|
+
Pe as onFormSave,
|
|
2224
|
+
Ge as onFormSaveAs,
|
|
2225
|
+
Ve as onFullscreenClick,
|
|
2226
|
+
Ze as onGridRowDelete,
|
|
2227
|
+
Xe as onGridRowEdit,
|
|
2228
|
+
Bl as onGridRowExpand,
|
|
2229
|
+
Ol as onOptionChanged,
|
|
2230
|
+
Bt as onReloadClick,
|
|
2231
|
+
U as onToolClicked,
|
|
2232
|
+
et as openNewForm,
|
|
2233
|
+
Ll as outFormDataFields,
|
|
2210
2234
|
zl as parseIcons,
|
|
2211
|
-
|
|
2235
|
+
cs as path,
|
|
2212
2236
|
Ul as pendingNavigation,
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2237
|
+
Yl as pinia,
|
|
2238
|
+
_s as processExcelFile,
|
|
2239
|
+
Ne as queryTree,
|
|
2240
|
+
Wl as resetRules,
|
|
2241
|
+
Kl as routes,
|
|
2242
|
+
Vl as saveForm,
|
|
2243
|
+
jl as setFormData,
|
|
2244
|
+
Hl as showBreadcrumb,
|
|
2245
|
+
ot as unloadOption,
|
|
2222
2246
|
Ql as useAppInfo,
|
|
2223
2247
|
ql as useEditorFactory,
|
|
2224
2248
|
Ee as useFormItemFactory,
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2249
|
+
Gl as useGridFactory,
|
|
2250
|
+
Jl as useHostInfo,
|
|
2251
|
+
O as useInputFactory,
|
|
2252
|
+
Xl as usePageFactory,
|
|
2253
|
+
Zl as usePageInfo,
|
|
2230
2254
|
ve as useSettingInfo,
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2255
|
+
Vt as useToolFactory,
|
|
2256
|
+
es as useTreeFactory,
|
|
2257
|
+
Qe as useUserInfo,
|
|
2258
|
+
us as userLogin,
|
|
2259
|
+
ds as userLogout,
|
|
2260
|
+
ts as validateData,
|
|
2261
|
+
bs as validateExcel
|
|
2238
2262
|
};
|