@okiss/oms 0.0.91 → 0.0.93
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +1277 -1199
- package/dist/index.es.js.map +1 -1
- package/dist/oms.css +1 -1
- package/dist/style.css +1 -1
- package/package.json +3 -3
package/dist/index.es.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { ref as
|
|
2
|
-
import { normalizeTheme as
|
|
3
|
-
import { defineStore as Ce, createPinia as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
1
|
+
import { ref as C, watch as ye, computed as k, defineComponent as z, onBeforeMount as Ge, provide as _o, resolveComponent as P, createBlock as m, openBlock as i, createVNode as u, createTextVNode as T, withCtx as r, TransitionGroup as vo, createElementBlock as v, Fragment as A, renderList as V, toDisplayString as B, normalizeClass as te, renderSlot as pe, createCommentVNode as $, mergeProps as X, toRefs as go, unref as h, isRef as Ke, onMounted as Ie, normalizeStyle as ko, createElementVNode as _, withKeys as ut, withModifiers as Ne, resolveDynamicComponent as ze, Transition as xt, normalizeProps as Z, guardReactiveProps as ce, onUnmounted as So, resolveDirective as wo, withDirectives as xo, getCurrentInstance as Eo, h as Io, toRaw as Co, createApp as To } from "vue";
|
|
2
|
+
import { normalizeTheme as fe, applyDocumentTheme as Oo, dispatchThemeChange as $o, addNewStyle as Bo, addNewStyleTag as Ao, queryParams as Ro, logGroup as Po, compactObject as Et, showEleByClassName as It, waterMarker as Lo, Cache as ke, isExternal as dt, getQueryParam as Ct, createIFrame as Mo, strVarReplace as ie, obj2Param as Do, isObject as re, isString as Je, effectDataTrans as jo, isArray as Tt } from "@okiss/utils";
|
|
3
|
+
import { defineStore as Ce, createPinia as No } from "pinia";
|
|
4
|
+
import oe from "js-cookie";
|
|
5
|
+
import Ot from "element-plus/es/locale/lang/zh-cn";
|
|
6
|
+
import Vo, { cloneDeep as E, merge as q, get as me, unset as $t, isObject as Uo } from "lodash";
|
|
7
7
|
import Re from "mockjs";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import "element-plus/
|
|
11
|
-
import "element-plus/theme-chalk/dark/css-vars.
|
|
8
|
+
import We from "axios";
|
|
9
|
+
import qo, { ElMessageBox as Bt, ElMessage as At, ElCol as Ho, ElRow as Fo, ElCard as Go } from "element-plus";
|
|
10
|
+
import "element-plus/theme-chalk/src/index.scss";
|
|
11
|
+
import "element-plus/theme-chalk/src/dark/css-vars.scss";
|
|
12
12
|
import "dayjs/locale/zh-cn";
|
|
13
|
-
import { useRoute as
|
|
14
|
-
import { ElBreadcrumb as
|
|
13
|
+
import { useRoute as Q, useRouter as Te, onBeforeRouteLeave as Ko, createRouter as zo, createWebHashHistory as Jo, onBeforeRouteUpdate as Wo } from "vue-router";
|
|
14
|
+
import { ElBreadcrumb as Qo, ElBreadcrumbItem as Xo, ElContainer as Zo, ElRow as _e, ElMain as Yo, ElAside as en, ElForm as Qe, ElFormItem as Xe, ElSelect as Ze, ElOption as Ye, ElDivider as Rt, ElButton as he, ElCol as Oe, ElDrawer as Pt, ElTooltip as Lt, ElIcon as Mt, ElDropdown as tn, ElAvatar as on, ElDropdownMenu as nn, ElDropdownItem as ln, ElImage as sn, ElMenuItem as an, ElSubMenu as rn, ElOptionGroup as cn, ElScrollbar as un, ElMenu as dn, ElBacktop as pn, ElCard as $e, ElInput as fn, ElAlert as et, ElTree as mn } from "element-plus/es";
|
|
15
15
|
import "element-plus/es/components/base/style/css";
|
|
16
16
|
import "element-plus/es/components/row/style/css";
|
|
17
17
|
import "element-plus/es/components/drawer/style/css";
|
|
@@ -24,7 +24,7 @@ import "element-plus/es/components/icon/style/css";
|
|
|
24
24
|
import "element-plus/es/components/col/style/css";
|
|
25
25
|
import "element-plus/es/components/breadcrumb/style/css";
|
|
26
26
|
import "element-plus/es/components/breadcrumb-item/style/css";
|
|
27
|
-
import * as
|
|
27
|
+
import * as hn from "path-to-regexp";
|
|
28
28
|
import "element-plus/es/components/form/style/css";
|
|
29
29
|
import "element-plus/es/components/form-item/style/css";
|
|
30
30
|
import "element-plus/es/components/select/style/css";
|
|
@@ -34,11 +34,11 @@ import "element-plus/es/components/divider/style/css";
|
|
|
34
34
|
import "element-plus/es/components/container/style/css";
|
|
35
35
|
import "element-plus/es/components/aside/style/css";
|
|
36
36
|
import "element-plus/es/components/main/style/css";
|
|
37
|
-
import { JsonView as
|
|
37
|
+
import { JsonView as tt, VBtn as ot, VForm as ne, VTable as be, VChart as bn, setUploadHeaderHandle as yn, VIcon as _n } from "@okiss/vbtf";
|
|
38
38
|
import "normalize.css/normalize.css";
|
|
39
39
|
import "@okiss/vbtf/style.css";
|
|
40
|
-
import
|
|
41
|
-
import { Moon as
|
|
40
|
+
import vn from "mitt";
|
|
41
|
+
import { Moon as gn, Sunny as kn, InfoFilled as Sn } from "@element-plus/icons-vue";
|
|
42
42
|
import "element-plus/es/components/scrollbar/style/css";
|
|
43
43
|
import "element-plus/es/components/menu/style/css";
|
|
44
44
|
import "element-plus/es/components/image/style/css";
|
|
@@ -46,48 +46,48 @@ import "element-plus/es/components/sub-menu/style/css";
|
|
|
46
46
|
import "element-plus/es/components/menu-item/style/css";
|
|
47
47
|
import "element-plus/es/components/option-group/style/css";
|
|
48
48
|
import "element-plus/es/components/backtop/style/css";
|
|
49
|
-
import { useEventListener as
|
|
49
|
+
import { useEventListener as wn } from "@vueuse/core";
|
|
50
50
|
import "element-plus/es/components/alert/style/css";
|
|
51
51
|
import "element-plus/es/components/card/style/css";
|
|
52
52
|
import "element-plus/es/components/tree/style/css";
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import "
|
|
56
|
-
import
|
|
53
|
+
import xn from "vue3-markdown-it";
|
|
54
|
+
import "element-plus/es/components/input/style/css";
|
|
55
|
+
import En from "crypto-js";
|
|
56
|
+
import Ve from "nprogress";
|
|
57
57
|
import "nprogress/nprogress.css";
|
|
58
58
|
String.prototype.format || (String.prototype.format = function() {
|
|
59
59
|
const e = arguments;
|
|
60
|
-
return this.replace(/{(\d+)}/g, function(t,
|
|
61
|
-
return typeof e[
|
|
60
|
+
return this.replace(/{(\d+)}/g, function(t, o) {
|
|
61
|
+
return typeof e[o] < "u" ? e[o] : t;
|
|
62
62
|
});
|
|
63
63
|
});
|
|
64
|
-
const
|
|
65
|
-
function
|
|
66
|
-
return
|
|
64
|
+
const nt = "oms:token";
|
|
65
|
+
function ve() {
|
|
66
|
+
return oe.get(nt) || "";
|
|
67
67
|
}
|
|
68
|
-
function
|
|
69
|
-
const t =
|
|
70
|
-
return
|
|
68
|
+
function In(e) {
|
|
69
|
+
const t = U(L), o = new Date((/* @__PURE__ */ new Date()).getTime() + (t.tokenExpire || 1440 * 60 * 1e3));
|
|
70
|
+
return oe.set(nt, e, { expires: o });
|
|
71
71
|
}
|
|
72
|
-
function
|
|
73
|
-
return
|
|
72
|
+
function Dt() {
|
|
73
|
+
return oe.remove(nt);
|
|
74
74
|
}
|
|
75
|
-
let
|
|
76
|
-
function
|
|
77
|
-
|
|
75
|
+
let jt = null;
|
|
76
|
+
function Cn(e) {
|
|
77
|
+
jt = e;
|
|
78
78
|
}
|
|
79
79
|
function Pe() {
|
|
80
|
-
return
|
|
80
|
+
return jt;
|
|
81
81
|
}
|
|
82
|
-
const
|
|
82
|
+
const Tn = {
|
|
83
83
|
baseURL: "/api",
|
|
84
84
|
withCredentials: !0,
|
|
85
85
|
cacheEnable: !0
|
|
86
|
-
},
|
|
86
|
+
}, Nt = {
|
|
87
87
|
title: "oms",
|
|
88
88
|
fixedHeader: !1,
|
|
89
89
|
sidebarLogo: !0,
|
|
90
|
-
logo: "
|
|
90
|
+
logo: "",
|
|
91
91
|
closeNavNotice: !1,
|
|
92
92
|
navBarNotice: "",
|
|
93
93
|
hasNewMessage: !0,
|
|
@@ -97,12 +97,12 @@ const To = {
|
|
|
97
97
|
ElementPlus: {
|
|
98
98
|
size: "default",
|
|
99
99
|
zIndex: 3e3,
|
|
100
|
-
locale:
|
|
100
|
+
locale: Ot
|
|
101
101
|
},
|
|
102
102
|
nav: [],
|
|
103
103
|
whiteRoutes: ["/login"],
|
|
104
104
|
tokenExpire: 10080 * 60 * 1e3,
|
|
105
|
-
defaultAvatar: "
|
|
105
|
+
defaultAvatar: "",
|
|
106
106
|
envColor: {
|
|
107
107
|
uat: "gray",
|
|
108
108
|
pre: "green"
|
|
@@ -111,23 +111,23 @@ const To = {
|
|
|
111
111
|
formMutex: !0,
|
|
112
112
|
captcha: !0,
|
|
113
113
|
themeMode: "light"
|
|
114
|
-
},
|
|
115
|
-
axios:
|
|
116
|
-
settings:
|
|
114
|
+
}, Be = {
|
|
115
|
+
axios: Tn,
|
|
116
|
+
settings: Nt,
|
|
117
117
|
plugins: [],
|
|
118
118
|
mock: !1
|
|
119
|
-
},
|
|
120
|
-
state: () => ({ ...
|
|
119
|
+
}, On = E(Nt), U = Ce("settings", {
|
|
120
|
+
state: () => ({ ...On }),
|
|
121
121
|
actions: {
|
|
122
122
|
updateSettings(e) {
|
|
123
|
-
|
|
123
|
+
q(this, e);
|
|
124
124
|
}
|
|
125
125
|
}
|
|
126
|
-
}),
|
|
126
|
+
}), pt = {
|
|
127
127
|
name: "",
|
|
128
128
|
nickname: "",
|
|
129
129
|
avatar: "",
|
|
130
|
-
token:
|
|
130
|
+
token: ve(),
|
|
131
131
|
customRouter: [],
|
|
132
132
|
remoteRouter: [],
|
|
133
133
|
menuRoutes: [],
|
|
@@ -137,27 +137,27 @@ const To = {
|
|
|
137
137
|
path: "",
|
|
138
138
|
env: "",
|
|
139
139
|
expired: !1
|
|
140
|
-
},
|
|
141
|
-
state: () => ({ ...
|
|
140
|
+
}, ft = (e) => typeof e.name == "string" ? e.name : e.path, j = Ce("user", {
|
|
141
|
+
state: () => ({ ...pt }),
|
|
142
142
|
actions: {
|
|
143
143
|
updateToken(e) {
|
|
144
|
-
this.token = e,
|
|
144
|
+
this.token = e, In(e);
|
|
145
145
|
},
|
|
146
146
|
removeToken() {
|
|
147
|
-
this.token = "",
|
|
147
|
+
this.token = "", Dt();
|
|
148
148
|
},
|
|
149
149
|
updateRemoteRouter(e) {
|
|
150
150
|
this.remoteRouter = e, this.isLodeRemoteRoutes = !0;
|
|
151
151
|
},
|
|
152
152
|
setCustomRoutes(e) {
|
|
153
|
-
const t = new Set(this.customRouter.map((
|
|
154
|
-
|
|
153
|
+
const t = new Set(this.customRouter.map((n) => ft(n))), o = e.filter((n) => !t.has(ft(n)));
|
|
154
|
+
o.length && (this.customRouter = this.customRouter.concat(o));
|
|
155
155
|
},
|
|
156
156
|
updateState({ key: e, value: t }) {
|
|
157
157
|
this[e] = t;
|
|
158
158
|
},
|
|
159
159
|
resetUser() {
|
|
160
|
-
const e = { ...
|
|
160
|
+
const e = { ...pt, token: ve() };
|
|
161
161
|
Object.assign(this, e);
|
|
162
162
|
},
|
|
163
163
|
SET_EXPIRED() {
|
|
@@ -165,19 +165,19 @@ const To = {
|
|
|
165
165
|
},
|
|
166
166
|
// async actions
|
|
167
167
|
login(e) {
|
|
168
|
-
return new Promise((t,
|
|
169
|
-
const
|
|
170
|
-
if (!
|
|
171
|
-
|
|
168
|
+
return new Promise((t, o) => {
|
|
169
|
+
const n = Pe();
|
|
170
|
+
if (!n) {
|
|
171
|
+
o("http client not init");
|
|
172
172
|
return;
|
|
173
173
|
}
|
|
174
|
-
|
|
174
|
+
n.request({
|
|
175
175
|
url: "/user/login",
|
|
176
176
|
method: "POST",
|
|
177
177
|
data: e
|
|
178
178
|
}).then((l) => {
|
|
179
179
|
this.updateToken(l.data?.token || ""), t(!0);
|
|
180
|
-
}).catch((l) =>
|
|
180
|
+
}).catch((l) => o(l));
|
|
181
181
|
});
|
|
182
182
|
},
|
|
183
183
|
logout() {
|
|
@@ -185,20 +185,20 @@ const To = {
|
|
|
185
185
|
},
|
|
186
186
|
info() {
|
|
187
187
|
return new Promise((e, t) => {
|
|
188
|
-
const
|
|
189
|
-
if (!
|
|
188
|
+
const o = Pe();
|
|
189
|
+
if (!o) {
|
|
190
190
|
t("http client not init");
|
|
191
191
|
return;
|
|
192
192
|
}
|
|
193
|
-
|
|
193
|
+
o.request({
|
|
194
194
|
url: "/user/info",
|
|
195
195
|
method: "GET"
|
|
196
|
-
}).then((
|
|
197
|
-
const l =
|
|
198
|
-
this.updateState({ key: "name", value:
|
|
199
|
-
const s =
|
|
200
|
-
|
|
201
|
-
}).catch((
|
|
196
|
+
}).then((n) => {
|
|
197
|
+
const l = n.data?.role_ids || [];
|
|
198
|
+
this.updateState({ key: "name", value: n.data?.name }), this.updateState({ key: "nickname", value: n.data?.nickname }), this.updateState({ key: "roleIds", value: l }), this.updateState({ key: "env", value: n.data?.env });
|
|
199
|
+
const s = n.data?.website || {};
|
|
200
|
+
U().updateSettings(s), !oe.get("username") && oe.set("username", n.data?.name), e(!0);
|
|
201
|
+
}).catch((n) => t(n));
|
|
202
202
|
});
|
|
203
203
|
},
|
|
204
204
|
loadRemoteRoutes() {
|
|
@@ -206,14 +206,14 @@ const To = {
|
|
|
206
206
|
Pe()?.request({
|
|
207
207
|
url: "/user/routes",
|
|
208
208
|
method: "get"
|
|
209
|
-
}).then((
|
|
210
|
-
if (
|
|
211
|
-
const l =
|
|
209
|
+
}).then((n) => {
|
|
210
|
+
if (n.code === 0) {
|
|
211
|
+
const l = n.data || [];
|
|
212
212
|
e(l);
|
|
213
213
|
} else
|
|
214
214
|
t("error");
|
|
215
|
-
}).catch((
|
|
216
|
-
t(
|
|
215
|
+
}).catch((n) => {
|
|
216
|
+
t(n);
|
|
217
217
|
});
|
|
218
218
|
});
|
|
219
219
|
},
|
|
@@ -222,22 +222,22 @@ const To = {
|
|
|
222
222
|
}
|
|
223
223
|
}
|
|
224
224
|
}), Ee = "sidebarStatus";
|
|
225
|
-
function $
|
|
225
|
+
function $n() {
|
|
226
226
|
if (typeof window > "u")
|
|
227
227
|
return;
|
|
228
228
|
const e = window.localStorage.getItem(Ee);
|
|
229
229
|
if (e !== null)
|
|
230
230
|
return e === "1";
|
|
231
|
-
const t =
|
|
231
|
+
const t = oe.get(Ee);
|
|
232
232
|
if (t !== void 0)
|
|
233
233
|
return !!t;
|
|
234
234
|
}
|
|
235
|
-
function
|
|
236
|
-
typeof window < "u" && window.localStorage.setItem(Ee, e ? "1" : "0"),
|
|
235
|
+
function mt(e) {
|
|
236
|
+
typeof window < "u" && window.localStorage.setItem(Ee, e ? "1" : "0"), oe.set(Ee, e ? "1" : "0");
|
|
237
237
|
}
|
|
238
|
-
const
|
|
238
|
+
const Bn = {
|
|
239
239
|
sidebar: {
|
|
240
|
-
opened: $
|
|
240
|
+
opened: $n() ?? !0,
|
|
241
241
|
withoutAnimation: !1
|
|
242
242
|
},
|
|
243
243
|
device: "desktop",
|
|
@@ -246,13 +246,13 @@ const Oo = {
|
|
|
246
246
|
builderSchema: {},
|
|
247
247
|
baseURL: ""
|
|
248
248
|
}, Y = Ce("app", {
|
|
249
|
-
state: () => ({ ...
|
|
249
|
+
state: () => ({ ...Bn }),
|
|
250
250
|
actions: {
|
|
251
251
|
TOGGLE_SIDEBAR() {
|
|
252
|
-
this.sidebar.opened = !this.sidebar.opened, this.sidebar.withoutAnimation = !1,
|
|
252
|
+
this.sidebar.opened = !this.sidebar.opened, this.sidebar.withoutAnimation = !1, mt(this.sidebar.opened);
|
|
253
253
|
},
|
|
254
254
|
CLOSE_SIDEBAR(e) {
|
|
255
|
-
this.sidebar.opened = !1,
|
|
255
|
+
this.sidebar.opened = !1, mt(this.sidebar.opened), this.sidebar.withoutAnimation = e;
|
|
256
256
|
},
|
|
257
257
|
TOGGLE_DEVICE(e) {
|
|
258
258
|
this.device = e;
|
|
@@ -292,11 +292,11 @@ const Oo = {
|
|
|
292
292
|
this.SET_BASE_API(e);
|
|
293
293
|
}
|
|
294
294
|
}
|
|
295
|
-
}),
|
|
295
|
+
}), An = {
|
|
296
296
|
currentCellItem: {}
|
|
297
297
|
// form/sub-form 当前单元格编辑数据
|
|
298
|
-
},
|
|
299
|
-
state: () => ({ ...
|
|
298
|
+
}, fr = Ce("builderSchema", {
|
|
299
|
+
state: () => ({ ...An }),
|
|
300
300
|
actions: {
|
|
301
301
|
SET_CURRENT_CELLITEM(e) {
|
|
302
302
|
this.currentCellItem = e;
|
|
@@ -305,86 +305,86 @@ const Oo = {
|
|
|
305
305
|
this.SET_CURRENT_CELLITEM(e);
|
|
306
306
|
}
|
|
307
307
|
}
|
|
308
|
-
}),
|
|
309
|
-
function
|
|
310
|
-
e.use(
|
|
308
|
+
}), L = No();
|
|
309
|
+
function Rn(e) {
|
|
310
|
+
e.use(L);
|
|
311
311
|
}
|
|
312
|
-
const
|
|
313
|
-
let
|
|
314
|
-
function
|
|
315
|
-
const t =
|
|
312
|
+
const Vt = "oms-theme", Ut = C("light");
|
|
313
|
+
let ht = !1, Se = null;
|
|
314
|
+
function Pn(e) {
|
|
315
|
+
const t = fe(e ?? void 0);
|
|
316
316
|
if (typeof window > "u")
|
|
317
317
|
return t;
|
|
318
|
-
const
|
|
319
|
-
return
|
|
318
|
+
const o = window.localStorage?.getItem(Vt);
|
|
319
|
+
return o === "dark" || o === "light" ? o : e === "dark" || e === "light" ? e : window.matchMedia?.("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
320
320
|
}
|
|
321
|
-
function
|
|
322
|
-
typeof window < "u" && window.localStorage?.setItem(
|
|
321
|
+
function Ln(e) {
|
|
322
|
+
typeof window < "u" && window.localStorage?.setItem(Vt, e);
|
|
323
323
|
}
|
|
324
324
|
function Le(e) {
|
|
325
|
-
const t =
|
|
326
|
-
|
|
325
|
+
const t = fe(e);
|
|
326
|
+
Ut.value = t, Oo(t), $o(t), Ln(t);
|
|
327
327
|
}
|
|
328
|
-
function
|
|
328
|
+
function Mn(e) {
|
|
329
329
|
if (typeof window > "u" || typeof window.matchMedia != "function") {
|
|
330
330
|
Se = null;
|
|
331
331
|
return;
|
|
332
332
|
}
|
|
333
|
-
const t = window.matchMedia("(prefers-color-scheme: dark)"),
|
|
334
|
-
const l =
|
|
333
|
+
const t = window.matchMedia("(prefers-color-scheme: dark)"), o = (n) => {
|
|
334
|
+
const l = n.matches ?? t.matches;
|
|
335
335
|
e(l ? "dark" : "light");
|
|
336
336
|
};
|
|
337
|
-
typeof t.addEventListener == "function" ? t.addEventListener("change",
|
|
338
|
-
typeof t.removeEventListener == "function" ? t.removeEventListener("change",
|
|
337
|
+
typeof t.addEventListener == "function" ? t.addEventListener("change", o) : t.addListener(o), Se = () => {
|
|
338
|
+
typeof t.removeEventListener == "function" ? t.removeEventListener("change", o) : t.removeListener(o), Se = null;
|
|
339
339
|
};
|
|
340
340
|
}
|
|
341
|
-
function
|
|
342
|
-
const e =
|
|
343
|
-
const a =
|
|
341
|
+
function qt() {
|
|
342
|
+
const e = U(), t = (s) => {
|
|
343
|
+
const a = fe(s);
|
|
344
344
|
e.themeMode !== a ? e.updateSettings({ themeMode: a }) : Le(a);
|
|
345
345
|
};
|
|
346
|
-
if (!
|
|
347
|
-
|
|
348
|
-
const s =
|
|
349
|
-
|
|
346
|
+
if (!ht) {
|
|
347
|
+
ht = !0;
|
|
348
|
+
const s = Pn(e.themeMode);
|
|
349
|
+
fe(e.themeMode) !== s ? e.updateSettings({ themeMode: s }) : Le(s), ye(
|
|
350
350
|
() => e.themeMode,
|
|
351
351
|
(a) => {
|
|
352
|
-
Le(
|
|
352
|
+
Le(fe(a));
|
|
353
353
|
},
|
|
354
354
|
{ immediate: !0 }
|
|
355
|
-
), Se?.(),
|
|
355
|
+
), Se?.(), Mn((a) => {
|
|
356
356
|
t(a);
|
|
357
357
|
});
|
|
358
358
|
}
|
|
359
|
-
const
|
|
359
|
+
const o = k(() => Ut.value), n = k(() => o.value === "dark");
|
|
360
360
|
return {
|
|
361
|
-
themeMode:
|
|
362
|
-
isDark:
|
|
361
|
+
themeMode: o,
|
|
362
|
+
isDark: n,
|
|
363
363
|
setTheme: t,
|
|
364
364
|
toggleTheme: () => {
|
|
365
|
-
t(
|
|
365
|
+
t(n.value ? "light" : "dark");
|
|
366
366
|
}
|
|
367
367
|
};
|
|
368
368
|
}
|
|
369
|
-
const
|
|
369
|
+
const Dn = /* @__PURE__ */ z({
|
|
370
370
|
__name: "App",
|
|
371
371
|
setup(e) {
|
|
372
|
-
return
|
|
372
|
+
return qt(), Ge(() => {
|
|
373
373
|
const t = document.getElementById("preloader");
|
|
374
|
-
t !== null && (document.body.removeChild(t), document.getElementById("preloader")?.remove(),
|
|
374
|
+
t !== null && (document.body.removeChild(t), document.getElementById("preloader")?.remove(), Bo("test-icon", "//at.alicdn.com/t/font_2246548_zclaqxwmzq8.css"), Ao(`.iconfont {
|
|
375
375
|
font-size: 19px;
|
|
376
376
|
font-style: normal;
|
|
377
377
|
-webkit-font-smoothing: antialiased;
|
|
378
378
|
font-family: iconfont !important;
|
|
379
379
|
}`));
|
|
380
|
-
}), window?.OmsOptions?.form?.vsPath &&
|
|
381
|
-
const
|
|
382
|
-
return i(),
|
|
380
|
+
}), window?.OmsOptions?.form?.vsPath && _o("vsPath", window?.OmsOptions?.form?.vsPath), (t, o) => {
|
|
381
|
+
const n = P("router-view");
|
|
382
|
+
return i(), m(n);
|
|
383
383
|
};
|
|
384
384
|
}
|
|
385
385
|
});
|
|
386
|
-
var
|
|
387
|
-
const
|
|
386
|
+
var ue = /* @__PURE__ */ ((e) => (e.GET = "get", e.POST = "post", e.DELETE = "delete", e.FETCH = "fetch", e.OPTION = "option", e.PUT = "put", e))(ue || {});
|
|
387
|
+
const jn = [
|
|
388
388
|
{
|
|
389
389
|
type: "jump",
|
|
390
390
|
text: "跳转",
|
|
@@ -441,9 +441,9 @@ const jo = [
|
|
|
441
441
|
}
|
|
442
442
|
];
|
|
443
443
|
[
|
|
444
|
-
...
|
|
444
|
+
...Vo.cloneDeep(jn)
|
|
445
445
|
];
|
|
446
|
-
const
|
|
446
|
+
const Nn = {
|
|
447
447
|
code: 0,
|
|
448
448
|
data: {
|
|
449
449
|
"list|0-100": [
|
|
@@ -464,9 +464,9 @@ const No = {
|
|
|
464
464
|
"page|1-5": 2
|
|
465
465
|
}
|
|
466
466
|
}
|
|
467
|
-
},
|
|
467
|
+
}, Vn = { listMock: Nn }, Un = [
|
|
468
468
|
{
|
|
469
|
-
method:
|
|
469
|
+
method: ue.POST,
|
|
470
470
|
url: "/login",
|
|
471
471
|
response(e) {
|
|
472
472
|
return {
|
|
@@ -479,7 +479,7 @@ const No = {
|
|
|
479
479
|
}
|
|
480
480
|
},
|
|
481
481
|
{
|
|
482
|
-
method:
|
|
482
|
+
method: ue.GET,
|
|
483
483
|
url: "/user/info",
|
|
484
484
|
response(e) {
|
|
485
485
|
return {
|
|
@@ -493,7 +493,7 @@ const No = {
|
|
|
493
493
|
},
|
|
494
494
|
{
|
|
495
495
|
url: "/user/routes",
|
|
496
|
-
method:
|
|
496
|
+
method: ue.GET,
|
|
497
497
|
response: (e) => ({
|
|
498
498
|
code: 0,
|
|
499
499
|
data: [
|
|
@@ -507,95 +507,95 @@ const No = {
|
|
|
507
507
|
},
|
|
508
508
|
{
|
|
509
509
|
url: "/user/list",
|
|
510
|
-
method:
|
|
511
|
-
response: (e) =>
|
|
510
|
+
method: ue.GET,
|
|
511
|
+
response: (e) => Vn.listMock
|
|
512
512
|
}
|
|
513
|
-
],
|
|
514
|
-
...
|
|
513
|
+
], qn = [
|
|
514
|
+
...Un
|
|
515
515
|
], Ue = {};
|
|
516
|
-
function
|
|
516
|
+
function Ht(e) {
|
|
517
517
|
e.forEach((t) => {
|
|
518
|
-
const
|
|
519
|
-
Ue[`${t.method}::${
|
|
518
|
+
const o = Ft(t);
|
|
519
|
+
Ue[`${t.method}::${o}`] = t;
|
|
520
520
|
});
|
|
521
521
|
}
|
|
522
|
-
|
|
523
|
-
function
|
|
524
|
-
let t = e.url,
|
|
525
|
-
return
|
|
522
|
+
Ht(qn);
|
|
523
|
+
function Ft(e) {
|
|
524
|
+
let t = e.url, o = e.baseURL || Be.axios?.baseURL;
|
|
525
|
+
return o || (o = ""), typeof t == "string" ? (t = ("/" + o + t).split("/").filter((n) => n).join("/"), t += "(|\\?.*)$", new RegExp(t)) : t;
|
|
526
526
|
}
|
|
527
|
-
function
|
|
527
|
+
function Hn() {
|
|
528
528
|
Object.keys(Ue).forEach((e) => {
|
|
529
|
-
const t = Ue[e],
|
|
530
|
-
Re.mock(
|
|
531
|
-
const { url: l, type: s, body: a } =
|
|
532
|
-
return
|
|
529
|
+
const t = Ue[e], o = Ft(t);
|
|
530
|
+
Re.mock(o, t.method, function(n) {
|
|
531
|
+
const { url: l, type: s, body: a } = n, c = Ro(l), d = a ? JSON.parse(a) : {}, f = t.response({ query: c, data: d }), p = Re.mock(f);
|
|
532
|
+
return Po(l, { type: s, query: c, data: d, response: p }), Re.mock(p);
|
|
533
533
|
});
|
|
534
534
|
});
|
|
535
535
|
}
|
|
536
|
-
const
|
|
536
|
+
const Fn = At, bt = Bt, Gn = We.CancelToken, we = {
|
|
537
537
|
taskList: {},
|
|
538
538
|
cacheList: /* @__PURE__ */ new Map(),
|
|
539
539
|
uniqueId(e) {
|
|
540
540
|
return `${location.href}|${e.method}|${e.url}|`;
|
|
541
541
|
},
|
|
542
542
|
addTask(e, t) {
|
|
543
|
-
const
|
|
544
|
-
this.taskList[
|
|
543
|
+
const o = this.uniqueId(e);
|
|
544
|
+
this.taskList[o] = t;
|
|
545
545
|
},
|
|
546
546
|
delTask(e) {
|
|
547
|
-
const t = this.uniqueId(e),
|
|
548
|
-
|
|
547
|
+
const t = this.uniqueId(e), o = this.taskList[t];
|
|
548
|
+
o && o(e);
|
|
549
549
|
},
|
|
550
550
|
pending(e) {
|
|
551
551
|
const t = this.uniqueId(e);
|
|
552
552
|
return !!this.taskList[t];
|
|
553
553
|
},
|
|
554
554
|
cache(e) {
|
|
555
|
-
const t = this.uniqueId(e),
|
|
556
|
-
if (
|
|
557
|
-
if (
|
|
555
|
+
const t = this.uniqueId(e), o = this.cacheList.get(t);
|
|
556
|
+
if (o) {
|
|
557
|
+
if (o.expirationTime < (/* @__PURE__ */ new Date()).getTime()) {
|
|
558
558
|
this.delCache(e);
|
|
559
559
|
return;
|
|
560
560
|
}
|
|
561
|
-
return
|
|
561
|
+
return o.response, o.response;
|
|
562
562
|
}
|
|
563
563
|
},
|
|
564
564
|
addCache(e, t) {
|
|
565
|
-
const
|
|
566
|
-
|
|
565
|
+
const o = this.uniqueId(e), n = e.cacheTime || 0;
|
|
566
|
+
n && this.cacheList.set(o, { response: t, expirationTime: (/* @__PURE__ */ new Date()).getTime() + n });
|
|
567
567
|
},
|
|
568
568
|
delCache(e) {
|
|
569
569
|
const t = this.uniqueId(e);
|
|
570
570
|
return this.cacheList.delete(t);
|
|
571
571
|
}
|
|
572
|
-
},
|
|
572
|
+
}, Kn = {
|
|
573
573
|
onFulfilled: function(e) {
|
|
574
|
-
return e.cacheEnable === !1 || (we.pending(e) && we.delTask(e), e.cancelToken = new
|
|
574
|
+
return e.cacheEnable === !1 || (we.pending(e) && we.delTask(e), e.cancelToken = new Gn((t) => {
|
|
575
575
|
we.addTask(e, t);
|
|
576
576
|
})), e;
|
|
577
577
|
},
|
|
578
578
|
onRejected(e) {
|
|
579
579
|
return Promise.reject(e);
|
|
580
580
|
}
|
|
581
|
-
},
|
|
581
|
+
}, zn = {
|
|
582
582
|
onFulfilled: function(e) {
|
|
583
583
|
return e.config.cacheEnable === !1 || e.config.method === "get" && Object.keys(e.data).length > 0 && we.addCache(e.config, e.data), e;
|
|
584
584
|
},
|
|
585
585
|
onRejected(e) {
|
|
586
586
|
return Promise.reject(e);
|
|
587
587
|
}
|
|
588
|
-
},
|
|
589
|
-
function
|
|
590
|
-
|
|
588
|
+
}, Gt = {};
|
|
589
|
+
function mr(e, t) {
|
|
590
|
+
Gt[e] = t;
|
|
591
591
|
}
|
|
592
|
-
function
|
|
593
|
-
return
|
|
592
|
+
function Jn(e) {
|
|
593
|
+
return Gt[e];
|
|
594
594
|
}
|
|
595
|
-
const
|
|
595
|
+
const Wn = /* @__PURE__ */ z({
|
|
596
596
|
name: "Dashboard",
|
|
597
597
|
setup() {
|
|
598
|
-
const e =
|
|
598
|
+
const e = Jn("dashboard");
|
|
599
599
|
if (e)
|
|
600
600
|
return () => u("span", null, [u(e, null, null)]);
|
|
601
601
|
const t = k(() => j().name);
|
|
@@ -603,14 +603,14 @@ const Wo = /* @__PURE__ */ K({
|
|
|
603
603
|
class: "dashboard-container"
|
|
604
604
|
}, [u("div", {
|
|
605
605
|
class: "dashboard-text"
|
|
606
|
-
}, [
|
|
606
|
+
}, [T("Hi "), t.value, T(" 😄")])]);
|
|
607
607
|
}
|
|
608
|
-
}),
|
|
609
|
-
const
|
|
610
|
-
for (const [
|
|
611
|
-
n
|
|
612
|
-
return
|
|
613
|
-
},
|
|
608
|
+
}), R = (e, t) => {
|
|
609
|
+
const o = e.__vccOpts || e;
|
|
610
|
+
for (const [n, l] of t)
|
|
611
|
+
o[n] = l;
|
|
612
|
+
return o;
|
|
613
|
+
}, Qn = /* @__PURE__ */ R(Wn, [["__scopeId", "data-v-85165680"]]), Xn = {
|
|
614
614
|
data() {
|
|
615
615
|
return {
|
|
616
616
|
levelList: null
|
|
@@ -627,13 +627,13 @@ const Wo = /* @__PURE__ */ K({
|
|
|
627
627
|
methods: {
|
|
628
628
|
getBreadcrumb() {
|
|
629
629
|
let e = this.$route.matched.filter(
|
|
630
|
-
(
|
|
630
|
+
(o) => o.meta && o.meta.title
|
|
631
631
|
);
|
|
632
632
|
const t = e[0];
|
|
633
633
|
this.isDashboard(t) || (e = [{ path: "/dashboard", meta: { title: "Dashboard" } }].concat(
|
|
634
634
|
e
|
|
635
635
|
)), this.levelList = e.filter(
|
|
636
|
-
(
|
|
636
|
+
(o) => o.meta && o.meta.title && o.meta.breadcrumb !== !1
|
|
637
637
|
);
|
|
638
638
|
},
|
|
639
639
|
isDashboard(e) {
|
|
@@ -642,38 +642,38 @@ const Wo = /* @__PURE__ */ K({
|
|
|
642
642
|
},
|
|
643
643
|
pathCompile(e) {
|
|
644
644
|
const { params: t } = this.$route;
|
|
645
|
-
return
|
|
645
|
+
return hn.compile(e)(t);
|
|
646
646
|
},
|
|
647
647
|
handleLink(e) {
|
|
648
|
-
const { redirect: t, path:
|
|
648
|
+
const { redirect: t, path: o } = e;
|
|
649
649
|
if (t) {
|
|
650
650
|
this.$router.push(t);
|
|
651
651
|
return;
|
|
652
652
|
}
|
|
653
|
-
this.$router.push(this.pathCompile(
|
|
653
|
+
this.$router.push(this.pathCompile(o));
|
|
654
654
|
}
|
|
655
655
|
}
|
|
656
|
-
},
|
|
656
|
+
}, Zn = {
|
|
657
657
|
key: 0,
|
|
658
658
|
class: "no-redirect"
|
|
659
|
-
},
|
|
660
|
-
function el(e, t,
|
|
661
|
-
const a =
|
|
662
|
-
return i(),
|
|
659
|
+
}, Yn = ["onClick"];
|
|
660
|
+
function el(e, t, o, n, l, s) {
|
|
661
|
+
const a = Xo, c = Qo;
|
|
662
|
+
return i(), m(c, {
|
|
663
663
|
class: "app-breadcrumb",
|
|
664
664
|
separator: "/"
|
|
665
665
|
}, {
|
|
666
666
|
default: r(() => [
|
|
667
|
-
u(
|
|
667
|
+
u(vo, { name: "breadcrumb" }, {
|
|
668
668
|
default: r(() => [
|
|
669
|
-
(i(!0),
|
|
669
|
+
(i(!0), v(A, null, V(l.levelList, (d, f) => (i(), m(a, {
|
|
670
670
|
key: d.path
|
|
671
671
|
}, {
|
|
672
672
|
default: r(() => [
|
|
673
|
-
d.path.indexOf("/DIR_") === 0 && d.redirect === void 0 || f === l.levelList.length - 1 ? (i(),
|
|
673
|
+
d.path.indexOf("/DIR_") === 0 && d.redirect === void 0 || f === l.levelList.length - 1 ? (i(), v("span", Zn, B(d.meta.title), 1)) : (i(), v("a", {
|
|
674
674
|
key: 1,
|
|
675
675
|
onClick: (p) => s.handleLink(d)
|
|
676
|
-
},
|
|
676
|
+
}, B(d.meta.title), 9, Yn))
|
|
677
677
|
]),
|
|
678
678
|
_: 2
|
|
679
679
|
}, 1024))), 128))
|
|
@@ -684,7 +684,7 @@ function el(e, t, n, o, l, s) {
|
|
|
684
684
|
_: 1
|
|
685
685
|
});
|
|
686
686
|
}
|
|
687
|
-
const tl = /* @__PURE__ */
|
|
687
|
+
const tl = /* @__PURE__ */ R(Xn, [["render", el], ["__scopeId", "data-v-fa74804e"]]), ol = {
|
|
688
688
|
name: "Hamburger",
|
|
689
689
|
props: {
|
|
690
690
|
isActive: {
|
|
@@ -699,35 +699,35 @@ const tl = /* @__PURE__ */ P(Xo, [["render", el], ["__scopeId", "data-v-fa74804e
|
|
|
699
699
|
}
|
|
700
700
|
}
|
|
701
701
|
};
|
|
702
|
-
function
|
|
703
|
-
const a =
|
|
704
|
-
return i(),
|
|
702
|
+
function nl(e, t, o, n, l, s) {
|
|
703
|
+
const a = P("v-icon");
|
|
704
|
+
return i(), v("div", {
|
|
705
705
|
style: { padding: "0 15px" },
|
|
706
706
|
onClick: t[0] || (t[0] = (...c) => s.toggleClick && s.toggleClick(...c))
|
|
707
707
|
}, [
|
|
708
708
|
u(a, {
|
|
709
|
-
class:
|
|
709
|
+
class: te({ "is-active": o.isActive }),
|
|
710
710
|
name: "ra-leftalignment"
|
|
711
711
|
}, null, 8, ["class"])
|
|
712
712
|
]);
|
|
713
713
|
}
|
|
714
|
-
const ll = /* @__PURE__ */
|
|
714
|
+
const ll = /* @__PURE__ */ R(ol, [["render", nl]]), sl = {};
|
|
715
715
|
function al(e, t) {
|
|
716
|
-
const
|
|
717
|
-
return i(),
|
|
716
|
+
const o = _e, n = Yo, l = en, s = Zo;
|
|
717
|
+
return i(), m(s, { style: { width: "100%", height: "100%" } }, {
|
|
718
718
|
default: r(() => [
|
|
719
|
-
u(
|
|
719
|
+
u(o, { class: "aside" }, {
|
|
720
720
|
default: r(() => [
|
|
721
|
-
|
|
721
|
+
pe(e.$slots, "left-aside", {}, void 0, !0)
|
|
722
722
|
]),
|
|
723
723
|
_: 3
|
|
724
724
|
}),
|
|
725
|
-
u(
|
|
725
|
+
u(n, {
|
|
726
726
|
class: "main",
|
|
727
727
|
style: { margin: "0 10px" }
|
|
728
728
|
}, {
|
|
729
729
|
default: r(() => [
|
|
730
|
-
|
|
730
|
+
pe(e.$slots, "main", {}, void 0, !0)
|
|
731
731
|
]),
|
|
732
732
|
_: 3
|
|
733
733
|
}),
|
|
@@ -737,7 +737,7 @@ function al(e, t) {
|
|
|
737
737
|
style: { padding: "20px" }
|
|
738
738
|
}, {
|
|
739
739
|
default: r(() => [
|
|
740
|
-
|
|
740
|
+
pe(e.$slots, "right-aside", {}, void 0, !0)
|
|
741
741
|
]),
|
|
742
742
|
_: 3
|
|
743
743
|
})
|
|
@@ -745,7 +745,7 @@ function al(e, t) {
|
|
|
745
745
|
_: 3
|
|
746
746
|
});
|
|
747
747
|
}
|
|
748
|
-
const
|
|
748
|
+
const Kt = /* @__PURE__ */ R(sl, [["render", al], ["__scopeId", "data-v-7c3d697b"]]), il = {
|
|
749
749
|
type: "input",
|
|
750
750
|
name: "文本框",
|
|
751
751
|
default: {
|
|
@@ -999,7 +999,7 @@ const Ft = /* @__PURE__ */ P(sl, [["render", al], ["__scopeId", "data-v-7c3d697b
|
|
|
999
999
|
}
|
|
1000
1000
|
],
|
|
1001
1001
|
trans(e) {
|
|
1002
|
-
const t =
|
|
1002
|
+
const t = E(e);
|
|
1003
1003
|
return e.optionType === 0 ? t.props && t.props.selectApi !== void 0 && delete t.props.selectApi : e.optionType === 1 && t.options && delete t.options, delete t.optionType, t;
|
|
1004
1004
|
}
|
|
1005
1005
|
}, dl = {
|
|
@@ -1318,24 +1318,24 @@ const Ft = /* @__PURE__ */ P(sl, [["render", al], ["__scopeId", "data-v-7c3d697b
|
|
|
1318
1318
|
}
|
|
1319
1319
|
}
|
|
1320
1320
|
]
|
|
1321
|
-
},
|
|
1322
|
-
function
|
|
1323
|
-
|
|
1321
|
+
}, zt = {};
|
|
1322
|
+
function H(e) {
|
|
1323
|
+
zt[e.type] = e;
|
|
1324
1324
|
}
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
const
|
|
1325
|
+
H(il);
|
|
1326
|
+
H(ul);
|
|
1327
|
+
H(rl);
|
|
1328
|
+
H(cl);
|
|
1329
|
+
H(pl);
|
|
1330
|
+
H(_l);
|
|
1331
|
+
H(dl);
|
|
1332
|
+
H(vl);
|
|
1333
|
+
H(fl);
|
|
1334
|
+
H(ml);
|
|
1335
|
+
H(hl);
|
|
1336
|
+
H(yl);
|
|
1337
|
+
H(bl);
|
|
1338
|
+
const qe = zt, gl = {
|
|
1339
1339
|
options: {
|
|
1340
1340
|
labelPosition: "top",
|
|
1341
1341
|
submitButton: !1,
|
|
@@ -1437,9 +1437,9 @@ const Ve = Gt, gl = {
|
|
|
1437
1437
|
labelPosition: "top",
|
|
1438
1438
|
submitButton: !1,
|
|
1439
1439
|
cancelButton: !1
|
|
1440
|
-
},
|
|
1441
|
-
Object.keys(
|
|
1442
|
-
|
|
1440
|
+
}, lt = [];
|
|
1441
|
+
Object.keys(qe).forEach((e) => {
|
|
1442
|
+
lt.push({ value: e, label: qe[e].name });
|
|
1443
1443
|
});
|
|
1444
1444
|
const kl = {
|
|
1445
1445
|
options: {
|
|
@@ -1462,7 +1462,7 @@ const kl = {
|
|
|
1462
1462
|
type: "select",
|
|
1463
1463
|
field: "type",
|
|
1464
1464
|
label: "类型",
|
|
1465
|
-
options:
|
|
1465
|
+
options: E(lt)
|
|
1466
1466
|
},
|
|
1467
1467
|
{
|
|
1468
1468
|
type: "input",
|
|
@@ -1474,7 +1474,7 @@ const kl = {
|
|
|
1474
1474
|
}
|
|
1475
1475
|
]
|
|
1476
1476
|
}, Sl = {
|
|
1477
|
-
components: { DevLayout:
|
|
1477
|
+
components: { DevLayout: Kt, VForm: ne, VButton: ot, JsonView: tt },
|
|
1478
1478
|
props: {
|
|
1479
1479
|
schema: {
|
|
1480
1480
|
type: Object,
|
|
@@ -1506,12 +1506,12 @@ const kl = {
|
|
|
1506
1506
|
ctrlSchema: {},
|
|
1507
1507
|
ctrlName: "",
|
|
1508
1508
|
activeIndex: void 0,
|
|
1509
|
-
ctrlMap:
|
|
1509
|
+
ctrlMap: qe,
|
|
1510
1510
|
activeIndexReg: /(formItems)?\[(\d+)\]/,
|
|
1511
1511
|
tableStruct: "",
|
|
1512
1512
|
activeName: "1",
|
|
1513
1513
|
currentCtrlType: "input",
|
|
1514
|
-
types:
|
|
1514
|
+
types: E(lt)
|
|
1515
1515
|
};
|
|
1516
1516
|
},
|
|
1517
1517
|
computed: {
|
|
@@ -1526,20 +1526,20 @@ const kl = {
|
|
|
1526
1526
|
deep: !0,
|
|
1527
1527
|
immediate: !0,
|
|
1528
1528
|
handler(e) {
|
|
1529
|
-
const t =
|
|
1530
|
-
e.showSubmitButton === !1 && (t.submitButton = !1), e.cancelSubmitButton === !1 && (t.cancelButton = !1), delete t.showSubmitButton, delete t.showCancelButton, Object.keys(t).length > 0 && (this.builderSchema =
|
|
1529
|
+
const t = E(e);
|
|
1530
|
+
e.showSubmitButton === !1 && (t.submitButton = !1), e.cancelSubmitButton === !1 && (t.cancelButton = !1), delete t.showSubmitButton, delete t.showCancelButton, Object.keys(t).length > 0 && (this.builderSchema = q(this.builderSchema, { options: t }), this.key++);
|
|
1531
1531
|
}
|
|
1532
1532
|
},
|
|
1533
1533
|
ctrlOptions: {
|
|
1534
1534
|
deep: !0,
|
|
1535
1535
|
// immediate: true,
|
|
1536
1536
|
handler(e) {
|
|
1537
|
-
const t =
|
|
1537
|
+
const t = me(this.builderSchema, this.activeIndex);
|
|
1538
1538
|
if (!t)
|
|
1539
1539
|
return;
|
|
1540
|
-
const
|
|
1540
|
+
const o = t ? t.type : "", n = this.ctrlMap[o], l = n.trans ? n.trans(e) : e;
|
|
1541
1541
|
if (l && Object.keys(l).length > 0) {
|
|
1542
|
-
if (l.type =
|
|
1542
|
+
if (l.type = o, this.activeIndex.indexOf("[") > -1) {
|
|
1543
1543
|
const [s, a, c] = this.activeIndex.match(/(\w+)\[(\d+)\]/);
|
|
1544
1544
|
this.builderSchema[a][c] = { ...l };
|
|
1545
1545
|
} else
|
|
@@ -1551,22 +1551,22 @@ const kl = {
|
|
|
1551
1551
|
currentCtrlType: {
|
|
1552
1552
|
handler(e) {
|
|
1553
1553
|
const t = this.ctrlMap[e];
|
|
1554
|
-
this.ctrlSchema =
|
|
1555
|
-
options:
|
|
1556
|
-
formItems:
|
|
1554
|
+
this.ctrlSchema = E({
|
|
1555
|
+
options: E(Me),
|
|
1556
|
+
formItems: E(t.builder)
|
|
1557
1557
|
});
|
|
1558
|
-
const
|
|
1559
|
-
this.ctrlOptions =
|
|
1558
|
+
const o = me(this.builderSchema, this.activeIndex);
|
|
1559
|
+
this.ctrlOptions = E(o), this.ctrlOptions.type = e, this.ctrlKey++, this.key++;
|
|
1560
1560
|
}
|
|
1561
1561
|
}
|
|
1562
1562
|
},
|
|
1563
1563
|
beforeCreate() {
|
|
1564
|
-
|
|
1564
|
+
se.on("dev-action", ({ event: e, data: t }) => {
|
|
1565
1565
|
this.onDevAction(t.type, t.devId);
|
|
1566
1566
|
});
|
|
1567
1567
|
},
|
|
1568
1568
|
unmounted() {
|
|
1569
|
-
|
|
1569
|
+
se.off("dev-action");
|
|
1570
1570
|
},
|
|
1571
1571
|
methods: {
|
|
1572
1572
|
onDevAction(e, t) {
|
|
@@ -1575,26 +1575,26 @@ const kl = {
|
|
|
1575
1575
|
push(e) {
|
|
1576
1576
|
const t = "formItems";
|
|
1577
1577
|
this.ctrlOptions = {}, this.builderSchema[t] = this.builderSchema[t] || [];
|
|
1578
|
-
const
|
|
1579
|
-
this.activeCtrl =
|
|
1580
|
-
options:
|
|
1581
|
-
formItems:
|
|
1578
|
+
const o = this.ctrlMap[e];
|
|
1579
|
+
this.activeCtrl = o, this.builderSchema[t].push(E(o.default)), this.ctrlSchema = E({
|
|
1580
|
+
options: E(Me),
|
|
1581
|
+
formItems: E(o.builder)
|
|
1582
1582
|
}), this.ctrlKey++, this.key++, this.activeIndex = `${t}[${this.builderSchema[t].length - 1}]`, this.activeTab = "ctrl";
|
|
1583
1583
|
},
|
|
1584
1584
|
removeOne() {
|
|
1585
|
-
|
|
1585
|
+
$t(this.builderSchema, this.activeIndex), this.builderSchema = E(Et(this.builderSchema)), this.activeIndex = "", this.ctrlOptions = {}, this.ctrlSchema = {}, this.key++, this.ctrlKey++;
|
|
1586
1586
|
},
|
|
1587
1587
|
clicklabel() {
|
|
1588
1588
|
const e = this.activeIndex;
|
|
1589
1589
|
if (e.match(this.activeIndexReg)) {
|
|
1590
|
-
const
|
|
1590
|
+
const o = E(me(this.builderSchema, e)), n = o.type, l = this.ctrlMap[n];
|
|
1591
1591
|
if (!l) {
|
|
1592
1592
|
this.$message({ type: "warning", message: "尚未支持该组件的UI编辑" });
|
|
1593
1593
|
return;
|
|
1594
1594
|
}
|
|
1595
|
-
this.currentCtrlType =
|
|
1596
|
-
options:
|
|
1597
|
-
formItems:
|
|
1595
|
+
this.currentCtrlType = n, this.ctrlOptions = o, this.ctrlSchema = E({
|
|
1596
|
+
options: E(Me),
|
|
1597
|
+
formItems: E(l.builder)
|
|
1598
1598
|
}), this.ctrlKey++;
|
|
1599
1599
|
}
|
|
1600
1600
|
},
|
|
@@ -1609,11 +1609,11 @@ const kl = {
|
|
|
1609
1609
|
}
|
|
1610
1610
|
}
|
|
1611
1611
|
};
|
|
1612
|
-
function wl(e, t,
|
|
1613
|
-
const a =
|
|
1614
|
-
return i(),
|
|
1612
|
+
function wl(e, t, o, n, l, s) {
|
|
1613
|
+
const a = P("v-form"), c = Rt, d = he, f = P("JsonView"), p = P("VButton"), b = Ye, S = Ze, I = Xe, O = Qe, w = P("dev-layout");
|
|
1614
|
+
return i(), m(w, null, {
|
|
1615
1615
|
main: r(() => [
|
|
1616
|
-
l.builderSchema.formItems ? (i(),
|
|
1616
|
+
l.builderSchema.formItems ? (i(), m(a, X({
|
|
1617
1617
|
ref: "form",
|
|
1618
1618
|
key: l.key,
|
|
1619
1619
|
dev: !0
|
|
@@ -1624,11 +1624,11 @@ function wl(e, t, n, o, l, s) {
|
|
|
1624
1624
|
onClick: s.saveSchema
|
|
1625
1625
|
}, {
|
|
1626
1626
|
default: r(() => [...t[2] || (t[2] = [
|
|
1627
|
-
|
|
1627
|
+
T("保存页面配置", -1)
|
|
1628
1628
|
])]),
|
|
1629
1629
|
_: 1
|
|
1630
1630
|
}, 8, ["onClick"]),
|
|
1631
|
-
t[3] || (t[3] =
|
|
1631
|
+
t[3] || (t[3] = T(" ", -1)),
|
|
1632
1632
|
u(p, {
|
|
1633
1633
|
text: "PageSchema",
|
|
1634
1634
|
type: "modal"
|
|
@@ -1640,19 +1640,19 @@ function wl(e, t, n, o, l, s) {
|
|
|
1640
1640
|
})
|
|
1641
1641
|
]),
|
|
1642
1642
|
"right-aside": r(() => [
|
|
1643
|
-
l.activeIndex ? (i(),
|
|
1643
|
+
l.activeIndex ? (i(), m(O, { key: 0 }, {
|
|
1644
1644
|
default: r(() => [
|
|
1645
|
-
u(
|
|
1645
|
+
u(I, { label: "控件类型" }, {
|
|
1646
1646
|
default: r(() => [
|
|
1647
|
-
u(
|
|
1647
|
+
u(S, {
|
|
1648
1648
|
modelValue: l.currentCtrlType,
|
|
1649
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
1649
|
+
"onUpdate:modelValue": t[0] || (t[0] = (y) => l.currentCtrlType = y)
|
|
1650
1650
|
}, {
|
|
1651
1651
|
default: r(() => [
|
|
1652
|
-
(i(!0),
|
|
1653
|
-
key:
|
|
1654
|
-
label:
|
|
1655
|
-
value:
|
|
1652
|
+
(i(!0), v(A, null, V(l.types, (y, x) => (i(), m(b, {
|
|
1653
|
+
key: x,
|
|
1654
|
+
label: y.label,
|
|
1655
|
+
value: y.value
|
|
1656
1656
|
}, null, 8, ["label", "value"]))), 128))
|
|
1657
1657
|
]),
|
|
1658
1658
|
_: 1
|
|
@@ -1663,16 +1663,16 @@ function wl(e, t, n, o, l, s) {
|
|
|
1663
1663
|
]),
|
|
1664
1664
|
_: 1
|
|
1665
1665
|
})) : $("", !0),
|
|
1666
|
-
(i(),
|
|
1666
|
+
(i(), m(a, X({
|
|
1667
1667
|
key: l.ctrlKey,
|
|
1668
1668
|
modelValue: l.ctrlOptions,
|
|
1669
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
1669
|
+
"onUpdate:modelValue": t[1] || (t[1] = (y) => l.ctrlOptions = y)
|
|
1670
1670
|
}, l.ctrlSchema), null, 16, ["modelValue"]))
|
|
1671
1671
|
]),
|
|
1672
1672
|
_: 1
|
|
1673
1673
|
});
|
|
1674
1674
|
}
|
|
1675
|
-
const xl = /* @__PURE__ */
|
|
1675
|
+
const xl = /* @__PURE__ */ R(Sl, [["render", wl], ["__scopeId", "data-v-875f0171"]]), El = {
|
|
1676
1676
|
type: "input",
|
|
1677
1677
|
name: "文本框",
|
|
1678
1678
|
default: {
|
|
@@ -1818,7 +1818,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
1818
1818
|
}
|
|
1819
1819
|
],
|
|
1820
1820
|
trans(e) {
|
|
1821
|
-
const t =
|
|
1821
|
+
const t = E(e);
|
|
1822
1822
|
return e.optionType === 0 ? t.props && t.props.selectApi !== void 0 && delete t.props.selectApi : e.optionType === 1 && t.options && delete t.options, delete t.optionType, t;
|
|
1823
1823
|
}
|
|
1824
1824
|
}, Cl = {
|
|
@@ -1841,7 +1841,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
1841
1841
|
label: "字段key"
|
|
1842
1842
|
}
|
|
1843
1843
|
]
|
|
1844
|
-
},
|
|
1844
|
+
}, yt = {
|
|
1845
1845
|
options: {
|
|
1846
1846
|
labelPosition: "top",
|
|
1847
1847
|
submitButton: !1,
|
|
@@ -1900,7 +1900,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
1900
1900
|
label: "排序"
|
|
1901
1901
|
}
|
|
1902
1902
|
]
|
|
1903
|
-
},
|
|
1903
|
+
}, Ol = {
|
|
1904
1904
|
type: "enum",
|
|
1905
1905
|
name: "标签",
|
|
1906
1906
|
default: {
|
|
@@ -1976,7 +1976,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
1976
1976
|
label: "提示"
|
|
1977
1977
|
}
|
|
1978
1978
|
]
|
|
1979
|
-
},
|
|
1979
|
+
}, Bl = {
|
|
1980
1980
|
type: "icon",
|
|
1981
1981
|
name: "图标",
|
|
1982
1982
|
default: {
|
|
@@ -2134,9 +2134,9 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2134
2134
|
]
|
|
2135
2135
|
}, Dl = {
|
|
2136
2136
|
span: Tl,
|
|
2137
|
-
enum:
|
|
2137
|
+
enum: Ol,
|
|
2138
2138
|
html: $l,
|
|
2139
|
-
icon:
|
|
2139
|
+
icon: Bl,
|
|
2140
2140
|
image: Al,
|
|
2141
2141
|
json: Rl,
|
|
2142
2142
|
link: Pl,
|
|
@@ -2258,7 +2258,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2258
2258
|
}
|
|
2259
2259
|
}
|
|
2260
2260
|
]
|
|
2261
|
-
},
|
|
2261
|
+
}, Vl = {
|
|
2262
2262
|
type: "form",
|
|
2263
2263
|
name: "弹框表单",
|
|
2264
2264
|
default: {
|
|
@@ -2312,7 +2312,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2312
2312
|
label: "保存接口"
|
|
2313
2313
|
}
|
|
2314
2314
|
]
|
|
2315
|
-
},
|
|
2315
|
+
}, Ul = {
|
|
2316
2316
|
type: "table",
|
|
2317
2317
|
name: "弹框列表",
|
|
2318
2318
|
default: {
|
|
@@ -2369,10 +2369,10 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2369
2369
|
}, ql = {
|
|
2370
2370
|
jump: jl,
|
|
2371
2371
|
api: Nl,
|
|
2372
|
-
form:
|
|
2373
|
-
table:
|
|
2372
|
+
form: Vl,
|
|
2373
|
+
table: Ul
|
|
2374
2374
|
}, Hl = {
|
|
2375
|
-
components: { JsonView:
|
|
2375
|
+
components: { JsonView: tt, DevLayout: Kt, VTable: be, VForm: ne, VButton: ot },
|
|
2376
2376
|
props: {
|
|
2377
2377
|
schema: {
|
|
2378
2378
|
type: Object,
|
|
@@ -2381,13 +2381,13 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2381
2381
|
}
|
|
2382
2382
|
},
|
|
2383
2383
|
data() {
|
|
2384
|
-
const e =
|
|
2384
|
+
const e = go(this.$props.schema);
|
|
2385
2385
|
return delete e.listApi, e.list = [{}], {
|
|
2386
|
-
baseSchema:
|
|
2386
|
+
baseSchema: yt,
|
|
2387
2387
|
activeTab: "base",
|
|
2388
2388
|
builderSchema: Object.assign(
|
|
2389
2389
|
{},
|
|
2390
|
-
|
|
2390
|
+
yt,
|
|
2391
2391
|
e
|
|
2392
2392
|
),
|
|
2393
2393
|
baseOptions: {},
|
|
@@ -2411,8 +2411,8 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2411
2411
|
computed: {
|
|
2412
2412
|
types() {
|
|
2413
2413
|
const e = [], t = this.ctrlMap[this.activeBrick];
|
|
2414
|
-
return Object.keys(t).forEach((
|
|
2415
|
-
e.push({ value:
|
|
2414
|
+
return Object.keys(t).forEach((o) => {
|
|
2415
|
+
e.push({ value: o, label: t[o].name });
|
|
2416
2416
|
}), e;
|
|
2417
2417
|
},
|
|
2418
2418
|
getSaveSchema() {
|
|
@@ -2433,7 +2433,7 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2433
2433
|
deep: !0,
|
|
2434
2434
|
immediate: !0,
|
|
2435
2435
|
handler(e) {
|
|
2436
|
-
this.builderSchema =
|
|
2436
|
+
this.builderSchema = q(this.builderSchema, e), this.key++, this.updateBuilderSchema();
|
|
2437
2437
|
}
|
|
2438
2438
|
},
|
|
2439
2439
|
ctrlOptions: {
|
|
@@ -2443,14 +2443,14 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2443
2443
|
const t = this.activeIndex.match(this.activeIndexReg);
|
|
2444
2444
|
if (!t)
|
|
2445
2445
|
return;
|
|
2446
|
-
let
|
|
2447
|
-
t[1] === "headers" &&
|
|
2448
|
-
const
|
|
2449
|
-
if (!
|
|
2446
|
+
let o = this.builderSchema[t[1]][parseInt(t[2])].type;
|
|
2447
|
+
t[1] === "headers" && o === void 0 && (o = "span");
|
|
2448
|
+
const n = this.ctrlMap[this.activeBrick][o];
|
|
2449
|
+
if (!n)
|
|
2450
2450
|
return;
|
|
2451
|
-
const l =
|
|
2451
|
+
const l = n.trans ? n.trans(e) : e;
|
|
2452
2452
|
if (l && Object.keys(l).length > 0) {
|
|
2453
|
-
if (l.type =
|
|
2453
|
+
if (l.type = o, this.activeIndex.indexOf("[") > -1) {
|
|
2454
2454
|
const [s, a, c] = this.activeIndex.match(/(\w+)\[(\d+)\]/);
|
|
2455
2455
|
this.builderSchema[a][c] = { ...l };
|
|
2456
2456
|
} else
|
|
@@ -2463,24 +2463,24 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2463
2463
|
currentCtrlType: {
|
|
2464
2464
|
handler(e) {
|
|
2465
2465
|
const t = this.ctrlMap[this.activeBrick][e];
|
|
2466
|
-
this.ctrlSchema =
|
|
2467
|
-
options:
|
|
2468
|
-
formItems:
|
|
2466
|
+
this.ctrlSchema = E({
|
|
2467
|
+
options: E(De),
|
|
2468
|
+
formItems: E(t.builder)
|
|
2469
2469
|
});
|
|
2470
|
-
const
|
|
2471
|
-
|
|
2472
|
-
const
|
|
2473
|
-
this.ctrlOptions =
|
|
2470
|
+
const o = me(this.builderSchema, this.activeIndex);
|
|
2471
|
+
o.type = e;
|
|
2472
|
+
const n = E(o);
|
|
2473
|
+
this.ctrlOptions = n, n.text && (this.ctrlOptions.text = n.text, this.ctrlOptions.props = n.props || {}), this.ctrlKey++, this.key++, this.updateBuilderSchema();
|
|
2474
2474
|
}
|
|
2475
2475
|
}
|
|
2476
2476
|
},
|
|
2477
2477
|
beforeCreate() {
|
|
2478
|
-
|
|
2478
|
+
se.on("dev-action", ({ event: e, data: t }) => {
|
|
2479
2479
|
this.onDevAction(t.type, t.devId);
|
|
2480
2480
|
});
|
|
2481
2481
|
},
|
|
2482
2482
|
unmounted() {
|
|
2483
|
-
|
|
2483
|
+
se.off("dev-action");
|
|
2484
2484
|
},
|
|
2485
2485
|
methods: {
|
|
2486
2486
|
updateBuilderSchema() {
|
|
@@ -2505,48 +2505,48 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2505
2505
|
pushRowButton(e) {
|
|
2506
2506
|
this.push(e, "rowButton", "buttons", "buttons");
|
|
2507
2507
|
},
|
|
2508
|
-
push(e, t,
|
|
2509
|
-
const l = this.ctrlMap[
|
|
2508
|
+
push(e, t, o, n) {
|
|
2509
|
+
const l = this.ctrlMap[o];
|
|
2510
2510
|
if (!l[e]) {
|
|
2511
2511
|
this.$message({ type: "warning", message: "尚未支持此组件的UI编辑" });
|
|
2512
2512
|
return;
|
|
2513
2513
|
}
|
|
2514
|
-
this.activeCtrl = l[e], this.activeBrick =
|
|
2515
|
-
options:
|
|
2516
|
-
formItems:
|
|
2514
|
+
this.activeCtrl = l[e], this.activeBrick = n, this.ctrlOptions = {}, this.builderSchema[t] = this.builderSchema[t] || [], this.builderSchema[t].push(E(l[e].default)), this.ctrlSchema = E({
|
|
2515
|
+
options: E(De),
|
|
2516
|
+
formItems: E(l[e].builder)
|
|
2517
2517
|
}), this.key++, this.ctrlKey++, this.activeIndex = `${t}[${this.builderSchema[t].length - 1}]`, this.activeTab = "ctrl";
|
|
2518
2518
|
},
|
|
2519
2519
|
removeOne() {
|
|
2520
|
-
|
|
2520
|
+
$t(this.builderSchema, this.activeIndex), this.builderSchema = E(Et(this.builderSchema)), this.activeIndex = "", this.ctrlOptions = {}, this.ctrlSchema = {}, this.key++, this.ctrlKey++;
|
|
2521
2521
|
},
|
|
2522
2522
|
clicklabel() {
|
|
2523
2523
|
const e = this.activeIndex, t = e.match(this.activeIndexReg);
|
|
2524
2524
|
if (t) {
|
|
2525
|
-
const
|
|
2525
|
+
const o = E(me(this.builderSchema, e));
|
|
2526
2526
|
this.activeBrick = t[1], ["normalButton", "batchButton", "rowButton"].indexOf(t[1]) > -1 && (this.activeBrick = "buttons");
|
|
2527
|
-
let
|
|
2528
|
-
t[1] === "headers" &&
|
|
2529
|
-
const l = this.ctrlMap[this.activeBrick][
|
|
2527
|
+
let n = this.builderSchema[t[1]][parseInt(t[2])].type;
|
|
2528
|
+
t[1] === "headers" && n === void 0 && (n = "span");
|
|
2529
|
+
const l = this.ctrlMap[this.activeBrick][n];
|
|
2530
2530
|
if (!l) {
|
|
2531
2531
|
this.activeBrick, this.$message({ type: "warning", message: "尚未支持此组件的UI编辑" });
|
|
2532
2532
|
return;
|
|
2533
2533
|
}
|
|
2534
|
-
this.ctrlOptions =
|
|
2535
|
-
options:
|
|
2536
|
-
formItems:
|
|
2534
|
+
this.ctrlOptions = o, this.currentCtrlType = n, this.ctrlSchema = E({
|
|
2535
|
+
options: E(De),
|
|
2536
|
+
formItems: E(l.builder)
|
|
2537
2537
|
}), this.ctrlKey++;
|
|
2538
2538
|
}
|
|
2539
2539
|
},
|
|
2540
2540
|
saveSchema() {
|
|
2541
|
-
const { filter: e, headers: t, rowButton:
|
|
2541
|
+
const { filter: e, headers: t, rowButton: o, normalButton: n, batchButton: l } = this.currentBuilderSchema;
|
|
2542
2542
|
this.$http.request({
|
|
2543
2543
|
method: "POST",
|
|
2544
2544
|
url: "/devtool/page_schema",
|
|
2545
2545
|
data: {
|
|
2546
2546
|
filter: e,
|
|
2547
2547
|
headers: t,
|
|
2548
|
-
rowButton:
|
|
2549
|
-
normalButton:
|
|
2548
|
+
rowButton: o,
|
|
2549
|
+
normalButton: n,
|
|
2550
2550
|
batchButton: l
|
|
2551
2551
|
}
|
|
2552
2552
|
}).then(({ data: s }) => {
|
|
@@ -2555,9 +2555,9 @@ const xl = /* @__PURE__ */ P(Sl, [["render", wl], ["__scopeId", "data-v-875f0171
|
|
|
2555
2555
|
}
|
|
2556
2556
|
}
|
|
2557
2557
|
};
|
|
2558
|
-
function Fl(e, t,
|
|
2559
|
-
const a =
|
|
2560
|
-
return i(),
|
|
2558
|
+
function Fl(e, t, o, n, l, s) {
|
|
2559
|
+
const a = Oe, c = he, d = _e, f = P("v-table"), p = Rt, b = he, S = P("JsonView"), I = P("VButton"), O = Ye, w = Ze, y = Xe, x = Qe, F = P("v-form"), G = P("dev-layout");
|
|
2560
|
+
return i(), m(G, null, {
|
|
2561
2561
|
"left-aside": r(() => [
|
|
2562
2562
|
u(d, { style: { width: "200px" } }, {
|
|
2563
2563
|
default: r(() => [
|
|
@@ -2568,7 +2568,7 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2568
2568
|
"data-id": 22222
|
|
2569
2569
|
}, {
|
|
2570
2570
|
default: r(() => [...t[5] || (t[5] = [
|
|
2571
|
-
|
|
2571
|
+
T("添加搜索条件", -1)
|
|
2572
2572
|
])]),
|
|
2573
2573
|
_: 1
|
|
2574
2574
|
}),
|
|
@@ -2576,10 +2576,10 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2576
2576
|
default: r(() => [
|
|
2577
2577
|
u(c, {
|
|
2578
2578
|
class: "ctrl-btn",
|
|
2579
|
-
onClick: t[0] || (t[0] = (
|
|
2579
|
+
onClick: t[0] || (t[0] = (g) => s.pushFilter("input"))
|
|
2580
2580
|
}, {
|
|
2581
2581
|
default: r(() => [...t[6] || (t[6] = [
|
|
2582
|
-
|
|
2582
|
+
T("文本框", -1)
|
|
2583
2583
|
])]),
|
|
2584
2584
|
_: 1
|
|
2585
2585
|
})
|
|
@@ -2590,10 +2590,10 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2590
2590
|
default: r(() => [
|
|
2591
2591
|
u(c, {
|
|
2592
2592
|
class: "ctrl-btn",
|
|
2593
|
-
onClick: t[1] || (t[1] = (
|
|
2593
|
+
onClick: t[1] || (t[1] = (g) => s.pushFilter("select"))
|
|
2594
2594
|
}, {
|
|
2595
2595
|
default: r(() => [...t[7] || (t[7] = [
|
|
2596
|
-
|
|
2596
|
+
T("下拉框", -1)
|
|
2597
2597
|
])]),
|
|
2598
2598
|
_: 1
|
|
2599
2599
|
})
|
|
@@ -2604,10 +2604,10 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2604
2604
|
default: r(() => [
|
|
2605
2605
|
u(c, {
|
|
2606
2606
|
class: "ctrl-btn",
|
|
2607
|
-
onClick: t[2] || (t[2] = (
|
|
2607
|
+
onClick: t[2] || (t[2] = (g) => s.pushFilter("date"))
|
|
2608
2608
|
}, {
|
|
2609
2609
|
default: r(() => [...t[8] || (t[8] = [
|
|
2610
|
-
|
|
2610
|
+
T("日期", -1)
|
|
2611
2611
|
])]),
|
|
2612
2612
|
_: 1
|
|
2613
2613
|
})
|
|
@@ -2621,21 +2621,21 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2621
2621
|
default: r(() => [
|
|
2622
2622
|
u(a, { class: "title" }, {
|
|
2623
2623
|
default: r(() => [...t[9] || (t[9] = [
|
|
2624
|
-
|
|
2624
|
+
T("添加列表项", -1)
|
|
2625
2625
|
])]),
|
|
2626
2626
|
_: 1
|
|
2627
2627
|
}),
|
|
2628
|
-
(i(!0),
|
|
2629
|
-
key: `column-${
|
|
2628
|
+
(i(!0), v(A, null, V(Object.keys(l.ctrlMap.headers), (g, M) => (i(), m(a, {
|
|
2629
|
+
key: `column-${M}`,
|
|
2630
2630
|
class: "ctrl"
|
|
2631
2631
|
}, {
|
|
2632
2632
|
default: r(() => [
|
|
2633
2633
|
u(c, {
|
|
2634
2634
|
class: "ctrl-btn",
|
|
2635
|
-
onClick: (
|
|
2635
|
+
onClick: (ee) => s.pushHeaders(l.ctrlMap.headers[g].type)
|
|
2636
2636
|
}, {
|
|
2637
2637
|
default: r(() => [
|
|
2638
|
-
|
|
2638
|
+
T(B(l.ctrlMap.headers[g].name), 1)
|
|
2639
2639
|
]),
|
|
2640
2640
|
_: 2
|
|
2641
2641
|
}, 1032, ["onClick"])
|
|
@@ -2649,21 +2649,21 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2649
2649
|
default: r(() => [
|
|
2650
2650
|
u(a, { class: "title" }, {
|
|
2651
2651
|
default: r(() => [...t[10] || (t[10] = [
|
|
2652
|
-
|
|
2652
|
+
T("添加行按钮", -1)
|
|
2653
2653
|
])]),
|
|
2654
2654
|
_: 1
|
|
2655
2655
|
}),
|
|
2656
|
-
(i(!0),
|
|
2657
|
-
key: `column-${
|
|
2656
|
+
(i(!0), v(A, null, V(Object.keys(l.ctrlMap.buttons), (g, M) => (i(), m(a, {
|
|
2657
|
+
key: `column-${M}`,
|
|
2658
2658
|
class: "ctrl"
|
|
2659
2659
|
}, {
|
|
2660
2660
|
default: r(() => [
|
|
2661
2661
|
u(c, {
|
|
2662
2662
|
class: "ctrl-btn",
|
|
2663
|
-
onClick: (
|
|
2663
|
+
onClick: (ee) => s.pushRowButton(l.ctrlMap.buttons[g].type)
|
|
2664
2664
|
}, {
|
|
2665
2665
|
default: r(() => [
|
|
2666
|
-
|
|
2666
|
+
T(B(l.ctrlMap.buttons[g].name), 1)
|
|
2667
2667
|
]),
|
|
2668
2668
|
_: 2
|
|
2669
2669
|
}, 1032, ["onClick"])
|
|
@@ -2677,21 +2677,21 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2677
2677
|
default: r(() => [
|
|
2678
2678
|
u(a, { class: "title" }, {
|
|
2679
2679
|
default: r(() => [...t[11] || (t[11] = [
|
|
2680
|
-
|
|
2680
|
+
T("添加常规按钮", -1)
|
|
2681
2681
|
])]),
|
|
2682
2682
|
_: 1
|
|
2683
2683
|
}),
|
|
2684
|
-
(i(!0),
|
|
2685
|
-
key: `column-${
|
|
2684
|
+
(i(!0), v(A, null, V(Object.keys(l.ctrlMap.buttons), (g, M) => (i(), m(a, {
|
|
2685
|
+
key: `column-${M}`,
|
|
2686
2686
|
class: "ctrl"
|
|
2687
2687
|
}, {
|
|
2688
2688
|
default: r(() => [
|
|
2689
2689
|
u(c, {
|
|
2690
2690
|
class: "ctrl-btn",
|
|
2691
|
-
onClick: (
|
|
2691
|
+
onClick: (ee) => s.pushNormalButton(l.ctrlMap.buttons[g].type)
|
|
2692
2692
|
}, {
|
|
2693
2693
|
default: r(() => [
|
|
2694
|
-
|
|
2694
|
+
T(B(l.ctrlMap.buttons[g].name), 1)
|
|
2695
2695
|
]),
|
|
2696
2696
|
_: 2
|
|
2697
2697
|
}, 1032, ["onClick"])
|
|
@@ -2702,7 +2702,7 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2702
2702
|
default: r(() => [
|
|
2703
2703
|
u(c, { class: "ctrl-btn" }, {
|
|
2704
2704
|
default: r(() => [...t[12] || (t[12] = [
|
|
2705
|
-
|
|
2705
|
+
T("按钮组", -1)
|
|
2706
2706
|
])]),
|
|
2707
2707
|
_: 1
|
|
2708
2708
|
})
|
|
@@ -2716,21 +2716,21 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2716
2716
|
default: r(() => [
|
|
2717
2717
|
u(a, { class: "title" }, {
|
|
2718
2718
|
default: r(() => [...t[13] || (t[13] = [
|
|
2719
|
-
|
|
2719
|
+
T("添加批量按钮", -1)
|
|
2720
2720
|
])]),
|
|
2721
2721
|
_: 1
|
|
2722
2722
|
}),
|
|
2723
|
-
(i(!0),
|
|
2724
|
-
key: `column-${
|
|
2723
|
+
(i(!0), v(A, null, V(Object.keys(l.ctrlMap.buttons), (g, M) => (i(), m(a, {
|
|
2724
|
+
key: `column-${M}`,
|
|
2725
2725
|
class: "ctrl"
|
|
2726
2726
|
}, {
|
|
2727
2727
|
default: r(() => [
|
|
2728
2728
|
u(c, {
|
|
2729
2729
|
class: "ctrl-btn",
|
|
2730
|
-
onClick: (
|
|
2730
|
+
onClick: (ee) => s.pushBatchButton(l.ctrlMap.buttons[g].type)
|
|
2731
2731
|
}, {
|
|
2732
2732
|
default: r(() => [
|
|
2733
|
-
|
|
2733
|
+
T(B(l.ctrlMap.buttons[g].name), 1)
|
|
2734
2734
|
]),
|
|
2735
2735
|
_: 2
|
|
2736
2736
|
}, 1032, ["onClick"])
|
|
@@ -2741,7 +2741,7 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2741
2741
|
default: r(() => [
|
|
2742
2742
|
u(c, { class: "ctrl-btn" }, {
|
|
2743
2743
|
default: r(() => [...t[14] || (t[14] = [
|
|
2744
|
-
|
|
2744
|
+
T("按钮组", -1)
|
|
2745
2745
|
])]),
|
|
2746
2746
|
_: 1
|
|
2747
2747
|
})
|
|
@@ -2756,46 +2756,46 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2756
2756
|
})
|
|
2757
2757
|
]),
|
|
2758
2758
|
main: r(() => [
|
|
2759
|
-
(i(),
|
|
2759
|
+
(i(), m(f, X({
|
|
2760
2760
|
ref: "table",
|
|
2761
2761
|
key: l.key,
|
|
2762
2762
|
dev: !0
|
|
2763
2763
|
}, l.builderSchema), null, 16)),
|
|
2764
2764
|
u(p),
|
|
2765
|
-
u(
|
|
2765
|
+
u(b, {
|
|
2766
2766
|
type: "primary",
|
|
2767
2767
|
onClick: s.saveSchema
|
|
2768
2768
|
}, {
|
|
2769
2769
|
default: r(() => [...t[15] || (t[15] = [
|
|
2770
|
-
|
|
2770
|
+
T("保存页面配置", -1)
|
|
2771
2771
|
])]),
|
|
2772
2772
|
_: 1
|
|
2773
2773
|
}, 8, ["onClick"]),
|
|
2774
|
-
t[16] || (t[16] =
|
|
2775
|
-
u(
|
|
2774
|
+
t[16] || (t[16] = T(" ", -1)),
|
|
2775
|
+
u(I, {
|
|
2776
2776
|
text: "PageSchema",
|
|
2777
2777
|
type: "modal"
|
|
2778
2778
|
}, {
|
|
2779
2779
|
default: r(() => [
|
|
2780
|
-
u(
|
|
2780
|
+
u(S, { data: s.getSaveSchema }, null, 8, ["data"])
|
|
2781
2781
|
]),
|
|
2782
2782
|
_: 1
|
|
2783
2783
|
})
|
|
2784
2784
|
]),
|
|
2785
2785
|
"right-aside": r(() => [
|
|
2786
|
-
l.activeIndex ? (i(),
|
|
2786
|
+
l.activeIndex ? (i(), m(x, { key: 0 }, {
|
|
2787
2787
|
default: r(() => [
|
|
2788
|
-
u(
|
|
2788
|
+
u(y, { label: "控件类型" }, {
|
|
2789
2789
|
default: r(() => [
|
|
2790
|
-
u(
|
|
2790
|
+
u(w, {
|
|
2791
2791
|
modelValue: l.currentCtrlType,
|
|
2792
|
-
"onUpdate:modelValue": t[3] || (t[3] = (
|
|
2792
|
+
"onUpdate:modelValue": t[3] || (t[3] = (g) => l.currentCtrlType = g)
|
|
2793
2793
|
}, {
|
|
2794
2794
|
default: r(() => [
|
|
2795
|
-
(i(!0),
|
|
2796
|
-
key:
|
|
2797
|
-
label:
|
|
2798
|
-
value:
|
|
2795
|
+
(i(!0), v(A, null, V(s.types, (g, M) => (i(), m(O, {
|
|
2796
|
+
key: M,
|
|
2797
|
+
label: g.label,
|
|
2798
|
+
value: g.value
|
|
2799
2799
|
}, null, 8, ["label", "value"]))), 128))
|
|
2800
2800
|
]),
|
|
2801
2801
|
_: 1
|
|
@@ -2806,31 +2806,31 @@ function Fl(e, t, n, o, l, s) {
|
|
|
2806
2806
|
]),
|
|
2807
2807
|
_: 1
|
|
2808
2808
|
})) : $("", !0),
|
|
2809
|
-
(i(),
|
|
2809
|
+
(i(), m(F, X({
|
|
2810
2810
|
key: l.ctrlKey,
|
|
2811
2811
|
modelValue: l.ctrlOptions,
|
|
2812
|
-
"onUpdate:modelValue": t[4] || (t[4] = (
|
|
2812
|
+
"onUpdate:modelValue": t[4] || (t[4] = (g) => l.ctrlOptions = g)
|
|
2813
2813
|
}, l.ctrlSchema), null, 16, ["modelValue"]))
|
|
2814
2814
|
]),
|
|
2815
2815
|
_: 1
|
|
2816
2816
|
});
|
|
2817
2817
|
}
|
|
2818
|
-
const Gl = /* @__PURE__ */
|
|
2818
|
+
const Gl = /* @__PURE__ */ R(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f"]]), Kl = "rtl", zl = {
|
|
2819
2819
|
__name: "PageEditor",
|
|
2820
2820
|
setup(e) {
|
|
2821
|
-
const t =
|
|
2822
|
-
|
|
2823
|
-
const
|
|
2821
|
+
const t = C(!1);
|
|
2822
|
+
C(1);
|
|
2823
|
+
const o = Q(), n = Y(), l = k(() => n.pages[o.path]);
|
|
2824
2824
|
return (s, a) => {
|
|
2825
|
-
const c =
|
|
2826
|
-
return i(),
|
|
2825
|
+
const c = P("VIcon"), d = Pt;
|
|
2826
|
+
return i(), v(A, null, [
|
|
2827
2827
|
u(c, {
|
|
2828
2828
|
name: "ra-set",
|
|
2829
|
-
onClick: a[0] || (a[0] = (f) => t.value = !
|
|
2829
|
+
onClick: a[0] || (a[0] = (f) => t.value = !h(t))
|
|
2830
2830
|
}),
|
|
2831
2831
|
u(d, {
|
|
2832
|
-
modelValue:
|
|
2833
|
-
"onUpdate:modelValue": a[1] || (a[1] = (f) =>
|
|
2832
|
+
modelValue: h(t),
|
|
2833
|
+
"onUpdate:modelValue": a[1] || (a[1] = (f) => Ke(t) ? t.value = f : null),
|
|
2834
2834
|
title: "页面设计",
|
|
2835
2835
|
class: "my-drawer",
|
|
2836
2836
|
direction: Kl,
|
|
@@ -2839,13 +2839,13 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
2839
2839
|
"append-to-body": ""
|
|
2840
2840
|
}, {
|
|
2841
2841
|
default: r(() => [
|
|
2842
|
-
|
|
2842
|
+
h(l).formItems !== void 0 ? (i(), m(xl, {
|
|
2843
2843
|
key: 0,
|
|
2844
|
-
schema:
|
|
2844
|
+
schema: h(l)
|
|
2845
2845
|
}, null, 8, ["schema"])) : $("", !0),
|
|
2846
|
-
|
|
2846
|
+
h(l).headers !== void 0 ? (i(), m(Gl, {
|
|
2847
2847
|
key: 1,
|
|
2848
|
-
schema:
|
|
2848
|
+
schema: h(l)
|
|
2849
2849
|
}, null, 8, ["schema"])) : $("", !0)
|
|
2850
2850
|
]),
|
|
2851
2851
|
_: 1
|
|
@@ -2859,136 +2859,136 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
2859
2859
|
}, Ql = {
|
|
2860
2860
|
class: "right-item-button",
|
|
2861
2861
|
style: { padding: "0" }
|
|
2862
|
-
}, Xl = { class: "user-info" }, Zl = { class: "user-name" }, Yl = /* @__PURE__ */
|
|
2862
|
+
}, Xl = { class: "user-info" }, Zl = { class: "user-name" }, Yl = /* @__PURE__ */ z({
|
|
2863
2863
|
__name: "Navbar",
|
|
2864
2864
|
setup(e) {
|
|
2865
|
-
const t = Y(),
|
|
2866
|
-
|
|
2867
|
-
const l =
|
|
2868
|
-
|
|
2869
|
-
const s = k(() =>
|
|
2870
|
-
const D =
|
|
2871
|
-
return
|
|
2872
|
-
background: "linear-gradient(135deg, rgba(
|
|
2873
|
-
borderBottom: "1px solid
|
|
2874
|
-
boxShadow: "0
|
|
2865
|
+
const t = Y(), o = U(), n = j();
|
|
2866
|
+
C(!1);
|
|
2867
|
+
const l = C(!1);
|
|
2868
|
+
C(""), C(0);
|
|
2869
|
+
const s = k(() => o.defaultAvatar), a = k(() => t.sidebar), c = k(() => t.device), d = k(() => n.avatar), f = k(() => n.name), p = k(() => n.nickname), b = k(() => o.nav), S = k(() => o), I = k(() => n), O = k(() => o.showPageJsonSchema || !1), { isDark: w, toggleTheme: y } = qt(), x = k(() => {
|
|
2870
|
+
const D = S.value.envColor?.[I.value.env];
|
|
2871
|
+
return w.value ? {
|
|
2872
|
+
background: "linear-gradient(135deg, rgba(0, 176, 116, 0.15) 0%, rgba(2, 6, 23, 0.95) 100%)",
|
|
2873
|
+
borderBottom: "1px solid var(--border-color)",
|
|
2874
|
+
boxShadow: "0 4px 12px rgba(0, 0, 0, 0.3)"
|
|
2875
2875
|
} : D ? {
|
|
2876
|
-
background: `linear-gradient(135deg, rgba(255, 255, 255, 0.
|
|
2877
|
-
borderBottom: "1px solid
|
|
2878
|
-
boxShadow: "0 1px 4px rgba(
|
|
2876
|
+
background: `linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(243, 244, 248, 0.9) 60%, ${D} 100%)`,
|
|
2877
|
+
borderBottom: "1px solid var(--border-color)",
|
|
2878
|
+
boxShadow: "0 1px 4px rgba(0, 0, 0, 0.05)"
|
|
2879
2879
|
} : {
|
|
2880
|
-
background: "linear-gradient(135deg, rgba(255, 255, 255, 0.
|
|
2881
|
-
borderBottom: "1px solid
|
|
2882
|
-
boxShadow: "0 1px
|
|
2880
|
+
background: "linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(243, 244, 248, 0.95) 70%, #ffffff 100%)",
|
|
2881
|
+
borderBottom: "1px solid var(--border-color)",
|
|
2882
|
+
boxShadow: "0 1px 10px rgba(0, 0, 0, 0.03)"
|
|
2883
2883
|
};
|
|
2884
2884
|
});
|
|
2885
2885
|
Ie(() => {
|
|
2886
|
-
|
|
2887
|
-
const D =
|
|
2888
|
-
D.length > 0 && !
|
|
2886
|
+
It("el-submenu is-active");
|
|
2887
|
+
const D = W("navBarNotice") || "";
|
|
2888
|
+
D.length > 0 && !W("closeNavNotice") && io(D) && window?.App?.config?.globalProperties?.$notify({
|
|
2889
2889
|
title: "提示",
|
|
2890
2890
|
message: D,
|
|
2891
2891
|
dangerouslyUseHTMLString: !0,
|
|
2892
2892
|
duration: 0,
|
|
2893
|
-
onClose:
|
|
2894
|
-
}),
|
|
2895
|
-
elRef:
|
|
2896
|
-
waterMark:
|
|
2893
|
+
onClose: ao
|
|
2894
|
+
}), S.value.envColor?.[I.value.env] && Lo({
|
|
2895
|
+
elRef: F.value.$el,
|
|
2896
|
+
waterMark: I.value.env,
|
|
2897
2897
|
color: "skyblue",
|
|
2898
2898
|
size: "20"
|
|
2899
2899
|
});
|
|
2900
2900
|
});
|
|
2901
|
-
const
|
|
2902
|
-
|
|
2903
|
-
|
|
2901
|
+
const F = C(), G = C(""), g = C(!1);
|
|
2902
|
+
ye([d, s], () => {
|
|
2903
|
+
g.value = !1, G.value = d.value || s.value || "";
|
|
2904
2904
|
}, { immediate: !0 });
|
|
2905
|
-
const
|
|
2906
|
-
const D = p.value || f.value ||
|
|
2905
|
+
const M = k(() => {
|
|
2906
|
+
const D = p.value || f.value || o.title || "用户";
|
|
2907
2907
|
return D ? D.toString().trim().charAt(0).toUpperCase() : "用";
|
|
2908
2908
|
});
|
|
2909
|
-
function
|
|
2909
|
+
function ee() {
|
|
2910
2910
|
t.toggleSideBar();
|
|
2911
2911
|
}
|
|
2912
|
-
async function
|
|
2913
|
-
await
|
|
2912
|
+
async function Ae() {
|
|
2913
|
+
await n.logout();
|
|
2914
2914
|
const D = window?.App?.config?.globalProperties?.$router?.currentRoute?.value;
|
|
2915
2915
|
location.reload(`${location.origin}/#/login?redirect=${D?.fullPath || "/"}`);
|
|
2916
2916
|
}
|
|
2917
|
-
function
|
|
2918
|
-
return
|
|
2917
|
+
function W(D) {
|
|
2918
|
+
return o[D];
|
|
2919
2919
|
}
|
|
2920
|
-
async function
|
|
2921
|
-
|
|
2920
|
+
async function ao() {
|
|
2921
|
+
o.updateSettings({ closeNavNotice: !0 }), ro(W("navBarNotice"));
|
|
2922
2922
|
}
|
|
2923
|
-
function
|
|
2923
|
+
function io(D) {
|
|
2924
2924
|
const N = "dismiss:navbar_notice";
|
|
2925
2925
|
return ke.exist(N) ? ke.get(N) !== D : !0;
|
|
2926
2926
|
}
|
|
2927
|
-
function
|
|
2927
|
+
function ro(D) {
|
|
2928
2928
|
ke.set("dismiss:navbar_notice", D);
|
|
2929
2929
|
}
|
|
2930
|
-
function
|
|
2931
|
-
|
|
2930
|
+
function co() {
|
|
2931
|
+
g.value || (g.value = !0, G.value = "");
|
|
2932
2932
|
}
|
|
2933
2933
|
return (D, N) => {
|
|
2934
|
-
const
|
|
2935
|
-
return i(),
|
|
2934
|
+
const rt = Oe, uo = Mt, po = Lt, fo = on, ct = ln, mo = nn, ho = tn, bo = Pt, yo = _e;
|
|
2935
|
+
return i(), m(yo, {
|
|
2936
2936
|
ref_key: "header",
|
|
2937
|
-
ref:
|
|
2937
|
+
ref: F,
|
|
2938
2938
|
class: "navbar",
|
|
2939
|
-
style:
|
|
2939
|
+
style: ko(x.value)
|
|
2940
2940
|
}, {
|
|
2941
2941
|
default: r(() => [
|
|
2942
|
-
u(
|
|
2942
|
+
u(rt, { span: 16 }, {
|
|
2943
2943
|
default: r(() => [
|
|
2944
2944
|
u(ll, {
|
|
2945
2945
|
"is-active": a.value.opened,
|
|
2946
2946
|
class: "hamburger-container",
|
|
2947
|
-
onToggleClick:
|
|
2947
|
+
onToggleClick: ee
|
|
2948
2948
|
}, null, 8, ["is-active"]),
|
|
2949
|
-
c.value !== "mobile" ? (i(),
|
|
2949
|
+
c.value !== "mobile" ? (i(), m(tl, {
|
|
2950
2950
|
key: 0,
|
|
2951
2951
|
class: "breadcrumb-container"
|
|
2952
2952
|
})) : $("", !0)
|
|
2953
2953
|
]),
|
|
2954
2954
|
_: 1
|
|
2955
2955
|
}),
|
|
2956
|
-
u(
|
|
2956
|
+
u(rt, { span: 8 }, {
|
|
2957
2957
|
default: r(() => [
|
|
2958
|
-
|
|
2959
|
-
|
|
2958
|
+
_("div", Jl, [
|
|
2959
|
+
O.value ? (i(), v("div", Wl, [
|
|
2960
2960
|
u(zl)
|
|
2961
2961
|
])) : $("", !0),
|
|
2962
|
-
|
|
2963
|
-
u(
|
|
2962
|
+
_("div", Ql, [
|
|
2963
|
+
u(h(ot), { buttons: b.value }, null, 8, ["buttons"])
|
|
2964
2964
|
]),
|
|
2965
|
-
u(
|
|
2965
|
+
u(po, {
|
|
2966
2966
|
placement: "bottom",
|
|
2967
|
-
content:
|
|
2967
|
+
content: h(w) ? "切换为明亮模式" : "切换为暗黑模式"
|
|
2968
2968
|
}, {
|
|
2969
2969
|
default: r(() => [
|
|
2970
|
-
|
|
2970
|
+
_("div", {
|
|
2971
2971
|
class: "right-item theme-toggle",
|
|
2972
2972
|
role: "button",
|
|
2973
2973
|
tabindex: "0",
|
|
2974
2974
|
onClick: N[0] || (N[0] = //@ts-ignore
|
|
2975
|
-
(...
|
|
2975
|
+
(...ae) => h(y) && h(y)(...ae)),
|
|
2976
2976
|
onKeydown: [
|
|
2977
|
-
N[1] || (N[1] =
|
|
2977
|
+
N[1] || (N[1] = ut(Ne(
|
|
2978
2978
|
//@ts-ignore
|
|
2979
|
-
(...
|
|
2979
|
+
(...ae) => h(y) && h(y)(...ae),
|
|
2980
2980
|
["prevent"]
|
|
2981
2981
|
), ["enter"])),
|
|
2982
|
-
N[2] || (N[2] =
|
|
2982
|
+
N[2] || (N[2] = ut(Ne(
|
|
2983
2983
|
//@ts-ignore
|
|
2984
|
-
(...
|
|
2984
|
+
(...ae) => h(y) && h(y)(...ae),
|
|
2985
2985
|
["prevent"]
|
|
2986
2986
|
), ["space"]))
|
|
2987
2987
|
]
|
|
2988
2988
|
}, [
|
|
2989
|
-
u(
|
|
2989
|
+
u(uo, null, {
|
|
2990
2990
|
default: r(() => [
|
|
2991
|
-
(i(),
|
|
2991
|
+
(i(), m(ze(h(w) ? h(gn) : h(kn))))
|
|
2992
2992
|
]),
|
|
2993
2993
|
_: 1
|
|
2994
2994
|
})
|
|
@@ -2996,29 +2996,29 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
2996
2996
|
]),
|
|
2997
2997
|
_: 1
|
|
2998
2998
|
}, 8, ["content"]),
|
|
2999
|
-
u(
|
|
2999
|
+
u(ho, {
|
|
3000
3000
|
class: "right-item",
|
|
3001
3001
|
trigger: "click"
|
|
3002
3002
|
}, {
|
|
3003
3003
|
dropdown: r(() => [
|
|
3004
|
-
u(
|
|
3004
|
+
u(mo, { class: "user-dropdown" }, {
|
|
3005
3005
|
default: r(() => [
|
|
3006
|
-
u(
|
|
3006
|
+
u(ct, {
|
|
3007
3007
|
icon: "oms-icon-index",
|
|
3008
|
-
onClick: N[3] || (N[3] = (
|
|
3008
|
+
onClick: N[3] || (N[3] = (ae) => D.$router.push("/"))
|
|
3009
3009
|
}, {
|
|
3010
3010
|
default: r(() => [...N[4] || (N[4] = [
|
|
3011
|
-
|
|
3011
|
+
T("首页", -1)
|
|
3012
3012
|
])]),
|
|
3013
3013
|
_: 1
|
|
3014
3014
|
}),
|
|
3015
|
-
u(
|
|
3015
|
+
u(ct, {
|
|
3016
3016
|
divided: "",
|
|
3017
3017
|
icon: "el-icon-switch-button",
|
|
3018
|
-
onClick:
|
|
3018
|
+
onClick: Ae
|
|
3019
3019
|
}, {
|
|
3020
3020
|
default: r(() => [...N[5] || (N[5] = [
|
|
3021
|
-
|
|
3021
|
+
T("退出登录", -1)
|
|
3022
3022
|
])]),
|
|
3023
3023
|
_: 1
|
|
3024
3024
|
})
|
|
@@ -3027,19 +3027,19 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
3027
3027
|
})
|
|
3028
3028
|
]),
|
|
3029
3029
|
default: r(() => [
|
|
3030
|
-
|
|
3031
|
-
u(
|
|
3030
|
+
_("div", Xl, [
|
|
3031
|
+
u(fo, {
|
|
3032
3032
|
class: "user-avatar",
|
|
3033
3033
|
size: 32,
|
|
3034
|
-
src:
|
|
3035
|
-
onError:
|
|
3034
|
+
src: G.value || void 0,
|
|
3035
|
+
onError: co
|
|
3036
3036
|
}, {
|
|
3037
3037
|
default: r(() => [
|
|
3038
|
-
|
|
3038
|
+
T(B(M.value), 1)
|
|
3039
3039
|
]),
|
|
3040
3040
|
_: 1
|
|
3041
3041
|
}, 8, ["src"]),
|
|
3042
|
-
|
|
3042
|
+
_("span", Zl, B(p.value || f.value), 1)
|
|
3043
3043
|
])
|
|
3044
3044
|
]),
|
|
3045
3045
|
_: 1
|
|
@@ -3048,7 +3048,7 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
3048
3048
|
]),
|
|
3049
3049
|
_: 1
|
|
3050
3050
|
}),
|
|
3051
|
-
l.value ? (i(),
|
|
3051
|
+
l.value ? (i(), m(bo, {
|
|
3052
3052
|
key: 0,
|
|
3053
3053
|
"with-header": !1,
|
|
3054
3054
|
size: "50%"
|
|
@@ -3058,75 +3058,75 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
3058
3058
|
}, 8, ["style"]);
|
|
3059
3059
|
};
|
|
3060
3060
|
}
|
|
3061
|
-
}), es = /* @__PURE__ */
|
|
3061
|
+
}), es = /* @__PURE__ */ R(Yl, [["__scopeId", "data-v-098b16ba"]]), ts = { class: "sidebar-logo-fallback" }, os = {
|
|
3062
3062
|
key: 1,
|
|
3063
3063
|
class: "sidebar-logo-fallback"
|
|
3064
|
-
},
|
|
3064
|
+
}, ns = { class: "sidebar-logo-fallback" }, ls = {
|
|
3065
3065
|
key: 1,
|
|
3066
3066
|
class: "sidebar-logo-fallback"
|
|
3067
|
-
}, ss = { class: "sidebar-title" }, as = /* @__PURE__ */
|
|
3067
|
+
}, ss = { class: "sidebar-title" }, as = /* @__PURE__ */ z({
|
|
3068
3068
|
__name: "Logo",
|
|
3069
3069
|
props: {
|
|
3070
3070
|
collapse: { type: Boolean }
|
|
3071
3071
|
},
|
|
3072
3072
|
setup(e) {
|
|
3073
|
-
const t =
|
|
3074
|
-
const d =
|
|
3073
|
+
const t = U(), o = k(() => t.title), n = k(() => t.logo), l = C(!1), s = k(() => !!n.value && !l.value), a = k(() => {
|
|
3074
|
+
const d = o.value || "OMS";
|
|
3075
3075
|
return d ? d.toString().trim().charAt(0).toUpperCase() : "O";
|
|
3076
3076
|
});
|
|
3077
|
-
|
|
3077
|
+
ye(n, () => {
|
|
3078
3078
|
l.value = !1;
|
|
3079
3079
|
}, { immediate: !0 });
|
|
3080
3080
|
function c() {
|
|
3081
3081
|
l.value = !0;
|
|
3082
3082
|
}
|
|
3083
3083
|
return (d, f) => {
|
|
3084
|
-
const p =
|
|
3085
|
-
return i(),
|
|
3086
|
-
class:
|
|
3084
|
+
const p = sn, b = P("router-link");
|
|
3085
|
+
return i(), v("div", {
|
|
3086
|
+
class: te(["sidebar-logo-container", { collapse: e.collapse }])
|
|
3087
3087
|
}, [
|
|
3088
|
-
u(
|
|
3088
|
+
u(xt, { name: "sidebarLogoFade" }, {
|
|
3089
3089
|
default: r(() => [
|
|
3090
|
-
e.collapse ? (i(),
|
|
3090
|
+
e.collapse ? (i(), m(b, {
|
|
3091
3091
|
key: "collapse",
|
|
3092
3092
|
class: "sidebar-logo-link",
|
|
3093
3093
|
to: "/"
|
|
3094
3094
|
}, {
|
|
3095
3095
|
default: r(() => [
|
|
3096
|
-
s.value ? (i(),
|
|
3096
|
+
s.value ? (i(), m(p, {
|
|
3097
3097
|
key: 0,
|
|
3098
|
-
src:
|
|
3098
|
+
src: n.value || "",
|
|
3099
3099
|
fit: "contain",
|
|
3100
3100
|
class: "sidebar-logo",
|
|
3101
3101
|
onError: c
|
|
3102
3102
|
}, {
|
|
3103
3103
|
error: r(() => [
|
|
3104
|
-
|
|
3104
|
+
_("div", ts, B(a.value), 1)
|
|
3105
3105
|
]),
|
|
3106
3106
|
_: 1
|
|
3107
|
-
}, 8, ["src"])) : (i(),
|
|
3108
|
-
f[0] || (f[0] =
|
|
3107
|
+
}, 8, ["src"])) : (i(), v("div", os, B(a.value), 1)),
|
|
3108
|
+
f[0] || (f[0] = _("div", { class: "sidebar-subtitle" }, "系统", -1))
|
|
3109
3109
|
]),
|
|
3110
3110
|
_: 1
|
|
3111
|
-
})) : (i(),
|
|
3111
|
+
})) : (i(), m(b, {
|
|
3112
3112
|
key: "expand",
|
|
3113
3113
|
class: "sidebar-logo-link",
|
|
3114
3114
|
to: "/"
|
|
3115
3115
|
}, {
|
|
3116
3116
|
default: r(() => [
|
|
3117
|
-
s.value ? (i(),
|
|
3117
|
+
s.value ? (i(), m(p, {
|
|
3118
3118
|
key: 0,
|
|
3119
|
-
src:
|
|
3119
|
+
src: n.value || "",
|
|
3120
3120
|
fit: "contain",
|
|
3121
3121
|
class: "sidebar-logo",
|
|
3122
3122
|
onError: c
|
|
3123
3123
|
}, {
|
|
3124
3124
|
error: r(() => [
|
|
3125
|
-
|
|
3125
|
+
_("div", ns, B(a.value), 1)
|
|
3126
3126
|
]),
|
|
3127
3127
|
_: 1
|
|
3128
|
-
}, 8, ["src"])) : (i(),
|
|
3129
|
-
|
|
3128
|
+
}, 8, ["src"])) : (i(), v("div", ls, B(a.value), 1)),
|
|
3129
|
+
_("h1", ss, B(o.value), 1)
|
|
3130
3130
|
]),
|
|
3131
3131
|
_: 1
|
|
3132
3132
|
}))
|
|
@@ -3136,7 +3136,7 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
3136
3136
|
], 2);
|
|
3137
3137
|
};
|
|
3138
3138
|
}
|
|
3139
|
-
}), is = /* @__PURE__ */
|
|
3139
|
+
}), is = /* @__PURE__ */ R(as, [["__scopeId", "data-v-fc532fb6"]]), rs = {
|
|
3140
3140
|
props: {
|
|
3141
3141
|
to: {
|
|
3142
3142
|
type: String,
|
|
@@ -3149,10 +3149,10 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
3149
3149
|
},
|
|
3150
3150
|
methods: {
|
|
3151
3151
|
compType(e) {
|
|
3152
|
-
return
|
|
3152
|
+
return dt(e) || this.newTab ? "a" : "router-link";
|
|
3153
3153
|
},
|
|
3154
3154
|
linkProps(e) {
|
|
3155
|
-
return
|
|
3155
|
+
return dt(e) ? {
|
|
3156
3156
|
is: "a",
|
|
3157
3157
|
href: e,
|
|
3158
3158
|
target: "_blank",
|
|
@@ -3169,15 +3169,15 @@ const Gl = /* @__PURE__ */ P(Hl, [["render", Fl], ["__scopeId", "data-v-cd18f87f
|
|
|
3169
3169
|
}
|
|
3170
3170
|
}
|
|
3171
3171
|
};
|
|
3172
|
-
function cs(e, t,
|
|
3173
|
-
return i(),
|
|
3172
|
+
function cs(e, t, o, n, l, s) {
|
|
3173
|
+
return i(), m(ze(s.compType(o.to)), Z(ce(s.linkProps(o.to))), {
|
|
3174
3174
|
default: r(() => [
|
|
3175
|
-
|
|
3175
|
+
pe(e.$slots, "default")
|
|
3176
3176
|
]),
|
|
3177
3177
|
_: 3
|
|
3178
3178
|
}, 16);
|
|
3179
3179
|
}
|
|
3180
|
-
const us = /* @__PURE__ */
|
|
3180
|
+
const us = /* @__PURE__ */ R(rs, [["render", cs]]), ds = {
|
|
3181
3181
|
computed: {
|
|
3182
3182
|
// @ts-ignore
|
|
3183
3183
|
device() {
|
|
@@ -3192,13 +3192,13 @@ const us = /* @__PURE__ */ P(rs, [["render", cs]]), ds = {
|
|
|
3192
3192
|
const e = this.$refs.subMenu;
|
|
3193
3193
|
if (e) {
|
|
3194
3194
|
const t = e.handleMouseleave;
|
|
3195
|
-
e.handleMouseleave = (
|
|
3196
|
-
this.device !== "mobile" && t(
|
|
3195
|
+
e.handleMouseleave = (o) => {
|
|
3196
|
+
this.device !== "mobile" && t(o);
|
|
3197
3197
|
};
|
|
3198
3198
|
}
|
|
3199
3199
|
}
|
|
3200
3200
|
}
|
|
3201
|
-
}, ps = { class: "menu-content" }, fs = /* @__PURE__ */
|
|
3201
|
+
}, ps = { class: "menu-content" }, fs = /* @__PURE__ */ z({
|
|
3202
3202
|
__name: "MenuContent",
|
|
3203
3203
|
props: {
|
|
3204
3204
|
meta: {
|
|
@@ -3210,13 +3210,13 @@ const us = /* @__PURE__ */ P(rs, [["render", cs]]), ds = {
|
|
|
3210
3210
|
}
|
|
3211
3211
|
},
|
|
3212
3212
|
setup(e) {
|
|
3213
|
-
return (t,
|
|
3214
|
-
const
|
|
3215
|
-
return i(),
|
|
3216
|
-
u(
|
|
3213
|
+
return (t, o) => {
|
|
3214
|
+
const n = P("VIcon");
|
|
3215
|
+
return i(), v(A, null, [
|
|
3216
|
+
u(n, {
|
|
3217
3217
|
name: e.meta.icon || "ra-all"
|
|
3218
3218
|
}, null, 8, ["name"]),
|
|
3219
|
-
|
|
3219
|
+
_("span", ps, B(e.meta.title), 1)
|
|
3220
3220
|
], 64);
|
|
3221
3221
|
};
|
|
3222
3222
|
}
|
|
@@ -3262,31 +3262,31 @@ const us = /* @__PURE__ */ P(rs, [["render", cs]]), ds = {
|
|
|
3262
3262
|
key: 0,
|
|
3263
3263
|
class: "menu-wrapper"
|
|
3264
3264
|
};
|
|
3265
|
-
function bs(e, t,
|
|
3266
|
-
const a =
|
|
3267
|
-
return
|
|
3268
|
-
|
|
3265
|
+
function bs(e, t, o, n, l, s) {
|
|
3266
|
+
const a = P("menu-content"), c = an, d = P("app-link"), f = Lt, p = P("sidebar-item", !0), b = rn;
|
|
3267
|
+
return o.item.hidden !== !1 ? (i(), v("div", hs, [
|
|
3268
|
+
o.item.meta && o.item.meta.menuType === 2 ? (i(), m(f, {
|
|
3269
3269
|
key: 0,
|
|
3270
|
-
disabled: !
|
|
3270
|
+
disabled: !o.isCollapse,
|
|
3271
3271
|
effect: "dark",
|
|
3272
3272
|
placement: "right",
|
|
3273
|
-
content:
|
|
3273
|
+
content: o.item.meta?.title
|
|
3274
3274
|
}, {
|
|
3275
3275
|
default: r(() => [
|
|
3276
|
-
|
|
3276
|
+
o.item.meta ? (i(), m(d, {
|
|
3277
3277
|
key: 0,
|
|
3278
|
-
to:
|
|
3279
|
-
"new-tab":
|
|
3278
|
+
to: o.to,
|
|
3279
|
+
"new-tab": o.item.meta.newTab
|
|
3280
3280
|
}, {
|
|
3281
3281
|
default: r(() => [
|
|
3282
3282
|
u(c, {
|
|
3283
|
-
index:
|
|
3284
|
-
class:
|
|
3283
|
+
index: o.to,
|
|
3284
|
+
class: te({ "submenu-title-noDropdown": !o.isNest }),
|
|
3285
3285
|
onClick: s.itemClick
|
|
3286
3286
|
}, {
|
|
3287
3287
|
default: r(() => [
|
|
3288
3288
|
u(a, {
|
|
3289
|
-
meta:
|
|
3289
|
+
meta: o.item.meta
|
|
3290
3290
|
}, null, 8, ["meta"])
|
|
3291
3291
|
]),
|
|
3292
3292
|
_: 1
|
|
@@ -3296,41 +3296,41 @@ function bs(e, t, n, o, l, s) {
|
|
|
3296
3296
|
}, 8, ["to", "new-tab"])) : $("", !0)
|
|
3297
3297
|
]),
|
|
3298
3298
|
_: 1
|
|
3299
|
-
}, 8, ["disabled", "content"])) :
|
|
3299
|
+
}, 8, ["disabled", "content"])) : o.item.meta && o.item.meta.menuType === 1 ? (i(), m(f, {
|
|
3300
3300
|
key: 1,
|
|
3301
|
-
disabled: !
|
|
3301
|
+
disabled: !o.isCollapse,
|
|
3302
3302
|
effect: "dark",
|
|
3303
3303
|
placement: "right",
|
|
3304
|
-
content:
|
|
3304
|
+
content: o.item.meta?.title
|
|
3305
3305
|
}, {
|
|
3306
3306
|
default: r(() => [
|
|
3307
|
-
u(
|
|
3307
|
+
u(b, {
|
|
3308
3308
|
ref: "subMenu",
|
|
3309
|
-
index:
|
|
3310
|
-
class:
|
|
3309
|
+
index: o.to,
|
|
3310
|
+
class: te({ "submenu-title-noDropdown": !o.isNest })
|
|
3311
3311
|
}, {
|
|
3312
3312
|
title: r(() => [
|
|
3313
|
-
|
|
3313
|
+
o.item.redirect && o.item.redirect !== "#" ? (i(), m(d, {
|
|
3314
3314
|
key: 0,
|
|
3315
|
-
to:
|
|
3315
|
+
to: o.to
|
|
3316
3316
|
}, {
|
|
3317
3317
|
default: r(() => [
|
|
3318
3318
|
u(a, {
|
|
3319
|
-
meta:
|
|
3319
|
+
meta: o.item.meta
|
|
3320
3320
|
}, null, 8, ["meta"])
|
|
3321
3321
|
]),
|
|
3322
3322
|
_: 1
|
|
3323
|
-
}, 8, ["to"])) : (i(),
|
|
3323
|
+
}, 8, ["to"])) : (i(), m(a, {
|
|
3324
3324
|
key: 1,
|
|
3325
|
-
meta:
|
|
3325
|
+
meta: o.item.meta
|
|
3326
3326
|
}, null, 8, ["meta"]))
|
|
3327
3327
|
]),
|
|
3328
3328
|
default: r(() => [
|
|
3329
|
-
(i(!0),
|
|
3330
|
-
key:
|
|
3329
|
+
(i(!0), v(A, null, V(o.item.children, (S) => (i(), m(p, {
|
|
3330
|
+
key: S.path,
|
|
3331
3331
|
"is-nest": !0,
|
|
3332
|
-
item:
|
|
3333
|
-
to: s.getTo(
|
|
3332
|
+
item: S,
|
|
3333
|
+
to: s.getTo(S),
|
|
3334
3334
|
class: "nest-menu"
|
|
3335
3335
|
}, null, 8, ["item", "to"]))), 128))
|
|
3336
3336
|
]),
|
|
@@ -3341,69 +3341,69 @@ function bs(e, t, n, o, l, s) {
|
|
|
3341
3341
|
}, 8, ["disabled", "content"])) : $("", !0)
|
|
3342
3342
|
])) : $("", !0);
|
|
3343
3343
|
}
|
|
3344
|
-
const ys = /* @__PURE__ */
|
|
3344
|
+
const ys = /* @__PURE__ */ R(ms, [["render", bs]]), _s = /* @__PURE__ */ z({
|
|
3345
3345
|
__name: "SearchMenu",
|
|
3346
3346
|
setup(e) {
|
|
3347
3347
|
const t = j();
|
|
3348
|
-
function
|
|
3349
|
-
return f.filter((p) => p.meta?.menuType === 0 ? !1 : (p.children && (p.children =
|
|
3348
|
+
function o(f) {
|
|
3349
|
+
return f.filter((p) => p.meta?.menuType === 0 ? !1 : (p.children && (p.children = o(p.children), p.children.length === 0 && delete p.children), !0));
|
|
3350
3350
|
}
|
|
3351
|
-
const
|
|
3351
|
+
const n = C(""), l = k(() => t.remoteRouter), s = Te(), a = k(() => {
|
|
3352
3352
|
let f = [];
|
|
3353
3353
|
return l.value.forEach((p) => {
|
|
3354
|
-
f = f.concat(
|
|
3355
|
-
}),
|
|
3354
|
+
f = f.concat(E(p.routes));
|
|
3355
|
+
}), o(f);
|
|
3356
3356
|
});
|
|
3357
3357
|
function c(f) {
|
|
3358
3358
|
let p = f;
|
|
3359
3359
|
if (f.meta.menuType === 1 && f.children && f.children.length > 0) {
|
|
3360
|
-
for (let
|
|
3361
|
-
if (f.children[
|
|
3362
|
-
p = f.children[
|
|
3360
|
+
for (let b = 0; b < f.children.length; b++)
|
|
3361
|
+
if (f.children[b].path.indexOf("/:") === -1) {
|
|
3362
|
+
p = f.children[b];
|
|
3363
3363
|
break;
|
|
3364
3364
|
}
|
|
3365
3365
|
}
|
|
3366
3366
|
return s.resolve(p.redirect ? p.redirect : p).fullPath;
|
|
3367
3367
|
}
|
|
3368
3368
|
function d(f) {
|
|
3369
|
-
s.push(f),
|
|
3369
|
+
s.push(f), n.value = "";
|
|
3370
3370
|
}
|
|
3371
3371
|
return (f, p) => {
|
|
3372
|
-
const
|
|
3373
|
-
return i(),
|
|
3374
|
-
modelValue:
|
|
3375
|
-
"onUpdate:modelValue": p[0] || (p[0] = (
|
|
3372
|
+
const b = Ye, S = cn, I = Ze;
|
|
3373
|
+
return i(), m(I, {
|
|
3374
|
+
modelValue: h(n),
|
|
3375
|
+
"onUpdate:modelValue": p[0] || (p[0] = (O) => Ke(n) ? n.value = O : null),
|
|
3376
3376
|
filterable: "",
|
|
3377
3377
|
placeholder: "搜索菜单...",
|
|
3378
3378
|
class: "search-menu",
|
|
3379
3379
|
onChange: d
|
|
3380
3380
|
}, {
|
|
3381
3381
|
default: r(() => [
|
|
3382
|
-
(i(!0),
|
|
3383
|
-
key:
|
|
3382
|
+
(i(!0), v(A, null, V(h(a), (O) => (i(), v(A, {
|
|
3383
|
+
key: O.path
|
|
3384
3384
|
}, [
|
|
3385
|
-
|
|
3386
|
-
|
|
3387
|
-
key:
|
|
3388
|
-
label:
|
|
3385
|
+
O.children !== void 0 ? (i(), v(A, { key: 0 }, [
|
|
3386
|
+
O.meta.menuType !== 0 ? (i(), m(S, {
|
|
3387
|
+
key: O.path + "-",
|
|
3388
|
+
label: O.meta.title
|
|
3389
3389
|
}, {
|
|
3390
3390
|
default: r(() => [
|
|
3391
|
-
(i(!0),
|
|
3392
|
-
key:
|
|
3391
|
+
(i(!0), v(A, null, V(O.children, (w, y) => (i(), v(A, {
|
|
3392
|
+
key: w.path
|
|
3393
3393
|
}, [
|
|
3394
|
-
|
|
3394
|
+
O.meta.menuType !== 0 ? (i(), m(b, {
|
|
3395
3395
|
key: 0,
|
|
3396
|
-
label: (
|
|
3397
|
-
value: c(
|
|
3396
|
+
label: (y === O.children.length - 1 ? "└─" : "├─") + w.meta.title,
|
|
3397
|
+
value: c(w)
|
|
3398
3398
|
}, null, 8, ["label", "value"])) : $("", !0)
|
|
3399
3399
|
], 64))), 128))
|
|
3400
3400
|
]),
|
|
3401
3401
|
_: 2
|
|
3402
3402
|
}, 1032, ["label"])) : $("", !0)
|
|
3403
|
-
], 64)) : (i(),
|
|
3403
|
+
], 64)) : (i(), m(b, {
|
|
3404
3404
|
key: 1,
|
|
3405
|
-
label: "" +
|
|
3406
|
-
value: c(
|
|
3405
|
+
label: "" + O.meta.title,
|
|
3406
|
+
value: c(O)
|
|
3407
3407
|
}, null, 8, ["label", "value"]))
|
|
3408
3408
|
], 64))), 128))
|
|
3409
3409
|
]),
|
|
@@ -3411,226 +3411,304 @@ const ys = /* @__PURE__ */ P(ms, [["render", bs]]), _s = /* @__PURE__ */ K({
|
|
|
3411
3411
|
}, 8, ["modelValue"]);
|
|
3412
3412
|
};
|
|
3413
3413
|
}
|
|
3414
|
-
}), vs = /* @__PURE__ */
|
|
3415
|
-
var J = /* @__PURE__ */ ((e) => (e[e.custom = 0] = "custom", e[e.list = 1] = "list", e[e.form = 2] = "form", e[e.customSchema = 3] = "customSchema", e[e.localComp = 4] = "localComp", e[e.tree = 5] = "tree", e[e.report = 6] = "report", e[e.entity = 7] = "entity", e))(J || {}),
|
|
3416
|
-
const gs = /* @__PURE__ */
|
|
3414
|
+
}), vs = /* @__PURE__ */ R(_s, [["__scopeId", "data-v-b75fab7b"]]);
|
|
3415
|
+
var J = /* @__PURE__ */ ((e) => (e[e.custom = 0] = "custom", e[e.list = 1] = "list", e[e.form = 2] = "form", e[e.customSchema = 3] = "customSchema", e[e.localComp = 4] = "localComp", e[e.tree = 5] = "tree", e[e.report = 6] = "report", e[e.entity = 7] = "entity", e))(J || {}), K = /* @__PURE__ */ ((e) => (e[e.hidden = 0] = "hidden", e[e.dir = 1] = "dir", e[e.menu = 2] = "menu", e[e.page = 3] = "page", e))(K || {});
|
|
3416
|
+
const gs = /* @__PURE__ */ z({
|
|
3417
3417
|
__name: "index",
|
|
3418
3418
|
setup(e) {
|
|
3419
|
-
const t = Y(),
|
|
3420
|
-
let
|
|
3421
|
-
return c.options.routes.concat(a.value || []).forEach((
|
|
3422
|
-
|
|
3423
|
-
}),
|
|
3424
|
-
{ label: "", routes:
|
|
3419
|
+
const t = Y(), o = j(), n = U(), l = k(() => t.sidebar), s = k(() => o.remoteRouter), a = k(() => o.customRouter), c = Te(), d = Q(), f = k(() => {
|
|
3420
|
+
let w = [];
|
|
3421
|
+
return c.options.routes.concat(a.value || []).forEach((y) => {
|
|
3422
|
+
y.path === "/" ? w = w.concat(y.children || []) : w.push(y);
|
|
3423
|
+
}), E([
|
|
3424
|
+
{ label: "", routes: w },
|
|
3425
3425
|
...s.value
|
|
3426
3426
|
]);
|
|
3427
3427
|
}), p = k(() => {
|
|
3428
|
-
const
|
|
3429
|
-
for (let
|
|
3430
|
-
const
|
|
3431
|
-
if (
|
|
3432
|
-
return
|
|
3428
|
+
const w = d.matched;
|
|
3429
|
+
for (let y = w.length - 1; y >= 0; y--) {
|
|
3430
|
+
const x = w[y];
|
|
3431
|
+
if (x.meta.menuType === K.menu)
|
|
3432
|
+
return I(), c.resolve(x.redirect ? x.redirect : x).fullPath;
|
|
3433
3433
|
}
|
|
3434
3434
|
return "";
|
|
3435
|
-
}),
|
|
3436
|
-
|
|
3437
|
-
|
|
3438
|
-
|
|
3439
|
-
})), y = k(() => !l.value.opened);
|
|
3440
|
-
Ie(() => T());
|
|
3441
|
-
function T() {
|
|
3442
|
-
xt("is-active", 200);
|
|
3435
|
+
}), b = k(() => n.sidebarLogo), S = k(() => !l.value.opened);
|
|
3436
|
+
Ie(() => I());
|
|
3437
|
+
function I() {
|
|
3438
|
+
It("is-active", 200);
|
|
3443
3439
|
}
|
|
3444
|
-
function
|
|
3445
|
-
return
|
|
3440
|
+
function O(w) {
|
|
3441
|
+
return w.filter((y) => [K.dir, K.menu].indexOf(y.meta.menuType) !== -1).map((y) => (y = Object.assign({}, y), y.children && (y.children = O(y.children)), y));
|
|
3446
3442
|
}
|
|
3447
|
-
return (
|
|
3448
|
-
const
|
|
3449
|
-
return i(),
|
|
3450
|
-
class:
|
|
3443
|
+
return (w, y) => {
|
|
3444
|
+
const x = dn, F = un;
|
|
3445
|
+
return i(), v("div", {
|
|
3446
|
+
class: te({ "has-logo": h(b) })
|
|
3451
3447
|
}, [
|
|
3452
|
-
|
|
3448
|
+
h(b) ? (i(), m(is, {
|
|
3453
3449
|
key: 0,
|
|
3454
|
-
collapse:
|
|
3450
|
+
collapse: h(S)
|
|
3455
3451
|
}, null, 8, ["collapse"])) : $("", !0),
|
|
3456
|
-
u(
|
|
3452
|
+
u(F, { "wrap-class": "scrollbar-wrapper" }, {
|
|
3457
3453
|
default: r(() => [
|
|
3458
|
-
|
|
3459
|
-
u(
|
|
3460
|
-
"default-active":
|
|
3461
|
-
collapse:
|
|
3462
|
-
"background-color": m(w).menuBg,
|
|
3463
|
-
"text-color": m(w).menuText,
|
|
3454
|
+
h(S) ? $("", !0) : (i(), m(vs, { key: 0 })),
|
|
3455
|
+
u(x, {
|
|
3456
|
+
"default-active": h(p),
|
|
3457
|
+
collapse: h(S),
|
|
3464
3458
|
"unique-opened": !1,
|
|
3465
|
-
"active-text-color": m(w).menuActiveText,
|
|
3466
3459
|
"collapse-transition": !1,
|
|
3467
3460
|
mode: "vertical"
|
|
3468
3461
|
}, {
|
|
3469
3462
|
default: r(() => [
|
|
3470
|
-
(i(!0),
|
|
3471
|
-
key:
|
|
3463
|
+
(i(!0), v(A, null, V(h(f), (G, g) => (i(), v(A, {
|
|
3464
|
+
key: g + "-module"
|
|
3472
3465
|
}, [
|
|
3473
|
-
(i(!0),
|
|
3474
|
-
key:
|
|
3475
|
-
item:
|
|
3476
|
-
to:
|
|
3477
|
-
"is-collapse":
|
|
3466
|
+
(i(!0), v(A, null, V(O(G.routes), (M) => (i(), m(ys, {
|
|
3467
|
+
key: M.path,
|
|
3468
|
+
item: M,
|
|
3469
|
+
to: w.$router.resolve(M.redirect ? M.redirect : M).fullPath,
|
|
3470
|
+
"is-collapse": h(S)
|
|
3478
3471
|
}, null, 8, ["item", "to", "is-collapse"]))), 128))
|
|
3479
3472
|
], 64))), 128))
|
|
3480
3473
|
]),
|
|
3481
3474
|
_: 1
|
|
3482
|
-
}, 8, ["default-active", "collapse"
|
|
3475
|
+
}, 8, ["default-active", "collapse"])
|
|
3483
3476
|
]),
|
|
3484
3477
|
_: 1
|
|
3485
3478
|
})
|
|
3486
3479
|
], 2);
|
|
3487
3480
|
};
|
|
3488
3481
|
}
|
|
3489
|
-
}), ks = /* @__PURE__ */
|
|
3482
|
+
}), ks = /* @__PURE__ */ R(gs, [["__scopeId", "data-v-ed591c64"]]), Ss = { class: "app-main" }, ws = {
|
|
3490
3483
|
__name: "AppMain",
|
|
3491
3484
|
setup(e) {
|
|
3492
|
-
const t =
|
|
3493
|
-
return
|
|
3494
|
-
t.meta?.keepAlive &&
|
|
3485
|
+
const t = Q(), o = [], n = C(0);
|
|
3486
|
+
return Ko(() => {
|
|
3487
|
+
t.meta?.keepAlive && o.indexOf(t.name) && o.push(t.name), n.value++;
|
|
3495
3488
|
}), (l, s) => {
|
|
3496
|
-
const a =
|
|
3497
|
-
return i(),
|
|
3498
|
-
(i(),
|
|
3499
|
-
key: l.$route.fullPath +
|
|
3489
|
+
const a = P("router-view"), c = pn;
|
|
3490
|
+
return i(), v("section", Ss, [
|
|
3491
|
+
(i(), m(a, {
|
|
3492
|
+
key: l.$route.fullPath + h(n)
|
|
3500
3493
|
})),
|
|
3501
3494
|
u(c, { bottom: 50 })
|
|
3502
3495
|
]);
|
|
3503
3496
|
};
|
|
3504
3497
|
}
|
|
3505
|
-
}, xs = /* @__PURE__ */
|
|
3498
|
+
}, xs = /* @__PURE__ */ R(ws, [["__scopeId", "data-v-ca0f0d98"]]), Es = { class: "main-container" }, Is = 992, Cs = {
|
|
3506
3499
|
__name: "index",
|
|
3507
3500
|
setup(e) {
|
|
3508
|
-
const { body: t } = document,
|
|
3501
|
+
const { body: t } = document, o = Y(), n = U(), l = Q(), s = k(() => o.sidebar), a = k(() => o.device), c = k(() => n.fixedHeader), d = k(() => ({
|
|
3509
3502
|
hideSidebar: !s.value.opened,
|
|
3510
3503
|
openSidebar: s.value.opened,
|
|
3511
3504
|
withoutAnimation: s.value.withoutAnimation,
|
|
3512
3505
|
mobile: a.value === "mobile"
|
|
3513
3506
|
})), f = () => t.getBoundingClientRect().width - 1 < Is, p = () => {
|
|
3514
3507
|
if (!document.hidden) {
|
|
3515
|
-
const
|
|
3516
|
-
|
|
3508
|
+
const S = f();
|
|
3509
|
+
o.toggleDevice(S ? "mobile" : "desktop"), S && o.closeSideBar({ withoutAnimation: !0 });
|
|
3517
3510
|
}
|
|
3518
3511
|
};
|
|
3519
|
-
p(),
|
|
3520
|
-
a.value === "mobile" && s.value.opened &&
|
|
3512
|
+
p(), wn(window, "resize", () => p()), ye(l, () => {
|
|
3513
|
+
a.value === "mobile" && s.value.opened && o.closeSideBar({ withoutAnimation: !1 });
|
|
3521
3514
|
});
|
|
3522
|
-
const
|
|
3523
|
-
return (
|
|
3524
|
-
class:
|
|
3515
|
+
const b = () => o.closeSideBar({ withoutAnimation: !1 });
|
|
3516
|
+
return (S, I) => (i(), v("div", {
|
|
3517
|
+
class: te([h(d), "app-wrapper"])
|
|
3525
3518
|
}, [
|
|
3526
|
-
|
|
3519
|
+
h(a) === "mobile" && h(s).opened ? (i(), v("div", {
|
|
3527
3520
|
key: 0,
|
|
3528
3521
|
class: "drawer-bg",
|
|
3529
|
-
onClick:
|
|
3522
|
+
onClick: b
|
|
3530
3523
|
})) : $("", !0),
|
|
3531
|
-
u(
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
class:
|
|
3524
|
+
u(h(ks), { class: "sidebar-container" }),
|
|
3525
|
+
_("div", Es, [
|
|
3526
|
+
_("div", {
|
|
3527
|
+
class: te({ "fixed-header": h(c) })
|
|
3535
3528
|
}, [
|
|
3536
|
-
u(
|
|
3529
|
+
u(h(es))
|
|
3537
3530
|
], 2),
|
|
3538
|
-
u(
|
|
3531
|
+
u(h(xs))
|
|
3539
3532
|
])
|
|
3540
3533
|
], 2));
|
|
3541
3534
|
}
|
|
3542
|
-
},
|
|
3543
|
-
key:
|
|
3544
|
-
class: "
|
|
3545
|
-
},
|
|
3535
|
+
}, Jt = /* @__PURE__ */ R(Cs, [["__scopeId", "data-v-6bf05d7c"]]), Ts = { class: "login-container" }, Os = { class: "login-card-wrapper" }, $s = { class: "login-header" }, Bs = { class: "logo-wrapper" }, As = ["src"], Rs = {
|
|
3536
|
+
key: 1,
|
|
3537
|
+
class: "logo-fallback"
|
|
3538
|
+
}, Ps = { class: "login-title" }, Ls = { class: "captcha-wrapper" }, Ms = ["src"], Ds = {
|
|
3539
|
+
key: 1,
|
|
3540
|
+
class: "login-tips"
|
|
3541
|
+
}, js = {
|
|
3542
|
+
key: 2,
|
|
3543
|
+
class: "sso-divider"
|
|
3544
|
+
}, Ns = { class: "login-footer" }, Vs = /* @__PURE__ */ z({
|
|
3546
3545
|
__name: "login",
|
|
3547
3546
|
setup(e) {
|
|
3548
|
-
const t = Te(),
|
|
3547
|
+
const t = Te(), o = Q(), n = U(), l = Y(), s = j(), a = k(() => n.loginTips), c = k(() => n.captcha), d = k(() => l.baseURL), f = C(0), p = C(!1), b = C({
|
|
3549
3548
|
username: "",
|
|
3550
3549
|
password: "",
|
|
3551
3550
|
captcha: "",
|
|
3552
3551
|
sing: ""
|
|
3553
|
-
}),
|
|
3552
|
+
}), S = k(() => {
|
|
3553
|
+
const y = n.title || "OMS";
|
|
3554
|
+
return y ? y.toString().trim().charAt(0).toUpperCase() : "O";
|
|
3555
|
+
}), I = () => {
|
|
3556
|
+
f.value++;
|
|
3557
|
+
}, O = k(() => b.value.username.length > 0 && b.value.password.length >= 4 && (c.value ? b.value.captcha.length === 4 : !0)), w = () => {
|
|
3554
3558
|
if (!p.value) {
|
|
3555
|
-
if (
|
|
3556
|
-
|
|
3559
|
+
if (!O.value) {
|
|
3560
|
+
At.error("请填写完整的登录信息");
|
|
3557
3561
|
return;
|
|
3558
3562
|
}
|
|
3559
|
-
c.value && (
|
|
3560
|
-
t.push({ path:
|
|
3561
|
-
}).catch((
|
|
3563
|
+
c.value && (b.value.sing = En.MD5(`${b.value.username}${b.value.password}${b.value.captcha}`).toString()), p.value = !0, s.login(b.value).then((y) => {
|
|
3564
|
+
t.push({ path: o.query?.redirect || "/" });
|
|
3565
|
+
}).catch((y) => {
|
|
3562
3566
|
f.value++;
|
|
3563
3567
|
}).finally(() => {
|
|
3564
3568
|
p.value = !1;
|
|
3565
3569
|
});
|
|
3566
3570
|
}
|
|
3567
3571
|
};
|
|
3568
|
-
return (
|
|
3569
|
-
const
|
|
3570
|
-
return i(),
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
-
|
|
3587
|
-
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3596
|
-
|
|
3597
|
-
|
|
3598
|
-
|
|
3599
|
-
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3572
|
+
return (y, x) => {
|
|
3573
|
+
const F = fn, G = Xe, g = Mt, M = he, ee = Qe, Ae = $e;
|
|
3574
|
+
return i(), v("div", Ts, [
|
|
3575
|
+
x[7] || (x[7] = _("div", { class: "login-background" }, [
|
|
3576
|
+
_("div", { class: "shape shape-1" }),
|
|
3577
|
+
_("div", { class: "shape shape-2" }),
|
|
3578
|
+
_("div", { class: "shape shape-3" })
|
|
3579
|
+
], -1)),
|
|
3580
|
+
u(xt, {
|
|
3581
|
+
name: "fade-scale",
|
|
3582
|
+
appear: ""
|
|
3583
|
+
}, {
|
|
3584
|
+
default: r(() => [
|
|
3585
|
+
_("div", Os, [
|
|
3586
|
+
u(Ae, {
|
|
3587
|
+
class: "login-card",
|
|
3588
|
+
shadow: "never"
|
|
3589
|
+
}, {
|
|
3590
|
+
default: r(() => [
|
|
3591
|
+
_("div", $s, [
|
|
3592
|
+
_("div", Bs, [
|
|
3593
|
+
h(n).logo ? (i(), v("img", {
|
|
3594
|
+
key: 0,
|
|
3595
|
+
src: h(n).logo,
|
|
3596
|
+
alt: "Logo",
|
|
3597
|
+
class: "logo-img"
|
|
3598
|
+
}, null, 8, As)) : (i(), v("div", Rs, B(S.value), 1))
|
|
3599
|
+
]),
|
|
3600
|
+
_("h1", Ps, B(h(n).title || "OMS"), 1),
|
|
3601
|
+
x[3] || (x[3] = _("p", { class: "login-subtitle" }, "欢迎回来,请登录您的账户", -1))
|
|
3602
|
+
]),
|
|
3603
|
+
u(ee, {
|
|
3604
|
+
ref: "loginForm",
|
|
3605
|
+
model: b.value,
|
|
3606
|
+
class: "login-form",
|
|
3607
|
+
size: "large",
|
|
3608
|
+
onSubmit: Ne(w, ["prevent"])
|
|
3609
|
+
}, {
|
|
3610
|
+
default: r(() => [
|
|
3611
|
+
u(G, { prop: "username" }, {
|
|
3612
|
+
default: r(() => [
|
|
3613
|
+
u(F, {
|
|
3614
|
+
modelValue: b.value.username,
|
|
3615
|
+
"onUpdate:modelValue": x[0] || (x[0] = (W) => b.value.username = W),
|
|
3616
|
+
placeholder: "用户名",
|
|
3617
|
+
"prefix-icon": "User",
|
|
3618
|
+
class: "custom-input"
|
|
3619
|
+
}, null, 8, ["modelValue"])
|
|
3620
|
+
]),
|
|
3621
|
+
_: 1
|
|
3622
|
+
}),
|
|
3623
|
+
u(G, { prop: "password" }, {
|
|
3624
|
+
default: r(() => [
|
|
3625
|
+
u(F, {
|
|
3626
|
+
modelValue: b.value.password,
|
|
3627
|
+
"onUpdate:modelValue": x[1] || (x[1] = (W) => b.value.password = W),
|
|
3628
|
+
type: "password",
|
|
3629
|
+
placeholder: "密码",
|
|
3630
|
+
"show-password": "",
|
|
3631
|
+
"prefix-icon": "Lock",
|
|
3632
|
+
class: "custom-input"
|
|
3633
|
+
}, null, 8, ["modelValue"])
|
|
3634
|
+
]),
|
|
3635
|
+
_: 1
|
|
3636
|
+
}),
|
|
3637
|
+
c.value ? (i(), m(G, {
|
|
3638
|
+
key: 0,
|
|
3639
|
+
prop: "captcha"
|
|
3640
|
+
}, {
|
|
3641
|
+
default: r(() => [
|
|
3642
|
+
_("div", Ls, [
|
|
3643
|
+
u(F, {
|
|
3644
|
+
modelValue: b.value.captcha,
|
|
3645
|
+
"onUpdate:modelValue": x[2] || (x[2] = (W) => b.value.captcha = W),
|
|
3646
|
+
placeholder: "验证码",
|
|
3647
|
+
"prefix-icon": "Key",
|
|
3648
|
+
class: "custom-input captcha-input"
|
|
3649
|
+
}, null, 8, ["modelValue"]),
|
|
3650
|
+
_("div", {
|
|
3651
|
+
class: "captcha-img-box",
|
|
3652
|
+
onClick: I
|
|
3653
|
+
}, [
|
|
3654
|
+
_("img", {
|
|
3655
|
+
src: d.value + "/user/captcha?ts=" + f.value,
|
|
3656
|
+
title: "点击刷新",
|
|
3657
|
+
class: "captcha-img"
|
|
3658
|
+
}, null, 8, Ms)
|
|
3659
|
+
])
|
|
3660
|
+
])
|
|
3661
|
+
]),
|
|
3662
|
+
_: 1
|
|
3663
|
+
})) : $("", !0),
|
|
3664
|
+
a.value ? (i(), v("div", Ds, [
|
|
3665
|
+
u(g, null, {
|
|
3666
|
+
default: r(() => [
|
|
3667
|
+
u(h(Sn))
|
|
3668
|
+
]),
|
|
3669
|
+
_: 1
|
|
3670
|
+
}),
|
|
3671
|
+
_("span", null, B(a.value), 1)
|
|
3672
|
+
])) : $("", !0),
|
|
3673
|
+
u(M, {
|
|
3674
|
+
class: "submit-button",
|
|
3675
|
+
type: "primary",
|
|
3676
|
+
loading: p.value,
|
|
3677
|
+
disabled: !O.value,
|
|
3678
|
+
"native-type": "submit",
|
|
3679
|
+
onClick: w
|
|
3680
|
+
}, {
|
|
3681
|
+
default: r(() => [...x[4] || (x[4] = [
|
|
3682
|
+
T(" 登 录 ", -1)
|
|
3683
|
+
])]),
|
|
3684
|
+
_: 1
|
|
3685
|
+
}, 8, ["loading", "disabled"]),
|
|
3686
|
+
Object.keys(h(n).sso || {}).length > 0 ? (i(), v("div", js, [...x[5] || (x[5] = [
|
|
3687
|
+
_("span", null, "其他登录方式", -1)
|
|
3688
|
+
])])) : $("", !0),
|
|
3689
|
+
x[6] || (x[6] = _("div", { class: "sso-container" }, [
|
|
3690
|
+
_("div", { id: "sso-qrcode" })
|
|
3691
|
+
], -1))
|
|
3692
|
+
]),
|
|
3693
|
+
_: 1
|
|
3694
|
+
}, 8, ["model"])
|
|
3695
|
+
]),
|
|
3696
|
+
_: 1
|
|
3697
|
+
}),
|
|
3698
|
+
_("div", Ns, " © " + B((/* @__PURE__ */ new Date()).getFullYear()) + " " + B(h(n).title || "OMS") + ". All rights reserved. ", 1)
|
|
3699
|
+
])
|
|
3619
3700
|
]),
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
(i(!0), _(O, null, U(Object.keys([]), (A) => (i(), _("div", { key: A }, R(A), 1))), 128))
|
|
3623
|
-
])
|
|
3624
|
-
])
|
|
3701
|
+
_: 1
|
|
3702
|
+
})
|
|
3625
3703
|
]);
|
|
3626
3704
|
};
|
|
3627
3705
|
}
|
|
3628
|
-
}),
|
|
3706
|
+
}), Us = {
|
|
3629
3707
|
name: "NotFoundPage"
|
|
3630
|
-
},
|
|
3631
|
-
function
|
|
3632
|
-
return i(),
|
|
3633
|
-
|
|
3708
|
+
}, qs = { class: "not-found" };
|
|
3709
|
+
function Hs(e, t, o, n, l, s) {
|
|
3710
|
+
return i(), v("div", qs, [...t[0] || (t[0] = [
|
|
3711
|
+
_("svg", {
|
|
3634
3712
|
width: "380px",
|
|
3635
3713
|
height: "500px",
|
|
3636
3714
|
viewBox: "0 0 837 1045",
|
|
@@ -3639,7 +3717,7 @@ function Ds(e, t, n, o, l, s) {
|
|
|
3639
3717
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
3640
3718
|
"xmlns:sketch": "http://www.bohemiancoding.com/sketch/ns"
|
|
3641
3719
|
}, [
|
|
3642
|
-
|
|
3720
|
+
_("g", {
|
|
3643
3721
|
id: "Page-1",
|
|
3644
3722
|
stroke: "none",
|
|
3645
3723
|
"stroke-width": "1",
|
|
@@ -3647,35 +3725,35 @@ function Ds(e, t, n, o, l, s) {
|
|
|
3647
3725
|
"fill-rule": "evenodd",
|
|
3648
3726
|
"sketch:type": "MSPage"
|
|
3649
3727
|
}, [
|
|
3650
|
-
|
|
3728
|
+
_("path", {
|
|
3651
3729
|
id: "Polygon-1",
|
|
3652
3730
|
d: "M353,9 L626.664028,170 L626.664028,487 L353,642 L79.3359724,487 L79.3359724,170 L353,9 Z",
|
|
3653
3731
|
stroke: "#007FB2",
|
|
3654
3732
|
"stroke-width": "6",
|
|
3655
3733
|
"sketch:type": "MSShapeGroup"
|
|
3656
3734
|
}),
|
|
3657
|
-
|
|
3735
|
+
_("path", {
|
|
3658
3736
|
id: "Polygon-2",
|
|
3659
3737
|
d: "M78.5,529 L147,569.186414 L147,648.311216 L78.5,687 L10,648.311216 L10,569.186414 L78.5,529 Z",
|
|
3660
3738
|
stroke: "#EF4A5B",
|
|
3661
3739
|
"stroke-width": "6",
|
|
3662
3740
|
"sketch:type": "MSShapeGroup"
|
|
3663
3741
|
}),
|
|
3664
|
-
|
|
3742
|
+
_("path", {
|
|
3665
3743
|
id: "Polygon-3",
|
|
3666
3744
|
d: "M773,186 L827,217.538705 L827,279.636651 L773,310 L719,279.636651 L719,217.538705 L773,186 Z",
|
|
3667
3745
|
stroke: "#795D9C",
|
|
3668
3746
|
"stroke-width": "6",
|
|
3669
3747
|
"sketch:type": "MSShapeGroup"
|
|
3670
3748
|
}),
|
|
3671
|
-
|
|
3749
|
+
_("path", {
|
|
3672
3750
|
id: "Polygon-4",
|
|
3673
3751
|
d: "M639,529 L773,607.846761 L773,763.091627 L639,839 L505,763.091627 L505,607.846761 L639,529 Z",
|
|
3674
3752
|
stroke: "#F2773F",
|
|
3675
3753
|
"stroke-width": "6",
|
|
3676
3754
|
"sketch:type": "MSShapeGroup"
|
|
3677
3755
|
}),
|
|
3678
|
-
|
|
3756
|
+
_("path", {
|
|
3679
3757
|
id: "Polygon-5",
|
|
3680
3758
|
d: "M281,801 L383,861.025276 L383,979.21169 L281,1037 L179,979.21169 L179,861.025276 L281,801 Z",
|
|
3681
3759
|
stroke: "#36B455",
|
|
@@ -3684,12 +3762,12 @@ function Ds(e, t, n, o, l, s) {
|
|
|
3684
3762
|
})
|
|
3685
3763
|
])
|
|
3686
3764
|
], -1),
|
|
3687
|
-
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
|
|
3691
|
-
|
|
3692
|
-
|
|
3765
|
+
_("div", { class: "message-box" }, [
|
|
3766
|
+
_("h1", null, "404"),
|
|
3767
|
+
_("p", null, "Page not found"),
|
|
3768
|
+
_("div", { class: "buttons-con" }, [
|
|
3769
|
+
_("div", { class: "action-link-wrap" }, [
|
|
3770
|
+
_("a", {
|
|
3693
3771
|
href: "",
|
|
3694
3772
|
class: "link-button"
|
|
3695
3773
|
}, "Go to Home Page")
|
|
@@ -3698,10 +3776,10 @@ function Ds(e, t, n, o, l, s) {
|
|
|
3698
3776
|
], -1)
|
|
3699
3777
|
])]);
|
|
3700
3778
|
}
|
|
3701
|
-
const
|
|
3779
|
+
const Fs = /* @__PURE__ */ R(Us, [["render", Hs], ["__scopeId", "data-v-26068803"]]), Gs = [
|
|
3702
3780
|
{
|
|
3703
3781
|
path: "/",
|
|
3704
|
-
component:
|
|
3782
|
+
component: Jt,
|
|
3705
3783
|
redirect: "/dashboard",
|
|
3706
3784
|
name: "Root",
|
|
3707
3785
|
meta: {
|
|
@@ -3711,78 +3789,78 @@ const js = /* @__PURE__ */ P(Ls, [["render", Ds], ["__scopeId", "data-v-26068803
|
|
|
3711
3789
|
{
|
|
3712
3790
|
path: "dashboard",
|
|
3713
3791
|
name: "Dashboard",
|
|
3714
|
-
component:
|
|
3792
|
+
component: Qn,
|
|
3715
3793
|
meta: { title: "Dashboard", icon: "el-icon-help", menuType: 2, keepAlive: !0 }
|
|
3716
3794
|
}
|
|
3717
3795
|
]
|
|
3718
3796
|
},
|
|
3719
3797
|
{
|
|
3720
3798
|
path: "/login",
|
|
3721
|
-
component:
|
|
3799
|
+
component: Vs,
|
|
3722
3800
|
meta: { title: "用户登录", menuType: 0 },
|
|
3723
3801
|
hidden: !0
|
|
3724
3802
|
},
|
|
3725
3803
|
{
|
|
3726
3804
|
path: "/404",
|
|
3727
|
-
component:
|
|
3805
|
+
component: Fs,
|
|
3728
3806
|
meta: { menuType: 0 },
|
|
3729
3807
|
hidden: !0
|
|
3730
3808
|
}
|
|
3731
|
-
],
|
|
3732
|
-
history:
|
|
3733
|
-
routes:
|
|
3809
|
+
], le = zo({
|
|
3810
|
+
history: Jo(),
|
|
3811
|
+
routes: Gs
|
|
3734
3812
|
});
|
|
3735
|
-
|
|
3736
|
-
function
|
|
3737
|
-
e.beforeEach((t,
|
|
3738
|
-
|
|
3813
|
+
Ve.configure({ showSpinner: !1 });
|
|
3814
|
+
function Ks(e) {
|
|
3815
|
+
e.beforeEach((t, o, n) => {
|
|
3816
|
+
Ve.start(), t.preHash = location.hash.replace("#", ""), n();
|
|
3739
3817
|
}), e.afterEach((t) => {
|
|
3740
|
-
const
|
|
3741
|
-
t.matched.length > 0 &&
|
|
3818
|
+
const o = j(L);
|
|
3819
|
+
t.matched.length > 0 && o.updateState({
|
|
3742
3820
|
key: "path",
|
|
3743
3821
|
value: t.matched[t.matched.length - 1].path.replace("(\\d+)", "")
|
|
3744
|
-
}),
|
|
3822
|
+
}), Ve.done();
|
|
3745
3823
|
});
|
|
3746
3824
|
}
|
|
3747
|
-
function
|
|
3748
|
-
return j(
|
|
3825
|
+
function zs() {
|
|
3826
|
+
return j(L).isLodeRemoteRoutes;
|
|
3749
3827
|
}
|
|
3750
|
-
function
|
|
3751
|
-
return
|
|
3828
|
+
function Wt() {
|
|
3829
|
+
return U(L).whiteRoutes || [];
|
|
3752
3830
|
}
|
|
3753
|
-
function
|
|
3754
|
-
return j(
|
|
3831
|
+
function Js() {
|
|
3832
|
+
return j(L).token;
|
|
3755
3833
|
}
|
|
3756
|
-
class
|
|
3834
|
+
class Qt {
|
|
3757
3835
|
type = "qrcode";
|
|
3758
3836
|
flag() {
|
|
3759
3837
|
}
|
|
3760
|
-
jumpToLoginPage(t,
|
|
3761
|
-
t(
|
|
3838
|
+
jumpToLoginPage(t, o) {
|
|
3839
|
+
t(o);
|
|
3762
3840
|
}
|
|
3763
3841
|
showQrCode() {
|
|
3764
3842
|
}
|
|
3765
3843
|
}
|
|
3766
|
-
class
|
|
3844
|
+
class hr extends Qt {
|
|
3767
3845
|
type = "jump";
|
|
3768
3846
|
client_id = "";
|
|
3769
3847
|
constructor(t) {
|
|
3770
3848
|
super(), this.client_id = t.client_id;
|
|
3771
3849
|
}
|
|
3772
3850
|
flag() {
|
|
3773
|
-
const t =
|
|
3851
|
+
const t = Ct("code");
|
|
3774
3852
|
if (t)
|
|
3775
3853
|
return {
|
|
3776
3854
|
ticket: t,
|
|
3777
3855
|
key: "github"
|
|
3778
3856
|
};
|
|
3779
3857
|
}
|
|
3780
|
-
jumpToLoginPage(t,
|
|
3781
|
-
const
|
|
3782
|
-
location.replace(`https://github.com/login/oauth/authorize?client_id=${this.client_id}&redirect_uri${
|
|
3858
|
+
jumpToLoginPage(t, o) {
|
|
3859
|
+
const n = encodeURIComponent(location.href);
|
|
3860
|
+
location.replace(`https://github.com/login/oauth/authorize?client_id=${this.client_id}&redirect_uri${n}`);
|
|
3783
3861
|
}
|
|
3784
3862
|
}
|
|
3785
|
-
class
|
|
3863
|
+
class br extends Qt {
|
|
3786
3864
|
type = "qrcode";
|
|
3787
3865
|
qrCodeUrl = "https://login.dingtalk.com/login/qrcode.htm?goto={goto}&style={style}";
|
|
3788
3866
|
reloadUrl = "https://oapi.dingtalk.com/connect/oauth2/sns_authorize?response_type=code&scope=snsapi_login&state=&appid={appid}&redirect_uri={redirect_uri}";
|
|
@@ -3795,7 +3873,7 @@ class ur extends Jt {
|
|
|
3795
3873
|
super();
|
|
3796
3874
|
}
|
|
3797
3875
|
flag() {
|
|
3798
|
-
const t =
|
|
3876
|
+
const t = Ct("code");
|
|
3799
3877
|
if (t)
|
|
3800
3878
|
return {
|
|
3801
3879
|
ticket: t,
|
|
@@ -3808,63 +3886,63 @@ class ur extends Jt {
|
|
|
3808
3886
|
appid: this.appid,
|
|
3809
3887
|
redirect_uri: encodeURIComponent(this.redirectUri)
|
|
3810
3888
|
};
|
|
3811
|
-
return
|
|
3812
|
-
},
|
|
3889
|
+
return ie(this.reloadUrl, s) + "&" + Do(l || {});
|
|
3890
|
+
}, o = () => {
|
|
3813
3891
|
const l = {
|
|
3814
3892
|
goto: encodeURIComponent(t()),
|
|
3815
3893
|
style: encodeURIComponent(this.style)
|
|
3816
3894
|
};
|
|
3817
|
-
return
|
|
3818
|
-
},
|
|
3895
|
+
return ie(this.qrCodeUrl, l);
|
|
3896
|
+
}, n = (l) => {
|
|
3819
3897
|
const { origin: s, data: a } = l;
|
|
3820
3898
|
s === "https://login.dingtalk.com" && (window.location.href = t({ loginTmpCode: a }));
|
|
3821
3899
|
};
|
|
3822
|
-
this.iframe.src =
|
|
3900
|
+
this.iframe.src = o(), Mo({ elId: this.elId, attrs: this.iframe }), typeof window.addEventListener < "u" ? window.addEventListener(
|
|
3823
3901
|
"message",
|
|
3824
|
-
(l) =>
|
|
3902
|
+
(l) => n(l),
|
|
3825
3903
|
!1
|
|
3826
3904
|
) : typeof window.attachEvent < "u" && window.attachEvent("onmessage", (l) => this.onScanSuccess(l));
|
|
3827
3905
|
}
|
|
3828
3906
|
}
|
|
3829
|
-
const
|
|
3830
|
-
function
|
|
3831
|
-
return
|
|
3907
|
+
const Ws = {};
|
|
3908
|
+
function Qs() {
|
|
3909
|
+
return q(U(L).sso || {}, Ws);
|
|
3832
3910
|
}
|
|
3833
|
-
function
|
|
3834
|
-
const e =
|
|
3835
|
-
if (
|
|
3836
|
-
return
|
|
3911
|
+
function Xs() {
|
|
3912
|
+
const e = Qs(), t = U(L).activeSsoKey || "", o = e[t];
|
|
3913
|
+
if (o !== void 0)
|
|
3914
|
+
return o();
|
|
3837
3915
|
}
|
|
3838
|
-
function
|
|
3839
|
-
e.beforeEach(async (t,
|
|
3840
|
-
if (
|
|
3841
|
-
|
|
3916
|
+
function Zs(e) {
|
|
3917
|
+
e.beforeEach(async (t, o, n) => {
|
|
3918
|
+
if (Wt().indexOf(t.path) !== -1) {
|
|
3919
|
+
n();
|
|
3842
3920
|
return;
|
|
3843
3921
|
}
|
|
3844
|
-
if (
|
|
3845
|
-
t.query?.redirect ?
|
|
3922
|
+
if (Js()) {
|
|
3923
|
+
t.query?.redirect ? n(t.query?.redirect) : n();
|
|
3846
3924
|
return;
|
|
3847
3925
|
}
|
|
3848
|
-
const s = t.query.redirect || t.path, a =
|
|
3926
|
+
const s = t.query.redirect || t.path, a = Xs();
|
|
3849
3927
|
if (!a) {
|
|
3850
|
-
|
|
3928
|
+
n(`/login?redirect=${s}`);
|
|
3851
3929
|
return;
|
|
3852
3930
|
}
|
|
3853
|
-
const c = a.flag(), d = j(
|
|
3854
|
-
if (c && await d.login(
|
|
3855
|
-
|
|
3931
|
+
const c = a.flag(), d = j(L);
|
|
3932
|
+
if (c && await d.login(Uo(c) ? c : { ticket: c })) {
|
|
3933
|
+
n();
|
|
3856
3934
|
return;
|
|
3857
3935
|
}
|
|
3858
|
-
a.jumpToLoginPage(
|
|
3936
|
+
a.jumpToLoginPage(n, `/login?redirect=${s}`);
|
|
3859
3937
|
});
|
|
3860
3938
|
}
|
|
3861
|
-
const
|
|
3862
|
-
function
|
|
3863
|
-
return i(),
|
|
3864
|
-
|
|
3939
|
+
const Ys = {}, ea = { class: "loading preloader" };
|
|
3940
|
+
function ta(e, t) {
|
|
3941
|
+
return i(), v("div", ea, [...t[0] || (t[0] = [
|
|
3942
|
+
_("div", { class: "preloader-inner" }, null, -1)
|
|
3865
3943
|
])]);
|
|
3866
3944
|
}
|
|
3867
|
-
const
|
|
3945
|
+
const oa = /* @__PURE__ */ R(Ys, [["render", ta]]), na = {
|
|
3868
3946
|
name: "VNotice",
|
|
3869
3947
|
props: {
|
|
3870
3948
|
dataApi: {
|
|
@@ -3893,93 +3971,93 @@ const Qs = /* @__PURE__ */ P(zs, [["render", Ws]]), Xs = {
|
|
|
3893
3971
|
this.hasNotice = Object.keys(this.$props.notice).length > 0, this.noticeProps = this.$props.notice;
|
|
3894
3972
|
}
|
|
3895
3973
|
};
|
|
3896
|
-
function
|
|
3897
|
-
const a =
|
|
3898
|
-
return i(),
|
|
3899
|
-
l.hasNotice ? (i(),
|
|
3974
|
+
function la(e, t, o, n, l, s) {
|
|
3975
|
+
const a = et;
|
|
3976
|
+
return i(), v("div", null, [
|
|
3977
|
+
l.hasNotice ? (i(), m(a, Z(X({ key: 0 }, l.noticeProps)), null, 16)) : $("", !0)
|
|
3900
3978
|
]);
|
|
3901
3979
|
}
|
|
3902
|
-
const
|
|
3980
|
+
const sa = /* @__PURE__ */ R(na, [["render", la]]), aa = ["innerHTML"], ia = /* @__PURE__ */ z({
|
|
3903
3981
|
__name: "PageLoad",
|
|
3904
3982
|
props: {
|
|
3905
3983
|
schemaHandler: { type: Function, default: (e) => e },
|
|
3906
3984
|
schemaApi: { default: "" }
|
|
3907
3985
|
},
|
|
3908
3986
|
setup(e) {
|
|
3909
|
-
const t = e,
|
|
3910
|
-
return
|
|
3911
|
-
const
|
|
3912
|
-
(window?.App?.config?.globalProperties?.$http).get(t.schemaApi ||
|
|
3913
|
-
a.value = !1,
|
|
3987
|
+
const t = e, o = Y(), n = U(), l = j(), s = Q(), a = C(!0), c = C(!1), d = C({}), f = C(""), p = C({}), b = C([]), S = C(!1), I = k(() => l.env), O = k(() => n);
|
|
3988
|
+
return Ge(() => {
|
|
3989
|
+
const w = s.path.split("/").filter((g) => g), y = w.length > 1 ? w.slice(0, w.length - 1).join("/") : w[0], x = "/schema" + s.meta.path, F = { params: s.params };
|
|
3990
|
+
(window?.App?.config?.globalProperties?.$http).get(t.schemaApi || x, F).then(({ data: g }) => {
|
|
3991
|
+
a.value = !1, re(g) && (g.notice !== void 0 && (c.value = !0, Je(g.notice) ? d.value = { title: g.notice } : re(g.notice) && (d.value = g.notice, f.value = g.notice.noticeApi), delete g.notice), b.value = g.ownerNames || [], S.value = g.serviceOffLine || !1), p.value = t.schemaHandler(g, y), o.SET_PAGE_JSON_SCHEMA({ page: s.path, json: p.value });
|
|
3914
3992
|
});
|
|
3915
|
-
}), (
|
|
3916
|
-
const
|
|
3917
|
-
return i(),
|
|
3918
|
-
|
|
3993
|
+
}), (w, y) => {
|
|
3994
|
+
const x = et;
|
|
3995
|
+
return i(), v(A, null, [
|
|
3996
|
+
h(b).length > 0 ? (i(), m(x, {
|
|
3919
3997
|
key: 0,
|
|
3920
|
-
title: `该页面功能对应开发: [ ${
|
|
3998
|
+
title: `该页面功能对应开发: [ ${h(b).join(", ")} ] 有问题可直接企微反馈`,
|
|
3921
3999
|
type: "info",
|
|
3922
4000
|
style: { margin: "0 0 20px 0" },
|
|
3923
4001
|
closable: !1
|
|
3924
4002
|
}, null, 8, ["title"])) : $("", !0),
|
|
3925
|
-
|
|
4003
|
+
h(I) === "prod" && h(S) ? (i(), v("div", {
|
|
3926
4004
|
key: 1,
|
|
3927
4005
|
class: "offline-notice",
|
|
3928
|
-
innerHTML:
|
|
3929
|
-
}, null, 8,
|
|
3930
|
-
|
|
4006
|
+
innerHTML: h(S) === !0 ? h(O).serviceOffLineNotice : h(S)
|
|
4007
|
+
}, null, 8, aa)) : (i(), v(A, { key: 2 }, [
|
|
4008
|
+
h(c) ? (i(), m(sa, {
|
|
3931
4009
|
key: 0,
|
|
3932
|
-
notice:
|
|
4010
|
+
notice: h(d),
|
|
3933
4011
|
style: { margin: "0 0 20px 0" },
|
|
3934
|
-
"data-api":
|
|
4012
|
+
"data-api": h(f)
|
|
3935
4013
|
}, null, 8, ["notice", "data-api"])) : $("", !0),
|
|
3936
|
-
|
|
4014
|
+
h(a) ? (i(), m(oa, { key: 1 })) : pe(w.$slots, "default", Z(X({ key: 2 }, h(p))), void 0, !0)
|
|
3937
4015
|
], 64))
|
|
3938
4016
|
], 64);
|
|
3939
4017
|
};
|
|
3940
4018
|
}
|
|
3941
|
-
}),
|
|
4019
|
+
}), ge = /* @__PURE__ */ R(ia, [["__scopeId", "data-v-e330fdc7"]]), Xt = {
|
|
3942
4020
|
__name: "table",
|
|
3943
4021
|
setup(e) {
|
|
3944
|
-
const t = (
|
|
3945
|
-
if (
|
|
4022
|
+
const t = (o, n) => {
|
|
4023
|
+
if (o.orderBy) {
|
|
3946
4024
|
const s = {
|
|
3947
|
-
prop:
|
|
3948
|
-
order:
|
|
4025
|
+
prop: o.orderBy.field,
|
|
4026
|
+
order: o.orderBy.mod === "desc" ? "descending" : "ascending"
|
|
3949
4027
|
};
|
|
3950
|
-
|
|
4028
|
+
o.tableProps = q(o.tableProps, { defaultSort: s });
|
|
3951
4029
|
}
|
|
3952
|
-
const l = Object.keys(
|
|
3953
|
-
return Object.keys(
|
|
3954
|
-
l.indexOf(s) === -1 && delete
|
|
3955
|
-
}),
|
|
4030
|
+
const l = Object.keys(be.props);
|
|
4031
|
+
return Object.keys(o).forEach((s) => {
|
|
4032
|
+
l.indexOf(s) === -1 && delete o[s];
|
|
4033
|
+
}), o.listApi === void 0 && (o.listApi = `/${n}/list`), o;
|
|
3956
4034
|
};
|
|
3957
|
-
return (
|
|
4035
|
+
return (o, n) => (i(), m(ge, { "schema-handler": t }, {
|
|
3958
4036
|
default: r((l) => [
|
|
3959
|
-
u(
|
|
4037
|
+
u(h(be), Z(ce(l)), null, 16)
|
|
3960
4038
|
]),
|
|
3961
4039
|
_: 1
|
|
3962
4040
|
}));
|
|
3963
4041
|
}
|
|
3964
|
-
},
|
|
4042
|
+
}, He = {
|
|
3965
4043
|
__name: "form",
|
|
3966
4044
|
setup(e) {
|
|
3967
|
-
const t =
|
|
4045
|
+
const t = Q(), o = Te(), n = (c, d) => {
|
|
3968
4046
|
const f = Object.keys(ne.props);
|
|
3969
4047
|
return Object.keys(c).forEach((p) => {
|
|
3970
4048
|
if (f.indexOf(p) === -1) {
|
|
3971
4049
|
delete c[p];
|
|
3972
4050
|
return;
|
|
3973
4051
|
}
|
|
3974
|
-
/.*Api$/.test(p) && (c[p] =
|
|
3975
|
-
}), c.saveApi === void 0 && (t.params.id !== void 0 ? (c.saveApi = `/${d}/update/${t.params.id}`, c.getApi || (c.getApi = `/${d}/get/${t.params.id}`)) : (delete c.getApi, c.saveApi = `/${d}/create`)), c =
|
|
4052
|
+
/.*Api$/.test(p) && (c[p] = ie(c[p], t.params));
|
|
4053
|
+
}), c.saveApi === void 0 && (t.params.id !== void 0 ? (c.saveApi = `/${d}/update/${t.params.id}`, c.getApi || (c.getApi = `/${d}/get/${t.params.id}`)) : (delete c.getApi, c.saveApi = `/${d}/create`)), c = q({
|
|
3976
4054
|
saveApi: d + "/save",
|
|
3977
4055
|
afterSubmit: "goback",
|
|
3978
4056
|
afterReset: "goback",
|
|
3979
4057
|
mod: t.params.id ? "edit" : "create"
|
|
3980
4058
|
}, c), c;
|
|
3981
|
-
}, l =
|
|
3982
|
-
|
|
4059
|
+
}, l = C(0), s = () => {
|
|
4060
|
+
no.request({
|
|
3983
4061
|
url: "/form_mutex",
|
|
3984
4062
|
method: "get",
|
|
3985
4063
|
params: {
|
|
@@ -3998,22 +4076,22 @@ const Ys = /* @__PURE__ */ P(Xs, [["render", Zs]]), ea = ["innerHTML"], ta = /*
|
|
|
3998
4076
|
});
|
|
3999
4077
|
};
|
|
4000
4078
|
Ie(() => {
|
|
4001
|
-
const c =
|
|
4079
|
+
const c = U();
|
|
4002
4080
|
t.params.id !== void 0 && c.formMutex && (s(), l.value = setInterval(s, 2e3));
|
|
4003
|
-
}),
|
|
4081
|
+
}), So(() => {
|
|
4004
4082
|
clearInterval(l.value);
|
|
4005
4083
|
});
|
|
4006
4084
|
function a() {
|
|
4007
|
-
t.query?.goback ?
|
|
4085
|
+
t.query?.goback ? o.push(t.query?.goback) : history.state.back && history.back();
|
|
4008
4086
|
}
|
|
4009
|
-
return (c, d) => (i(),
|
|
4087
|
+
return (c, d) => (i(), m(ge, { "schema-handler": n }, {
|
|
4010
4088
|
default: r((f) => [
|
|
4011
|
-
u(
|
|
4089
|
+
u(h(ne), Z(ce(f)), null, 16)
|
|
4012
4090
|
]),
|
|
4013
4091
|
_: 1
|
|
4014
4092
|
}));
|
|
4015
4093
|
}
|
|
4016
|
-
},
|
|
4094
|
+
}, ra = z({
|
|
4017
4095
|
name: "VTree",
|
|
4018
4096
|
components: {
|
|
4019
4097
|
VForm: ne
|
|
@@ -4069,7 +4147,7 @@ const Ys = /* @__PURE__ */ P(Xs, [["render", Zs]]), ea = ["innerHTML"], ta = /*
|
|
|
4069
4147
|
// 1 新增, 2 编辑
|
|
4070
4148
|
treeData: [],
|
|
4071
4149
|
formData: {},
|
|
4072
|
-
localTreeProps:
|
|
4150
|
+
localTreeProps: q({
|
|
4073
4151
|
"default-expand-all": !0,
|
|
4074
4152
|
"expand-on-click-node": !1,
|
|
4075
4153
|
props: {
|
|
@@ -4087,7 +4165,7 @@ const Ys = /* @__PURE__ */ P(Xs, [["render", Zs]]), ea = ["innerHTML"], ta = /*
|
|
|
4087
4165
|
return ["", "新建", "编辑"][this.type];
|
|
4088
4166
|
},
|
|
4089
4167
|
formProps() {
|
|
4090
|
-
let e =
|
|
4168
|
+
let e = ie(this.$props.saveApi, this.formData);
|
|
4091
4169
|
return this.type === 1 && (e = this.$props.createApi), {
|
|
4092
4170
|
saveApi: e,
|
|
4093
4171
|
getApi: this.$props.getApi,
|
|
@@ -4112,8 +4190,8 @@ const Ys = /* @__PURE__ */ P(Xs, [["render", Zs]]), ea = ["innerHTML"], ta = /*
|
|
|
4112
4190
|
},
|
|
4113
4191
|
append(e, t) {
|
|
4114
4192
|
this.type = 1;
|
|
4115
|
-
const
|
|
4116
|
-
e.children || (e.children = []), this.formData =
|
|
4193
|
+
const o = { pid: e.id, [this.$props.props?.levelKey ?? "level"]: t.level + 1, ...jo(this.$props.props?.effectData, e) };
|
|
4194
|
+
e.children || (e.children = []), this.formData = o, this.formkey++, e.children.push(o), this.treeData = [...this.treeData];
|
|
4117
4195
|
},
|
|
4118
4196
|
canAppend(e, t) {
|
|
4119
4197
|
return e[this.localTreeProps.props.label] ? t.level < this.$props.maxDepth : !1;
|
|
@@ -4126,7 +4204,7 @@ const Ys = /* @__PURE__ */ P(Xs, [["render", Zs]]), ea = ["innerHTML"], ta = /*
|
|
|
4126
4204
|
remove(e) {
|
|
4127
4205
|
this.$http.request({
|
|
4128
4206
|
method: "DELETE",
|
|
4129
|
-
url:
|
|
4207
|
+
url: ie(this.$props.deleteApi, e)
|
|
4130
4208
|
}).then(({ code: t }) => {
|
|
4131
4209
|
t !== 0 ? this.$message.error("操作失败") : this.loadTree();
|
|
4132
4210
|
});
|
|
@@ -4139,27 +4217,27 @@ const Ys = /* @__PURE__ */ P(Xs, [["render", Zs]]), ea = ["innerHTML"], ta = /*
|
|
|
4139
4217
|
allowDrap(e) {
|
|
4140
4218
|
return !0;
|
|
4141
4219
|
},
|
|
4142
|
-
allowDrop(e, t,
|
|
4143
|
-
return
|
|
4220
|
+
allowDrop(e, t, o) {
|
|
4221
|
+
return o === "inner";
|
|
4144
4222
|
},
|
|
4145
|
-
handleDragEnd(e, t,
|
|
4223
|
+
handleDragEnd(e, t, o, n) {
|
|
4146
4224
|
const l = e.data;
|
|
4147
4225
|
l.pid = t.data.id, this.$http.request({
|
|
4148
4226
|
method: "POST",
|
|
4149
|
-
url:
|
|
4227
|
+
url: ie(this.$props.saveApi, l),
|
|
4150
4228
|
data: l
|
|
4151
4229
|
}).then(({ code: s }) => {
|
|
4152
4230
|
s !== 0 && this.$message.error("操作失败");
|
|
4153
4231
|
});
|
|
4154
4232
|
}
|
|
4155
4233
|
}
|
|
4156
|
-
}),
|
|
4234
|
+
}), ca = { class: "card-header" }, ua = { class: "tree-action" }, da = { key: 0 }, pa = {
|
|
4157
4235
|
key: 1,
|
|
4158
4236
|
style: { color: "#E6A23C" }
|
|
4159
|
-
},
|
|
4160
|
-
function
|
|
4161
|
-
const a =
|
|
4162
|
-
return i(),
|
|
4237
|
+
}, fa = { class: "card-header" };
|
|
4238
|
+
function ma(e, t, o, n, l, s) {
|
|
4239
|
+
const a = he, c = mn, d = $e, f = Oe, p = P("v-form"), b = _e;
|
|
4240
|
+
return i(), m(b, {
|
|
4163
4241
|
class: "tree-box",
|
|
4164
4242
|
gutter: 20
|
|
4165
4243
|
}, {
|
|
@@ -4171,21 +4249,21 @@ function ra(e, t, n, o, l, s) {
|
|
|
4171
4249
|
default: r(() => [
|
|
4172
4250
|
u(d, { shadow: "never" }, {
|
|
4173
4251
|
header: r(() => [
|
|
4174
|
-
|
|
4175
|
-
t[3] || (t[3] =
|
|
4252
|
+
_("div", ca, [
|
|
4253
|
+
t[3] || (t[3] = _("span", null, "列表", -1)),
|
|
4176
4254
|
u(a, {
|
|
4177
4255
|
type: "text",
|
|
4178
4256
|
onClick: t[0] || (t[0] = () => e.appendNew())
|
|
4179
4257
|
}, {
|
|
4180
4258
|
default: r(() => [...t[2] || (t[2] = [
|
|
4181
|
-
|
|
4259
|
+
T("添加", -1)
|
|
4182
4260
|
])]),
|
|
4183
4261
|
_: 1
|
|
4184
4262
|
})
|
|
4185
4263
|
])
|
|
4186
4264
|
]),
|
|
4187
4265
|
default: r(() => [
|
|
4188
|
-
(e.treeData || []).length > 0 ? (i(),
|
|
4266
|
+
(e.treeData || []).length > 0 ? (i(), m(c, X({
|
|
4189
4267
|
key: 0,
|
|
4190
4268
|
style: { height: "100vh" },
|
|
4191
4269
|
data: e.treeData,
|
|
@@ -4196,40 +4274,40 @@ function ra(e, t, n, o, l, s) {
|
|
|
4196
4274
|
"allow-drop": e.allowDrop,
|
|
4197
4275
|
onNodeDragEnd: e.handleDragEnd
|
|
4198
4276
|
}), {
|
|
4199
|
-
default: r(({ node:
|
|
4200
|
-
|
|
4201
|
-
|
|
4202
|
-
|
|
4203
|
-
|
|
4277
|
+
default: r(({ node: S, data: I }) => [
|
|
4278
|
+
_("span", ua, [
|
|
4279
|
+
I[e.localTreeProps.props.label] ? (i(), v("span", da, B(I[e.localTreeProps.props.label]), 1)) : (i(), v("span", pa, "请在右侧表单中修改 --> ")),
|
|
4280
|
+
_("span", null, [
|
|
4281
|
+
I[e.localTreeProps.props.label] ? (i(), m(a, {
|
|
4204
4282
|
key: 0,
|
|
4205
4283
|
class: "button",
|
|
4206
4284
|
type: "text",
|
|
4207
|
-
onClick: () => e.onclick(
|
|
4285
|
+
onClick: () => e.onclick(I)
|
|
4208
4286
|
}, {
|
|
4209
4287
|
default: r(() => [...t[4] || (t[4] = [
|
|
4210
|
-
|
|
4288
|
+
T("编辑", -1)
|
|
4211
4289
|
])]),
|
|
4212
4290
|
_: 1
|
|
4213
4291
|
}, 8, ["onClick"])) : $("", !0),
|
|
4214
|
-
e.canAppend(
|
|
4292
|
+
e.canAppend(I, S) ? (i(), m(a, {
|
|
4215
4293
|
key: 1,
|
|
4216
4294
|
class: "button",
|
|
4217
4295
|
type: "text",
|
|
4218
|
-
onClick: () => e.append(
|
|
4296
|
+
onClick: () => e.append(I, S)
|
|
4219
4297
|
}, {
|
|
4220
4298
|
default: r(() => [...t[5] || (t[5] = [
|
|
4221
|
-
|
|
4299
|
+
T("添加", -1)
|
|
4222
4300
|
])]),
|
|
4223
4301
|
_: 1
|
|
4224
4302
|
}, 8, ["onClick"])) : $("", !0),
|
|
4225
|
-
|
|
4303
|
+
I.children === void 0 || I.children.length === 0 ? (i(), m(a, {
|
|
4226
4304
|
key: 2,
|
|
4227
4305
|
class: "button",
|
|
4228
4306
|
type: "text",
|
|
4229
|
-
onClick: () => e.remove(
|
|
4307
|
+
onClick: () => e.remove(I)
|
|
4230
4308
|
}, {
|
|
4231
4309
|
default: r(() => [...t[6] || (t[6] = [
|
|
4232
|
-
|
|
4310
|
+
T("删除", -1)
|
|
4233
4311
|
])]),
|
|
4234
4312
|
_: 1
|
|
4235
4313
|
}, 8, ["onClick"])) : $("", !0)
|
|
@@ -4249,20 +4327,20 @@ function ra(e, t, n, o, l, s) {
|
|
|
4249
4327
|
class: "tree-form"
|
|
4250
4328
|
}, {
|
|
4251
4329
|
default: r(() => [
|
|
4252
|
-
e.type ? (i(),
|
|
4330
|
+
e.type ? (i(), m(d, {
|
|
4253
4331
|
key: 0,
|
|
4254
4332
|
shadow: "never"
|
|
4255
4333
|
}, {
|
|
4256
4334
|
header: r(() => [
|
|
4257
|
-
|
|
4258
|
-
|
|
4335
|
+
_("div", fa, [
|
|
4336
|
+
_("span", null, B(e.formType), 1)
|
|
4259
4337
|
])
|
|
4260
4338
|
]),
|
|
4261
4339
|
default: r(() => [
|
|
4262
|
-
(i(),
|
|
4340
|
+
(i(), m(p, X({
|
|
4263
4341
|
key: e.formkey,
|
|
4264
4342
|
modelValue: e.formData,
|
|
4265
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
4343
|
+
"onUpdate:modelValue": t[1] || (t[1] = (S) => e.formData = S)
|
|
4266
4344
|
}, e.formProps, { onSubmit: e.submit }), null, 16, ["modelValue", "onSubmit"]))
|
|
4267
4345
|
]),
|
|
4268
4346
|
_: 1
|
|
@@ -4274,18 +4352,18 @@ function ra(e, t, n, o, l, s) {
|
|
|
4274
4352
|
_: 1
|
|
4275
4353
|
});
|
|
4276
4354
|
}
|
|
4277
|
-
const
|
|
4355
|
+
const _t = /* @__PURE__ */ R(ra, [["render", ma]]), ha = {
|
|
4278
4356
|
__name: "tree",
|
|
4279
4357
|
setup(e) {
|
|
4280
|
-
const t = (
|
|
4281
|
-
const l = Object.keys(
|
|
4282
|
-
return Object.keys(
|
|
4283
|
-
l.indexOf(s) === -1 && delete
|
|
4284
|
-
}),
|
|
4358
|
+
const t = (o, n) => {
|
|
4359
|
+
const l = Object.keys(_t.props);
|
|
4360
|
+
return Object.keys(o).forEach((s) => {
|
|
4361
|
+
l.indexOf(s) === -1 && delete o[s];
|
|
4362
|
+
}), o;
|
|
4285
4363
|
};
|
|
4286
|
-
return (
|
|
4364
|
+
return (o, n) => (i(), m(ge, { "schema-handler": t }, {
|
|
4287
4365
|
default: r((l) => [
|
|
4288
|
-
u(
|
|
4366
|
+
u(_t, Z(ce(l)), null, 16)
|
|
4289
4367
|
]),
|
|
4290
4368
|
_: 1
|
|
4291
4369
|
}));
|
|
@@ -4293,15 +4371,15 @@ const yt = /* @__PURE__ */ P(na, [["render", ra]]), ca = {
|
|
|
4293
4371
|
}, je = {
|
|
4294
4372
|
__name: "container",
|
|
4295
4373
|
setup(e) {
|
|
4296
|
-
const t =
|
|
4297
|
-
return
|
|
4374
|
+
const t = C(0);
|
|
4375
|
+
return Wo(() => {
|
|
4298
4376
|
t.value++;
|
|
4299
|
-
}), (
|
|
4300
|
-
const l =
|
|
4301
|
-
return i(),
|
|
4377
|
+
}), (o, n) => {
|
|
4378
|
+
const l = P("router-view");
|
|
4379
|
+
return i(), m(l);
|
|
4302
4380
|
};
|
|
4303
4381
|
}
|
|
4304
|
-
},
|
|
4382
|
+
}, ba = {
|
|
4305
4383
|
title: {
|
|
4306
4384
|
text: ""
|
|
4307
4385
|
},
|
|
@@ -4330,34 +4408,34 @@ const yt = /* @__PURE__ */ P(na, [["render", ra]]), ca = {
|
|
|
4330
4408
|
},
|
|
4331
4409
|
series: []
|
|
4332
4410
|
};
|
|
4333
|
-
function
|
|
4334
|
-
if (
|
|
4411
|
+
function ya(e, t, o) {
|
|
4412
|
+
if (o.length === 0)
|
|
4335
4413
|
return {};
|
|
4336
|
-
let
|
|
4337
|
-
if (
|
|
4338
|
-
const l = [], s = Object.keys(
|
|
4414
|
+
let n = q({}, ba);
|
|
4415
|
+
if (n.title.text = e, Je(t)) {
|
|
4416
|
+
const l = [], s = Object.keys(o[0]);
|
|
4339
4417
|
let a = s[0], c = s.filter((f, p) => p > 0), d = t;
|
|
4340
4418
|
if (t.indexOf(":") > -1) {
|
|
4341
4419
|
const f = t.split(":"), p = f[1].split(",");
|
|
4342
|
-
d = f[0], a = p[0], c = p.filter((
|
|
4420
|
+
d = f[0], a = p[0], c = p.filter((b, S) => S > 0);
|
|
4343
4421
|
}
|
|
4344
4422
|
c.forEach((f) => {
|
|
4345
4423
|
const p = [];
|
|
4346
|
-
|
|
4347
|
-
p.push(
|
|
4348
|
-
}),
|
|
4424
|
+
o.forEach((b) => {
|
|
4425
|
+
p.push(b[f]);
|
|
4426
|
+
}), n.series.push({
|
|
4349
4427
|
name: f,
|
|
4350
4428
|
type: d,
|
|
4351
4429
|
smooth: !0,
|
|
4352
4430
|
data: p
|
|
4353
|
-
}),
|
|
4354
|
-
}),
|
|
4431
|
+
}), n.legend.data.push(f);
|
|
4432
|
+
}), o.forEach((f) => {
|
|
4355
4433
|
l.push(f[a]);
|
|
4356
|
-
}),
|
|
4434
|
+
}), n.xAxis.data = l;
|
|
4357
4435
|
}
|
|
4358
|
-
return
|
|
4436
|
+
return re(t) && (n = q(n, t)), n;
|
|
4359
4437
|
}
|
|
4360
|
-
const
|
|
4438
|
+
const _a = z({
|
|
4361
4439
|
name: "NumberPanel",
|
|
4362
4440
|
props: {
|
|
4363
4441
|
dataList: {
|
|
@@ -4368,27 +4446,27 @@ const pa = K({
|
|
|
4368
4446
|
data() {
|
|
4369
4447
|
return {};
|
|
4370
4448
|
}
|
|
4371
|
-
}),
|
|
4372
|
-
function
|
|
4373
|
-
return i(!0),
|
|
4374
|
-
|
|
4375
|
-
(i(!0),
|
|
4449
|
+
}), va = { class: "number-panel-title" }, ga = { class: "number" }, ka = { class: "name" };
|
|
4450
|
+
function Sa(e, t, o, n, l, s) {
|
|
4451
|
+
return i(!0), v(A, null, V(e.dataList, (a, c) => (i(), v("span", { key: c }, [
|
|
4452
|
+
_("div", va, [
|
|
4453
|
+
(i(!0), v(A, null, V(Object.keys(a), (d, f) => (i(), v("div", {
|
|
4376
4454
|
key: f,
|
|
4377
4455
|
class: "title-inner"
|
|
4378
4456
|
}, [
|
|
4379
|
-
|
|
4380
|
-
|
|
4457
|
+
_("p", ga, B(a[d]), 1),
|
|
4458
|
+
_("p", ka, B(d), 1)
|
|
4381
4459
|
]))), 128))
|
|
4382
4460
|
])
|
|
4383
4461
|
]))), 128);
|
|
4384
4462
|
}
|
|
4385
|
-
const
|
|
4463
|
+
const wa = /* @__PURE__ */ R(_a, [["render", Sa], ["__scopeId", "data-v-cc0d8293"]]), xa = {
|
|
4386
4464
|
components: {
|
|
4387
|
-
Chart:
|
|
4388
|
-
Md:
|
|
4389
|
-
Json:
|
|
4390
|
-
Table:
|
|
4391
|
-
Number:
|
|
4465
|
+
Chart: bn,
|
|
4466
|
+
Md: xn,
|
|
4467
|
+
Json: tt,
|
|
4468
|
+
Table: be,
|
|
4469
|
+
Number: wa,
|
|
4392
4470
|
Html: ""
|
|
4393
4471
|
},
|
|
4394
4472
|
props: {
|
|
@@ -4401,29 +4479,29 @@ const ya = /* @__PURE__ */ P(pa, [["render", ba], ["__scopeId", "data-v-cc0d8293
|
|
|
4401
4479
|
setup(e) {
|
|
4402
4480
|
const t = () => e.option.chart === "num" ? "number" : e.option.type;
|
|
4403
4481
|
return {
|
|
4404
|
-
compprops: (
|
|
4482
|
+
compprops: (n) => {
|
|
4405
4483
|
const l = t();
|
|
4406
4484
|
if (l === "number")
|
|
4407
4485
|
return {
|
|
4408
|
-
dataList:
|
|
4486
|
+
dataList: n.data
|
|
4409
4487
|
};
|
|
4410
4488
|
if (l === "chart")
|
|
4411
4489
|
return {
|
|
4412
|
-
options:
|
|
4490
|
+
options: ya(n.id, n.chart, n.data)
|
|
4413
4491
|
};
|
|
4414
4492
|
if (l === "md")
|
|
4415
4493
|
return {
|
|
4416
|
-
source:
|
|
4494
|
+
source: n.data
|
|
4417
4495
|
};
|
|
4418
4496
|
if (l === "table") {
|
|
4419
|
-
if (!
|
|
4497
|
+
if (!Tt(n.data))
|
|
4420
4498
|
return { showPagination: !1 };
|
|
4421
4499
|
const s = [];
|
|
4422
|
-
return
|
|
4500
|
+
return n.data[0] && Object.keys(n.data[0]).forEach((a, c) => {
|
|
4423
4501
|
s.push({ field: a, label: a });
|
|
4424
4502
|
}), {
|
|
4425
4503
|
headers: s,
|
|
4426
|
-
list:
|
|
4504
|
+
list: n.data,
|
|
4427
4505
|
showPagination: !1
|
|
4428
4506
|
};
|
|
4429
4507
|
}
|
|
@@ -4433,21 +4511,21 @@ const ya = /* @__PURE__ */ P(pa, [["render", ba], ["__scopeId", "data-v-cc0d8293
|
|
|
4433
4511
|
};
|
|
4434
4512
|
}
|
|
4435
4513
|
};
|
|
4436
|
-
function
|
|
4437
|
-
const a =
|
|
4438
|
-
return
|
|
4514
|
+
function Ea(e, t, o, n, l, s) {
|
|
4515
|
+
const a = $e, c = wo("resize");
|
|
4516
|
+
return xo((i(), m(a, {
|
|
4439
4517
|
shadow: "never",
|
|
4440
4518
|
class: "part"
|
|
4441
4519
|
}, {
|
|
4442
4520
|
default: r(() => [
|
|
4443
|
-
(i(),
|
|
4521
|
+
(i(), m(ze(n.comptype()), Z(ce(n.compprops(o.option))), null, 16))
|
|
4444
4522
|
]),
|
|
4445
4523
|
_: 1
|
|
4446
4524
|
})), [
|
|
4447
4525
|
[c, !0]
|
|
4448
4526
|
]);
|
|
4449
4527
|
}
|
|
4450
|
-
const
|
|
4528
|
+
const Ia = /* @__PURE__ */ R(xa, [["render", Ea], ["__scopeId", "data-v-a5a65cc1"]]), Ca = /* @__PURE__ */ z({
|
|
4451
4529
|
__name: "index",
|
|
4452
4530
|
props: {
|
|
4453
4531
|
filter: {
|
|
@@ -4460,13 +4538,13 @@ const ga = /* @__PURE__ */ P(_a, [["render", va], ["__scopeId", "data-v-a5a65cc1
|
|
|
4460
4538
|
}
|
|
4461
4539
|
},
|
|
4462
4540
|
setup(e) {
|
|
4463
|
-
const t =
|
|
4541
|
+
const t = Q();
|
|
4464
4542
|
Ie(() => {
|
|
4465
4543
|
});
|
|
4466
|
-
const
|
|
4467
|
-
|
|
4468
|
-
|
|
4469
|
-
p.default !== null && (
|
|
4544
|
+
const o = e, n = C({});
|
|
4545
|
+
Ge(() => {
|
|
4546
|
+
o.filter?.forEach((p) => {
|
|
4547
|
+
p.default !== null && (n.value[p.field] = p.default);
|
|
4470
4548
|
});
|
|
4471
4549
|
});
|
|
4472
4550
|
const l = {
|
|
@@ -4479,36 +4557,36 @@ const ga = /* @__PURE__ */ P(_a, [["render", va], ["__scopeId", "data-v-a5a65cc1
|
|
|
4479
4557
|
cancelButton: {
|
|
4480
4558
|
text: "重置"
|
|
4481
4559
|
}
|
|
4482
|
-
}, s =
|
|
4560
|
+
}, s = C(1), a = C(o.filter), c = C(o.dataPart), d = k(() => {
|
|
4483
4561
|
let p = t.params.id;
|
|
4484
4562
|
if (!p) {
|
|
4485
|
-
const
|
|
4486
|
-
p =
|
|
4563
|
+
const b = t.path.split("/");
|
|
4564
|
+
p = b[b.length - 1];
|
|
4487
4565
|
}
|
|
4488
4566
|
return "/focusbi_report/view/" + p;
|
|
4489
4567
|
}), f = (p) => {
|
|
4490
|
-
|
|
4491
|
-
a.value =
|
|
4568
|
+
no.get(d.value, { params: p }).then(({ data: b }) => {
|
|
4569
|
+
a.value = b.filter, c.value = b.dataPart, s.value++;
|
|
4492
4570
|
});
|
|
4493
4571
|
};
|
|
4494
|
-
return (p,
|
|
4495
|
-
const
|
|
4496
|
-
return i(),
|
|
4572
|
+
return (p, b) => {
|
|
4573
|
+
const S = $e, I = Oe, O = et, w = _e;
|
|
4574
|
+
return i(), m(w, null, {
|
|
4497
4575
|
default: r(() => [
|
|
4498
|
-
|
|
4576
|
+
h(a).length > 0 ? (i(), m(I, {
|
|
4499
4577
|
key: 0,
|
|
4500
4578
|
span: 24
|
|
4501
4579
|
}, {
|
|
4502
4580
|
default: r(() => [
|
|
4503
|
-
u(
|
|
4581
|
+
u(S, {
|
|
4504
4582
|
shadow: "never",
|
|
4505
4583
|
class: "part-filter"
|
|
4506
4584
|
}, {
|
|
4507
4585
|
default: r(() => [
|
|
4508
|
-
u(
|
|
4509
|
-
modelValue:
|
|
4510
|
-
"onUpdate:modelValue":
|
|
4511
|
-
"form-items":
|
|
4586
|
+
u(h(ne), {
|
|
4587
|
+
modelValue: h(n),
|
|
4588
|
+
"onUpdate:modelValue": b[0] || (b[0] = (y) => Ke(n) ? n.value = y : null),
|
|
4589
|
+
"form-items": h(a),
|
|
4512
4590
|
options: l,
|
|
4513
4591
|
onSubmit: f
|
|
4514
4592
|
}, null, 8, ["modelValue", "form-items"])
|
|
@@ -4518,27 +4596,27 @@ const ga = /* @__PURE__ */ P(_a, [["render", va], ["__scopeId", "data-v-a5a65cc1
|
|
|
4518
4596
|
]),
|
|
4519
4597
|
_: 1
|
|
4520
4598
|
})) : $("", !0),
|
|
4521
|
-
u(
|
|
4599
|
+
u(I, { span: 24 }, {
|
|
4522
4600
|
default: r(() => [
|
|
4523
|
-
u(
|
|
4601
|
+
u(w, { gutter: 20 }, {
|
|
4524
4602
|
default: r(() => [
|
|
4525
|
-
(i(!0),
|
|
4526
|
-
key:
|
|
4527
|
-
span:
|
|
4603
|
+
(i(!0), v(A, null, V(h(c), (y, x) => (i(), m(I, {
|
|
4604
|
+
key: x,
|
|
4605
|
+
span: y.col || 24
|
|
4528
4606
|
}, {
|
|
4529
4607
|
default: r(() => [
|
|
4530
|
-
|
|
4608
|
+
y.errMsg ? (i(), m(O, {
|
|
4531
4609
|
key: 1,
|
|
4532
|
-
title:
|
|
4610
|
+
title: y.id + " 片段执行出错",
|
|
4533
4611
|
type: "error"
|
|
4534
4612
|
}, {
|
|
4535
4613
|
default: r(() => [
|
|
4536
|
-
|
|
4614
|
+
T(B(y.errMsg), 1)
|
|
4537
4615
|
]),
|
|
4538
4616
|
_: 2
|
|
4539
|
-
}, 1032, ["title"])) : (i(),
|
|
4540
|
-
key:
|
|
4541
|
-
option:
|
|
4617
|
+
}, 1032, ["title"])) : (i(), m(Ia, {
|
|
4618
|
+
key: h(s),
|
|
4619
|
+
option: y
|
|
4542
4620
|
}, null, 8, ["option"]))
|
|
4543
4621
|
]),
|
|
4544
4622
|
_: 2
|
|
@@ -4554,32 +4632,32 @@ const ga = /* @__PURE__ */ P(_a, [["render", va], ["__scopeId", "data-v-a5a65cc1
|
|
|
4554
4632
|
});
|
|
4555
4633
|
};
|
|
4556
4634
|
}
|
|
4557
|
-
}),
|
|
4635
|
+
}), Ta = {
|
|
4558
4636
|
__name: "report",
|
|
4559
4637
|
setup(e) {
|
|
4560
|
-
const t =
|
|
4561
|
-
let
|
|
4562
|
-
if (!
|
|
4638
|
+
const t = Q(), o = k(() => {
|
|
4639
|
+
let n = t.params.id;
|
|
4640
|
+
if (!n) {
|
|
4563
4641
|
const l = t.path.split("/");
|
|
4564
|
-
|
|
4642
|
+
n = l[l.length - 1];
|
|
4565
4643
|
}
|
|
4566
|
-
return "/focusbi_report/view/" +
|
|
4644
|
+
return "/focusbi_report/view/" + n;
|
|
4567
4645
|
});
|
|
4568
|
-
return (
|
|
4646
|
+
return (n, l) => (i(), m(ge, { "schema-api": h(o) }, {
|
|
4569
4647
|
default: r((s) => [
|
|
4570
|
-
u(
|
|
4648
|
+
u(Ca, Z(ce(s)), null, 16)
|
|
4571
4649
|
]),
|
|
4572
4650
|
_: 1
|
|
4573
4651
|
}, 8, ["schema-api"]));
|
|
4574
4652
|
}
|
|
4575
|
-
},
|
|
4576
|
-
card:
|
|
4653
|
+
}, Oa = (e) => u("div", null, [e.test]), $a = {
|
|
4654
|
+
card: Go,
|
|
4577
4655
|
form: ne,
|
|
4578
|
-
table:
|
|
4579
|
-
test:
|
|
4580
|
-
row:
|
|
4581
|
-
col:
|
|
4582
|
-
},
|
|
4656
|
+
table: be,
|
|
4657
|
+
test: Oa,
|
|
4658
|
+
row: Fo,
|
|
4659
|
+
col: Ho
|
|
4660
|
+
}, Ba = {
|
|
4583
4661
|
card: {
|
|
4584
4662
|
type: "card",
|
|
4585
4663
|
props: {
|
|
@@ -4600,21 +4678,21 @@ const ga = /* @__PURE__ */ P(_a, [["render", va], ["__scopeId", "data-v-a5a65cc1
|
|
|
4600
4678
|
}
|
|
4601
4679
|
}
|
|
4602
4680
|
};
|
|
4603
|
-
function
|
|
4604
|
-
const t = Object.assign({}, e),
|
|
4681
|
+
function Aa(e) {
|
|
4682
|
+
const t = Object.assign({}, e), o = t.type.split(".").reverse(), n = t.span || 24;
|
|
4605
4683
|
delete t.span;
|
|
4606
4684
|
let l = {
|
|
4607
4685
|
...t,
|
|
4608
|
-
type:
|
|
4686
|
+
type: o[0]
|
|
4609
4687
|
};
|
|
4610
|
-
for (let s = 1; s <
|
|
4688
|
+
for (let s = 1; s < o.length; s++)
|
|
4611
4689
|
l = {
|
|
4612
|
-
type:
|
|
4690
|
+
type: o[s],
|
|
4613
4691
|
children: [l]
|
|
4614
4692
|
};
|
|
4615
|
-
return l.span =
|
|
4693
|
+
return l.span = n, st([l]);
|
|
4616
4694
|
}
|
|
4617
|
-
function
|
|
4695
|
+
function st(e) {
|
|
4618
4696
|
const t = {
|
|
4619
4697
|
type: "row",
|
|
4620
4698
|
props: {
|
|
@@ -4623,98 +4701,98 @@ function ot(e) {
|
|
|
4623
4701
|
},
|
|
4624
4702
|
children: []
|
|
4625
4703
|
};
|
|
4626
|
-
return e.forEach((
|
|
4627
|
-
let
|
|
4628
|
-
if (
|
|
4704
|
+
return e.forEach((o) => {
|
|
4705
|
+
let n = Object.assign({}, o);
|
|
4706
|
+
if (re(n.props?.style)) {
|
|
4629
4707
|
let a = "";
|
|
4630
|
-
Object.keys(
|
|
4631
|
-
a += c + ":" +
|
|
4632
|
-
}),
|
|
4708
|
+
Object.keys(n.props?.style).forEach((c) => {
|
|
4709
|
+
a += c + ":" + n.props?.style[c] + ";";
|
|
4710
|
+
}), n.props.style = a;
|
|
4633
4711
|
}
|
|
4634
4712
|
const l = {
|
|
4635
|
-
span:
|
|
4713
|
+
span: n.span ?? 24,
|
|
4636
4714
|
class: "render-col"
|
|
4637
4715
|
};
|
|
4638
|
-
if (delete
|
|
4716
|
+
if (delete n.span, n.type.indexOf(".") > 0) {
|
|
4639
4717
|
t.children.push({
|
|
4640
4718
|
type: "col",
|
|
4641
4719
|
props: l,
|
|
4642
|
-
children:
|
|
4720
|
+
children: Aa(n)
|
|
4643
4721
|
});
|
|
4644
4722
|
return;
|
|
4645
4723
|
}
|
|
4646
|
-
|
|
4724
|
+
n = q({
|
|
4647
4725
|
props: {}
|
|
4648
|
-
},
|
|
4649
|
-
const s =
|
|
4650
|
-
s.length && (
|
|
4726
|
+
}, Ba[n.type] || {}, n);
|
|
4727
|
+
const s = Zt(n.children);
|
|
4728
|
+
s.length && (n.children = st(s)), t.children.push({
|
|
4651
4729
|
type: "col",
|
|
4652
4730
|
props: l,
|
|
4653
|
-
children: [
|
|
4731
|
+
children: [n]
|
|
4654
4732
|
});
|
|
4655
4733
|
}), [t];
|
|
4656
4734
|
}
|
|
4657
|
-
function
|
|
4658
|
-
return
|
|
4735
|
+
function Zt(e) {
|
|
4736
|
+
return Tt(e) ? e : re(e) ? [e] : [];
|
|
4659
4737
|
}
|
|
4660
|
-
let
|
|
4661
|
-
const
|
|
4662
|
-
const t =
|
|
4663
|
-
return
|
|
4664
|
-
default: () =>
|
|
4738
|
+
let Fe = {};
|
|
4739
|
+
const Yt = (e) => {
|
|
4740
|
+
const t = $a[e.type] || Fe[e.type] || e.type;
|
|
4741
|
+
return Io(t, e.props, {
|
|
4742
|
+
default: () => Zt(e.children).map((o) => Yt(o))
|
|
4665
4743
|
});
|
|
4666
|
-
},
|
|
4744
|
+
}, Ra = (e) => (Object.keys(Fe).length === 0 && (Fe = Eo().appContext.components), st(Object.values(e.schema)).map((o) => Yt(o))), Pa = {
|
|
4667
4745
|
__name: "custom",
|
|
4668
4746
|
setup(e) {
|
|
4669
|
-
const t =
|
|
4670
|
-
return (
|
|
4747
|
+
const t = C([]), o = (n, l) => (t.value = Co(n), n);
|
|
4748
|
+
return (n, l) => (i(), m(ge, { "schema-handler": o }, {
|
|
4671
4749
|
default: r(() => [
|
|
4672
|
-
u(
|
|
4750
|
+
u(h(Ra), { schema: h(t) }, null, 8, ["schema"])
|
|
4673
4751
|
]),
|
|
4674
4752
|
_: 1
|
|
4675
4753
|
}));
|
|
4676
4754
|
}
|
|
4677
4755
|
};
|
|
4678
|
-
let
|
|
4679
|
-
function
|
|
4680
|
-
|
|
4756
|
+
let de = {};
|
|
4757
|
+
function yr(e) {
|
|
4758
|
+
de = e;
|
|
4681
4759
|
}
|
|
4682
|
-
const
|
|
4683
|
-
const t = (
|
|
4684
|
-
const
|
|
4685
|
-
return
|
|
4760
|
+
const La = (e) => {
|
|
4761
|
+
const t = (o) => {
|
|
4762
|
+
const n = "./views/" + o + ".vue";
|
|
4763
|
+
return de && de[n] && de[n].default ? de[n].default : (console.error(`自定义组件不存在 ${e.name} ${e.view}`), je);
|
|
4686
4764
|
};
|
|
4687
4765
|
if (e.path === "#")
|
|
4688
4766
|
return je;
|
|
4689
4767
|
switch (e.page_type) {
|
|
4690
4768
|
case J.list:
|
|
4691
|
-
return
|
|
4769
|
+
return Xt;
|
|
4692
4770
|
case J.form:
|
|
4693
|
-
return
|
|
4771
|
+
return He;
|
|
4694
4772
|
case J.custom:
|
|
4695
4773
|
case J.localComp:
|
|
4696
4774
|
return t(e.view || "");
|
|
4697
4775
|
case J.tree:
|
|
4698
|
-
return
|
|
4776
|
+
return ha;
|
|
4699
4777
|
case J.report:
|
|
4700
|
-
return Sa;
|
|
4701
|
-
case J.customSchema:
|
|
4702
4778
|
return Ta;
|
|
4779
|
+
case J.customSchema:
|
|
4780
|
+
return Pa;
|
|
4703
4781
|
}
|
|
4704
4782
|
return je;
|
|
4705
4783
|
};
|
|
4706
|
-
function
|
|
4784
|
+
function Ma(e) {
|
|
4707
4785
|
let t = e.path;
|
|
4708
|
-
return e.type ===
|
|
4786
|
+
return e.type === K.menu && e.page_type === J.entity && (t = "#"), t.indexOf(":id") > -1 && t.indexOf(":id") + 3 === t.length && (t = t.replace(":id", ":id(\\d+)")), t === "#" ? "/" + e.id + "_DIR_" + e.name : t[0] !== "/" ? "/" + t : t;
|
|
4709
4787
|
}
|
|
4710
|
-
function
|
|
4788
|
+
function Da(e) {
|
|
4711
4789
|
return (e.path + e.name).split("/").filter((t) => t).join("_");
|
|
4712
4790
|
}
|
|
4713
|
-
const
|
|
4714
|
-
const t = e.type !==
|
|
4715
|
-
path:
|
|
4716
|
-
name: e.id + "_" +
|
|
4717
|
-
component:
|
|
4791
|
+
const eo = (e) => {
|
|
4792
|
+
const t = e.type !== K.page, o = {
|
|
4793
|
+
path: Ma(e),
|
|
4794
|
+
name: e.id + "_" + Da(e) + "_" + e.path.replaceAll("/", "_"),
|
|
4795
|
+
component: La(e),
|
|
4718
4796
|
meta: {
|
|
4719
4797
|
id: e.id,
|
|
4720
4798
|
pageId: e.id,
|
|
@@ -4726,18 +4804,18 @@ const Zt = (e) => {
|
|
|
4726
4804
|
keepAlive: !1,
|
|
4727
4805
|
role: e.role
|
|
4728
4806
|
},
|
|
4729
|
-
children: e.children ? e.children.map((
|
|
4807
|
+
children: e.children ? e.children.map((n) => eo(n)) : []
|
|
4730
4808
|
};
|
|
4731
4809
|
if (e.page_type === J.entity) {
|
|
4732
|
-
const
|
|
4733
|
-
path:
|
|
4810
|
+
const n = e.path + "/list", l = e.path + "/form", s = e.path + "/:id", a = [{
|
|
4811
|
+
path: n,
|
|
4734
4812
|
name: e.name + "列表" + e.id,
|
|
4735
|
-
component:
|
|
4813
|
+
component: Xt,
|
|
4736
4814
|
meta: {
|
|
4737
4815
|
id: e.id + 99999,
|
|
4738
4816
|
title: "列表",
|
|
4739
4817
|
hidden: !0,
|
|
4740
|
-
menuType:
|
|
4818
|
+
menuType: K.hidden,
|
|
4741
4819
|
keepAlive: !1,
|
|
4742
4820
|
pageId: e.id,
|
|
4743
4821
|
path: e.path
|
|
@@ -4745,12 +4823,12 @@ const Zt = (e) => {
|
|
|
4745
4823
|
}, {
|
|
4746
4824
|
path: l,
|
|
4747
4825
|
name: e.name + "新建" + e.id,
|
|
4748
|
-
component:
|
|
4826
|
+
component: He,
|
|
4749
4827
|
meta: {
|
|
4750
4828
|
id: e.id + 99999 + 1,
|
|
4751
4829
|
title: "新建",
|
|
4752
4830
|
hidden: !0,
|
|
4753
|
-
menuType:
|
|
4831
|
+
menuType: K.hidden,
|
|
4754
4832
|
keepAlive: !1,
|
|
4755
4833
|
pageId: e.id,
|
|
4756
4834
|
path: e.path
|
|
@@ -4758,110 +4836,110 @@ const Zt = (e) => {
|
|
|
4758
4836
|
}, {
|
|
4759
4837
|
path: s,
|
|
4760
4838
|
name: e.name + "编辑" + e.id,
|
|
4761
|
-
component:
|
|
4839
|
+
component: He,
|
|
4762
4840
|
meta: {
|
|
4763
4841
|
id: e.id + 99999 + 2,
|
|
4764
4842
|
title: "编辑",
|
|
4765
4843
|
hidden: !0,
|
|
4766
|
-
menuType:
|
|
4844
|
+
menuType: K.hidden,
|
|
4767
4845
|
keepAlive: !1,
|
|
4768
4846
|
pageId: e.id,
|
|
4769
4847
|
path: e.path
|
|
4770
4848
|
}
|
|
4771
4849
|
}];
|
|
4772
|
-
|
|
4850
|
+
o.children = [...a, ...o.children];
|
|
4773
4851
|
}
|
|
4774
|
-
if (
|
|
4775
|
-
let
|
|
4776
|
-
if (
|
|
4777
|
-
l.meta && !l.meta.hidden && (
|
|
4778
|
-
}),
|
|
4779
|
-
|
|
4852
|
+
if (o.children && o.children.length > 0) {
|
|
4853
|
+
let n = !0;
|
|
4854
|
+
if (o.children.forEach((l) => {
|
|
4855
|
+
l.meta && !l.meta.hidden && (n = !1);
|
|
4856
|
+
}), o.meta && (o.meta.menuType = t ? K.dir : K.hidden), n) {
|
|
4857
|
+
o.meta && (o.meta.menuType = K.menu);
|
|
4780
4858
|
let l = "/";
|
|
4781
|
-
for (let s = 0; s <
|
|
4782
|
-
if (
|
|
4783
|
-
l =
|
|
4859
|
+
for (let s = 0; s < o.children.length; s++)
|
|
4860
|
+
if (o.children[s].path.indexOf("/:") === -1) {
|
|
4861
|
+
l = o.children[s].path;
|
|
4784
4862
|
break;
|
|
4785
4863
|
}
|
|
4786
|
-
|
|
4864
|
+
o.redirect = l, o.path = "/" + e.id + "_DIR" + o.redirect.replaceAll("/", "_").toUpperCase();
|
|
4787
4865
|
}
|
|
4788
4866
|
}
|
|
4789
|
-
return
|
|
4790
|
-
},
|
|
4867
|
+
return o;
|
|
4868
|
+
}, ja = (e) => {
|
|
4791
4869
|
const t = [];
|
|
4792
|
-
return e.forEach((
|
|
4793
|
-
const
|
|
4794
|
-
id:
|
|
4795
|
-
label:
|
|
4870
|
+
return e.forEach((o) => {
|
|
4871
|
+
const n = {
|
|
4872
|
+
id: o.id,
|
|
4873
|
+
label: o.label,
|
|
4796
4874
|
routes: []
|
|
4797
4875
|
};
|
|
4798
|
-
|
|
4799
|
-
|
|
4800
|
-
}), t.push(
|
|
4876
|
+
o.routes.forEach((l) => {
|
|
4877
|
+
n.routes.push(eo(l));
|
|
4878
|
+
}), t.push(n);
|
|
4801
4879
|
}), t;
|
|
4802
|
-
},
|
|
4803
|
-
const t = typeof e.role == "string" ? e.role : "",
|
|
4804
|
-
return !
|
|
4805
|
-
},
|
|
4880
|
+
}, Na = "root", vt = (e) => e ? e.split(",").map((t) => t.trim()).filter((t) => !!t) : [], Va = (e) => {
|
|
4881
|
+
const t = typeof e.role == "string" ? e.role : "", o = e.meta && typeof e.meta.role == "string" ? e.meta.role : "", n = [...vt(t), ...vt(o)];
|
|
4882
|
+
return !n.length && e.children && e.children.length ? [] : Array.from(new Set(n));
|
|
4883
|
+
}, to = (e) => {
|
|
4806
4884
|
const t = { ...e };
|
|
4807
|
-
return e.meta && (t.meta = { ...e.meta }), e.children && e.children.length && (t.children = e.children.map((
|
|
4808
|
-
},
|
|
4809
|
-
const l =
|
|
4810
|
-
if (!
|
|
4811
|
-
return
|
|
4812
|
-
const s = { ...
|
|
4813
|
-
if (
|
|
4814
|
-
const a =
|
|
4885
|
+
return e.meta && (t.meta = { ...e.meta }), e.children && e.children.length && (t.children = e.children.map((o) => to(o))), t;
|
|
4886
|
+
}, Ua = (e, t) => e.length ? t.length ? e.some((o) => t.includes(o)) : !1 : !0, at = (e = [], t) => t.includes(Na) ? e.map((o) => to(o)) : e.reduce((o, n) => {
|
|
4887
|
+
const l = Va(n);
|
|
4888
|
+
if (!Ua(l, t))
|
|
4889
|
+
return o;
|
|
4890
|
+
const s = { ...n };
|
|
4891
|
+
if (n.meta && (s.meta = { ...n.meta }), n.children && n.children.length) {
|
|
4892
|
+
const a = at(n.children, t);
|
|
4815
4893
|
if (!a.length)
|
|
4816
|
-
return
|
|
4894
|
+
return o;
|
|
4817
4895
|
s.children = a;
|
|
4818
4896
|
}
|
|
4819
|
-
return
|
|
4820
|
-
}, []),
|
|
4897
|
+
return o.push(s), o;
|
|
4898
|
+
}, []), qa = (e) => {
|
|
4821
4899
|
const t = globalThis.atob(e);
|
|
4822
|
-
let
|
|
4823
|
-
for (let
|
|
4824
|
-
const l = t.charCodeAt(
|
|
4825
|
-
|
|
4900
|
+
let o = "";
|
|
4901
|
+
for (let n = 0; n < t.length; n++) {
|
|
4902
|
+
const l = t.charCodeAt(n).toString(16).padStart(2, "0");
|
|
4903
|
+
o += "%" + l;
|
|
4826
4904
|
}
|
|
4827
4905
|
try {
|
|
4828
|
-
return decodeURIComponent(
|
|
4906
|
+
return decodeURIComponent(o);
|
|
4829
4907
|
} catch {
|
|
4830
4908
|
return decodeURIComponent(encodeURIComponent(t));
|
|
4831
4909
|
}
|
|
4832
|
-
},
|
|
4833
|
-
const t = e.replace(/-/g, "+").replace(/_/g, "/"),
|
|
4834
|
-
return typeof globalThis.atob == "function" ?
|
|
4835
|
-
},
|
|
4910
|
+
}, Ha = (e) => {
|
|
4911
|
+
const t = e.replace(/-/g, "+").replace(/_/g, "/"), o = 4 - t.length % 4, n = t + (o < 4 ? "=".repeat(o) : "");
|
|
4912
|
+
return typeof globalThis.atob == "function" ? qa(n) : typeof Buffer < "u" ? Buffer.from(n, "base64").toString("utf-8") : "";
|
|
4913
|
+
}, Fa = (e) => {
|
|
4836
4914
|
if (!e)
|
|
4837
4915
|
return null;
|
|
4838
4916
|
const t = e.split(".");
|
|
4839
4917
|
if (t.length < 2)
|
|
4840
4918
|
return null;
|
|
4841
4919
|
try {
|
|
4842
|
-
const
|
|
4843
|
-
return
|
|
4920
|
+
const o = Ha(t[1]);
|
|
4921
|
+
return o ? JSON.parse(o) : null;
|
|
4844
4922
|
} catch {
|
|
4845
4923
|
return null;
|
|
4846
4924
|
}
|
|
4847
|
-
},
|
|
4848
|
-
const t =
|
|
4849
|
-
return (t && typeof t.role == "string" ? t.role : "").split(",").map((
|
|
4925
|
+
}, oo = (e) => {
|
|
4926
|
+
const t = Fa(e);
|
|
4927
|
+
return (t && typeof t.role == "string" ? t.role : "").split(",").map((n) => n.trim()).filter((n) => !!n);
|
|
4850
4928
|
};
|
|
4851
|
-
function
|
|
4852
|
-
e.beforeEach(async (t,
|
|
4853
|
-
if (
|
|
4854
|
-
|
|
4929
|
+
function Ga(e) {
|
|
4930
|
+
e.beforeEach(async (t, o, n) => {
|
|
4931
|
+
if (Wt().indexOf(t.path) !== -1) {
|
|
4932
|
+
n();
|
|
4855
4933
|
return;
|
|
4856
4934
|
}
|
|
4857
|
-
if (
|
|
4858
|
-
|
|
4935
|
+
if (zs()) {
|
|
4936
|
+
n();
|
|
4859
4937
|
return;
|
|
4860
4938
|
}
|
|
4861
|
-
const l = j(
|
|
4939
|
+
const l = j(L);
|
|
4862
4940
|
await l.info();
|
|
4863
|
-
const s = await l.loadRemoteRoutes(), a =
|
|
4864
|
-
const p =
|
|
4941
|
+
const s = await l.loadRemoteRoutes(), a = ja(s), c = oo(ve()), d = a.map((f) => {
|
|
4942
|
+
const p = at(f.routes, c);
|
|
4865
4943
|
return {
|
|
4866
4944
|
...f,
|
|
4867
4945
|
routes: p
|
|
@@ -4871,259 +4949,259 @@ function Na(e) {
|
|
|
4871
4949
|
f.routes.forEach((p) => {
|
|
4872
4950
|
e.addRoute({
|
|
4873
4951
|
path: "/",
|
|
4874
|
-
component:
|
|
4952
|
+
component: Jt,
|
|
4875
4953
|
children: [p]
|
|
4876
4954
|
});
|
|
4877
4955
|
});
|
|
4878
|
-
}), e.addRoute({ name: "404", path: "/:pathMatch(.*)*", redirect: "/404", hidden: !0 }), l.updateRemoteRouter(d), await e.replace(t),
|
|
4956
|
+
}), e.addRoute({ name: "404", path: "/:pathMatch(.*)*", redirect: "/404", hidden: !0 }), l.updateRemoteRouter(d), await e.replace(t), n();
|
|
4879
4957
|
});
|
|
4880
4958
|
}
|
|
4881
|
-
function
|
|
4882
|
-
e.beforeEach(async (t,
|
|
4883
|
-
const s = [
|
|
4959
|
+
function Ka(e) {
|
|
4960
|
+
e.beforeEach(async (t, o, n) => {
|
|
4961
|
+
const s = [U(L).title || ""], a = t.matched.length;
|
|
4884
4962
|
for (let c = a; c > a - 3; c--) {
|
|
4885
4963
|
const d = t.matched[c - 1];
|
|
4886
4964
|
d?.meta?.title && s.push(d.meta.title + "");
|
|
4887
4965
|
}
|
|
4888
|
-
s.length > 1 && (document.title = s.reverse().join("-")),
|
|
4889
|
-
}), e.afterEach(async (t,
|
|
4890
|
-
const l = Y(
|
|
4966
|
+
s.length > 1 && (document.title = s.reverse().join("-")), n();
|
|
4967
|
+
}), e.afterEach(async (t, o, n) => {
|
|
4968
|
+
const l = Y(L);
|
|
4891
4969
|
Object.keys(t.meta).length > 0 && await l.setCurrentMeta(t.meta);
|
|
4892
4970
|
});
|
|
4893
4971
|
}
|
|
4894
|
-
function
|
|
4895
|
-
|
|
4972
|
+
function za(e) {
|
|
4973
|
+
Zs(e), Ks(e), Ga(e), Ka(e);
|
|
4896
4974
|
}
|
|
4897
|
-
|
|
4898
|
-
function
|
|
4899
|
-
return j(
|
|
4975
|
+
za(le);
|
|
4976
|
+
function Ja() {
|
|
4977
|
+
return j(L).token;
|
|
4900
4978
|
}
|
|
4901
|
-
function
|
|
4902
|
-
return j(
|
|
4979
|
+
function Wa() {
|
|
4980
|
+
return j(L).expired;
|
|
4903
4981
|
}
|
|
4904
|
-
function
|
|
4905
|
-
|
|
4982
|
+
function gt(e) {
|
|
4983
|
+
Fn({
|
|
4906
4984
|
message: e,
|
|
4907
4985
|
type: "error",
|
|
4908
4986
|
duration: 5 * 1e3,
|
|
4909
4987
|
grouping: !0
|
|
4910
4988
|
});
|
|
4911
4989
|
}
|
|
4912
|
-
const
|
|
4990
|
+
const Qa = {
|
|
4913
4991
|
onFulfilled: function(e) {
|
|
4914
4992
|
e.headers = e.headers || {};
|
|
4915
|
-
const t =
|
|
4916
|
-
return t && (e.headers["X-Token"] = t),
|
|
4993
|
+
const t = Ja();
|
|
4994
|
+
return t && (e.headers["X-Token"] = t), le.currentRoute.value.meta?.path && (e.headers["X-Path"] = le.currentRoute.value.meta.path), e;
|
|
4917
4995
|
}
|
|
4918
|
-
},
|
|
4996
|
+
}, Xa = {
|
|
4919
4997
|
onFulfilled(e) {
|
|
4920
4998
|
if (!(e.config?.notHoldApiErr !== void 0 && e.config?.notHoldApiErr === !0) && e.data.code !== 0) {
|
|
4921
|
-
const
|
|
4999
|
+
const n = e.data.message || `接口请求错误 ${e.config.method}::${e.config.url?.split("?")[0]}`;
|
|
4922
5000
|
if (e.data.code === 401) {
|
|
4923
|
-
if (
|
|
5001
|
+
if (Wa())
|
|
4924
5002
|
return;
|
|
4925
|
-
j(
|
|
5003
|
+
j(L).SetExpired(), bt.alert("登录信息已过期或未登录, 是否跳转登录", "操作提醒", {
|
|
4926
5004
|
showClose: !1,
|
|
4927
5005
|
confirmButtonText: "重新登录",
|
|
4928
5006
|
showCancelButton: !0,
|
|
4929
5007
|
cancelButtonText: "取消",
|
|
4930
5008
|
callback: (l) => {
|
|
4931
|
-
l === "confirm" && (
|
|
5009
|
+
l === "confirm" && (Dt(), location.href = location.origin + location.pathname + location.hash.replace("#", "#/?redirect="), location.reload()), j(L).SetExpired();
|
|
4932
5010
|
}
|
|
4933
5011
|
});
|
|
4934
5012
|
return;
|
|
4935
5013
|
} else
|
|
4936
|
-
|
|
4937
|
-
return Promise.reject(
|
|
5014
|
+
gt(n);
|
|
5015
|
+
return Promise.reject(n);
|
|
4938
5016
|
}
|
|
4939
|
-
let
|
|
4940
|
-
return
|
|
5017
|
+
let o = e.data?.data?._message_box;
|
|
5018
|
+
return o !== void 0 && (Je(o) && (o = {
|
|
4941
5019
|
message: e.data?.data?._message_box
|
|
4942
|
-
}),
|
|
5020
|
+
}), bt({
|
|
4943
5021
|
title: "提示",
|
|
4944
5022
|
type: "success",
|
|
4945
5023
|
grouping: !0,
|
|
4946
|
-
...
|
|
5024
|
+
...o
|
|
4947
5025
|
})), e.data;
|
|
4948
5026
|
},
|
|
4949
5027
|
onRejected(e) {
|
|
4950
|
-
return
|
|
5028
|
+
return We.isCancel(e) ? Promise.reject("") : (gt(`${e.message} ${e.config.method}::${e.config.url?.split("?")[0]}`), Promise.reject(e));
|
|
4951
5029
|
}
|
|
4952
|
-
},
|
|
5030
|
+
}, Za = [
|
|
4953
5031
|
{
|
|
4954
|
-
request:
|
|
4955
|
-
response:
|
|
5032
|
+
request: Kn,
|
|
5033
|
+
response: zn
|
|
4956
5034
|
},
|
|
4957
5035
|
{
|
|
4958
|
-
request:
|
|
4959
|
-
response:
|
|
5036
|
+
request: Qa,
|
|
5037
|
+
response: Xa
|
|
4960
5038
|
}
|
|
4961
5039
|
];
|
|
4962
|
-
function
|
|
4963
|
-
const t =
|
|
4964
|
-
...
|
|
5040
|
+
function it(e = {}) {
|
|
5041
|
+
const t = Be.axios || {}, o = q(t, e || {}), n = We.create({
|
|
5042
|
+
...o
|
|
4965
5043
|
// adapter: (c) => cacheAdapter(c, defaultAxios)
|
|
4966
5044
|
});
|
|
4967
|
-
return
|
|
4968
|
-
|
|
4969
|
-
}),
|
|
5045
|
+
return Za.forEach((l) => {
|
|
5046
|
+
n.interceptors.request.use(l.request.onFulfilled, l.request.onRejected), n.interceptors.response.use(l.response.onFulfilled, l.response.onRejected);
|
|
5047
|
+
}), n;
|
|
4970
5048
|
}
|
|
4971
|
-
const
|
|
5049
|
+
const no = it(), Ya = {
|
|
4972
5050
|
beforeMount(e, t) {
|
|
4973
|
-
e.clickOutsideEvent = function(
|
|
4974
|
-
e ===
|
|
5051
|
+
e.clickOutsideEvent = function(o) {
|
|
5052
|
+
e === o.target || e.contains(o.target) || t.value(o, e);
|
|
4975
5053
|
}, document.body.addEventListener("click", e.clickOutsideEvent);
|
|
4976
5054
|
},
|
|
4977
5055
|
unmounted(e) {
|
|
4978
5056
|
document.body.removeEventListener("click", e.clickOutsideEvent);
|
|
4979
5057
|
}
|
|
4980
|
-
},
|
|
5058
|
+
}, se = vn(), ei = {
|
|
4981
5059
|
mounted: (e, t) => {
|
|
4982
|
-
e !== null && (t.value, e.oncontextmenu = (
|
|
4983
|
-
|
|
5060
|
+
e !== null && (t.value, e.oncontextmenu = (o) => {
|
|
5061
|
+
o.preventDefault(), o.stopPropagation(), o.cancelBubble = !0, t.value && se.emit("right-click", { event: o, data: t.value });
|
|
4984
5062
|
});
|
|
4985
5063
|
}
|
|
4986
|
-
},
|
|
5064
|
+
}, ti = {
|
|
4987
5065
|
mounted(e) {
|
|
4988
5066
|
}
|
|
4989
5067
|
};
|
|
4990
|
-
function
|
|
4991
|
-
let
|
|
4992
|
-
for (;
|
|
4993
|
-
|
|
4994
|
-
return
|
|
5068
|
+
function kt(e, t) {
|
|
5069
|
+
let o = e[`offset${t}`], n = e.offsetParent;
|
|
5070
|
+
for (; n; )
|
|
5071
|
+
o += n[`offset${t}`], n = n.offsetParent;
|
|
5072
|
+
return o;
|
|
4995
5073
|
}
|
|
4996
|
-
const
|
|
5074
|
+
const oi = {
|
|
4997
5075
|
mounted: (e, t) => {
|
|
4998
5076
|
if (e === null || !t.value.dev)
|
|
4999
5077
|
return;
|
|
5000
|
-
let
|
|
5078
|
+
let o = e;
|
|
5001
5079
|
if (t.value.parent)
|
|
5002
5080
|
for (let d = 0; d < t.value.parent; d++)
|
|
5003
|
-
|
|
5004
|
-
|
|
5005
|
-
const
|
|
5006
|
-
|
|
5007
|
-
|
|
5081
|
+
o.parentElement && (o = o.parentElement);
|
|
5082
|
+
o.classList.add("devtool-hover");
|
|
5083
|
+
const n = document.createElement("i");
|
|
5084
|
+
n.className = "devtool-item-wrapper", o.onmouseover = () => {
|
|
5085
|
+
n.style.height = o.offsetHeight + 30 + "px", n.style.width = o.offsetWidth + 30 + "px", n.style.top = kt(o, "Top") - 15 + "px", n.style.left = kt(o, "Left") - 15 + "px";
|
|
5008
5086
|
};
|
|
5009
5087
|
const l = document.createElement("span");
|
|
5010
5088
|
l.className = "dev-action-edit", l.title = "编辑";
|
|
5011
5089
|
const s = document.createElement("i");
|
|
5012
5090
|
s.className = "iconfont ra-editor1", l.appendChild(s), l.onclick = (d) => {
|
|
5013
|
-
|
|
5014
|
-
},
|
|
5091
|
+
se.emit("dev-action", { event: d, data: { type: "edit", devId: t.value.devId } });
|
|
5092
|
+
}, n.appendChild(l);
|
|
5015
5093
|
const a = document.createElement("span");
|
|
5016
5094
|
a.className = "dev-action-del", a.title = "删除";
|
|
5017
5095
|
const c = document.createElement("i");
|
|
5018
5096
|
c.className = "iconfont ra-cut", a.appendChild(c), a.onclick = (d) => {
|
|
5019
|
-
|
|
5020
|
-
},
|
|
5097
|
+
se.emit("dev-action", { event: d, data: { type: "del", devId: t.value.devId } });
|
|
5098
|
+
}, n.appendChild(a), o.insertBefore(n, o.firstChild);
|
|
5021
5099
|
}
|
|
5022
|
-
},
|
|
5100
|
+
}, ni = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
5023
5101
|
__proto__: null,
|
|
5024
|
-
devtool:
|
|
5025
|
-
outClick:
|
|
5026
|
-
resize:
|
|
5027
|
-
rightClick:
|
|
5102
|
+
devtool: oi,
|
|
5103
|
+
outClick: Ya,
|
|
5104
|
+
resize: ti,
|
|
5105
|
+
rightClick: ei
|
|
5028
5106
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
5029
5107
|
let xe;
|
|
5030
|
-
const
|
|
5031
|
-
function
|
|
5032
|
-
return e ?
|
|
5108
|
+
const lo = [], St = /* @__PURE__ */ new Set(), wt = (e) => typeof e.name == "string" ? e.name : e.path;
|
|
5109
|
+
function _r(e) {
|
|
5110
|
+
return e ? it(q(Be.axios, e)) : xe;
|
|
5033
5111
|
}
|
|
5034
|
-
function
|
|
5035
|
-
const t =
|
|
5036
|
-
l.unshift(
|
|
5037
|
-
|
|
5038
|
-
}), t?.mock &&
|
|
5039
|
-
const s = Y(
|
|
5040
|
-
|
|
5041
|
-
"X-Token":
|
|
5042
|
-
})),
|
|
5043
|
-
|
|
5044
|
-
}, { immediate: !0 }),
|
|
5112
|
+
function vr(e) {
|
|
5113
|
+
const t = q(Be, e), o = To(Dn), n = ui(t), l = t.plugins || [];
|
|
5114
|
+
l.unshift(n), l.forEach((d) => {
|
|
5115
|
+
ci(o, d);
|
|
5116
|
+
}), t?.mock && Hn(), xe = it(t.axios), Rn(o);
|
|
5117
|
+
const s = Y(L), a = U(L), c = j(L);
|
|
5118
|
+
Cn(xe), a.updateSettings(e?.settings || {}), s.setBaseAPI(t?.axios.baseURL), o.config.globalProperties.$http = xe, o.config.globalProperties.$router = le, window.App = o, window.OmsOptions = t, yn(() => ({
|
|
5119
|
+
"X-Token": ve()
|
|
5120
|
+
})), ye(() => c.token, () => {
|
|
5121
|
+
so();
|
|
5122
|
+
}, { immediate: !0 }), le.isReady().then(() => o.mount("#app"));
|
|
5045
5123
|
}
|
|
5046
|
-
function
|
|
5047
|
-
Object.keys(t).forEach((
|
|
5048
|
-
e.component(
|
|
5124
|
+
function li(e, t = {}) {
|
|
5125
|
+
Object.keys(t).forEach((o) => {
|
|
5126
|
+
e.component(o, t[o]);
|
|
5049
5127
|
});
|
|
5050
5128
|
}
|
|
5051
|
-
function
|
|
5052
|
-
const e =
|
|
5053
|
-
const a =
|
|
5054
|
-
return
|
|
5129
|
+
function so() {
|
|
5130
|
+
const e = oo(ve()), t = at(lo, e), o = j(L), n = new Set(o.customRouter.map((s) => wt(s))), l = t.filter((s) => {
|
|
5131
|
+
const a = wt(s);
|
|
5132
|
+
return St.has(a) || n.has(a) ? !1 : (St.add(a), !0);
|
|
5055
5133
|
});
|
|
5056
5134
|
l.forEach((s) => {
|
|
5057
|
-
|
|
5058
|
-
}), l.length &&
|
|
5135
|
+
le.addRoute(s);
|
|
5136
|
+
}), l.length && o.setCustomRoutes(l);
|
|
5059
5137
|
}
|
|
5060
|
-
function
|
|
5061
|
-
|
|
5138
|
+
function si(e = []) {
|
|
5139
|
+
lo.push(...e), so();
|
|
5062
5140
|
}
|
|
5063
|
-
function
|
|
5064
|
-
t.forEach((
|
|
5065
|
-
|
|
5141
|
+
function ai(e, t) {
|
|
5142
|
+
t.forEach((o) => {
|
|
5143
|
+
re(o) && (o = [o]), e.use(...o);
|
|
5066
5144
|
});
|
|
5067
5145
|
}
|
|
5068
|
-
function
|
|
5069
|
-
Object.keys(t).forEach((
|
|
5070
|
-
e.directive(
|
|
5146
|
+
function ii(e, t = {}) {
|
|
5147
|
+
Object.keys(t).forEach((o) => {
|
|
5148
|
+
e.directive(o, t[o]);
|
|
5071
5149
|
});
|
|
5072
5150
|
}
|
|
5073
|
-
function
|
|
5151
|
+
function ri(e = {}) {
|
|
5074
5152
|
const t = ["app", "settings", "user"];
|
|
5075
|
-
Object.keys(e).forEach((
|
|
5076
|
-
if (t.indexOf(
|
|
5077
|
-
console.warn(`storeModule name [${
|
|
5153
|
+
Object.keys(e).forEach((o) => {
|
|
5154
|
+
if (t.indexOf(o) !== -1) {
|
|
5155
|
+
console.warn(`storeModule name [${o}] is use by base, please change it!`);
|
|
5078
5156
|
return;
|
|
5079
5157
|
}
|
|
5080
|
-
console.warn("[store] plugin storeModules are not supported under Pinia. Ignored:",
|
|
5158
|
+
console.warn("[store] plugin storeModules are not supported under Pinia. Ignored:", o);
|
|
5081
5159
|
});
|
|
5082
5160
|
}
|
|
5083
|
-
function
|
|
5084
|
-
|
|
5161
|
+
function ci(e, t) {
|
|
5162
|
+
li(e, t.components || {}), si(t.routes || []), ai(e, t.use || []), ii(e, t.directives || {}), ri(t.storeModules || {}), Ht(t.mockApis || []);
|
|
5085
5163
|
}
|
|
5086
|
-
function
|
|
5164
|
+
function ui(e) {
|
|
5087
5165
|
return {
|
|
5088
|
-
components: { VIcon:
|
|
5089
|
-
directives:
|
|
5166
|
+
components: { VIcon: _n },
|
|
5167
|
+
directives: ni,
|
|
5090
5168
|
use: [
|
|
5091
|
-
|
|
5092
|
-
[
|
|
5169
|
+
le,
|
|
5170
|
+
[qo, { locale: Ot, ...e.settings?.ElementPlus }]
|
|
5093
5171
|
]
|
|
5094
5172
|
};
|
|
5095
5173
|
}
|
|
5096
5174
|
export {
|
|
5097
|
-
|
|
5175
|
+
Qt as BaseSso,
|
|
5098
5176
|
je as Container,
|
|
5099
|
-
|
|
5100
|
-
|
|
5101
|
-
|
|
5102
|
-
|
|
5103
|
-
|
|
5104
|
-
|
|
5177
|
+
br as DingTalk,
|
|
5178
|
+
hr as Github,
|
|
5179
|
+
Jt as Layout,
|
|
5180
|
+
K as MenuType,
|
|
5181
|
+
Fn as Message,
|
|
5182
|
+
bt as MessageBox,
|
|
5105
5183
|
J as PageType,
|
|
5106
|
-
|
|
5107
|
-
|
|
5108
|
-
|
|
5109
|
-
|
|
5110
|
-
|
|
5111
|
-
|
|
5184
|
+
Qs as allSso,
|
|
5185
|
+
Bn as appState,
|
|
5186
|
+
An as builderSchemaState,
|
|
5187
|
+
vr as createAdmin,
|
|
5188
|
+
se as eventBus,
|
|
5189
|
+
Jn as getCmp,
|
|
5112
5190
|
Pe as getHttp,
|
|
5113
5191
|
xe as http,
|
|
5114
|
-
|
|
5115
|
-
|
|
5116
|
-
|
|
5117
|
-
|
|
5118
|
-
|
|
5119
|
-
|
|
5120
|
-
|
|
5121
|
-
|
|
5192
|
+
it as instance,
|
|
5193
|
+
L as pinia,
|
|
5194
|
+
yr as regViews,
|
|
5195
|
+
mr as setCmp,
|
|
5196
|
+
Cn as setHttp,
|
|
5197
|
+
On as settings,
|
|
5198
|
+
Rn as setupStore,
|
|
5199
|
+
ja as transRemoteModules,
|
|
5122
5200
|
Y as useAppStore,
|
|
5123
|
-
|
|
5124
|
-
|
|
5125
|
-
|
|
5201
|
+
fr as useBuilderSchemaStore,
|
|
5202
|
+
_r as useHttp,
|
|
5203
|
+
U as useSettingsStore,
|
|
5126
5204
|
j as useUserStore,
|
|
5127
|
-
|
|
5205
|
+
pt as userState
|
|
5128
5206
|
};
|
|
5129
5207
|
//# sourceMappingURL=index.es.js.map
|