@okiss/oms 0.0.50 → 0.0.52
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 +1091 -1064
- package/dist/index.es.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/types.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var R = (e, t, l) => (
|
|
4
|
-
import { defineComponent as q, onBeforeMount as ze, provide as
|
|
5
|
-
import { addNewStyle as
|
|
1
|
+
var At = Object.defineProperty;
|
|
2
|
+
var Pt = (e, t, l) => t in e ? At(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l;
|
|
3
|
+
var R = (e, t, l) => (Pt(e, typeof t != "symbol" ? t + "" : t, l), l);
|
|
4
|
+
import { defineComponent as q, onBeforeMount as ze, provide as Rt, resolveComponent as v, openBlock as i, createBlock as f, createVNode as p, computed as j, createTextVNode as k, withCtx as c, TransitionGroup as Lt, createElementBlock as h, Fragment as E, renderList as O, toDisplayString as B, normalizeClass as H, renderSlot as le, mergeProps as F, createCommentVNode as $, toRefs as Mt, ref as M, normalizeStyle as jt, createElementVNode as _, Transition as Dt, pushScopeId as Ke, popScopeId as We, resolveDynamicComponent as Ze, normalizeProps as G, guardReactiveProps as Y, unref as S, withDirectives as ie, vModelText as he, onMounted as Qe, onUnmounted as Nt, resolveDirective as Vt, isRef as qt, getCurrentInstance as Ut, h as Ht, toRaw as Ft, createApp as Gt } from "vue";
|
|
5
|
+
import { addNewStyle as Jt, addNewStyleTag as zt, queryParams as Kt, logGroup as Wt, compactObject as Xe, showEleByClassName as Ye, waterMarker as Zt, Cache as be, isExternal as Ve, getQueryParam as et, createIFrame as Qt, strVarReplace as Q, obj2Param as Xt, isObject as X, isString as $e, effectDataTrans as Yt, isArray as tt } from "@okiss/utils";
|
|
6
6
|
import _e from "mockjs";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
7
|
+
import el, { cloneDeep as y, merge as A, get as ne, unset as lt, isObject as tl } from "lodash";
|
|
8
|
+
import nt from "element-plus/lib/locale/lang/zh-cn";
|
|
9
9
|
import Ie from "axios";
|
|
10
10
|
import N from "js-cookie";
|
|
11
|
-
import { createStore as
|
|
12
|
-
import
|
|
11
|
+
import { createStore as ll, useStore as ot, mapGetters as Ce } from "vuex";
|
|
12
|
+
import nl, { ElMessage as ol, ElMessageBox as at, ElCard as al, ElRow as sl, ElCol as il } from "element-plus";
|
|
13
13
|
import "element-plus/dist/index.css";
|
|
14
14
|
import "dayjs/locale/zh-cn";
|
|
15
|
-
import { useRoute as pe, onBeforeRouteLeave as
|
|
16
|
-
import { ElBreadcrumbItem as
|
|
15
|
+
import { useRoute as pe, onBeforeRouteLeave as rl, useRouter as st, createRouter as cl, createWebHashHistory as ul, onBeforeRouteUpdate as pl } from "vue-router";
|
|
16
|
+
import { ElBreadcrumbItem as dl, ElBreadcrumb as ml, ElRow as ae, ElMain as fl, ElAside as hl, ElContainer as bl, ElDivider as it, ElButton as ue, ElOption as Te, ElSelect as Be, ElFormItem as rt, ElForm as ct, ElCol as de, ElDrawer as ut, ElDropdownItem as _l, ElDropdownMenu as yl, ElDropdown as vl, ElMenuItem as gl, ElSubMenu as kl, ElOptionGroup as wl, ElMenu as Sl, ElScrollbar as xl, ElBacktop as El, ElMessage as $l, ElAlert as Oe, ElTree as Il, ElCard as Ae } from "element-plus/es";
|
|
17
17
|
import "element-plus/es/components/base/style/css";
|
|
18
18
|
import "element-plus/es/components/row/style/css";
|
|
19
19
|
import "element-plus/es/components/drawer/style/css";
|
|
@@ -23,7 +23,7 @@ import "element-plus/es/components/dropdown-item/style/css";
|
|
|
23
23
|
import "element-plus/es/components/col/style/css";
|
|
24
24
|
import "element-plus/es/components/breadcrumb/style/css";
|
|
25
25
|
import "element-plus/es/components/breadcrumb-item/style/css";
|
|
26
|
-
import * as
|
|
26
|
+
import * as Cl from "path-to-regexp";
|
|
27
27
|
import "element-plus/es/components/form/style/css";
|
|
28
28
|
import "element-plus/es/components/form-item/style/css";
|
|
29
29
|
import "element-plus/es/components/select/style/css";
|
|
@@ -33,22 +33,22 @@ import "element-plus/es/components/divider/style/css";
|
|
|
33
33
|
import "element-plus/es/components/container/style/css";
|
|
34
34
|
import "element-plus/es/components/aside/style/css";
|
|
35
35
|
import "element-plus/es/components/main/style/css";
|
|
36
|
-
import { VForm as z, VBtn as Pe, JsonView as Re, VTable as oe, VChart as
|
|
36
|
+
import { VForm as z, VBtn as Pe, JsonView as Re, VTable as oe, VChart as Tl, setUploadHeaderHandle as Bl, VIcon as Ol } from "@okiss/vbtf";
|
|
37
37
|
import "normalize.css/normalize.css";
|
|
38
38
|
import "@okiss/vbtf/style.css";
|
|
39
|
-
import
|
|
39
|
+
import Al from "mitt";
|
|
40
40
|
import "element-plus/es/components/scrollbar/style/css";
|
|
41
41
|
import "element-plus/es/components/menu/style/css";
|
|
42
42
|
import "element-plus/es/components/sub-menu/style/css";
|
|
43
43
|
import "element-plus/es/components/menu-item/style/css";
|
|
44
44
|
import "element-plus/es/components/option-group/style/css";
|
|
45
45
|
import "element-plus/es/components/backtop/style/css";
|
|
46
|
-
import { useEventListener as
|
|
46
|
+
import { useEventListener as Pl } from "@vueuse/core";
|
|
47
47
|
import "element-plus/es/components/alert/style/css";
|
|
48
48
|
import "element-plus/es/components/card/style/css";
|
|
49
49
|
import "element-plus/es/components/tree/style/css";
|
|
50
|
-
import
|
|
51
|
-
import { MD5 as
|
|
50
|
+
import Rl from "vue3-markdown-it";
|
|
51
|
+
import { MD5 as Ll } from "crypto-js";
|
|
52
52
|
import "element-plus/es/components/message/style/css";
|
|
53
53
|
import ke from "nprogress";
|
|
54
54
|
import "nprogress/nprogress.css";
|
|
@@ -58,27 +58,27 @@ String.prototype.format || (String.prototype.format = function() {
|
|
|
58
58
|
return typeof e[l] < "u" ? e[l] : t;
|
|
59
59
|
});
|
|
60
60
|
});
|
|
61
|
-
const
|
|
61
|
+
const Ml = /* @__PURE__ */ q({
|
|
62
62
|
__name: "App",
|
|
63
63
|
setup(e) {
|
|
64
|
-
var t, l,
|
|
64
|
+
var t, l, o, n;
|
|
65
65
|
return ze(() => {
|
|
66
66
|
var s;
|
|
67
67
|
const a = document.getElementById("preloader");
|
|
68
|
-
a !== null && (document.body.removeChild(a), (s = document.getElementById("preloader")) == null || s.remove(),
|
|
68
|
+
a !== null && (document.body.removeChild(a), (s = document.getElementById("preloader")) == null || s.remove(), Jt("test-icon", "//at.alicdn.com/t/font_2246548_zclaqxwmzq8.css"), zt(`.iconfont {
|
|
69
69
|
font-size: 19px;
|
|
70
70
|
font-style: normal;
|
|
71
71
|
-webkit-font-smoothing: antialiased;
|
|
72
72
|
font-family: iconfont !important;
|
|
73
73
|
}`));
|
|
74
|
-
}), (l = (t = window == null ? void 0 : window.OmsOptions) == null ? void 0 : t.form) != null && l.vsPath &&
|
|
75
|
-
const
|
|
76
|
-
return i(),
|
|
74
|
+
}), (l = (t = window == null ? void 0 : window.OmsOptions) == null ? void 0 : t.form) != null && l.vsPath && Rt("vsPath", (n = (o = window == null ? void 0 : window.OmsOptions) == null ? void 0 : o.form) == null ? void 0 : n.vsPath), (a, s) => {
|
|
75
|
+
const r = v("router-view");
|
|
76
|
+
return i(), f(r);
|
|
77
77
|
};
|
|
78
78
|
}
|
|
79
79
|
});
|
|
80
80
|
var ee = /* @__PURE__ */ ((e) => (e.GET = "get", e.POST = "post", e.DELETE = "delete", e.FETCH = "fetch", e.OPTION = "option", e.PUT = "put", e))(ee || {});
|
|
81
|
-
const
|
|
81
|
+
const jl = {
|
|
82
82
|
saveApi: "/save",
|
|
83
83
|
afterSubmit: "",
|
|
84
84
|
afterReset: "goback",
|
|
@@ -467,7 +467,7 @@ const Ll = {
|
|
|
467
467
|
type: "success"
|
|
468
468
|
}
|
|
469
469
|
}
|
|
470
|
-
],
|
|
470
|
+
], Dl = {
|
|
471
471
|
exportAble: !0,
|
|
472
472
|
filter: [
|
|
473
473
|
{
|
|
@@ -564,7 +564,7 @@ const Ll = {
|
|
|
564
564
|
}
|
|
565
565
|
],
|
|
566
566
|
normalButton: [
|
|
567
|
-
...
|
|
567
|
+
...el.cloneDeep(qe),
|
|
568
568
|
{
|
|
569
569
|
type: "jump",
|
|
570
570
|
target: "/user/form",
|
|
@@ -576,7 +576,7 @@ const Ll = {
|
|
|
576
576
|
],
|
|
577
577
|
selectedNotice: "当前共勾选: {selectedCount} 条",
|
|
578
578
|
listApi: "/user/list"
|
|
579
|
-
},
|
|
579
|
+
}, Nl = {
|
|
580
580
|
code: 0,
|
|
581
581
|
data: {
|
|
582
582
|
"list|0-100": [
|
|
@@ -597,7 +597,7 @@ const Ll = {
|
|
|
597
597
|
"page|1-5": 2
|
|
598
598
|
}
|
|
599
599
|
}
|
|
600
|
-
},
|
|
600
|
+
}, Vl = {
|
|
601
601
|
afterSubmit: "",
|
|
602
602
|
afterReset: "goback",
|
|
603
603
|
formItems: [
|
|
@@ -634,7 +634,7 @@ const Ll = {
|
|
|
634
634
|
label: "span"
|
|
635
635
|
}
|
|
636
636
|
]
|
|
637
|
-
},
|
|
637
|
+
}, ql = {
|
|
638
638
|
afterSubmit: "",
|
|
639
639
|
afterReset: "",
|
|
640
640
|
formItems: [
|
|
@@ -673,7 +673,7 @@ const Ll = {
|
|
|
673
673
|
label: "span"
|
|
674
674
|
}
|
|
675
675
|
]
|
|
676
|
-
},
|
|
676
|
+
}, Ul = { form: jl, table: Dl, listMock: Nl, layoutForm: Vl, layoutSection: ql }, Hl = [
|
|
677
677
|
{
|
|
678
678
|
method: ee.POST,
|
|
679
679
|
url: "/login",
|
|
@@ -717,15 +717,15 @@ const Ll = {
|
|
|
717
717
|
{
|
|
718
718
|
url: "/user/list",
|
|
719
719
|
method: ee.GET,
|
|
720
|
-
response: (e) =>
|
|
720
|
+
response: (e) => Ul.listMock
|
|
721
721
|
}
|
|
722
|
-
],
|
|
723
|
-
...
|
|
724
|
-
],
|
|
722
|
+
], Fl = [
|
|
723
|
+
...Hl
|
|
724
|
+
], Gl = {
|
|
725
725
|
baseURL: "/api",
|
|
726
726
|
withCredentials: !0,
|
|
727
727
|
cacheEnable: !0
|
|
728
|
-
},
|
|
728
|
+
}, pt = {
|
|
729
729
|
title: "oms",
|
|
730
730
|
fixedHeader: !1,
|
|
731
731
|
sidebarLogo: !0,
|
|
@@ -739,7 +739,7 @@ const Ll = {
|
|
|
739
739
|
ElementPlus: {
|
|
740
740
|
size: "default",
|
|
741
741
|
zIndex: 3e3,
|
|
742
|
-
locale:
|
|
742
|
+
locale: nt
|
|
743
743
|
},
|
|
744
744
|
nav: [],
|
|
745
745
|
whiteRoutes: ["/login"],
|
|
@@ -749,46 +749,47 @@ const Ll = {
|
|
|
749
749
|
uat: "gray",
|
|
750
750
|
pre: "green"
|
|
751
751
|
},
|
|
752
|
-
serviceOffLineNotice: "当前页面功能正在维护, 请稍后再试~~~"
|
|
752
|
+
serviceOffLineNotice: "当前页面功能正在维护, 请稍后再试~~~",
|
|
753
|
+
formMutex: !0
|
|
753
754
|
}, me = {
|
|
754
|
-
axios:
|
|
755
|
-
settings:
|
|
755
|
+
axios: Gl,
|
|
756
|
+
settings: pt,
|
|
756
757
|
plugins: [],
|
|
757
758
|
mock: !1
|
|
758
759
|
}, we = {};
|
|
759
|
-
function
|
|
760
|
+
function dt(e) {
|
|
760
761
|
e.forEach((t) => {
|
|
761
|
-
const l =
|
|
762
|
+
const l = mt(t);
|
|
762
763
|
we[`${t.method}::${l}`] = t;
|
|
763
764
|
});
|
|
764
765
|
}
|
|
765
|
-
|
|
766
|
-
function
|
|
767
|
-
var
|
|
768
|
-
let t = e.url, l = e.baseURL || ((
|
|
769
|
-
return l || (l = ""), typeof t == "string" ? (t = ("/" + l + t).split("/").filter((
|
|
766
|
+
dt(Fl);
|
|
767
|
+
function mt(e) {
|
|
768
|
+
var o;
|
|
769
|
+
let t = e.url, l = e.baseURL || ((o = me.axios) == null ? void 0 : o.baseURL);
|
|
770
|
+
return l || (l = ""), typeof t == "string" ? (t = ("/" + l + t).split("/").filter((n) => n).join("/"), t += "(|\\?.*)$", new RegExp(t)) : t;
|
|
770
771
|
}
|
|
771
|
-
function
|
|
772
|
+
function Jl() {
|
|
772
773
|
Object.keys(we).forEach((e) => {
|
|
773
|
-
const t = we[e], l =
|
|
774
|
-
_e.mock(l, t.method, function(
|
|
775
|
-
const { url:
|
|
776
|
-
return
|
|
774
|
+
const t = we[e], l = mt(t);
|
|
775
|
+
_e.mock(l, t.method, function(o) {
|
|
776
|
+
const { url: n, type: a, body: s } = o, r = Kt(n), u = s ? JSON.parse(s) : {}, d = t.response({ query: r, data: u }), m = _e.mock(d);
|
|
777
|
+
return Wt(n, { type: a, query: r, data: u, response: m }), _e.mock(m);
|
|
777
778
|
});
|
|
778
|
-
})
|
|
779
|
+
});
|
|
779
780
|
}
|
|
780
781
|
const Le = "oms:token";
|
|
781
782
|
function Me() {
|
|
782
783
|
return N.get(Le) || "";
|
|
783
784
|
}
|
|
784
|
-
function
|
|
785
|
-
const t = new Date((/* @__PURE__ */ new Date()).getTime() + (
|
|
785
|
+
function zl(e) {
|
|
786
|
+
const t = new Date((/* @__PURE__ */ new Date()).getTime() + (w.state.settings.tokenExpire || 864e5));
|
|
786
787
|
return N.set(Le, e, { expires: t });
|
|
787
788
|
}
|
|
788
|
-
function
|
|
789
|
+
function ft() {
|
|
789
790
|
return N.remove(Le);
|
|
790
791
|
}
|
|
791
|
-
const
|
|
792
|
+
const Kl = {
|
|
792
793
|
name: "",
|
|
793
794
|
nickname: "",
|
|
794
795
|
avatar: "",
|
|
@@ -801,15 +802,15 @@ const Jl = {
|
|
|
801
802
|
roleIds: [],
|
|
802
803
|
path: "",
|
|
803
804
|
env: ""
|
|
804
|
-
},
|
|
805
|
+
}, Wl = {
|
|
805
806
|
namespaced: !0,
|
|
806
|
-
state:
|
|
807
|
+
state: Kl,
|
|
807
808
|
mutations: {
|
|
808
809
|
updateToken(e, t) {
|
|
809
|
-
e.token = t,
|
|
810
|
+
e.token = t, zl(t);
|
|
810
811
|
},
|
|
811
812
|
removeToken(e) {
|
|
812
|
-
e.token = "",
|
|
813
|
+
e.token = "", ft();
|
|
813
814
|
},
|
|
814
815
|
updateRemoteRouter(e, t) {
|
|
815
816
|
e.remoteRouter = t, e.isLodeRemoteRoutes = !0;
|
|
@@ -842,15 +843,15 @@ const Jl = {
|
|
|
842
843
|
commit: e,
|
|
843
844
|
state: t,
|
|
844
845
|
rootState: l
|
|
845
|
-
},
|
|
846
|
-
return new Promise((
|
|
846
|
+
}, o) {
|
|
847
|
+
return new Promise((n, a) => {
|
|
847
848
|
l.http ? l.http.request({
|
|
848
849
|
url: "/user/login",
|
|
849
850
|
method: "POST",
|
|
850
|
-
data:
|
|
851
|
+
data: o
|
|
851
852
|
}).then((s) => {
|
|
852
|
-
var
|
|
853
|
-
e("updateToken", (
|
|
853
|
+
var r;
|
|
854
|
+
e("updateToken", (r = s.data) == null ? void 0 : r.token), n(!0);
|
|
854
855
|
}).catch((s) => {
|
|
855
856
|
a(s);
|
|
856
857
|
}) : a("http client not init");
|
|
@@ -860,25 +861,25 @@ const Jl = {
|
|
|
860
861
|
e("removeToken"), e("resetUser");
|
|
861
862
|
},
|
|
862
863
|
info({ commit: e, rootState: t }) {
|
|
863
|
-
return new Promise((l,
|
|
864
|
+
return new Promise((l, o) => {
|
|
864
865
|
t.http ? t.http.request({
|
|
865
866
|
url: "/user/info",
|
|
866
867
|
method: "GET"
|
|
867
|
-
}).then((
|
|
868
|
-
var
|
|
869
|
-
const a = ((
|
|
870
|
-
e("updateState", { key: "name", value: (
|
|
871
|
-
const s = ((b =
|
|
872
|
-
e("settings/updateSettings", s, { root: !0 }), !N.get("username") && N.set("username", (g =
|
|
873
|
-
}).catch((
|
|
874
|
-
n
|
|
875
|
-
}) :
|
|
868
|
+
}).then((n) => {
|
|
869
|
+
var r, u, d, m, b, g;
|
|
870
|
+
const a = ((r = n.data) == null ? void 0 : r.role_ids) || [];
|
|
871
|
+
e("updateState", { key: "name", value: (u = n.data) == null ? void 0 : u.name }), e("updateState", { key: "nickname", value: (d = n.data) == null ? void 0 : d.nickname }), e("updateState", { key: "roleIds", value: a }), e("updateState", { key: "env", value: (m = n.data) == null ? void 0 : m.env });
|
|
872
|
+
const s = ((b = n.data) == null ? void 0 : b.website) || {};
|
|
873
|
+
e("settings/updateSettings", s, { root: !0 }), !N.get("username") && N.set("username", (g = n.data) == null ? void 0 : g.name), l(!0);
|
|
874
|
+
}).catch((n) => {
|
|
875
|
+
o(n);
|
|
876
|
+
}) : o("http client not init");
|
|
876
877
|
});
|
|
877
878
|
},
|
|
878
879
|
loadRemoteRoutes({ state: e, rootState: t }) {
|
|
879
|
-
return new Promise((l,
|
|
880
|
-
var
|
|
881
|
-
(
|
|
880
|
+
return new Promise((l, o) => {
|
|
881
|
+
var n;
|
|
882
|
+
(n = t.http) == null || n.request({
|
|
882
883
|
url: "/user/routes",
|
|
883
884
|
method: "get"
|
|
884
885
|
}).then((a) => {
|
|
@@ -886,16 +887,16 @@ const Jl = {
|
|
|
886
887
|
const s = a.data || [];
|
|
887
888
|
l(s);
|
|
888
889
|
} else
|
|
889
|
-
|
|
890
|
+
o("error");
|
|
890
891
|
}).catch((a) => {
|
|
891
|
-
|
|
892
|
+
o(a);
|
|
892
893
|
});
|
|
893
894
|
});
|
|
894
895
|
}
|
|
895
896
|
}
|
|
896
|
-
},
|
|
897
|
+
}, Zl = y(pt), Ql = {
|
|
897
898
|
namespaced: !0,
|
|
898
|
-
state:
|
|
899
|
+
state: Zl,
|
|
899
900
|
mutations: {
|
|
900
901
|
updateSettings(e, t) {
|
|
901
902
|
e = A(e, t);
|
|
@@ -906,7 +907,7 @@ const Jl = {
|
|
|
906
907
|
e("updateSettings", l);
|
|
907
908
|
}
|
|
908
909
|
}
|
|
909
|
-
},
|
|
910
|
+
}, Xl = {
|
|
910
911
|
sidebar: {
|
|
911
912
|
opened: N.get("sidebarStatus") ? !!N.get("sidebarStatus") : !0,
|
|
912
913
|
withoutAnimation: !1
|
|
@@ -916,9 +917,9 @@ const Jl = {
|
|
|
916
917
|
currentRouteMeta: {},
|
|
917
918
|
builderSchema: {},
|
|
918
919
|
baseURL: ""
|
|
919
|
-
},
|
|
920
|
+
}, Yl = {
|
|
920
921
|
namespaced: !0,
|
|
921
|
-
state:
|
|
922
|
+
state: Xl,
|
|
922
923
|
mutations: {
|
|
923
924
|
TOGGLE_SIDEBAR: (e) => {
|
|
924
925
|
e.sidebar.opened = !e.sidebar.opened, e.sidebar.withoutAnimation = !1, e.sidebar.opened ? N.set("sidebarStatus", "1") : N.set("sidebarStatus", "0");
|
|
@@ -965,12 +966,12 @@ const Jl = {
|
|
|
965
966
|
e("SET_BASE_API", t);
|
|
966
967
|
}
|
|
967
968
|
}
|
|
968
|
-
},
|
|
969
|
+
}, en = {
|
|
969
970
|
currentCellItem: {}
|
|
970
971
|
// form/sub-form 当前单元格编辑数据
|
|
971
|
-
},
|
|
972
|
+
}, tn = {
|
|
972
973
|
namespaced: !0,
|
|
973
|
-
state:
|
|
974
|
+
state: en,
|
|
974
975
|
mutations: {
|
|
975
976
|
SET_CURRENT_CELLITEM: (e, t) => {
|
|
976
977
|
e.currentCellItem = t;
|
|
@@ -981,7 +982,7 @@ const Jl = {
|
|
|
981
982
|
e("SET_CURRENT_CELLITEM", t);
|
|
982
983
|
}
|
|
983
984
|
}
|
|
984
|
-
},
|
|
985
|
+
}, w = ll({
|
|
985
986
|
state: void 0,
|
|
986
987
|
getters: {
|
|
987
988
|
http: (e) => e.http,
|
|
@@ -1008,12 +1009,12 @@ const Jl = {
|
|
|
1008
1009
|
}
|
|
1009
1010
|
},
|
|
1010
1011
|
modules: {
|
|
1011
|
-
user:
|
|
1012
|
-
settings:
|
|
1013
|
-
app:
|
|
1014
|
-
builderSchema:
|
|
1012
|
+
user: Wl,
|
|
1013
|
+
settings: Ql,
|
|
1014
|
+
app: Yl,
|
|
1015
|
+
builderSchema: tn
|
|
1015
1016
|
}
|
|
1016
|
-
}),
|
|
1017
|
+
}), ln = ol, Ue = at, nn = Ie.CancelToken, re = {
|
|
1017
1018
|
taskList: {},
|
|
1018
1019
|
cacheList: /* @__PURE__ */ new Map(),
|
|
1019
1020
|
uniqueId(e) {
|
|
@@ -1038,61 +1039,61 @@ const Jl = {
|
|
|
1038
1039
|
this.delCache(e);
|
|
1039
1040
|
return;
|
|
1040
1041
|
}
|
|
1041
|
-
return
|
|
1042
|
+
return l.response, l.response;
|
|
1042
1043
|
}
|
|
1043
1044
|
},
|
|
1044
1045
|
addCache(e, t) {
|
|
1045
|
-
const l = this.uniqueId(e),
|
|
1046
|
-
|
|
1046
|
+
const l = this.uniqueId(e), o = e.cacheTime || 0;
|
|
1047
|
+
o && this.cacheList.set(l, { response: t, expirationTime: (/* @__PURE__ */ new Date()).getTime() + o });
|
|
1047
1048
|
},
|
|
1048
1049
|
delCache(e) {
|
|
1049
1050
|
const t = this.uniqueId(e);
|
|
1050
1051
|
return this.cacheList.delete(t);
|
|
1051
1052
|
}
|
|
1052
|
-
},
|
|
1053
|
+
}, on = {
|
|
1053
1054
|
onFulfilled: function(e) {
|
|
1054
|
-
return e.cacheEnable === !1 || (re.pending(e) && re.delTask(e), e.cancelToken = new
|
|
1055
|
+
return e.cacheEnable === !1 || (re.pending(e) && re.delTask(e), e.cancelToken = new nn((t) => {
|
|
1055
1056
|
re.addTask(e, t);
|
|
1056
1057
|
})), e;
|
|
1057
1058
|
},
|
|
1058
1059
|
onRejected(e) {
|
|
1059
1060
|
return Promise.reject(e);
|
|
1060
1061
|
}
|
|
1061
|
-
},
|
|
1062
|
+
}, an = {
|
|
1062
1063
|
onFulfilled: function(e) {
|
|
1063
1064
|
return e.config.cacheEnable === !1 || e.config.method === "get" && Object.keys(e.data).length > 0 && re.addCache(e.config, e.data), e;
|
|
1064
1065
|
},
|
|
1065
1066
|
onRejected(e) {
|
|
1066
1067
|
return Promise.reject(e);
|
|
1067
1068
|
}
|
|
1068
|
-
},
|
|
1069
|
-
function
|
|
1070
|
-
|
|
1069
|
+
}, ht = {};
|
|
1070
|
+
function xi(e, t) {
|
|
1071
|
+
ht[e] = t;
|
|
1071
1072
|
}
|
|
1072
|
-
function
|
|
1073
|
-
return
|
|
1073
|
+
function sn(e) {
|
|
1074
|
+
return ht[e];
|
|
1074
1075
|
}
|
|
1075
|
-
const
|
|
1076
|
+
const rn = /* @__PURE__ */ q({
|
|
1076
1077
|
name: "Dashboard",
|
|
1077
1078
|
setup() {
|
|
1078
|
-
const e =
|
|
1079
|
+
const e = ot(), t = sn("dashboard");
|
|
1079
1080
|
if (t)
|
|
1080
|
-
return () =>
|
|
1081
|
+
return () => p("span", null, [p(t, null, null)]);
|
|
1081
1082
|
const l = j(() => e.getters.name);
|
|
1082
|
-
return () =>
|
|
1083
|
+
return () => p("div", {
|
|
1083
1084
|
class: "dashboard-container"
|
|
1084
|
-
}, [
|
|
1085
|
+
}, [p("div", {
|
|
1085
1086
|
class: "dashboard-text"
|
|
1086
1087
|
}, [k("Hi "), l.value, k(" 😄")])]);
|
|
1087
1088
|
}
|
|
1088
1089
|
});
|
|
1089
1090
|
const I = (e, t) => {
|
|
1090
1091
|
const l = e.__vccOpts || e;
|
|
1091
|
-
for (const [
|
|
1092
|
-
l[
|
|
1092
|
+
for (const [o, n] of t)
|
|
1093
|
+
l[o] = n;
|
|
1093
1094
|
return l;
|
|
1094
|
-
},
|
|
1095
|
-
const
|
|
1095
|
+
}, cn = /* @__PURE__ */ I(rn, [["__scopeId", "data-v-3122b6c7"]]);
|
|
1096
|
+
const un = {
|
|
1096
1097
|
data() {
|
|
1097
1098
|
return {
|
|
1098
1099
|
levelList: null
|
|
@@ -1124,7 +1125,7 @@ const rn = {
|
|
|
1124
1125
|
},
|
|
1125
1126
|
pathCompile(e) {
|
|
1126
1127
|
const { params: t } = this.$route;
|
|
1127
|
-
return
|
|
1128
|
+
return Cl.compile(e)(t);
|
|
1128
1129
|
},
|
|
1129
1130
|
handleLink(e) {
|
|
1130
1131
|
const { redirect: t, path: l } = e;
|
|
@@ -1135,27 +1136,27 @@ const rn = {
|
|
|
1135
1136
|
this.$router.push(this.pathCompile(l));
|
|
1136
1137
|
}
|
|
1137
1138
|
}
|
|
1138
|
-
},
|
|
1139
|
+
}, pn = {
|
|
1139
1140
|
key: 0,
|
|
1140
1141
|
class: "no-redirect"
|
|
1141
|
-
},
|
|
1142
|
-
function
|
|
1143
|
-
const s =
|
|
1144
|
-
return i(),
|
|
1142
|
+
}, dn = ["onClick"];
|
|
1143
|
+
function mn(e, t, l, o, n, a) {
|
|
1144
|
+
const s = dl, r = ml;
|
|
1145
|
+
return i(), f(r, {
|
|
1145
1146
|
class: "app-breadcrumb",
|
|
1146
1147
|
separator: "/"
|
|
1147
1148
|
}, {
|
|
1148
|
-
default:
|
|
1149
|
-
|
|
1150
|
-
default:
|
|
1151
|
-
(i(!0), h(E, null,
|
|
1152
|
-
key:
|
|
1149
|
+
default: c(() => [
|
|
1150
|
+
p(Lt, { name: "breadcrumb" }, {
|
|
1151
|
+
default: c(() => [
|
|
1152
|
+
(i(!0), h(E, null, O(n.levelList, (u, d) => (i(), f(s, {
|
|
1153
|
+
key: u.path
|
|
1153
1154
|
}, {
|
|
1154
|
-
default:
|
|
1155
|
-
|
|
1155
|
+
default: c(() => [
|
|
1156
|
+
u.path.indexOf("/DIR_") === 0 && u.redirect === void 0 || d === n.levelList.length - 1 ? (i(), h("span", pn, B(u.meta.title), 1)) : (i(), h("a", {
|
|
1156
1157
|
key: 1,
|
|
1157
|
-
onClick: (
|
|
1158
|
-
},
|
|
1158
|
+
onClick: (m) => a.handleLink(u)
|
|
1159
|
+
}, B(u.meta.title), 9, dn))
|
|
1159
1160
|
]),
|
|
1160
1161
|
_: 2
|
|
1161
1162
|
}, 1024))), 128))
|
|
@@ -1166,7 +1167,7 @@ function pn(e, t, l, n, o, a) {
|
|
|
1166
1167
|
_: 1
|
|
1167
1168
|
});
|
|
1168
1169
|
}
|
|
1169
|
-
const
|
|
1170
|
+
const fn = /* @__PURE__ */ I(un, [["render", mn], ["__scopeId", "data-v-fa74804e"]]), hn = {
|
|
1170
1171
|
name: "Hamburger",
|
|
1171
1172
|
props: {
|
|
1172
1173
|
isActive: {
|
|
@@ -1181,45 +1182,45 @@ const dn = /* @__PURE__ */ I(rn, [["render", pn], ["__scopeId", "data-v-fa74804e
|
|
|
1181
1182
|
}
|
|
1182
1183
|
}
|
|
1183
1184
|
};
|
|
1184
|
-
function
|
|
1185
|
+
function bn(e, t, l, o, n, a) {
|
|
1185
1186
|
const s = v("v-icon");
|
|
1186
1187
|
return i(), h("div", {
|
|
1187
1188
|
style: { padding: "0 15px" },
|
|
1188
|
-
onClick: t[0] || (t[0] = (...
|
|
1189
|
+
onClick: t[0] || (t[0] = (...r) => a.toggleClick && a.toggleClick(...r))
|
|
1189
1190
|
}, [
|
|
1190
|
-
|
|
1191
|
+
p(s, {
|
|
1191
1192
|
class: H({ "is-active": l.isActive }),
|
|
1192
1193
|
name: "ra-leftalignment"
|
|
1193
1194
|
}, null, 8, ["class"])
|
|
1194
1195
|
]);
|
|
1195
1196
|
}
|
|
1196
|
-
const
|
|
1197
|
-
const
|
|
1198
|
-
function
|
|
1199
|
-
const l = ae,
|
|
1200
|
-
return i(),
|
|
1201
|
-
default:
|
|
1202
|
-
|
|
1203
|
-
default:
|
|
1197
|
+
const _n = /* @__PURE__ */ I(hn, [["render", bn]]);
|
|
1198
|
+
const yn = {};
|
|
1199
|
+
function vn(e, t) {
|
|
1200
|
+
const l = ae, o = fl, n = hl, a = bl;
|
|
1201
|
+
return i(), f(a, { style: { width: "100%", height: "100%" } }, {
|
|
1202
|
+
default: c(() => [
|
|
1203
|
+
p(l, { class: "aside" }, {
|
|
1204
|
+
default: c(() => [
|
|
1204
1205
|
le(e.$slots, "left-aside", {}, void 0, !0)
|
|
1205
1206
|
]),
|
|
1206
1207
|
_: 3
|
|
1207
1208
|
}),
|
|
1208
|
-
|
|
1209
|
+
p(o, {
|
|
1209
1210
|
class: "main",
|
|
1210
1211
|
style: { margin: "0 10px" }
|
|
1211
1212
|
}, {
|
|
1212
|
-
default:
|
|
1213
|
+
default: c(() => [
|
|
1213
1214
|
le(e.$slots, "main", {}, void 0, !0)
|
|
1214
1215
|
]),
|
|
1215
1216
|
_: 3
|
|
1216
1217
|
}),
|
|
1217
|
-
|
|
1218
|
+
p(n, {
|
|
1218
1219
|
class: "aside",
|
|
1219
1220
|
width: "350px",
|
|
1220
1221
|
style: { padding: "20px" }
|
|
1221
1222
|
}, {
|
|
1222
|
-
default:
|
|
1223
|
+
default: c(() => [
|
|
1223
1224
|
le(e.$slots, "right-aside", {}, void 0, !0)
|
|
1224
1225
|
]),
|
|
1225
1226
|
_: 3
|
|
@@ -1228,7 +1229,7 @@ function _n(e, t) {
|
|
|
1228
1229
|
_: 3
|
|
1229
1230
|
});
|
|
1230
1231
|
}
|
|
1231
|
-
const
|
|
1232
|
+
const bt = /* @__PURE__ */ I(yn, [["render", vn], ["__scopeId", "data-v-7c3d697b"]]), gn = {
|
|
1232
1233
|
type: "input",
|
|
1233
1234
|
name: "文本框",
|
|
1234
1235
|
default: {
|
|
@@ -1296,7 +1297,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1296
1297
|
}
|
|
1297
1298
|
}
|
|
1298
1299
|
]
|
|
1299
|
-
},
|
|
1300
|
+
}, kn = {
|
|
1300
1301
|
type: "number",
|
|
1301
1302
|
name: "数字",
|
|
1302
1303
|
default: {
|
|
@@ -1338,7 +1339,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1338
1339
|
}
|
|
1339
1340
|
}
|
|
1340
1341
|
]
|
|
1341
|
-
},
|
|
1342
|
+
}, wn = {
|
|
1342
1343
|
type: "number-range",
|
|
1343
1344
|
name: "数字区间",
|
|
1344
1345
|
default: {
|
|
@@ -1379,7 +1380,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1379
1380
|
}
|
|
1380
1381
|
}
|
|
1381
1382
|
]
|
|
1382
|
-
},
|
|
1383
|
+
}, Sn = {
|
|
1383
1384
|
type: "select",
|
|
1384
1385
|
name: "下拉框",
|
|
1385
1386
|
default: {
|
|
@@ -1485,7 +1486,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1485
1486
|
const t = y(e);
|
|
1486
1487
|
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;
|
|
1487
1488
|
}
|
|
1488
|
-
},
|
|
1489
|
+
}, xn = {
|
|
1489
1490
|
type: "radio",
|
|
1490
1491
|
name: "单选框",
|
|
1491
1492
|
default: {
|
|
@@ -1531,7 +1532,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1531
1532
|
label: "默认值"
|
|
1532
1533
|
}
|
|
1533
1534
|
]
|
|
1534
|
-
},
|
|
1535
|
+
}, En = {
|
|
1535
1536
|
type: "switch",
|
|
1536
1537
|
name: "开关",
|
|
1537
1538
|
default: {
|
|
@@ -1587,7 +1588,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1587
1588
|
}
|
|
1588
1589
|
}
|
|
1589
1590
|
]
|
|
1590
|
-
},
|
|
1591
|
+
}, $n = {
|
|
1591
1592
|
type: "code",
|
|
1592
1593
|
name: "Code",
|
|
1593
1594
|
default: {
|
|
@@ -1607,7 +1608,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1607
1608
|
label: "字段key"
|
|
1608
1609
|
}
|
|
1609
1610
|
]
|
|
1610
|
-
},
|
|
1611
|
+
}, In = {
|
|
1611
1612
|
type: "json",
|
|
1612
1613
|
name: "json",
|
|
1613
1614
|
default: {
|
|
@@ -1627,7 +1628,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1627
1628
|
label: "字段key"
|
|
1628
1629
|
}
|
|
1629
1630
|
]
|
|
1630
|
-
},
|
|
1631
|
+
}, Cn = {
|
|
1631
1632
|
type: "upload",
|
|
1632
1633
|
name: "上传",
|
|
1633
1634
|
default: {
|
|
@@ -1647,7 +1648,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1647
1648
|
label: "字段key"
|
|
1648
1649
|
}
|
|
1649
1650
|
]
|
|
1650
|
-
},
|
|
1651
|
+
}, Tn = {
|
|
1651
1652
|
type: "template",
|
|
1652
1653
|
name: "自定义组件",
|
|
1653
1654
|
default: {
|
|
@@ -1667,7 +1668,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1667
1668
|
label: "字段key"
|
|
1668
1669
|
}
|
|
1669
1670
|
]
|
|
1670
|
-
},
|
|
1671
|
+
}, Bn = {
|
|
1671
1672
|
type: "icon-select",
|
|
1672
1673
|
name: "图标选择器",
|
|
1673
1674
|
default: {
|
|
@@ -1687,7 +1688,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1687
1688
|
label: "字段key"
|
|
1688
1689
|
}
|
|
1689
1690
|
]
|
|
1690
|
-
},
|
|
1691
|
+
}, On = {
|
|
1691
1692
|
type: "sub-form",
|
|
1692
1693
|
name: "子表单",
|
|
1693
1694
|
default: {
|
|
@@ -1755,7 +1756,7 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1755
1756
|
}
|
|
1756
1757
|
}
|
|
1757
1758
|
]
|
|
1758
|
-
},
|
|
1759
|
+
}, An = {
|
|
1759
1760
|
type: "checkbox",
|
|
1760
1761
|
name: "复选框",
|
|
1761
1762
|
default: {
|
|
@@ -1801,24 +1802,24 @@ const mt = /* @__PURE__ */ I(bn, [["render", _n], ["__scopeId", "data-v-7c3d697b
|
|
|
1801
1802
|
}
|
|
1802
1803
|
}
|
|
1803
1804
|
]
|
|
1804
|
-
},
|
|
1805
|
+
}, _t = {};
|
|
1805
1806
|
function P(e) {
|
|
1806
|
-
|
|
1807
|
+
_t[e.type] = e;
|
|
1807
1808
|
}
|
|
1808
|
-
P(yn);
|
|
1809
|
-
P(kn);
|
|
1810
|
-
P(vn);
|
|
1811
1809
|
P(gn);
|
|
1812
1810
|
P(Sn);
|
|
1813
|
-
P(
|
|
1811
|
+
P(kn);
|
|
1814
1812
|
P(wn);
|
|
1813
|
+
P(En);
|
|
1815
1814
|
P(On);
|
|
1816
1815
|
P(xn);
|
|
1817
|
-
P(
|
|
1816
|
+
P(An);
|
|
1818
1817
|
P($n);
|
|
1819
|
-
P(Cn);
|
|
1820
1818
|
P(In);
|
|
1821
|
-
|
|
1819
|
+
P(Cn);
|
|
1820
|
+
P(Bn);
|
|
1821
|
+
P(Tn);
|
|
1822
|
+
const Se = _t, Pn = {
|
|
1822
1823
|
options: {
|
|
1823
1824
|
labelPosition: "top",
|
|
1824
1825
|
submitButton: !1,
|
|
@@ -1925,7 +1926,7 @@ const ye = {
|
|
|
1925
1926
|
Object.keys(Se).forEach((e) => {
|
|
1926
1927
|
je.push({ value: e, label: Se[e].name });
|
|
1927
1928
|
});
|
|
1928
|
-
const
|
|
1929
|
+
const Rn = {
|
|
1929
1930
|
options: {
|
|
1930
1931
|
submitButton: !1,
|
|
1931
1932
|
cancelButton: !1
|
|
@@ -1957,8 +1958,8 @@ const An = {
|
|
|
1957
1958
|
}
|
|
1958
1959
|
}
|
|
1959
1960
|
]
|
|
1960
|
-
},
|
|
1961
|
-
components: { DevLayout:
|
|
1961
|
+
}, Ln = {
|
|
1962
|
+
components: { DevLayout: bt, VForm: z, VButton: Pe, JsonView: Re },
|
|
1962
1963
|
props: {
|
|
1963
1964
|
schema: {
|
|
1964
1965
|
type: Object,
|
|
@@ -1969,8 +1970,8 @@ const An = {
|
|
|
1969
1970
|
data() {
|
|
1970
1971
|
return {
|
|
1971
1972
|
sqlOptions: {},
|
|
1972
|
-
sqlSchema:
|
|
1973
|
-
baseSchema:
|
|
1973
|
+
sqlSchema: Rn,
|
|
1974
|
+
baseSchema: Pn,
|
|
1974
1975
|
activeTab: "base",
|
|
1975
1976
|
builderSchema: Object.assign(
|
|
1976
1977
|
{},
|
|
@@ -2021,13 +2022,13 @@ const An = {
|
|
|
2021
2022
|
const t = ne(this.builderSchema, this.activeIndex);
|
|
2022
2023
|
if (!t)
|
|
2023
2024
|
return;
|
|
2024
|
-
const l = t ? t.type : "",
|
|
2025
|
-
if (
|
|
2026
|
-
if (
|
|
2027
|
-
const [a, s,
|
|
2028
|
-
this.builderSchema[s][
|
|
2025
|
+
const l = t ? t.type : "", o = this.ctrlMap[l], n = o.trans ? o.trans(e) : e;
|
|
2026
|
+
if (n && Object.keys(n).length > 0) {
|
|
2027
|
+
if (n.type = l, this.activeIndex.indexOf("[") > -1) {
|
|
2028
|
+
const [a, s, r] = this.activeIndex.match(/(\w+)\[(\d+)\]/);
|
|
2029
|
+
this.builderSchema[s][r] = { ...n };
|
|
2029
2030
|
} else
|
|
2030
|
-
this.builderSchema[this.activeIndex] =
|
|
2031
|
+
this.builderSchema[this.activeIndex] = n;
|
|
2031
2032
|
this.key++;
|
|
2032
2033
|
}
|
|
2033
2034
|
}
|
|
@@ -2066,19 +2067,19 @@ const An = {
|
|
|
2066
2067
|
}), this.ctrlKey++, this.key++, this.activeIndex = `${t}[${this.builderSchema[t].length - 1}]`, this.activeTab = "ctrl";
|
|
2067
2068
|
},
|
|
2068
2069
|
removeOne() {
|
|
2069
|
-
|
|
2070
|
+
lt(this.builderSchema, this.activeIndex), this.builderSchema = y(Xe(this.builderSchema)), this.activeIndex = "", this.ctrlOptions = {}, this.ctrlSchema = {}, this.key++, this.ctrlKey++;
|
|
2070
2071
|
},
|
|
2071
2072
|
clicklabel() {
|
|
2072
2073
|
const e = this.activeIndex;
|
|
2073
2074
|
if (e.match(this.activeIndexReg)) {
|
|
2074
|
-
const l = y(ne(this.builderSchema, e)),
|
|
2075
|
-
if (!
|
|
2075
|
+
const l = y(ne(this.builderSchema, e)), o = l.type, n = this.ctrlMap[o];
|
|
2076
|
+
if (!n) {
|
|
2076
2077
|
this.$message({ type: "warning", message: "尚未支持该组件的UI编辑" });
|
|
2077
2078
|
return;
|
|
2078
2079
|
}
|
|
2079
|
-
this.currentCtrlType =
|
|
2080
|
+
this.currentCtrlType = o, this.ctrlOptions = l, this.ctrlSchema = y({
|
|
2080
2081
|
options: y(ye),
|
|
2081
|
-
formItems: y(
|
|
2082
|
+
formItems: y(n.builder)
|
|
2082
2083
|
}), this.ctrlKey++;
|
|
2083
2084
|
}
|
|
2084
2085
|
},
|
|
@@ -2093,47 +2094,47 @@ const An = {
|
|
|
2093
2094
|
}
|
|
2094
2095
|
}
|
|
2095
2096
|
};
|
|
2096
|
-
function
|
|
2097
|
-
const s = v("v-form"),
|
|
2098
|
-
return i(),
|
|
2099
|
-
main:
|
|
2100
|
-
|
|
2097
|
+
function Mn(e, t, l, o, n, a) {
|
|
2098
|
+
const s = v("v-form"), r = it, u = ue, d = v("JsonView"), m = v("VButton"), b = Te, g = Be, x = rt, J = ct, U = v("dev-layout");
|
|
2099
|
+
return i(), f(U, null, {
|
|
2100
|
+
main: c(() => [
|
|
2101
|
+
n.builderSchema.formItems ? (i(), f(s, F({
|
|
2101
2102
|
ref: "form",
|
|
2102
|
-
key:
|
|
2103
|
+
key: n.key,
|
|
2103
2104
|
dev: !0
|
|
2104
|
-
},
|
|
2105
|
-
|
|
2106
|
-
u
|
|
2105
|
+
}, n.builderSchema), null, 16)) : $("", !0),
|
|
2106
|
+
p(r),
|
|
2107
|
+
p(u, {
|
|
2107
2108
|
type: "primary",
|
|
2108
2109
|
onClick: a.saveSchema
|
|
2109
2110
|
}, {
|
|
2110
|
-
default:
|
|
2111
|
+
default: c(() => [
|
|
2111
2112
|
k("保存页面配置")
|
|
2112
2113
|
]),
|
|
2113
2114
|
_: 1
|
|
2114
2115
|
}, 8, ["onClick"]),
|
|
2115
2116
|
k(" "),
|
|
2116
|
-
|
|
2117
|
+
p(m, {
|
|
2117
2118
|
text: "PageSchema",
|
|
2118
2119
|
type: "modal"
|
|
2119
2120
|
}, {
|
|
2120
|
-
default:
|
|
2121
|
-
|
|
2121
|
+
default: c(() => [
|
|
2122
|
+
p(d, { data: a.getSaveSchema }, null, 8, ["data"])
|
|
2122
2123
|
]),
|
|
2123
2124
|
_: 1
|
|
2124
2125
|
})
|
|
2125
2126
|
]),
|
|
2126
|
-
"right-aside":
|
|
2127
|
-
|
|
2128
|
-
default:
|
|
2129
|
-
|
|
2130
|
-
default:
|
|
2131
|
-
|
|
2132
|
-
modelValue:
|
|
2133
|
-
"onUpdate:modelValue": t[0] || (t[0] = (T) =>
|
|
2127
|
+
"right-aside": c(() => [
|
|
2128
|
+
n.activeIndex ? (i(), f(J, { key: 0 }, {
|
|
2129
|
+
default: c(() => [
|
|
2130
|
+
p(x, { label: "控件类型" }, {
|
|
2131
|
+
default: c(() => [
|
|
2132
|
+
p(g, {
|
|
2133
|
+
modelValue: n.currentCtrlType,
|
|
2134
|
+
"onUpdate:modelValue": t[0] || (t[0] = (T) => n.currentCtrlType = T)
|
|
2134
2135
|
}, {
|
|
2135
|
-
default:
|
|
2136
|
-
(i(!0), h(E, null,
|
|
2136
|
+
default: c(() => [
|
|
2137
|
+
(i(!0), h(E, null, O(n.types, (T, Z) => (i(), f(b, {
|
|
2137
2138
|
key: Z,
|
|
2138
2139
|
label: T.label,
|
|
2139
2140
|
value: T.value
|
|
@@ -2147,16 +2148,16 @@ function Rn(e, t, l, n, o, a) {
|
|
|
2147
2148
|
]),
|
|
2148
2149
|
_: 1
|
|
2149
2150
|
})) : $("", !0),
|
|
2150
|
-
(i(),
|
|
2151
|
-
key:
|
|
2152
|
-
modelValue:
|
|
2153
|
-
"onUpdate:modelValue": t[1] || (t[1] = (T) =>
|
|
2154
|
-
},
|
|
2151
|
+
(i(), f(s, F({
|
|
2152
|
+
key: n.ctrlKey,
|
|
2153
|
+
modelValue: n.ctrlOptions,
|
|
2154
|
+
"onUpdate:modelValue": t[1] || (t[1] = (T) => n.ctrlOptions = T)
|
|
2155
|
+
}, n.ctrlSchema), null, 16, ["modelValue"]))
|
|
2155
2156
|
]),
|
|
2156
2157
|
_: 1
|
|
2157
2158
|
});
|
|
2158
2159
|
}
|
|
2159
|
-
const
|
|
2160
|
+
const jn = /* @__PURE__ */ I(Ln, [["render", Mn], ["__scopeId", "data-v-875f0171"]]), Dn = {
|
|
2160
2161
|
type: "input",
|
|
2161
2162
|
name: "文本框",
|
|
2162
2163
|
default: {
|
|
@@ -2204,7 +2205,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2204
2205
|
}
|
|
2205
2206
|
}
|
|
2206
2207
|
]
|
|
2207
|
-
},
|
|
2208
|
+
}, Nn = {
|
|
2208
2209
|
type: "select",
|
|
2209
2210
|
name: "下拉框",
|
|
2210
2211
|
default: {
|
|
@@ -2305,7 +2306,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2305
2306
|
const t = y(e);
|
|
2306
2307
|
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;
|
|
2307
2308
|
}
|
|
2308
|
-
},
|
|
2309
|
+
}, Vn = {
|
|
2309
2310
|
type: "date",
|
|
2310
2311
|
name: "日期",
|
|
2311
2312
|
default: {
|
|
@@ -2354,7 +2355,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2354
2355
|
labelPosition: "top",
|
|
2355
2356
|
submitButton: !1,
|
|
2356
2357
|
cancelButton: !1
|
|
2357
|
-
},
|
|
2358
|
+
}, qn = {
|
|
2358
2359
|
type: "span",
|
|
2359
2360
|
name: "文本",
|
|
2360
2361
|
default: {
|
|
@@ -2384,7 +2385,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2384
2385
|
label: "排序"
|
|
2385
2386
|
}
|
|
2386
2387
|
]
|
|
2387
|
-
},
|
|
2388
|
+
}, Un = {
|
|
2388
2389
|
type: "enum",
|
|
2389
2390
|
name: "标签",
|
|
2390
2391
|
default: {
|
|
@@ -2435,7 +2436,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2435
2436
|
trans(e) {
|
|
2436
2437
|
return e.options = e.options || [], e.label || (e.label = "表头"), e;
|
|
2437
2438
|
}
|
|
2438
|
-
},
|
|
2439
|
+
}, Hn = {
|
|
2439
2440
|
type: "html",
|
|
2440
2441
|
name: "HTML",
|
|
2441
2442
|
default: {
|
|
@@ -2460,7 +2461,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2460
2461
|
label: "提示"
|
|
2461
2462
|
}
|
|
2462
2463
|
]
|
|
2463
|
-
},
|
|
2464
|
+
}, Fn = {
|
|
2464
2465
|
type: "icon",
|
|
2465
2466
|
name: "图标",
|
|
2466
2467
|
default: {
|
|
@@ -2485,7 +2486,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2485
2486
|
label: "提示"
|
|
2486
2487
|
}
|
|
2487
2488
|
]
|
|
2488
|
-
},
|
|
2489
|
+
}, Gn = {
|
|
2489
2490
|
type: "image",
|
|
2490
2491
|
name: "图片",
|
|
2491
2492
|
default: {
|
|
@@ -2510,7 +2511,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2510
2511
|
label: "提示"
|
|
2511
2512
|
}
|
|
2512
2513
|
]
|
|
2513
|
-
},
|
|
2514
|
+
}, Jn = {
|
|
2514
2515
|
type: "json",
|
|
2515
2516
|
name: "JSON",
|
|
2516
2517
|
default: {
|
|
@@ -2535,7 +2536,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2535
2536
|
label: "提示"
|
|
2536
2537
|
}
|
|
2537
2538
|
]
|
|
2538
|
-
},
|
|
2539
|
+
}, zn = {
|
|
2539
2540
|
type: "link",
|
|
2540
2541
|
name: "链接",
|
|
2541
2542
|
default: {
|
|
@@ -2560,7 +2561,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2560
2561
|
label: "提示"
|
|
2561
2562
|
}
|
|
2562
2563
|
]
|
|
2563
|
-
},
|
|
2564
|
+
}, Kn = {
|
|
2564
2565
|
type: "rich",
|
|
2565
2566
|
name: "富文本",
|
|
2566
2567
|
default: {
|
|
@@ -2585,7 +2586,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2585
2586
|
label: "提示"
|
|
2586
2587
|
}
|
|
2587
2588
|
]
|
|
2588
|
-
},
|
|
2589
|
+
}, Wn = {
|
|
2589
2590
|
type: "tpl",
|
|
2590
2591
|
name: "模板",
|
|
2591
2592
|
default: {
|
|
@@ -2616,17 +2617,17 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2616
2617
|
info: "例如 <code>姓名: {name} 年龄:{age}</code>"
|
|
2617
2618
|
}
|
|
2618
2619
|
]
|
|
2619
|
-
},
|
|
2620
|
-
span:
|
|
2621
|
-
enum:
|
|
2622
|
-
html:
|
|
2623
|
-
icon:
|
|
2624
|
-
image:
|
|
2625
|
-
json:
|
|
2626
|
-
link:
|
|
2627
|
-
rich:
|
|
2628
|
-
tpl:
|
|
2629
|
-
},
|
|
2620
|
+
}, Zn = {
|
|
2621
|
+
span: qn,
|
|
2622
|
+
enum: Un,
|
|
2623
|
+
html: Hn,
|
|
2624
|
+
icon: Fn,
|
|
2625
|
+
image: Gn,
|
|
2626
|
+
json: Jn,
|
|
2627
|
+
link: zn,
|
|
2628
|
+
rich: Kn,
|
|
2629
|
+
tpl: Wn
|
|
2630
|
+
}, Qn = {
|
|
2630
2631
|
type: "jump",
|
|
2631
2632
|
name: "跳转",
|
|
2632
2633
|
default: {
|
|
@@ -2673,7 +2674,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2673
2674
|
}
|
|
2674
2675
|
}
|
|
2675
2676
|
]
|
|
2676
|
-
},
|
|
2677
|
+
}, Xn = {
|
|
2677
2678
|
type: "api",
|
|
2678
2679
|
name: "接口请求",
|
|
2679
2680
|
default: {
|
|
@@ -2742,7 +2743,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2742
2743
|
}
|
|
2743
2744
|
}
|
|
2744
2745
|
]
|
|
2745
|
-
},
|
|
2746
|
+
}, Yn = {
|
|
2746
2747
|
type: "form",
|
|
2747
2748
|
name: "弹框表单",
|
|
2748
2749
|
default: {
|
|
@@ -2796,7 +2797,7 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2796
2797
|
label: "保存接口"
|
|
2797
2798
|
}
|
|
2798
2799
|
]
|
|
2799
|
-
},
|
|
2800
|
+
}, eo = {
|
|
2800
2801
|
type: "table",
|
|
2801
2802
|
name: "弹框列表",
|
|
2802
2803
|
default: {
|
|
@@ -2850,14 +2851,14 @@ const Ln = /* @__PURE__ */ I(Pn, [["render", Rn], ["__scopeId", "data-v-875f0171
|
|
|
2850
2851
|
label: "保存接口"
|
|
2851
2852
|
}
|
|
2852
2853
|
]
|
|
2853
|
-
},
|
|
2854
|
-
jump:
|
|
2855
|
-
api:
|
|
2856
|
-
form:
|
|
2857
|
-
table:
|
|
2854
|
+
}, to = {
|
|
2855
|
+
jump: Qn,
|
|
2856
|
+
api: Xn,
|
|
2857
|
+
form: Yn,
|
|
2858
|
+
table: eo
|
|
2858
2859
|
};
|
|
2859
|
-
const
|
|
2860
|
-
components: { JsonView: Re, DevLayout:
|
|
2860
|
+
const lo = {
|
|
2861
|
+
components: { JsonView: Re, DevLayout: bt, VTable: oe, VForm: z, VButton: Pe },
|
|
2861
2862
|
props: {
|
|
2862
2863
|
schema: {
|
|
2863
2864
|
type: Object,
|
|
@@ -2866,7 +2867,7 @@ const eo = {
|
|
|
2866
2867
|
}
|
|
2867
2868
|
},
|
|
2868
2869
|
data() {
|
|
2869
|
-
const e =
|
|
2870
|
+
const e = Mt(this.$props.schema);
|
|
2870
2871
|
return delete e.listApi, e.list = [{}], {
|
|
2871
2872
|
baseSchema: He,
|
|
2872
2873
|
activeTab: "base",
|
|
@@ -2885,9 +2886,9 @@ const eo = {
|
|
|
2885
2886
|
ctrlName: "",
|
|
2886
2887
|
activeIndex: void 0,
|
|
2887
2888
|
ctrlMap: {
|
|
2888
|
-
filter: { input:
|
|
2889
|
-
headers:
|
|
2890
|
-
buttons:
|
|
2889
|
+
filter: { input: Dn, select: Nn, date: Vn },
|
|
2890
|
+
headers: Zn,
|
|
2891
|
+
buttons: to
|
|
2891
2892
|
},
|
|
2892
2893
|
activeIndexReg: /(filter|headers|normalButton|batchButton|rowButton)?\[(\d+)\]/,
|
|
2893
2894
|
currentCtrlType: "input"
|
|
@@ -2930,16 +2931,16 @@ const eo = {
|
|
|
2930
2931
|
return;
|
|
2931
2932
|
let l = this.builderSchema[t[1]][parseInt(t[2])].type;
|
|
2932
2933
|
t[1] === "headers" && l === void 0 && (l = "span");
|
|
2933
|
-
const
|
|
2934
|
-
if (!
|
|
2934
|
+
const o = this.ctrlMap[this.activeBrick][l];
|
|
2935
|
+
if (!o)
|
|
2935
2936
|
return;
|
|
2936
|
-
const
|
|
2937
|
-
if (
|
|
2938
|
-
if (
|
|
2939
|
-
const [a, s,
|
|
2940
|
-
this.builderSchema[s][
|
|
2937
|
+
const n = o.trans ? o.trans(e) : e;
|
|
2938
|
+
if (n && Object.keys(n).length > 0) {
|
|
2939
|
+
if (n.type = l, this.activeIndex.indexOf("[") > -1) {
|
|
2940
|
+
const [a, s, r] = this.activeIndex.match(/(\w+)\[(\d+)\]/);
|
|
2941
|
+
this.builderSchema[s][r] = { ...n };
|
|
2941
2942
|
} else
|
|
2942
|
-
this.builderSchema[this.activeIndex] =
|
|
2943
|
+
this.builderSchema[this.activeIndex] = n;
|
|
2943
2944
|
this.key++;
|
|
2944
2945
|
}
|
|
2945
2946
|
this.updateBuilderSchema();
|
|
@@ -2954,8 +2955,8 @@ const eo = {
|
|
|
2954
2955
|
});
|
|
2955
2956
|
const l = ne(this.builderSchema, this.activeIndex);
|
|
2956
2957
|
l.type = e;
|
|
2957
|
-
const
|
|
2958
|
-
this.ctrlOptions =
|
|
2958
|
+
const o = y(l);
|
|
2959
|
+
this.ctrlOptions = o, o.text && (this.ctrlOptions.text = o.text, this.ctrlOptions.props = o.props || {}), this.ctrlKey++, this.key++, this.updateBuilderSchema();
|
|
2959
2960
|
}
|
|
2960
2961
|
}
|
|
2961
2962
|
},
|
|
@@ -2989,40 +2990,40 @@ const eo = {
|
|
|
2989
2990
|
pushRowButton(e) {
|
|
2990
2991
|
this.push(e, "rowButton", "buttons", "buttons");
|
|
2991
2992
|
},
|
|
2992
|
-
push(e, t, l,
|
|
2993
|
-
const
|
|
2994
|
-
if (!
|
|
2993
|
+
push(e, t, l, o) {
|
|
2994
|
+
const n = this.ctrlMap[l];
|
|
2995
|
+
if (!n[e]) {
|
|
2995
2996
|
this.$message({ type: "warning", message: "尚未支持此组件的UI编辑" });
|
|
2996
2997
|
return;
|
|
2997
2998
|
}
|
|
2998
|
-
this.activeCtrl =
|
|
2999
|
+
this.activeCtrl = n[e], this.activeBrick = o, this.ctrlOptions = {}, this.builderSchema[t] = this.builderSchema[t] || [], this.builderSchema[t].push(y(n[e].default)), this.ctrlSchema = y({
|
|
2999
3000
|
options: y(ve),
|
|
3000
|
-
formItems: y(
|
|
3001
|
+
formItems: y(n[e].builder)
|
|
3001
3002
|
}), this.key++, this.ctrlKey++, this.activeIndex = `${t}[${this.builderSchema[t].length - 1}]`, this.activeTab = "ctrl";
|
|
3002
3003
|
},
|
|
3003
3004
|
removeOne() {
|
|
3004
|
-
|
|
3005
|
+
lt(this.builderSchema, this.activeIndex), this.builderSchema = y(Xe(this.builderSchema)), this.activeIndex = "", this.ctrlOptions = {}, this.ctrlSchema = {}, this.key++, this.ctrlKey++;
|
|
3005
3006
|
},
|
|
3006
3007
|
clicklabel() {
|
|
3007
3008
|
const e = this.activeIndex, t = e.match(this.activeIndexReg);
|
|
3008
3009
|
if (t) {
|
|
3009
3010
|
const l = y(ne(this.builderSchema, e));
|
|
3010
3011
|
this.activeBrick = t[1], ["normalButton", "batchButton", "rowButton"].indexOf(t[1]) > -1 && (this.activeBrick = "buttons");
|
|
3011
|
-
let
|
|
3012
|
-
t[1] === "headers" &&
|
|
3013
|
-
const
|
|
3014
|
-
if (!
|
|
3015
|
-
|
|
3012
|
+
let o = this.builderSchema[t[1]][parseInt(t[2])].type;
|
|
3013
|
+
t[1] === "headers" && o === void 0 && (o = "span");
|
|
3014
|
+
const n = this.ctrlMap[this.activeBrick][o];
|
|
3015
|
+
if (!n) {
|
|
3016
|
+
this.activeBrick, this.$message({ type: "warning", message: "尚未支持此组件的UI编辑" });
|
|
3016
3017
|
return;
|
|
3017
3018
|
}
|
|
3018
|
-
this.ctrlOptions = l, this.currentCtrlType =
|
|
3019
|
+
this.ctrlOptions = l, this.currentCtrlType = o, this.ctrlSchema = y({
|
|
3019
3020
|
options: y(ve),
|
|
3020
|
-
formItems: y(
|
|
3021
|
+
formItems: y(n.builder)
|
|
3021
3022
|
}), this.ctrlKey++;
|
|
3022
3023
|
}
|
|
3023
3024
|
},
|
|
3024
3025
|
saveSchema() {
|
|
3025
|
-
const { filter: e, headers: t, rowButton: l, normalButton:
|
|
3026
|
+
const { filter: e, headers: t, rowButton: l, normalButton: o, batchButton: n } = this.currentBuilderSchema;
|
|
3026
3027
|
this.$http.request({
|
|
3027
3028
|
method: "POST",
|
|
3028
3029
|
url: "/devtool/page_schema",
|
|
@@ -3030,8 +3031,8 @@ const eo = {
|
|
|
3030
3031
|
filter: e,
|
|
3031
3032
|
headers: t,
|
|
3032
3033
|
rowButton: l,
|
|
3033
|
-
normalButton:
|
|
3034
|
-
batchButton:
|
|
3034
|
+
normalButton: o,
|
|
3035
|
+
batchButton: n
|
|
3035
3036
|
}
|
|
3036
3037
|
}).then(({ data: a }) => {
|
|
3037
3038
|
a && this.$message({ type: "success", message: "保存成功, 请刷新页面查看效果" });
|
|
@@ -3039,30 +3040,30 @@ const eo = {
|
|
|
3039
3040
|
}
|
|
3040
3041
|
}
|
|
3041
3042
|
};
|
|
3042
|
-
function
|
|
3043
|
-
const s = de,
|
|
3044
|
-
return i(),
|
|
3045
|
-
"left-aside":
|
|
3046
|
-
u
|
|
3047
|
-
default:
|
|
3048
|
-
u
|
|
3049
|
-
default:
|
|
3050
|
-
|
|
3043
|
+
function no(e, t, l, o, n, a) {
|
|
3044
|
+
const s = de, r = ue, u = ae, d = v("v-table"), m = it, b = ue, g = v("JsonView"), x = v("VButton"), J = Te, U = Be, T = rt, Z = ct, Bt = v("v-form"), Ot = v("dev-layout");
|
|
3045
|
+
return i(), f(Ot, null, {
|
|
3046
|
+
"left-aside": c(() => [
|
|
3047
|
+
p(u, { style: { width: "200px" } }, {
|
|
3048
|
+
default: c(() => [
|
|
3049
|
+
p(u, null, {
|
|
3050
|
+
default: c(() => [
|
|
3051
|
+
p(s, {
|
|
3051
3052
|
class: "title",
|
|
3052
3053
|
"data-id": 22222
|
|
3053
3054
|
}, {
|
|
3054
|
-
default:
|
|
3055
|
+
default: c(() => [
|
|
3055
3056
|
k("添加搜索条件")
|
|
3056
3057
|
]),
|
|
3057
3058
|
_: 1
|
|
3058
3059
|
}),
|
|
3059
|
-
|
|
3060
|
-
default:
|
|
3061
|
-
|
|
3060
|
+
p(s, { class: "ctrl" }, {
|
|
3061
|
+
default: c(() => [
|
|
3062
|
+
p(r, {
|
|
3062
3063
|
class: "ctrl-btn",
|
|
3063
3064
|
onClick: t[0] || (t[0] = (C) => a.pushFilter("input"))
|
|
3064
3065
|
}, {
|
|
3065
|
-
default:
|
|
3066
|
+
default: c(() => [
|
|
3066
3067
|
k("文本框")
|
|
3067
3068
|
]),
|
|
3068
3069
|
_: 1
|
|
@@ -3070,13 +3071,13 @@ function to(e, t, l, n, o, a) {
|
|
|
3070
3071
|
]),
|
|
3071
3072
|
_: 1
|
|
3072
3073
|
}),
|
|
3073
|
-
|
|
3074
|
-
default:
|
|
3075
|
-
|
|
3074
|
+
p(s, { class: "ctrl" }, {
|
|
3075
|
+
default: c(() => [
|
|
3076
|
+
p(r, {
|
|
3076
3077
|
class: "ctrl-btn",
|
|
3077
3078
|
onClick: t[1] || (t[1] = (C) => a.pushFilter("select"))
|
|
3078
3079
|
}, {
|
|
3079
|
-
default:
|
|
3080
|
+
default: c(() => [
|
|
3080
3081
|
k("下拉框")
|
|
3081
3082
|
]),
|
|
3082
3083
|
_: 1
|
|
@@ -3084,13 +3085,13 @@ function to(e, t, l, n, o, a) {
|
|
|
3084
3085
|
]),
|
|
3085
3086
|
_: 1
|
|
3086
3087
|
}),
|
|
3087
|
-
|
|
3088
|
-
default:
|
|
3089
|
-
|
|
3088
|
+
p(s, { class: "ctrl" }, {
|
|
3089
|
+
default: c(() => [
|
|
3090
|
+
p(r, {
|
|
3090
3091
|
class: "ctrl-btn",
|
|
3091
3092
|
onClick: t[2] || (t[2] = (C) => a.pushFilter("date"))
|
|
3092
3093
|
}, {
|
|
3093
|
-
default:
|
|
3094
|
+
default: c(() => [
|
|
3094
3095
|
k("日期")
|
|
3095
3096
|
]),
|
|
3096
3097
|
_: 1
|
|
@@ -3101,25 +3102,25 @@ function to(e, t, l, n, o, a) {
|
|
|
3101
3102
|
]),
|
|
3102
3103
|
_: 1
|
|
3103
3104
|
}),
|
|
3104
|
-
u
|
|
3105
|
-
default:
|
|
3106
|
-
|
|
3107
|
-
default:
|
|
3105
|
+
p(u, null, {
|
|
3106
|
+
default: c(() => [
|
|
3107
|
+
p(s, { class: "title" }, {
|
|
3108
|
+
default: c(() => [
|
|
3108
3109
|
k("添加列表项")
|
|
3109
3110
|
]),
|
|
3110
3111
|
_: 1
|
|
3111
3112
|
}),
|
|
3112
|
-
(i(!0), h(E, null,
|
|
3113
|
+
(i(!0), h(E, null, O(Object.keys(n.ctrlMap.headers), (C, V) => (i(), f(s, {
|
|
3113
3114
|
key: `column-${V}`,
|
|
3114
3115
|
class: "ctrl"
|
|
3115
3116
|
}, {
|
|
3116
|
-
default:
|
|
3117
|
-
|
|
3117
|
+
default: c(() => [
|
|
3118
|
+
p(r, {
|
|
3118
3119
|
class: "ctrl-btn",
|
|
3119
|
-
onClick: (fe) => a.pushHeaders(
|
|
3120
|
+
onClick: (fe) => a.pushHeaders(n.ctrlMap.headers[C].type)
|
|
3120
3121
|
}, {
|
|
3121
|
-
default:
|
|
3122
|
-
k(
|
|
3122
|
+
default: c(() => [
|
|
3123
|
+
k(B(n.ctrlMap.headers[C].name), 1)
|
|
3123
3124
|
]),
|
|
3124
3125
|
_: 2
|
|
3125
3126
|
}, 1032, ["onClick"])
|
|
@@ -3129,25 +3130,25 @@ function to(e, t, l, n, o, a) {
|
|
|
3129
3130
|
]),
|
|
3130
3131
|
_: 1
|
|
3131
3132
|
}),
|
|
3132
|
-
u
|
|
3133
|
-
default:
|
|
3134
|
-
|
|
3135
|
-
default:
|
|
3133
|
+
p(u, null, {
|
|
3134
|
+
default: c(() => [
|
|
3135
|
+
p(s, { class: "title" }, {
|
|
3136
|
+
default: c(() => [
|
|
3136
3137
|
k("添加行按钮")
|
|
3137
3138
|
]),
|
|
3138
3139
|
_: 1
|
|
3139
3140
|
}),
|
|
3140
|
-
(i(!0), h(E, null,
|
|
3141
|
+
(i(!0), h(E, null, O(Object.keys(n.ctrlMap.buttons), (C, V) => (i(), f(s, {
|
|
3141
3142
|
key: `column-${V}`,
|
|
3142
3143
|
class: "ctrl"
|
|
3143
3144
|
}, {
|
|
3144
|
-
default:
|
|
3145
|
-
|
|
3145
|
+
default: c(() => [
|
|
3146
|
+
p(r, {
|
|
3146
3147
|
class: "ctrl-btn",
|
|
3147
|
-
onClick: (fe) => a.pushRowButton(
|
|
3148
|
+
onClick: (fe) => a.pushRowButton(n.ctrlMap.buttons[C].type)
|
|
3148
3149
|
}, {
|
|
3149
|
-
default:
|
|
3150
|
-
k(
|
|
3150
|
+
default: c(() => [
|
|
3151
|
+
k(B(n.ctrlMap.buttons[C].name), 1)
|
|
3151
3152
|
]),
|
|
3152
3153
|
_: 2
|
|
3153
3154
|
}, 1032, ["onClick"])
|
|
@@ -3157,35 +3158,35 @@ function to(e, t, l, n, o, a) {
|
|
|
3157
3158
|
]),
|
|
3158
3159
|
_: 1
|
|
3159
3160
|
}),
|
|
3160
|
-
u
|
|
3161
|
-
default:
|
|
3162
|
-
|
|
3163
|
-
default:
|
|
3161
|
+
p(u, null, {
|
|
3162
|
+
default: c(() => [
|
|
3163
|
+
p(s, { class: "title" }, {
|
|
3164
|
+
default: c(() => [
|
|
3164
3165
|
k("添加常规按钮")
|
|
3165
3166
|
]),
|
|
3166
3167
|
_: 1
|
|
3167
3168
|
}),
|
|
3168
|
-
(i(!0), h(E, null,
|
|
3169
|
+
(i(!0), h(E, null, O(Object.keys(n.ctrlMap.buttons), (C, V) => (i(), f(s, {
|
|
3169
3170
|
key: `column-${V}`,
|
|
3170
3171
|
class: "ctrl"
|
|
3171
3172
|
}, {
|
|
3172
|
-
default:
|
|
3173
|
-
|
|
3173
|
+
default: c(() => [
|
|
3174
|
+
p(r, {
|
|
3174
3175
|
class: "ctrl-btn",
|
|
3175
|
-
onClick: (fe) => a.pushNormalButton(
|
|
3176
|
+
onClick: (fe) => a.pushNormalButton(n.ctrlMap.buttons[C].type)
|
|
3176
3177
|
}, {
|
|
3177
|
-
default:
|
|
3178
|
-
k(
|
|
3178
|
+
default: c(() => [
|
|
3179
|
+
k(B(n.ctrlMap.buttons[C].name), 1)
|
|
3179
3180
|
]),
|
|
3180
3181
|
_: 2
|
|
3181
3182
|
}, 1032, ["onClick"])
|
|
3182
3183
|
]),
|
|
3183
3184
|
_: 2
|
|
3184
3185
|
}, 1024))), 128)),
|
|
3185
|
-
|
|
3186
|
-
default:
|
|
3187
|
-
|
|
3188
|
-
default:
|
|
3186
|
+
p(s, { class: "ctrl" }, {
|
|
3187
|
+
default: c(() => [
|
|
3188
|
+
p(r, { class: "ctrl-btn" }, {
|
|
3189
|
+
default: c(() => [
|
|
3189
3190
|
k("按钮组")
|
|
3190
3191
|
]),
|
|
3191
3192
|
_: 1
|
|
@@ -3196,35 +3197,35 @@ function to(e, t, l, n, o, a) {
|
|
|
3196
3197
|
]),
|
|
3197
3198
|
_: 1
|
|
3198
3199
|
}),
|
|
3199
|
-
u
|
|
3200
|
-
default:
|
|
3201
|
-
|
|
3202
|
-
default:
|
|
3200
|
+
p(u, null, {
|
|
3201
|
+
default: c(() => [
|
|
3202
|
+
p(s, { class: "title" }, {
|
|
3203
|
+
default: c(() => [
|
|
3203
3204
|
k("添加批量按钮")
|
|
3204
3205
|
]),
|
|
3205
3206
|
_: 1
|
|
3206
3207
|
}),
|
|
3207
|
-
(i(!0), h(E, null,
|
|
3208
|
+
(i(!0), h(E, null, O(Object.keys(n.ctrlMap.buttons), (C, V) => (i(), f(s, {
|
|
3208
3209
|
key: `column-${V}`,
|
|
3209
3210
|
class: "ctrl"
|
|
3210
3211
|
}, {
|
|
3211
|
-
default:
|
|
3212
|
-
|
|
3212
|
+
default: c(() => [
|
|
3213
|
+
p(r, {
|
|
3213
3214
|
class: "ctrl-btn",
|
|
3214
|
-
onClick: (fe) => a.pushBatchButton(
|
|
3215
|
+
onClick: (fe) => a.pushBatchButton(n.ctrlMap.buttons[C].type)
|
|
3215
3216
|
}, {
|
|
3216
|
-
default:
|
|
3217
|
-
k(
|
|
3217
|
+
default: c(() => [
|
|
3218
|
+
k(B(n.ctrlMap.buttons[C].name), 1)
|
|
3218
3219
|
]),
|
|
3219
3220
|
_: 2
|
|
3220
3221
|
}, 1032, ["onClick"])
|
|
3221
3222
|
]),
|
|
3222
3223
|
_: 2
|
|
3223
3224
|
}, 1024))), 128)),
|
|
3224
|
-
|
|
3225
|
-
default:
|
|
3226
|
-
|
|
3227
|
-
default:
|
|
3225
|
+
p(s, { class: "ctrl" }, {
|
|
3226
|
+
default: c(() => [
|
|
3227
|
+
p(r, { class: "ctrl-btn" }, {
|
|
3228
|
+
default: c(() => [
|
|
3228
3229
|
k("按钮组")
|
|
3229
3230
|
]),
|
|
3230
3231
|
_: 1
|
|
@@ -3239,44 +3240,44 @@ function to(e, t, l, n, o, a) {
|
|
|
3239
3240
|
_: 1
|
|
3240
3241
|
})
|
|
3241
3242
|
]),
|
|
3242
|
-
main:
|
|
3243
|
-
(i(),
|
|
3243
|
+
main: c(() => [
|
|
3244
|
+
(i(), f(d, F({
|
|
3244
3245
|
ref: "table",
|
|
3245
|
-
key:
|
|
3246
|
+
key: n.key,
|
|
3246
3247
|
dev: !0
|
|
3247
|
-
},
|
|
3248
|
-
|
|
3249
|
-
|
|
3248
|
+
}, n.builderSchema), null, 16)),
|
|
3249
|
+
p(m),
|
|
3250
|
+
p(b, {
|
|
3250
3251
|
type: "primary",
|
|
3251
3252
|
onClick: a.saveSchema
|
|
3252
3253
|
}, {
|
|
3253
|
-
default:
|
|
3254
|
+
default: c(() => [
|
|
3254
3255
|
k("保存页面配置")
|
|
3255
3256
|
]),
|
|
3256
3257
|
_: 1
|
|
3257
3258
|
}, 8, ["onClick"]),
|
|
3258
3259
|
k(" "),
|
|
3259
|
-
|
|
3260
|
+
p(x, {
|
|
3260
3261
|
text: "PageSchema",
|
|
3261
3262
|
type: "modal"
|
|
3262
3263
|
}, {
|
|
3263
|
-
default:
|
|
3264
|
-
|
|
3264
|
+
default: c(() => [
|
|
3265
|
+
p(g, { data: a.getSaveSchema }, null, 8, ["data"])
|
|
3265
3266
|
]),
|
|
3266
3267
|
_: 1
|
|
3267
3268
|
})
|
|
3268
3269
|
]),
|
|
3269
|
-
"right-aside":
|
|
3270
|
-
|
|
3271
|
-
default:
|
|
3272
|
-
|
|
3273
|
-
default:
|
|
3274
|
-
|
|
3275
|
-
modelValue:
|
|
3276
|
-
"onUpdate:modelValue": t[3] || (t[3] = (C) =>
|
|
3270
|
+
"right-aside": c(() => [
|
|
3271
|
+
n.activeIndex ? (i(), f(Z, { key: 0 }, {
|
|
3272
|
+
default: c(() => [
|
|
3273
|
+
p(T, { label: "控件类型" }, {
|
|
3274
|
+
default: c(() => [
|
|
3275
|
+
p(U, {
|
|
3276
|
+
modelValue: n.currentCtrlType,
|
|
3277
|
+
"onUpdate:modelValue": t[3] || (t[3] = (C) => n.currentCtrlType = C)
|
|
3277
3278
|
}, {
|
|
3278
|
-
default:
|
|
3279
|
-
(i(!0), h(E, null,
|
|
3279
|
+
default: c(() => [
|
|
3280
|
+
(i(!0), h(E, null, O(a.types, (C, V) => (i(), f(J, {
|
|
3280
3281
|
key: V,
|
|
3281
3282
|
label: C.label,
|
|
3282
3283
|
value: C.value
|
|
@@ -3290,61 +3291,61 @@ function to(e, t, l, n, o, a) {
|
|
|
3290
3291
|
]),
|
|
3291
3292
|
_: 1
|
|
3292
3293
|
})) : $("", !0),
|
|
3293
|
-
(i(),
|
|
3294
|
-
key:
|
|
3295
|
-
modelValue:
|
|
3296
|
-
"onUpdate:modelValue": t[4] || (t[4] = (C) =>
|
|
3297
|
-
},
|
|
3294
|
+
(i(), f(Bt, F({
|
|
3295
|
+
key: n.ctrlKey,
|
|
3296
|
+
modelValue: n.ctrlOptions,
|
|
3297
|
+
"onUpdate:modelValue": t[4] || (t[4] = (C) => n.ctrlOptions = C)
|
|
3298
|
+
}, n.ctrlSchema), null, 16, ["modelValue"]))
|
|
3298
3299
|
]),
|
|
3299
3300
|
_: 1
|
|
3300
3301
|
});
|
|
3301
3302
|
}
|
|
3302
|
-
const
|
|
3303
|
+
const oo = /* @__PURE__ */ I(lo, [["render", no], ["__scopeId", "data-v-e5209cb7"]]), ao = {
|
|
3303
3304
|
name: "PageEditor",
|
|
3304
|
-
components: { FormBuilder:
|
|
3305
|
+
components: { FormBuilder: jn, TableBuilder: oo },
|
|
3305
3306
|
setup() {
|
|
3306
|
-
const e = M(!1), t = M(1), l = "rtl",
|
|
3307
|
-
return { show: e, key: t, direction: l, pageSchema:
|
|
3307
|
+
const e = M(!1), t = M(1), l = "rtl", o = pe(), n = j(() => w.state.app.pages[o.path]);
|
|
3308
|
+
return { show: e, key: t, direction: l, pageSchema: n };
|
|
3308
3309
|
}
|
|
3309
3310
|
};
|
|
3310
|
-
function
|
|
3311
|
-
const s = v("VIcon"),
|
|
3311
|
+
function so(e, t, l, o, n, a) {
|
|
3312
|
+
const s = v("VIcon"), r = v("form-builder"), u = v("table-builder"), d = ut;
|
|
3312
3313
|
return i(), h(E, null, [
|
|
3313
|
-
|
|
3314
|
+
p(s, {
|
|
3314
3315
|
name: "ra-set",
|
|
3315
|
-
onClick: t[0] || (t[0] = (
|
|
3316
|
+
onClick: t[0] || (t[0] = (m) => o.show = !o.show)
|
|
3316
3317
|
}),
|
|
3317
|
-
|
|
3318
|
-
modelValue:
|
|
3319
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
3318
|
+
p(d, {
|
|
3319
|
+
modelValue: o.show,
|
|
3320
|
+
"onUpdate:modelValue": t[1] || (t[1] = (m) => o.show = m),
|
|
3320
3321
|
title: "页面设计",
|
|
3321
3322
|
class: "my-drawer",
|
|
3322
|
-
direction:
|
|
3323
|
+
direction: o.direction,
|
|
3323
3324
|
size: "90%",
|
|
3324
3325
|
"destroy-on-close": "",
|
|
3325
3326
|
"append-to-body": ""
|
|
3326
3327
|
}, {
|
|
3327
|
-
default:
|
|
3328
|
-
|
|
3328
|
+
default: c(() => [
|
|
3329
|
+
o.pageSchema.formItems !== void 0 ? (i(), f(r, {
|
|
3329
3330
|
key: 0,
|
|
3330
|
-
schema:
|
|
3331
|
+
schema: o.pageSchema
|
|
3331
3332
|
}, null, 8, ["schema"])) : $("", !0),
|
|
3332
|
-
|
|
3333
|
+
o.pageSchema.headers !== void 0 ? (i(), f(u, {
|
|
3333
3334
|
key: 1,
|
|
3334
|
-
schema:
|
|
3335
|
+
schema: o.pageSchema
|
|
3335
3336
|
}, null, 8, ["schema"])) : $("", !0)
|
|
3336
3337
|
]),
|
|
3337
3338
|
_: 1
|
|
3338
3339
|
}, 8, ["modelValue", "direction"])
|
|
3339
3340
|
], 64);
|
|
3340
3341
|
}
|
|
3341
|
-
const
|
|
3342
|
-
const
|
|
3342
|
+
const io = /* @__PURE__ */ I(ao, [["render", so]]);
|
|
3343
|
+
const ro = {
|
|
3343
3344
|
components: {
|
|
3344
|
-
Breadcrumb:
|
|
3345
|
-
Hamburger:
|
|
3345
|
+
Breadcrumb: fn,
|
|
3346
|
+
Hamburger: _n,
|
|
3346
3347
|
VButton: Pe,
|
|
3347
|
-
PageEditor:
|
|
3348
|
+
PageEditor: io
|
|
3348
3349
|
},
|
|
3349
3350
|
data() {
|
|
3350
3351
|
return {
|
|
@@ -3375,7 +3376,7 @@ const so = {
|
|
|
3375
3376
|
}
|
|
3376
3377
|
},
|
|
3377
3378
|
mounted() {
|
|
3378
|
-
|
|
3379
|
+
Ye("el-submenu is-active");
|
|
3379
3380
|
const e = this.getSetting("navBarNotice");
|
|
3380
3381
|
e.length > 0 && !this.getSetting("closeNavNotice") && this.showNotice(e) && this.$notify({
|
|
3381
3382
|
title: "提示",
|
|
@@ -3383,7 +3384,7 @@ const so = {
|
|
|
3383
3384
|
dangerouslyUseHTMLString: !0,
|
|
3384
3385
|
duration: 0,
|
|
3385
3386
|
onClose: this.closeNavBarNotice
|
|
3386
|
-
}), this.setting.envColor[this.user.env] &&
|
|
3387
|
+
}), this.setting.envColor[this.user.env] && Zt({
|
|
3387
3388
|
elRef: this.$refs.header.$el,
|
|
3388
3389
|
waterMark: this.user.env,
|
|
3389
3390
|
color: "skyblue",
|
|
@@ -3415,73 +3416,73 @@ const so = {
|
|
|
3415
3416
|
be.set(t, e);
|
|
3416
3417
|
},
|
|
3417
3418
|
gotoMenuEdit() {
|
|
3418
|
-
var e, t, l,
|
|
3419
|
-
(t = (e = this.$route) == null ? void 0 : e.meta) != null && t.pageId && window.open(location.origin + location.pathname + "#/menu/" + ((
|
|
3419
|
+
var e, t, l, o;
|
|
3420
|
+
(t = (e = this.$route) == null ? void 0 : e.meta) != null && t.pageId && window.open(location.origin + location.pathname + "#/menu/" + ((o = (l = this.$route) == null ? void 0 : l.meta) == null ? void 0 : o.pageId));
|
|
3420
3421
|
}
|
|
3421
3422
|
}
|
|
3422
|
-
},
|
|
3423
|
+
}, co = { class: "right-content" }, uo = { class: "right-item" }, po = {
|
|
3423
3424
|
key: 0,
|
|
3424
3425
|
class: "right-item"
|
|
3425
|
-
},
|
|
3426
|
+
}, mo = {
|
|
3426
3427
|
class: "right-item-button",
|
|
3427
3428
|
style: { padding: "0" }
|
|
3428
|
-
},
|
|
3429
|
-
function
|
|
3430
|
-
const s = v("hamburger"),
|
|
3431
|
-
return i(),
|
|
3429
|
+
}, fo = { class: "user-info" }, ho = ["src"], bo = { class: "user-name" };
|
|
3430
|
+
function _o(e, t, l, o, n, a) {
|
|
3431
|
+
const s = v("hamburger"), r = v("breadcrumb"), u = de, d = v("VIcon"), m = v("PageEditor"), b = v("v-button"), g = _l, x = yl, J = vl, U = ut, T = ae;
|
|
3432
|
+
return i(), f(T, {
|
|
3432
3433
|
ref: "header",
|
|
3433
3434
|
class: "navbar",
|
|
3434
|
-
style:
|
|
3435
|
+
style: jt({ background: a.setting.envColor[a.user.env] })
|
|
3435
3436
|
}, {
|
|
3436
|
-
default:
|
|
3437
|
-
u
|
|
3438
|
-
default:
|
|
3439
|
-
|
|
3437
|
+
default: c(() => [
|
|
3438
|
+
p(u, { span: 16 }, {
|
|
3439
|
+
default: c(() => [
|
|
3440
|
+
p(s, {
|
|
3440
3441
|
"is-active": e.sidebar.opened,
|
|
3441
3442
|
class: "hamburger-container",
|
|
3442
3443
|
onToggleClick: a.toggleSideBar
|
|
3443
3444
|
}, null, 8, ["is-active", "onToggleClick"]),
|
|
3444
|
-
|
|
3445
|
+
p(r, { class: "breadcrumb-container" })
|
|
3445
3446
|
]),
|
|
3446
3447
|
_: 1
|
|
3447
3448
|
}),
|
|
3448
|
-
u
|
|
3449
|
-
default:
|
|
3450
|
-
_("div",
|
|
3451
|
-
_("div",
|
|
3452
|
-
|
|
3449
|
+
p(u, { span: 8 }, {
|
|
3450
|
+
default: c(() => [
|
|
3451
|
+
_("div", co, [
|
|
3452
|
+
_("div", uo, [
|
|
3453
|
+
p(d, {
|
|
3453
3454
|
name: "ra-code",
|
|
3454
3455
|
onClick: a.gotoMenuEdit
|
|
3455
3456
|
}, null, 8, ["onClick"])
|
|
3456
3457
|
]),
|
|
3457
|
-
a.showPageJsonSchemaIcon ? (i(), h("div",
|
|
3458
|
-
|
|
3458
|
+
a.showPageJsonSchemaIcon ? (i(), h("div", po, [
|
|
3459
|
+
p(m)
|
|
3459
3460
|
])) : $("", !0),
|
|
3460
|
-
_("div",
|
|
3461
|
-
|
|
3461
|
+
_("div", mo, [
|
|
3462
|
+
p(b, { buttons: e.nav }, null, 8, ["buttons"])
|
|
3462
3463
|
]),
|
|
3463
|
-
|
|
3464
|
+
p(J, {
|
|
3464
3465
|
class: "right-item",
|
|
3465
3466
|
trigger: "click"
|
|
3466
3467
|
}, {
|
|
3467
|
-
dropdown:
|
|
3468
|
-
|
|
3469
|
-
default:
|
|
3470
|
-
|
|
3468
|
+
dropdown: c(() => [
|
|
3469
|
+
p(x, { class: "user-dropdown" }, {
|
|
3470
|
+
default: c(() => [
|
|
3471
|
+
p(g, {
|
|
3471
3472
|
icon: "oms-icon-index",
|
|
3472
3473
|
onClick: t[0] || (t[0] = (Z) => e.$router.push("/"))
|
|
3473
3474
|
}, {
|
|
3474
|
-
default:
|
|
3475
|
+
default: c(() => [
|
|
3475
3476
|
k("首页")
|
|
3476
3477
|
]),
|
|
3477
3478
|
_: 1
|
|
3478
3479
|
}),
|
|
3479
|
-
|
|
3480
|
+
p(g, {
|
|
3480
3481
|
divided: "",
|
|
3481
3482
|
icon: "el-icon-switch-button",
|
|
3482
3483
|
onClick: a.logout
|
|
3483
3484
|
}, {
|
|
3484
|
-
default:
|
|
3485
|
+
default: c(() => [
|
|
3485
3486
|
k("退出登录")
|
|
3486
3487
|
]),
|
|
3487
3488
|
_: 1
|
|
@@ -3490,15 +3491,15 @@ function ho(e, t, l, n, o, a) {
|
|
|
3490
3491
|
_: 1
|
|
3491
3492
|
})
|
|
3492
3493
|
]),
|
|
3493
|
-
default:
|
|
3494
|
-
_("div",
|
|
3494
|
+
default: c(() => [
|
|
3495
|
+
_("div", fo, [
|
|
3495
3496
|
_("img", {
|
|
3496
|
-
src: e.avatar ? e.avatar :
|
|
3497
|
+
src: e.avatar ? e.avatar : n.defaultAvatar,
|
|
3497
3498
|
class: "user-avatar",
|
|
3498
3499
|
alt: "头像"
|
|
3499
|
-
}, null, 8,
|
|
3500
|
+
}, null, 8, ho),
|
|
3500
3501
|
k(),
|
|
3501
|
-
_("span",
|
|
3502
|
+
_("span", bo, B(e.nickname || e.name), 1)
|
|
3502
3503
|
])
|
|
3503
3504
|
]),
|
|
3504
3505
|
_: 1
|
|
@@ -3507,7 +3508,7 @@ function ho(e, t, l, n, o, a) {
|
|
|
3507
3508
|
]),
|
|
3508
3509
|
_: 1
|
|
3509
3510
|
}),
|
|
3510
|
-
|
|
3511
|
+
n.showJsonSchema ? (i(), f(U, {
|
|
3511
3512
|
key: 0,
|
|
3512
3513
|
"with-header": !1,
|
|
3513
3514
|
size: "50%"
|
|
@@ -3516,8 +3517,8 @@ function ho(e, t, l, n, o, a) {
|
|
|
3516
3517
|
_: 1
|
|
3517
3518
|
}, 8, ["style"]);
|
|
3518
3519
|
}
|
|
3519
|
-
const
|
|
3520
|
-
const
|
|
3520
|
+
const yo = /* @__PURE__ */ I(ro, [["render", _o], ["__scopeId", "data-v-99b3c688"]]);
|
|
3521
|
+
const vo = {
|
|
3521
3522
|
name: "SidebarLogo",
|
|
3522
3523
|
props: {
|
|
3523
3524
|
collapse: {
|
|
@@ -3533,43 +3534,43 @@ const _o = {
|
|
|
3533
3534
|
return this.$store.state.settings.logo;
|
|
3534
3535
|
}
|
|
3535
3536
|
}
|
|
3536
|
-
},
|
|
3537
|
+
}, go = (e) => (Ke("data-v-49084925"), e = e(), We(), e), ko = ["src"], wo = {
|
|
3537
3538
|
key: 1,
|
|
3538
3539
|
class: "sidebar-title"
|
|
3539
|
-
},
|
|
3540
|
-
function
|
|
3540
|
+
}, So = /* @__PURE__ */ go(() => /* @__PURE__ */ _("div", null, "系统", -1)), xo = ["src"], Eo = { class: "sidebar-title" };
|
|
3541
|
+
function $o(e, t, l, o, n, a) {
|
|
3541
3542
|
const s = v("router-link");
|
|
3542
3543
|
return i(), h("div", {
|
|
3543
3544
|
class: H(["sidebar-logo-container", { collapse: l.collapse }])
|
|
3544
3545
|
}, [
|
|
3545
|
-
|
|
3546
|
-
default:
|
|
3547
|
-
l.collapse ? (i(),
|
|
3546
|
+
p(Dt, { name: "sidebarLogoFade" }, {
|
|
3547
|
+
default: c(() => [
|
|
3548
|
+
l.collapse ? (i(), f(s, {
|
|
3548
3549
|
key: "collapse",
|
|
3549
3550
|
class: "sidebar-logo-link",
|
|
3550
3551
|
to: "/"
|
|
3551
3552
|
}, {
|
|
3552
|
-
default:
|
|
3553
|
+
default: c(() => [
|
|
3553
3554
|
a.logo ? (i(), h("img", {
|
|
3554
3555
|
key: 0,
|
|
3555
3556
|
src: a.logo,
|
|
3556
3557
|
class: "sidebar-logo"
|
|
3557
|
-
}, null, 8,
|
|
3558
|
-
|
|
3558
|
+
}, null, 8, ko)) : (i(), h("h1", wo, B(a.title), 1)),
|
|
3559
|
+
So
|
|
3559
3560
|
]),
|
|
3560
3561
|
_: 1
|
|
3561
|
-
})) : (i(),
|
|
3562
|
+
})) : (i(), f(s, {
|
|
3562
3563
|
key: "expand",
|
|
3563
3564
|
class: "sidebar-logo-link",
|
|
3564
3565
|
to: "/"
|
|
3565
3566
|
}, {
|
|
3566
|
-
default:
|
|
3567
|
+
default: c(() => [
|
|
3567
3568
|
a.logo ? (i(), h("img", {
|
|
3568
3569
|
key: 0,
|
|
3569
3570
|
src: a.logo,
|
|
3570
3571
|
class: "sidebar-logo"
|
|
3571
|
-
}, null, 8,
|
|
3572
|
-
_("h1",
|
|
3572
|
+
}, null, 8, xo)) : $("", !0),
|
|
3573
|
+
_("h1", Eo, B(a.title), 1)
|
|
3573
3574
|
]),
|
|
3574
3575
|
_: 1
|
|
3575
3576
|
}))
|
|
@@ -3578,7 +3579,7 @@ function xo(e, t, l, n, o, a) {
|
|
|
3578
3579
|
})
|
|
3579
3580
|
], 2);
|
|
3580
3581
|
}
|
|
3581
|
-
const
|
|
3582
|
+
const Io = /* @__PURE__ */ I(vo, [["render", $o], ["__scopeId", "data-v-49084925"]]), Co = {
|
|
3582
3583
|
props: {
|
|
3583
3584
|
to: {
|
|
3584
3585
|
type: String,
|
|
@@ -3611,15 +3612,15 @@ const Eo = /* @__PURE__ */ I(_o, [["render", xo], ["__scopeId", "data-v-49084925
|
|
|
3611
3612
|
}
|
|
3612
3613
|
}
|
|
3613
3614
|
};
|
|
3614
|
-
function
|
|
3615
|
-
return i(),
|
|
3616
|
-
default:
|
|
3615
|
+
function To(e, t, l, o, n, a) {
|
|
3616
|
+
return i(), f(Ze(a.compType(l.to)), G(Y(a.linkProps(l.to))), {
|
|
3617
|
+
default: c(() => [
|
|
3617
3618
|
le(e.$slots, "default")
|
|
3618
3619
|
]),
|
|
3619
3620
|
_: 3
|
|
3620
3621
|
}, 16);
|
|
3621
3622
|
}
|
|
3622
|
-
const
|
|
3623
|
+
const Bo = /* @__PURE__ */ I(Co, [["render", To]]), Oo = {
|
|
3623
3624
|
computed: {
|
|
3624
3625
|
// @ts-ignore
|
|
3625
3626
|
device() {
|
|
@@ -3640,7 +3641,7 @@ const Co = /* @__PURE__ */ I($o, [["render", Io]]), To = {
|
|
|
3640
3641
|
}
|
|
3641
3642
|
}
|
|
3642
3643
|
}
|
|
3643
|
-
},
|
|
3644
|
+
}, Ao = { class: "menu-content" }, Po = /* @__PURE__ */ q({
|
|
3644
3645
|
__name: "MenuContent",
|
|
3645
3646
|
props: {
|
|
3646
3647
|
meta: {
|
|
@@ -3653,22 +3654,22 @@ const Co = /* @__PURE__ */ I($o, [["render", Io]]), To = {
|
|
|
3653
3654
|
},
|
|
3654
3655
|
setup(e) {
|
|
3655
3656
|
return (t, l) => {
|
|
3656
|
-
const
|
|
3657
|
+
const o = v("VIcon");
|
|
3657
3658
|
return i(), h(E, null, [
|
|
3658
|
-
|
|
3659
|
+
p(o, {
|
|
3659
3660
|
name: e.meta.icon || "ra-all"
|
|
3660
3661
|
}, null, 8, ["name"]),
|
|
3661
|
-
_("span",
|
|
3662
|
+
_("span", Ao, B(e.meta.title), 1)
|
|
3662
3663
|
], 64);
|
|
3663
3664
|
};
|
|
3664
3665
|
}
|
|
3665
|
-
}),
|
|
3666
|
+
}), Ro = {
|
|
3666
3667
|
name: "SidebarItem",
|
|
3667
3668
|
components: {
|
|
3668
|
-
AppLink:
|
|
3669
|
-
MenuContent:
|
|
3669
|
+
AppLink: Bo,
|
|
3670
|
+
MenuContent: Po
|
|
3670
3671
|
},
|
|
3671
|
-
mixins: [
|
|
3672
|
+
mixins: [Oo],
|
|
3672
3673
|
props: {
|
|
3673
3674
|
// route object
|
|
3674
3675
|
item: {
|
|
@@ -3693,26 +3694,26 @@ const Co = /* @__PURE__ */ I($o, [["render", Io]]), To = {
|
|
|
3693
3694
|
}
|
|
3694
3695
|
}
|
|
3695
3696
|
}
|
|
3696
|
-
},
|
|
3697
|
+
}, Lo = {
|
|
3697
3698
|
key: 0,
|
|
3698
3699
|
class: "menu-wrapper"
|
|
3699
3700
|
};
|
|
3700
|
-
function
|
|
3701
|
-
const s = v("menu-content"),
|
|
3702
|
-
return l.item.hidden !== !1 ? (i(), h("div",
|
|
3701
|
+
function Mo(e, t, l, o, n, a) {
|
|
3702
|
+
const s = v("menu-content"), r = gl, u = v("app-link"), d = v("sidebar-item", !0), m = kl;
|
|
3703
|
+
return l.item.hidden !== !1 ? (i(), h("div", Lo, [
|
|
3703
3704
|
l.item.meta && l.item.meta.menuType === 2 ? (i(), h(E, { key: 0 }, [
|
|
3704
|
-
l.item.meta ? (i(),
|
|
3705
|
+
l.item.meta ? (i(), f(u, {
|
|
3705
3706
|
key: 0,
|
|
3706
3707
|
to: l.to,
|
|
3707
3708
|
"new-tab": l.item.meta.newTab
|
|
3708
3709
|
}, {
|
|
3709
|
-
default:
|
|
3710
|
-
|
|
3710
|
+
default: c(() => [
|
|
3711
|
+
p(r, {
|
|
3711
3712
|
index: l.to,
|
|
3712
3713
|
class: H({ "submenu-title-noDropdown": !l.isNest })
|
|
3713
3714
|
}, {
|
|
3714
|
-
default:
|
|
3715
|
-
|
|
3715
|
+
default: c(() => [
|
|
3716
|
+
p(s, {
|
|
3716
3717
|
meta: l.item.meta
|
|
3717
3718
|
}, null, 8, ["meta"])
|
|
3718
3719
|
]),
|
|
@@ -3721,30 +3722,30 @@ function Ro(e, t, l, n, o, a) {
|
|
|
3721
3722
|
]),
|
|
3722
3723
|
_: 1
|
|
3723
3724
|
}, 8, ["to", "new-tab"])) : $("", !0)
|
|
3724
|
-
], 64)) : l.item.meta && l.item.meta.menuType === 1 ? (i(), m
|
|
3725
|
+
], 64)) : l.item.meta && l.item.meta.menuType === 1 ? (i(), f(m, {
|
|
3725
3726
|
key: 1,
|
|
3726
3727
|
ref: "subMenu",
|
|
3727
3728
|
index: l.to,
|
|
3728
3729
|
class: H({ "submenu-title-noDropdown": !l.isNest })
|
|
3729
3730
|
}, {
|
|
3730
|
-
title:
|
|
3731
|
-
l.item.redirect && l.item.redirect !== "#" ? (i(),
|
|
3731
|
+
title: c(() => [
|
|
3732
|
+
l.item.redirect && l.item.redirect !== "#" ? (i(), f(u, {
|
|
3732
3733
|
key: 0,
|
|
3733
3734
|
to: l.to
|
|
3734
3735
|
}, {
|
|
3735
|
-
default:
|
|
3736
|
-
|
|
3736
|
+
default: c(() => [
|
|
3737
|
+
p(s, {
|
|
3737
3738
|
meta: l.item.meta
|
|
3738
3739
|
}, null, 8, ["meta"])
|
|
3739
3740
|
]),
|
|
3740
3741
|
_: 1
|
|
3741
|
-
}, 8, ["to"])) : (i(),
|
|
3742
|
+
}, 8, ["to"])) : (i(), f(s, {
|
|
3742
3743
|
key: 1,
|
|
3743
3744
|
meta: l.item.meta
|
|
3744
3745
|
}, null, 8, ["meta"]))
|
|
3745
3746
|
]),
|
|
3746
|
-
default:
|
|
3747
|
-
(i(!0), h(E, null,
|
|
3747
|
+
default: c(() => [
|
|
3748
|
+
(i(!0), h(E, null, O(l.item.children, (b) => (i(), f(d, {
|
|
3748
3749
|
key: b.path,
|
|
3749
3750
|
"is-nest": !0,
|
|
3750
3751
|
item: b,
|
|
@@ -3756,14 +3757,14 @@ function Ro(e, t, l, n, o, a) {
|
|
|
3756
3757
|
}, 8, ["index", "class"])) : $("", !0)
|
|
3757
3758
|
])) : $("", !0);
|
|
3758
3759
|
}
|
|
3759
|
-
const
|
|
3760
|
-
function
|
|
3760
|
+
const jo = /* @__PURE__ */ I(Ro, [["render", Mo]]);
|
|
3761
|
+
function yt(e) {
|
|
3761
3762
|
return e.filter((t) => {
|
|
3762
3763
|
var l;
|
|
3763
|
-
return ((l = t.meta) == null ? void 0 : l.menuType) === 0 ? !1 : (t.children && (t.children =
|
|
3764
|
+
return ((l = t.meta) == null ? void 0 : l.menuType) === 0 ? !1 : (t.children && (t.children = yt(t.children), t.children.length === 0 && delete t.children), !0);
|
|
3764
3765
|
});
|
|
3765
3766
|
}
|
|
3766
|
-
const
|
|
3767
|
+
const Do = {
|
|
3767
3768
|
data() {
|
|
3768
3769
|
return {
|
|
3769
3770
|
selected: ""
|
|
@@ -3775,13 +3776,13 @@ const Mo = {
|
|
|
3775
3776
|
let e = [];
|
|
3776
3777
|
return this.remoteRouter.forEach((t) => {
|
|
3777
3778
|
e = e.concat(y(t.routes));
|
|
3778
|
-
}),
|
|
3779
|
+
}), yt(e);
|
|
3779
3780
|
}
|
|
3780
3781
|
},
|
|
3781
3782
|
methods: {
|
|
3782
3783
|
getJumpPath: function(e) {
|
|
3783
3784
|
let t = e;
|
|
3784
|
-
if (e.meta.menuType === 1 && e.children.length > 0) {
|
|
3785
|
+
if (e.meta.menuType === 1 && e.children && e.children.length > 0) {
|
|
3785
3786
|
for (let l = 0; l < e.children.length; l++)
|
|
3786
3787
|
if (e.children[l].path.indexOf("/:") === -1) {
|
|
3787
3788
|
t = e.children[l];
|
|
@@ -3795,39 +3796,39 @@ const Mo = {
|
|
|
3795
3796
|
}
|
|
3796
3797
|
}
|
|
3797
3798
|
};
|
|
3798
|
-
function
|
|
3799
|
-
const s = Te,
|
|
3800
|
-
return i(),
|
|
3801
|
-
modelValue:
|
|
3802
|
-
"onUpdate:modelValue": t[0] || (t[0] = (d) =>
|
|
3799
|
+
function No(e, t, l, o, n, a) {
|
|
3800
|
+
const s = Te, r = wl, u = Be;
|
|
3801
|
+
return i(), f(u, {
|
|
3802
|
+
modelValue: n.selected,
|
|
3803
|
+
"onUpdate:modelValue": t[0] || (t[0] = (d) => n.selected = d),
|
|
3803
3804
|
filterable: "",
|
|
3804
3805
|
placeholder: "搜索菜单...",
|
|
3805
3806
|
class: "search-menu",
|
|
3806
3807
|
onChange: a.onselected
|
|
3807
3808
|
}, {
|
|
3808
|
-
default:
|
|
3809
|
-
(i(!0), h(E, null,
|
|
3809
|
+
default: c(() => [
|
|
3810
|
+
(i(!0), h(E, null, O(a.filterRoutes, (d) => (i(), h(E, {
|
|
3810
3811
|
key: d.path
|
|
3811
3812
|
}, [
|
|
3812
3813
|
d.children !== void 0 ? (i(), h(E, { key: 0 }, [
|
|
3813
|
-
d.meta.menuType !== 0 ? (i(),
|
|
3814
|
+
d.meta.menuType !== 0 ? (i(), f(r, {
|
|
3814
3815
|
key: d.path + "-",
|
|
3815
3816
|
label: d.meta.title
|
|
3816
3817
|
}, {
|
|
3817
|
-
default:
|
|
3818
|
-
(i(!0), h(E, null,
|
|
3819
|
-
key:
|
|
3818
|
+
default: c(() => [
|
|
3819
|
+
(i(!0), h(E, null, O(d.children, (m, b) => (i(), h(E, {
|
|
3820
|
+
key: m.path
|
|
3820
3821
|
}, [
|
|
3821
|
-
d.meta.menuType !== 0 ? (i(),
|
|
3822
|
+
d.meta.menuType !== 0 ? (i(), f(s, {
|
|
3822
3823
|
key: 0,
|
|
3823
|
-
label: (b === d.children.length - 1 ? "└─" : "├─") +
|
|
3824
|
-
value: a.getJumpPath(
|
|
3824
|
+
label: (b === d.children.length - 1 ? "└─" : "├─") + m.meta.title,
|
|
3825
|
+
value: a.getJumpPath(m)
|
|
3825
3826
|
}, null, 8, ["label", "value"])) : $("", !0)
|
|
3826
3827
|
], 64))), 128))
|
|
3827
3828
|
]),
|
|
3828
3829
|
_: 2
|
|
3829
3830
|
}, 1032, ["label"])) : $("", !0)
|
|
3830
|
-
], 64)) : (i(),
|
|
3831
|
+
], 64)) : (i(), f(s, {
|
|
3831
3832
|
key: 1,
|
|
3832
3833
|
label: "" + d.meta.title,
|
|
3833
3834
|
value: a.getJumpPath(d)
|
|
@@ -3837,10 +3838,10 @@ function jo(e, t, l, n, o, a) {
|
|
|
3837
3838
|
_: 1
|
|
3838
3839
|
}, 8, ["modelValue", "onChange"]);
|
|
3839
3840
|
}
|
|
3840
|
-
const
|
|
3841
|
+
const Vo = /* @__PURE__ */ I(Do, [["render", No], ["__scopeId", "data-v-38301044"]]);
|
|
3841
3842
|
var D = /* @__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))(D || {}), L = /* @__PURE__ */ ((e) => (e[e.hidden = 0] = "hidden", e[e.dir = 1] = "dir", e[e.menu = 2] = "menu", e[e.page = 3] = "page", e))(L || {});
|
|
3842
|
-
const
|
|
3843
|
-
components: { SidebarItem:
|
|
3843
|
+
const qo = q({
|
|
3844
|
+
components: { SidebarItem: jo, Logo: Io, SearchMenu: Vo },
|
|
3844
3845
|
computed: {
|
|
3845
3846
|
...Ce(["sidebar", "remoteRouter", "customRouter"]),
|
|
3846
3847
|
routes() {
|
|
@@ -3883,26 +3884,26 @@ const No = q({
|
|
|
3883
3884
|
},
|
|
3884
3885
|
methods: {
|
|
3885
3886
|
showActive() {
|
|
3886
|
-
|
|
3887
|
+
Ye("is-active", 200);
|
|
3887
3888
|
},
|
|
3888
3889
|
filterRoute(e) {
|
|
3889
3890
|
return e.filter((t) => [L.dir, L.menu].indexOf(t.meta.menuType) !== -1).map((t) => (t = Object.assign({}, t), t.children && (t.children = this.filterRoute(t.children)), t));
|
|
3890
3891
|
}
|
|
3891
3892
|
}
|
|
3892
3893
|
});
|
|
3893
|
-
function
|
|
3894
|
-
const s = v("logo"),
|
|
3894
|
+
function Uo(e, t, l, o, n, a) {
|
|
3895
|
+
const s = v("logo"), r = v("search-menu"), u = v("sidebar-item"), d = Sl, m = xl;
|
|
3895
3896
|
return i(), h("div", {
|
|
3896
3897
|
class: H({ "has-logo": e.showLogo })
|
|
3897
3898
|
}, [
|
|
3898
|
-
e.showLogo ? (i(),
|
|
3899
|
+
e.showLogo ? (i(), f(s, {
|
|
3899
3900
|
key: 0,
|
|
3900
3901
|
collapse: e.isCollapse
|
|
3901
3902
|
}, null, 8, ["collapse"])) : $("", !0),
|
|
3902
|
-
|
|
3903
|
-
default:
|
|
3904
|
-
e.isCollapse ? $("", !0) : (i(),
|
|
3905
|
-
|
|
3903
|
+
p(m, { "wrap-class": "scrollbar-wrapper" }, {
|
|
3904
|
+
default: c(() => [
|
|
3905
|
+
e.isCollapse ? $("", !0) : (i(), f(r, { key: 0 })),
|
|
3906
|
+
p(d, {
|
|
3906
3907
|
"default-active": e.activeMenu,
|
|
3907
3908
|
collapse: e.isCollapse,
|
|
3908
3909
|
"background-color": e.variables.menuBg,
|
|
@@ -3912,11 +3913,11 @@ function Vo(e, t, l, n, o, a) {
|
|
|
3912
3913
|
"collapse-transition": !1,
|
|
3913
3914
|
mode: "vertical"
|
|
3914
3915
|
}, {
|
|
3915
|
-
default:
|
|
3916
|
-
(i(!0), h(E, null,
|
|
3916
|
+
default: c(() => [
|
|
3917
|
+
(i(!0), h(E, null, O(e.routes, (b, g) => (i(), h(E, {
|
|
3917
3918
|
key: g + "-module"
|
|
3918
3919
|
}, [
|
|
3919
|
-
(i(!0), h(E, null,
|
|
3920
|
+
(i(!0), h(E, null, O(e.filterRoute(b.routes), (x) => (i(), f(u, {
|
|
3920
3921
|
key: x.path,
|
|
3921
3922
|
item: x,
|
|
3922
3923
|
to: e.$router.resolve(x.redirect ? x.redirect : x).fullPath
|
|
@@ -3930,221 +3931,135 @@ function Vo(e, t, l, n, o, a) {
|
|
|
3930
3931
|
})
|
|
3931
3932
|
], 2);
|
|
3932
3933
|
}
|
|
3933
|
-
const
|
|
3934
|
-
const
|
|
3934
|
+
const Ho = /* @__PURE__ */ I(qo, [["render", Uo], ["__scopeId", "data-v-d252f828"]]);
|
|
3935
|
+
const Fo = { class: "app-main" }, Go = {
|
|
3935
3936
|
__name: "AppMain",
|
|
3936
3937
|
setup(e) {
|
|
3937
|
-
const t = pe(), l = [],
|
|
3938
|
-
return
|
|
3939
|
-
var
|
|
3940
|
-
(
|
|
3941
|
-
}), (
|
|
3942
|
-
const s = v("router-view"),
|
|
3943
|
-
return i(), h("section",
|
|
3944
|
-
(i(),
|
|
3945
|
-
key:
|
|
3938
|
+
const t = pe(), l = [], o = M(0);
|
|
3939
|
+
return rl(() => {
|
|
3940
|
+
var n;
|
|
3941
|
+
(n = t.meta) != null && n.keepAlive && l.indexOf(t.name) && l.push(t.name), o.value++;
|
|
3942
|
+
}), (n, a) => {
|
|
3943
|
+
const s = v("router-view"), r = El;
|
|
3944
|
+
return i(), h("section", Fo, [
|
|
3945
|
+
(i(), f(s, {
|
|
3946
|
+
key: n.$route.fullPath + S(o)
|
|
3946
3947
|
})),
|
|
3947
|
-
|
|
3948
|
+
p(r, { bottom: 50 })
|
|
3948
3949
|
]);
|
|
3949
3950
|
};
|
|
3950
3951
|
}
|
|
3951
|
-
},
|
|
3952
|
-
const
|
|
3952
|
+
}, Jo = /* @__PURE__ */ I(Go, [["__scopeId", "data-v-ca0f0d98"]]);
|
|
3953
|
+
const zo = { class: "main-container" }, Ko = 992, Wo = {
|
|
3953
3954
|
__name: "index",
|
|
3954
3955
|
setup(e) {
|
|
3955
|
-
const t =
|
|
3956
|
-
hideSidebar: !
|
|
3957
|
-
openSidebar:
|
|
3958
|
-
withoutAnimation:
|
|
3959
|
-
mobile:
|
|
3960
|
-
})),
|
|
3961
|
-
|
|
3962
|
-
const
|
|
3956
|
+
const t = ot(), { body: l } = document, o = j(() => t.state.app.sidebar), n = j(() => t.state.app.device), a = j(() => t.state.settings.fixedHeader), s = j(() => ({
|
|
3957
|
+
hideSidebar: !o.value.opened,
|
|
3958
|
+
openSidebar: o.value.opened,
|
|
3959
|
+
withoutAnimation: o.value.withoutAnimation,
|
|
3960
|
+
mobile: n.value === "mobile"
|
|
3961
|
+
})), r = () => l.getBoundingClientRect().width - 1 < Ko;
|
|
3962
|
+
Pl(window, "resize", () => d());
|
|
3963
|
+
const u = () => {
|
|
3963
3964
|
t.dispatch("app/closeSideBar", { withoutAnimation: !1 });
|
|
3964
3965
|
}, d = () => {
|
|
3965
3966
|
if (!document.hidden) {
|
|
3966
|
-
const
|
|
3967
|
-
t.dispatch("app/toggleDevice",
|
|
3967
|
+
const m = r();
|
|
3968
|
+
t.dispatch("app/toggleDevice", m ? "mobile" : "desktop"), m && t.dispatch("app/closeSideBar", { withoutAnimation: !0 });
|
|
3968
3969
|
}
|
|
3969
3970
|
};
|
|
3970
|
-
return (
|
|
3971
|
-
class: H([
|
|
3971
|
+
return (m, b) => (i(), h("div", {
|
|
3972
|
+
class: H([S(s), "app-wrapper"])
|
|
3972
3973
|
}, [
|
|
3973
|
-
|
|
3974
|
+
S(n) === "mobile" && S(o).opened ? (i(), h("div", {
|
|
3974
3975
|
key: 0,
|
|
3975
3976
|
class: "drawer-bg",
|
|
3976
|
-
onClick:
|
|
3977
|
+
onClick: u
|
|
3977
3978
|
})) : $("", !0),
|
|
3978
|
-
|
|
3979
|
-
_("div",
|
|
3979
|
+
p(S(Ho), { class: "sidebar-container" }),
|
|
3980
|
+
_("div", zo, [
|
|
3980
3981
|
_("div", {
|
|
3981
|
-
class: H({ "fixed-header":
|
|
3982
|
+
class: H({ "fixed-header": S(a) })
|
|
3982
3983
|
}, [
|
|
3983
|
-
|
|
3984
|
+
p(S(yo))
|
|
3984
3985
|
], 2),
|
|
3985
|
-
|
|
3986
|
+
p(S(Jo))
|
|
3986
3987
|
])
|
|
3987
3988
|
], 2));
|
|
3988
3989
|
}
|
|
3989
|
-
},
|
|
3990
|
-
class _t {
|
|
3991
|
-
constructor() {
|
|
3992
|
-
R(this, "type", "qrcode");
|
|
3993
|
-
}
|
|
3994
|
-
flag() {
|
|
3995
|
-
}
|
|
3996
|
-
jumpToLoginPage(t, l) {
|
|
3997
|
-
t(l);
|
|
3998
|
-
}
|
|
3999
|
-
showQrCode() {
|
|
4000
|
-
}
|
|
4001
|
-
}
|
|
4002
|
-
class xi extends _t {
|
|
4003
|
-
constructor(l) {
|
|
4004
|
-
super();
|
|
4005
|
-
R(this, "type", "jump");
|
|
4006
|
-
R(this, "client_id", "");
|
|
4007
|
-
this.client_id = l.client_id;
|
|
4008
|
-
}
|
|
4009
|
-
flag() {
|
|
4010
|
-
const l = Ye("code");
|
|
4011
|
-
if (l)
|
|
4012
|
-
return {
|
|
4013
|
-
ticket: l,
|
|
4014
|
-
key: "github"
|
|
4015
|
-
};
|
|
4016
|
-
}
|
|
4017
|
-
jumpToLoginPage(l, n) {
|
|
4018
|
-
const o = encodeURIComponent(location.href);
|
|
4019
|
-
location.replace(`https://github.com/login/oauth/authorize?client_id=${this.client_id}&redirect_uri${o}`);
|
|
4020
|
-
}
|
|
4021
|
-
}
|
|
4022
|
-
class Ei extends _t {
|
|
4023
|
-
constructor(l) {
|
|
4024
|
-
super();
|
|
4025
|
-
R(this, "type", "qrcode");
|
|
4026
|
-
R(this, "qrCodeUrl", "https://login.dingtalk.com/login/qrcode.htm?goto={goto}&style={style}");
|
|
4027
|
-
R(this, "reloadUrl", "https://oapi.dingtalk.com/connect/oauth2/sns_authorize?response_type=code&scope=snsapi_login&state=&appid={appid}&redirect_uri={redirect_uri}");
|
|
4028
|
-
R(this, "elId", "");
|
|
4029
|
-
R(this, "appid", "");
|
|
4030
|
-
R(this, "iframe", new HTMLIFrameElement());
|
|
4031
|
-
R(this, "redirectUri", "");
|
|
4032
|
-
R(this, "style", "");
|
|
4033
|
-
}
|
|
4034
|
-
flag() {
|
|
4035
|
-
const l = Ye("code");
|
|
4036
|
-
if (l)
|
|
4037
|
-
return {
|
|
4038
|
-
ticket: l,
|
|
4039
|
-
key: "dingtalk"
|
|
4040
|
-
};
|
|
4041
|
-
}
|
|
4042
|
-
showQrCode() {
|
|
4043
|
-
const l = (a) => {
|
|
4044
|
-
const s = {
|
|
4045
|
-
appid: this.appid,
|
|
4046
|
-
redirect_uri: encodeURIComponent(this.redirectUri)
|
|
4047
|
-
};
|
|
4048
|
-
return Q(this.reloadUrl, s) + "&" + Kt(a || {});
|
|
4049
|
-
}, n = () => {
|
|
4050
|
-
const a = {
|
|
4051
|
-
goto: encodeURIComponent(l()),
|
|
4052
|
-
style: encodeURIComponent(this.style)
|
|
4053
|
-
};
|
|
4054
|
-
return Q(this.qrCodeUrl, a);
|
|
4055
|
-
}, o = (a) => {
|
|
4056
|
-
const { origin: s, data: p } = a;
|
|
4057
|
-
s === "https://login.dingtalk.com" && (window.location.href = l({ loginTmpCode: p }));
|
|
4058
|
-
};
|
|
4059
|
-
this.iframe.src = n(), zt({ elId: this.elId, attrs: this.iframe }), typeof window.addEventListener < "u" ? window.addEventListener(
|
|
4060
|
-
"message",
|
|
4061
|
-
(a) => o(a),
|
|
4062
|
-
!1
|
|
4063
|
-
) : typeof window.attachEvent < "u" && window.attachEvent("onmessage", (a) => this.onScanSuccess(a));
|
|
4064
|
-
}
|
|
4065
|
-
}
|
|
4066
|
-
const Ko = {};
|
|
4067
|
-
function Wo() {
|
|
4068
|
-
return A(S.state.settings.sso || {}, Ko);
|
|
4069
|
-
}
|
|
4070
|
-
function Zo() {
|
|
4071
|
-
const e = Wo(), t = S.state.settings.activeSsoKey || "";
|
|
4072
|
-
console.log(e, t);
|
|
4073
|
-
const l = e[t];
|
|
4074
|
-
if (l !== void 0)
|
|
4075
|
-
return l();
|
|
4076
|
-
}
|
|
4077
|
-
const Qo = { id: "login" }, Xo = /* @__PURE__ */ _("h1", { id: "title" }, "登录", -1), Yo = { id: "form" }, ea = { class: "captcha" }, ta = ["src"], la = { class: "tips" }, na = { class: "sso" }, oa = /* @__PURE__ */ _("div", { id: "sso-qrcode" }, null, -1), aa = /* @__PURE__ */ q({
|
|
3990
|
+
}, vt = /* @__PURE__ */ I(Wo, [["__scopeId", "data-v-957442cd"]]), Zo = { id: "login" }, Qo = /* @__PURE__ */ _("h1", { id: "title" }, "登录", -1), Xo = { id: "form" }, Yo = { class: "captcha" }, ea = ["src"], ta = { class: "tips" }, la = { class: "sso" }, na = /* @__PURE__ */ _("div", { id: "sso-qrcode" }, null, -1), oa = /* @__PURE__ */ q({
|
|
4078
3991
|
__name: "login",
|
|
4079
3992
|
setup(e) {
|
|
4080
|
-
const t =
|
|
3993
|
+
const t = st(), l = pe(), o = j(() => w.state.settings.loginTips), n = j(() => (w.state.app, w.state.app.baseURL)), a = M(0), s = () => a.value++, r = j(() => u.value.username.length > 0 && u.value.password.length >= 4 && u.value.captcha.length === 4), u = M({
|
|
4081
3994
|
username: "",
|
|
4082
3995
|
password: "",
|
|
4083
3996
|
captcha: "",
|
|
4084
3997
|
sing: ""
|
|
4085
3998
|
}), d = () => {
|
|
4086
|
-
if (
|
|
4087
|
-
|
|
3999
|
+
if (u.value.username === "" || u.value.password === "" || u.value.captcha === "") {
|
|
4000
|
+
$l.error("用户名, 密码, 验证码是必须的");
|
|
4088
4001
|
return;
|
|
4089
4002
|
}
|
|
4090
|
-
|
|
4003
|
+
u.value.sing = Ll(`${u.value.username}${u.value.password}${u.value.captcha}`).toString(), w.dispatch("user/login", u.value).then((m) => {
|
|
4091
4004
|
var b;
|
|
4092
4005
|
t.push({ path: ((b = l.query) == null ? void 0 : b.redirect) || "/" });
|
|
4006
|
+
}).catch((m) => {
|
|
4007
|
+
a.value++;
|
|
4093
4008
|
});
|
|
4094
4009
|
};
|
|
4095
|
-
return
|
|
4096
|
-
|
|
4097
|
-
_("form",
|
|
4010
|
+
return (m, b) => (i(), h("div", Zo, [
|
|
4011
|
+
Qo,
|
|
4012
|
+
_("form", Xo, [
|
|
4098
4013
|
ie(_("input", {
|
|
4099
|
-
"onUpdate:modelValue": b[0] || (b[0] = (g) =>
|
|
4014
|
+
"onUpdate:modelValue": b[0] || (b[0] = (g) => S(u).username = g),
|
|
4100
4015
|
type: "text",
|
|
4101
4016
|
placeholder: "用户名",
|
|
4102
4017
|
class: "input"
|
|
4103
4018
|
}, null, 512), [
|
|
4104
|
-
[he,
|
|
4019
|
+
[he, S(u).username]
|
|
4105
4020
|
]),
|
|
4106
4021
|
ie(_("input", {
|
|
4107
|
-
"onUpdate:modelValue": b[1] || (b[1] = (g) =>
|
|
4022
|
+
"onUpdate:modelValue": b[1] || (b[1] = (g) => S(u).password = g),
|
|
4108
4023
|
type: "password",
|
|
4109
4024
|
placeholder: "密码",
|
|
4110
4025
|
class: "input"
|
|
4111
4026
|
}, null, 512), [
|
|
4112
|
-
[he,
|
|
4027
|
+
[he, S(u).password]
|
|
4113
4028
|
]),
|
|
4114
|
-
_("div",
|
|
4029
|
+
_("div", Yo, [
|
|
4115
4030
|
ie(_("input", {
|
|
4116
|
-
"onUpdate:modelValue": b[2] || (b[2] = (g) =>
|
|
4031
|
+
"onUpdate:modelValue": b[2] || (b[2] = (g) => S(u).captcha = g),
|
|
4117
4032
|
type: "text",
|
|
4118
4033
|
placeholder: "验证码",
|
|
4119
4034
|
class: "input-captcha"
|
|
4120
4035
|
}, null, 512), [
|
|
4121
|
-
[he,
|
|
4036
|
+
[he, S(u).captcha]
|
|
4122
4037
|
]),
|
|
4123
4038
|
_("img", {
|
|
4124
4039
|
class: "captcha-img",
|
|
4125
|
-
src:
|
|
4040
|
+
src: n.value + "/user/captcha?ts=" + S(a),
|
|
4126
4041
|
title: "点击刷新",
|
|
4127
4042
|
onClick: s
|
|
4128
|
-
}, null, 8,
|
|
4043
|
+
}, null, 8, ea)
|
|
4129
4044
|
]),
|
|
4130
4045
|
_("div", {
|
|
4131
|
-
class: H({ input: !0, button: !0, "no-ready": !
|
|
4046
|
+
class: H({ input: !0, button: !0, "no-ready": !r.value }),
|
|
4132
4047
|
onClick: d
|
|
4133
4048
|
}, "登录", 2),
|
|
4134
|
-
_("div",
|
|
4135
|
-
_("div", null,
|
|
4049
|
+
_("div", ta, [
|
|
4050
|
+
_("div", null, B(o.value), 1)
|
|
4136
4051
|
]),
|
|
4137
|
-
_("div",
|
|
4138
|
-
|
|
4139
|
-
(i(!0), h(E, null,
|
|
4052
|
+
_("div", la, [
|
|
4053
|
+
na,
|
|
4054
|
+
(i(!0), h(E, null, O(Object.keys([]), (g) => (i(), h("div", { key: g }, B(g), 1))), 128))
|
|
4140
4055
|
])
|
|
4141
4056
|
])
|
|
4142
4057
|
]));
|
|
4143
4058
|
}
|
|
4144
4059
|
});
|
|
4145
|
-
const
|
|
4060
|
+
const aa = {
|
|
4146
4061
|
name: "NotFoundPage"
|
|
4147
|
-
},
|
|
4062
|
+
}, gt = (e) => (Ke("data-v-26068803"), e = e(), We(), e), sa = { class: "not-found" }, ia = /* @__PURE__ */ gt(() => /* @__PURE__ */ _("svg", {
|
|
4148
4063
|
width: "380px",
|
|
4149
4064
|
height: "500px",
|
|
4150
4065
|
viewBox: "0 0 837 1045",
|
|
@@ -4197,7 +4112,7 @@ const sa = {
|
|
|
4197
4112
|
"sketch:type": "MSShapeGroup"
|
|
4198
4113
|
})
|
|
4199
4114
|
])
|
|
4200
|
-
], -1)),
|
|
4115
|
+
], -1)), ra = /* @__PURE__ */ gt(() => /* @__PURE__ */ _("div", { class: "message-box" }, [
|
|
4201
4116
|
/* @__PURE__ */ _("h1", null, "404"),
|
|
4202
4117
|
/* @__PURE__ */ _("p", null, "Page not found"),
|
|
4203
4118
|
/* @__PURE__ */ _("div", { class: "buttons-con" }, [
|
|
@@ -4208,17 +4123,17 @@ const sa = {
|
|
|
4208
4123
|
}, "Go to Home Page")
|
|
4209
4124
|
])
|
|
4210
4125
|
])
|
|
4211
|
-
], -1)),
|
|
4212
|
-
|
|
4213
|
-
|
|
4126
|
+
], -1)), ca = [
|
|
4127
|
+
ia,
|
|
4128
|
+
ra
|
|
4214
4129
|
];
|
|
4215
|
-
function
|
|
4216
|
-
return i(), h("div",
|
|
4130
|
+
function ua(e, t, l, o, n, a) {
|
|
4131
|
+
return i(), h("div", sa, ca);
|
|
4217
4132
|
}
|
|
4218
|
-
const
|
|
4133
|
+
const pa = /* @__PURE__ */ I(aa, [["render", ua], ["__scopeId", "data-v-26068803"]]), da = [
|
|
4219
4134
|
{
|
|
4220
4135
|
path: "/",
|
|
4221
|
-
component:
|
|
4136
|
+
component: vt,
|
|
4222
4137
|
redirect: "/dashboard",
|
|
4223
4138
|
name: "Root",
|
|
4224
4139
|
meta: {
|
|
@@ -4228,78 +4143,163 @@ const da = /* @__PURE__ */ I(sa, [["render", pa], ["__scopeId", "data-v-26068803
|
|
|
4228
4143
|
{
|
|
4229
4144
|
path: "dashboard",
|
|
4230
4145
|
name: "Dashboard",
|
|
4231
|
-
component:
|
|
4146
|
+
component: cn,
|
|
4232
4147
|
meta: { title: "Dashboard", icon: "el-icon-help", menuType: 2, keepAlive: !0 }
|
|
4233
4148
|
}
|
|
4234
4149
|
]
|
|
4235
4150
|
},
|
|
4236
4151
|
{
|
|
4237
4152
|
path: "/login",
|
|
4238
|
-
component:
|
|
4153
|
+
component: oa,
|
|
4239
4154
|
meta: { title: "用户登录", menuType: 0 },
|
|
4240
4155
|
hidden: !0
|
|
4241
4156
|
},
|
|
4242
4157
|
{
|
|
4243
4158
|
path: "/404",
|
|
4244
|
-
component:
|
|
4159
|
+
component: pa,
|
|
4245
4160
|
meta: { menuType: 0 },
|
|
4246
4161
|
hidden: !0
|
|
4247
4162
|
}
|
|
4248
|
-
], K =
|
|
4249
|
-
history:
|
|
4250
|
-
routes:
|
|
4163
|
+
], K = cl({
|
|
4164
|
+
history: ul(),
|
|
4165
|
+
routes: da
|
|
4251
4166
|
});
|
|
4252
4167
|
ke.configure({ showSpinner: !1 });
|
|
4253
|
-
function
|
|
4254
|
-
e.beforeEach((t, l,
|
|
4255
|
-
ke.start(), t.preHash = location.hash.replace("#", ""),
|
|
4168
|
+
function ma(e) {
|
|
4169
|
+
e.beforeEach((t, l, o) => {
|
|
4170
|
+
ke.start(), t.preHash = location.hash.replace("#", ""), o();
|
|
4256
4171
|
}), e.afterEach((t) => {
|
|
4257
|
-
t.matched.length > 0 &&
|
|
4172
|
+
t.matched.length > 0 && w.commit("user/updateState", {
|
|
4258
4173
|
key: "path",
|
|
4259
4174
|
value: t.matched[t.matched.length - 1].path.replace("(\\d+)", "")
|
|
4260
4175
|
}), ke.done();
|
|
4261
4176
|
});
|
|
4262
4177
|
}
|
|
4178
|
+
function fa() {
|
|
4179
|
+
return w.state.user.isLodeRemoteRoutes;
|
|
4180
|
+
}
|
|
4181
|
+
function kt() {
|
|
4182
|
+
return w.state.settings.whiteRoutes || [];
|
|
4183
|
+
}
|
|
4263
4184
|
function ha() {
|
|
4264
|
-
return
|
|
4185
|
+
return w.state.user.token;
|
|
4186
|
+
}
|
|
4187
|
+
class wt {
|
|
4188
|
+
constructor() {
|
|
4189
|
+
R(this, "type", "qrcode");
|
|
4190
|
+
}
|
|
4191
|
+
flag() {
|
|
4192
|
+
}
|
|
4193
|
+
jumpToLoginPage(t, l) {
|
|
4194
|
+
t(l);
|
|
4195
|
+
}
|
|
4196
|
+
showQrCode() {
|
|
4197
|
+
}
|
|
4198
|
+
}
|
|
4199
|
+
class Ei extends wt {
|
|
4200
|
+
constructor(l) {
|
|
4201
|
+
super();
|
|
4202
|
+
R(this, "type", "jump");
|
|
4203
|
+
R(this, "client_id", "");
|
|
4204
|
+
this.client_id = l.client_id;
|
|
4205
|
+
}
|
|
4206
|
+
flag() {
|
|
4207
|
+
const l = et("code");
|
|
4208
|
+
if (l)
|
|
4209
|
+
return {
|
|
4210
|
+
ticket: l,
|
|
4211
|
+
key: "github"
|
|
4212
|
+
};
|
|
4213
|
+
}
|
|
4214
|
+
jumpToLoginPage(l, o) {
|
|
4215
|
+
const n = encodeURIComponent(location.href);
|
|
4216
|
+
location.replace(`https://github.com/login/oauth/authorize?client_id=${this.client_id}&redirect_uri${n}`);
|
|
4217
|
+
}
|
|
4218
|
+
}
|
|
4219
|
+
class $i extends wt {
|
|
4220
|
+
constructor(l) {
|
|
4221
|
+
super();
|
|
4222
|
+
R(this, "type", "qrcode");
|
|
4223
|
+
R(this, "qrCodeUrl", "https://login.dingtalk.com/login/qrcode.htm?goto={goto}&style={style}");
|
|
4224
|
+
R(this, "reloadUrl", "https://oapi.dingtalk.com/connect/oauth2/sns_authorize?response_type=code&scope=snsapi_login&state=&appid={appid}&redirect_uri={redirect_uri}");
|
|
4225
|
+
R(this, "elId", "");
|
|
4226
|
+
R(this, "appid", "");
|
|
4227
|
+
R(this, "iframe", new HTMLIFrameElement());
|
|
4228
|
+
R(this, "redirectUri", "");
|
|
4229
|
+
R(this, "style", "");
|
|
4230
|
+
}
|
|
4231
|
+
flag() {
|
|
4232
|
+
const l = et("code");
|
|
4233
|
+
if (l)
|
|
4234
|
+
return {
|
|
4235
|
+
ticket: l,
|
|
4236
|
+
key: "dingtalk"
|
|
4237
|
+
};
|
|
4238
|
+
}
|
|
4239
|
+
showQrCode() {
|
|
4240
|
+
const l = (a) => {
|
|
4241
|
+
const s = {
|
|
4242
|
+
appid: this.appid,
|
|
4243
|
+
redirect_uri: encodeURIComponent(this.redirectUri)
|
|
4244
|
+
};
|
|
4245
|
+
return Q(this.reloadUrl, s) + "&" + Xt(a || {});
|
|
4246
|
+
}, o = () => {
|
|
4247
|
+
const a = {
|
|
4248
|
+
goto: encodeURIComponent(l()),
|
|
4249
|
+
style: encodeURIComponent(this.style)
|
|
4250
|
+
};
|
|
4251
|
+
return Q(this.qrCodeUrl, a);
|
|
4252
|
+
}, n = (a) => {
|
|
4253
|
+
const { origin: s, data: r } = a;
|
|
4254
|
+
s === "https://login.dingtalk.com" && (window.location.href = l({ loginTmpCode: r }));
|
|
4255
|
+
};
|
|
4256
|
+
this.iframe.src = o(), Qt({ elId: this.elId, attrs: this.iframe }), typeof window.addEventListener < "u" ? window.addEventListener(
|
|
4257
|
+
"message",
|
|
4258
|
+
(a) => n(a),
|
|
4259
|
+
!1
|
|
4260
|
+
) : typeof window.attachEvent < "u" && window.attachEvent("onmessage", (a) => this.onScanSuccess(a));
|
|
4261
|
+
}
|
|
4265
4262
|
}
|
|
4266
|
-
|
|
4267
|
-
|
|
4263
|
+
const ba = {};
|
|
4264
|
+
function _a() {
|
|
4265
|
+
return A(w.state.settings.sso || {}, ba);
|
|
4268
4266
|
}
|
|
4269
|
-
function
|
|
4270
|
-
|
|
4267
|
+
function ya() {
|
|
4268
|
+
const e = _a(), t = w.state.settings.activeSsoKey || "", l = e[t];
|
|
4269
|
+
if (l !== void 0)
|
|
4270
|
+
return l();
|
|
4271
4271
|
}
|
|
4272
|
-
function
|
|
4273
|
-
e.beforeEach(async (t, l,
|
|
4274
|
-
var
|
|
4275
|
-
if (
|
|
4276
|
-
|
|
4272
|
+
function va(e) {
|
|
4273
|
+
e.beforeEach(async (t, l, o) => {
|
|
4274
|
+
var u, d;
|
|
4275
|
+
if (kt().indexOf(t.path) !== -1) {
|
|
4276
|
+
o();
|
|
4277
4277
|
return;
|
|
4278
4278
|
}
|
|
4279
|
-
if (
|
|
4280
|
-
(
|
|
4279
|
+
if (ha()) {
|
|
4280
|
+
(u = t.query) != null && u.redirect ? o((d = t.query) == null ? void 0 : d.redirect) : o();
|
|
4281
4281
|
return;
|
|
4282
4282
|
}
|
|
4283
|
-
const a = t.query.redirect || t.path, s =
|
|
4283
|
+
const a = t.query.redirect || t.path, s = ya();
|
|
4284
4284
|
if (!s) {
|
|
4285
|
-
|
|
4285
|
+
o(`/login?redirect=${a}`);
|
|
4286
4286
|
return;
|
|
4287
4287
|
}
|
|
4288
|
-
const
|
|
4289
|
-
if (
|
|
4290
|
-
|
|
4288
|
+
const r = s.flag();
|
|
4289
|
+
if (r && await w.dispatch("user/login", tl(r) ? r : { ticket: r })) {
|
|
4290
|
+
o();
|
|
4291
4291
|
return;
|
|
4292
4292
|
}
|
|
4293
|
-
s.jumpToLoginPage(
|
|
4293
|
+
s.jumpToLoginPage(o, `/login?redirect=${a}`);
|
|
4294
4294
|
});
|
|
4295
4295
|
}
|
|
4296
|
-
const
|
|
4297
|
-
|
|
4296
|
+
const ga = {}, ka = { class: "loading preloader" }, wa = /* @__PURE__ */ _("div", { class: "preloader-inner" }, null, -1), Sa = [
|
|
4297
|
+
wa
|
|
4298
4298
|
];
|
|
4299
|
-
function
|
|
4300
|
-
return i(), h("div",
|
|
4299
|
+
function xa(e, t) {
|
|
4300
|
+
return i(), h("div", ka, Sa);
|
|
4301
4301
|
}
|
|
4302
|
-
const
|
|
4302
|
+
const St = /* @__PURE__ */ I(ga, [["render", xa]]), Ea = {
|
|
4303
4303
|
name: "VNotice",
|
|
4304
4304
|
props: {
|
|
4305
4305
|
dataApi: {
|
|
@@ -4319,7 +4319,7 @@ const gt = /* @__PURE__ */ I(ya, [["render", wa]]), Sa = {
|
|
|
4319
4319
|
};
|
|
4320
4320
|
},
|
|
4321
4321
|
mounted() {
|
|
4322
|
-
if (
|
|
4322
|
+
if (this.$props.dataApi, this.$props.dataApi) {
|
|
4323
4323
|
this.$http.get(this.$props.dataApi).then(({ data: e }) => {
|
|
4324
4324
|
this.noticeProps = e, this.hasNotice = !!e;
|
|
4325
4325
|
});
|
|
@@ -4328,14 +4328,14 @@ const gt = /* @__PURE__ */ I(ya, [["render", wa]]), Sa = {
|
|
|
4328
4328
|
this.hasNotice = Object.keys(this.$props.notice).length > 0, this.noticeProps = this.$props.notice;
|
|
4329
4329
|
}
|
|
4330
4330
|
};
|
|
4331
|
-
function
|
|
4332
|
-
const s =
|
|
4331
|
+
function $a(e, t, l, o, n, a) {
|
|
4332
|
+
const s = Oe;
|
|
4333
4333
|
return i(), h("div", null, [
|
|
4334
|
-
|
|
4334
|
+
n.hasNotice ? (i(), f(s, G(F({ key: 0 }, n.noticeProps)), null, 16)) : $("", !0)
|
|
4335
4335
|
]);
|
|
4336
4336
|
}
|
|
4337
|
-
const
|
|
4338
|
-
components: { VLoading:
|
|
4337
|
+
const xt = /* @__PURE__ */ I(Ea, [["render", $a]]), Ia = q({
|
|
4338
|
+
components: { VLoading: St, VNotice: xt },
|
|
4339
4339
|
props: {
|
|
4340
4340
|
schemaHandler: {
|
|
4341
4341
|
type: Function,
|
|
@@ -4368,19 +4368,19 @@ const kt = /* @__PURE__ */ I(Sa, [["render", xa]]), Ea = q({
|
|
|
4368
4368
|
}
|
|
4369
4369
|
},
|
|
4370
4370
|
beforeCreate() {
|
|
4371
|
-
const e = this.$route.path.split("/").filter((
|
|
4372
|
-
this.$http.get(this.$props.schemaApi || l,
|
|
4373
|
-
this.loading = !1, X(
|
|
4374
|
-
title:
|
|
4375
|
-
} : X(
|
|
4371
|
+
const e = this.$route.path.split("/").filter((n) => n), t = e.length > 1 ? e.slice(0, e.length - 1).join("/") : e[0], l = "/schema" + this.$route.meta.path, o = { params: this.$route.params };
|
|
4372
|
+
this.$http.get(this.$props.schemaApi || l, o).then(({ data: n }) => {
|
|
4373
|
+
this.loading = !1, X(n) && (n.notice !== void 0 && (this.haveNotice = !0, $e(n.notice) ? this.notice = {
|
|
4374
|
+
title: n.notice
|
|
4375
|
+
} : X(n.notice) && (this.notice = n.notice, this.noticeApi = n.notice.noticeApi), delete n.notice), this.owners = n.ownerNames || [], this.serviceOffLine = n.serviceOffLine || !1), this.schema = this.$props.schemaHandler(n, t), w.commit("app/SET_PAGE_JSON_SCHEMA", { page: this.$route.path, json: this.schema });
|
|
4376
4376
|
});
|
|
4377
4377
|
}
|
|
4378
4378
|
});
|
|
4379
|
-
const
|
|
4380
|
-
function
|
|
4381
|
-
const s =
|
|
4379
|
+
const Ca = ["innerHTML"];
|
|
4380
|
+
function Ta(e, t, l, o, n, a) {
|
|
4381
|
+
const s = Oe, r = xt, u = St;
|
|
4382
4382
|
return i(), h(E, null, [
|
|
4383
|
-
e.owners.length > 0 ? (i(),
|
|
4383
|
+
e.owners.length > 0 ? (i(), f(s, {
|
|
4384
4384
|
key: 0,
|
|
4385
4385
|
title: `该页面功能对应开发: [ ${e.owners.join(", ")} ] 有问题可直接企微反馈`,
|
|
4386
4386
|
type: "info",
|
|
@@ -4391,21 +4391,21 @@ function Ia(e, t, l, n, o, a) {
|
|
|
4391
4391
|
key: 1,
|
|
4392
4392
|
class: "offline-notice",
|
|
4393
4393
|
innerHTML: e.serviceOffLine === !0 ? e.setting.serviceOffLineNotice : e.serviceOffLine
|
|
4394
|
-
}, null, 8,
|
|
4395
|
-
e.haveNotice ? (i(),
|
|
4394
|
+
}, null, 8, Ca)) : (i(), h(E, { key: 2 }, [
|
|
4395
|
+
e.haveNotice ? (i(), f(r, {
|
|
4396
4396
|
key: 0,
|
|
4397
4397
|
notice: e.notice,
|
|
4398
4398
|
style: { margin: "0 0 20px 0" },
|
|
4399
4399
|
"data-api": e.noticeApi
|
|
4400
4400
|
}, null, 8, ["notice", "data-api"])) : $("", !0),
|
|
4401
|
-
e.loading ? (i(),
|
|
4401
|
+
e.loading ? (i(), f(u, { key: 1 })) : le(e.$slots, "default", G(F({ key: 2 }, e.schema)), void 0, !0)
|
|
4402
4402
|
], 64))
|
|
4403
4403
|
], 64);
|
|
4404
4404
|
}
|
|
4405
|
-
const se = /* @__PURE__ */ I(
|
|
4405
|
+
const se = /* @__PURE__ */ I(Ia, [["render", Ta], ["__scopeId", "data-v-4965a709"]]), Et = {
|
|
4406
4406
|
__name: "table",
|
|
4407
4407
|
setup(e) {
|
|
4408
|
-
const t = (l,
|
|
4408
|
+
const t = (l, o) => {
|
|
4409
4409
|
if (l.orderBy) {
|
|
4410
4410
|
const a = {
|
|
4411
4411
|
prop: l.orderBy.field,
|
|
@@ -4413,14 +4413,14 @@ const se = /* @__PURE__ */ I(Ea, [["render", Ia], ["__scopeId", "data-v-4965a709
|
|
|
4413
4413
|
};
|
|
4414
4414
|
l.tableProps = A(l.tableProps, { defaultSort: a });
|
|
4415
4415
|
}
|
|
4416
|
-
const
|
|
4416
|
+
const n = Object.keys(oe.props);
|
|
4417
4417
|
return Object.keys(l).forEach((a) => {
|
|
4418
|
-
|
|
4419
|
-
}), l.listApi === void 0 && (l.listApi = `/${
|
|
4418
|
+
n.indexOf(a) === -1 && delete l[a];
|
|
4419
|
+
}), l.listApi === void 0 && (l.listApi = `/${o}/list`), l;
|
|
4420
4420
|
};
|
|
4421
|
-
return (l,
|
|
4422
|
-
default:
|
|
4423
|
-
|
|
4421
|
+
return (l, o) => (i(), f(se, { "schema-handler": t }, {
|
|
4422
|
+
default: c((n) => [
|
|
4423
|
+
p(S(oe), G(Y(n)), null, 16)
|
|
4424
4424
|
]),
|
|
4425
4425
|
_: 1
|
|
4426
4426
|
}));
|
|
@@ -4428,29 +4428,56 @@ const se = /* @__PURE__ */ I(Ea, [["render", Ia], ["__scopeId", "data-v-4965a709
|
|
|
4428
4428
|
}, xe = {
|
|
4429
4429
|
__name: "form",
|
|
4430
4430
|
setup(e) {
|
|
4431
|
-
const t = pe(), l = (
|
|
4432
|
-
const
|
|
4433
|
-
return Object.keys(
|
|
4434
|
-
if (
|
|
4435
|
-
delete
|
|
4431
|
+
const t = pe(), l = st(), o = (r, u) => {
|
|
4432
|
+
const d = Object.keys(z.props);
|
|
4433
|
+
return Object.keys(r).forEach((m) => {
|
|
4434
|
+
if (d.indexOf(m) === -1) {
|
|
4435
|
+
delete r[m];
|
|
4436
4436
|
return;
|
|
4437
4437
|
}
|
|
4438
|
-
/.*Api$/.test(
|
|
4439
|
-
}),
|
|
4440
|
-
saveApi:
|
|
4438
|
+
/.*Api$/.test(m) && (r[m] = Q(r[m], t.params));
|
|
4439
|
+
}), r.saveApi === void 0 && (t.params.id !== void 0 ? (r.saveApi = `/${u}/update/${t.params.id}`, r.getApi || (r.getApi = `/${u}/get/${t.params.id}`)) : (delete r.getApi, r.saveApi = `/${u}/create`)), r = A({
|
|
4440
|
+
saveApi: u + "/save",
|
|
4441
4441
|
afterSubmit: "goback",
|
|
4442
4442
|
afterReset: "goback",
|
|
4443
4443
|
mod: t.params.id ? "edit" : "create"
|
|
4444
|
-
},
|
|
4444
|
+
}, r), r;
|
|
4445
|
+
}, n = M(0), a = () => {
|
|
4446
|
+
Tt.request({
|
|
4447
|
+
url: "/form_mutex",
|
|
4448
|
+
method: "get",
|
|
4449
|
+
params: {
|
|
4450
|
+
path: t.fullPath
|
|
4451
|
+
}
|
|
4452
|
+
}).then((r) => {
|
|
4453
|
+
r.data && (clearInterval(n.value), at.alert(`${r.data}`, "操作提醒", {
|
|
4454
|
+
showClose: !1,
|
|
4455
|
+
showCancelButton: !0,
|
|
4456
|
+
confirmButtonText: "返回",
|
|
4457
|
+
cancelButtonText: "刷新",
|
|
4458
|
+
callback: (u) => {
|
|
4459
|
+
u === "cancel" ? location.reload() : s();
|
|
4460
|
+
}
|
|
4461
|
+
}));
|
|
4462
|
+
});
|
|
4445
4463
|
};
|
|
4446
|
-
|
|
4447
|
-
|
|
4448
|
-
|
|
4464
|
+
Qe(() => {
|
|
4465
|
+
t.params.id !== void 0 && w.state.settings.formMutex && (a(), n.value = setInterval(a, 2e3));
|
|
4466
|
+
}), Nt(() => {
|
|
4467
|
+
clearInterval(n.value);
|
|
4468
|
+
});
|
|
4469
|
+
function s() {
|
|
4470
|
+
var r, u;
|
|
4471
|
+
(r = t.query) != null && r.goback ? l.push((u = t.query) == null ? void 0 : u.goback) : history.state.back && history.back();
|
|
4472
|
+
}
|
|
4473
|
+
return (r, u) => (i(), f(se, { "schema-handler": o }, {
|
|
4474
|
+
default: c((d) => [
|
|
4475
|
+
p(S(z), G(Y(d)), null, 16)
|
|
4449
4476
|
]),
|
|
4450
4477
|
_: 1
|
|
4451
4478
|
}));
|
|
4452
4479
|
}
|
|
4453
|
-
},
|
|
4480
|
+
}, Ba = q({
|
|
4454
4481
|
name: "VTree",
|
|
4455
4482
|
components: {
|
|
4456
4483
|
VForm: z
|
|
@@ -4548,10 +4575,10 @@ const se = /* @__PURE__ */ I(Ea, [["render", Ia], ["__scopeId", "data-v-4965a709
|
|
|
4548
4575
|
this.type = 2, this.formData = e, this.formkey++;
|
|
4549
4576
|
},
|
|
4550
4577
|
append(e, t) {
|
|
4551
|
-
var
|
|
4578
|
+
var o, n;
|
|
4552
4579
|
this.type = 1;
|
|
4553
|
-
const l = { pid: e.id, [((
|
|
4554
|
-
|
|
4580
|
+
const l = { pid: e.id, [((o = this.$props.props) == null ? void 0 : o.levelKey) ?? "level"]: t.level + 1, ...Yt((n = this.$props.props) == null ? void 0 : n.effectData, e) };
|
|
4581
|
+
e.children || (e.children = []), this.formData = l, this.formkey++, e.children.push(l), this.treeData = [...this.treeData];
|
|
4555
4582
|
},
|
|
4556
4583
|
canAppend(e, t) {
|
|
4557
4584
|
return e[this.localTreeProps.props.label] ? t.level < this.$props.maxDepth : !1;
|
|
@@ -4579,53 +4606,53 @@ const se = /* @__PURE__ */ I(Ea, [["render", Ia], ["__scopeId", "data-v-4965a709
|
|
|
4579
4606
|
return !0;
|
|
4580
4607
|
},
|
|
4581
4608
|
allowDrop(e, t, l) {
|
|
4582
|
-
return
|
|
4609
|
+
return l === "inner";
|
|
4583
4610
|
},
|
|
4584
|
-
handleDragEnd(e, t, l,
|
|
4585
|
-
const
|
|
4586
|
-
|
|
4611
|
+
handleDragEnd(e, t, l, o) {
|
|
4612
|
+
const n = e.data;
|
|
4613
|
+
n.pid = t.data.id, this.$http.request({
|
|
4587
4614
|
method: "POST",
|
|
4588
|
-
url: Q(this.$props.saveApi,
|
|
4589
|
-
data:
|
|
4615
|
+
url: Q(this.$props.saveApi, n),
|
|
4616
|
+
data: n
|
|
4590
4617
|
}).then(({ code: a }) => {
|
|
4591
4618
|
a !== 0 && this.$message.error("操作失败");
|
|
4592
4619
|
});
|
|
4593
4620
|
}
|
|
4594
4621
|
}
|
|
4595
4622
|
});
|
|
4596
|
-
const
|
|
4623
|
+
const Oa = { class: "card-header" }, Aa = /* @__PURE__ */ _("span", null, "列表", -1), Pa = { class: "tree-action" }, Ra = { key: 0 }, La = {
|
|
4597
4624
|
key: 1,
|
|
4598
4625
|
style: { color: "#E6A23C" }
|
|
4599
|
-
},
|
|
4600
|
-
function
|
|
4601
|
-
const s = ue,
|
|
4602
|
-
return i(),
|
|
4626
|
+
}, Ma = { class: "card-header" };
|
|
4627
|
+
function ja(e, t, l, o, n, a) {
|
|
4628
|
+
const s = ue, r = Il, u = Ae, d = de, m = v("v-form"), b = ae;
|
|
4629
|
+
return i(), f(b, {
|
|
4603
4630
|
class: "tree-box",
|
|
4604
4631
|
gutter: 20
|
|
4605
4632
|
}, {
|
|
4606
|
-
default:
|
|
4607
|
-
|
|
4633
|
+
default: c(() => [
|
|
4634
|
+
p(d, {
|
|
4608
4635
|
span: 8,
|
|
4609
4636
|
class: "tree-tree"
|
|
4610
4637
|
}, {
|
|
4611
|
-
default:
|
|
4612
|
-
u
|
|
4613
|
-
header:
|
|
4614
|
-
_("div",
|
|
4615
|
-
|
|
4616
|
-
|
|
4638
|
+
default: c(() => [
|
|
4639
|
+
p(u, { shadow: "never" }, {
|
|
4640
|
+
header: c(() => [
|
|
4641
|
+
_("div", Oa, [
|
|
4642
|
+
Aa,
|
|
4643
|
+
p(s, {
|
|
4617
4644
|
type: "text",
|
|
4618
4645
|
onClick: t[0] || (t[0] = () => e.appendNew())
|
|
4619
4646
|
}, {
|
|
4620
|
-
default:
|
|
4647
|
+
default: c(() => [
|
|
4621
4648
|
k("添加")
|
|
4622
4649
|
]),
|
|
4623
4650
|
_: 1
|
|
4624
4651
|
})
|
|
4625
4652
|
])
|
|
4626
4653
|
]),
|
|
4627
|
-
default:
|
|
4628
|
-
(e.treeData || []).length > 0 ? (i(),
|
|
4654
|
+
default: c(() => [
|
|
4655
|
+
(e.treeData || []).length > 0 ? (i(), f(r, F({
|
|
4629
4656
|
key: 0,
|
|
4630
4657
|
style: { height: "100vh" },
|
|
4631
4658
|
data: e.treeData,
|
|
@@ -4636,39 +4663,39 @@ function La(e, t, l, n, o, a) {
|
|
|
4636
4663
|
"allow-drop": e.allowDrop,
|
|
4637
4664
|
onNodeDragEnd: e.handleDragEnd
|
|
4638
4665
|
}), {
|
|
4639
|
-
default:
|
|
4640
|
-
_("span",
|
|
4641
|
-
x[e.localTreeProps.props.label] ? (i(), h("span",
|
|
4666
|
+
default: c(({ node: g, data: x }) => [
|
|
4667
|
+
_("span", Pa, [
|
|
4668
|
+
x[e.localTreeProps.props.label] ? (i(), h("span", Ra, B(x[e.localTreeProps.props.label]), 1)) : (i(), h("span", La, "请在右侧表单中修改 --> ")),
|
|
4642
4669
|
_("span", null, [
|
|
4643
|
-
x[e.localTreeProps.props.label] ? (i(),
|
|
4670
|
+
x[e.localTreeProps.props.label] ? (i(), f(s, {
|
|
4644
4671
|
key: 0,
|
|
4645
4672
|
class: "button",
|
|
4646
4673
|
type: "text",
|
|
4647
4674
|
onClick: () => e.onclick(x)
|
|
4648
4675
|
}, {
|
|
4649
|
-
default:
|
|
4676
|
+
default: c(() => [
|
|
4650
4677
|
k("编辑")
|
|
4651
4678
|
]),
|
|
4652
4679
|
_: 2
|
|
4653
4680
|
}, 1032, ["onClick"])) : $("", !0),
|
|
4654
|
-
e.canAppend(x, g) ? (i(),
|
|
4681
|
+
e.canAppend(x, g) ? (i(), f(s, {
|
|
4655
4682
|
key: 1,
|
|
4656
4683
|
class: "button",
|
|
4657
4684
|
type: "text",
|
|
4658
4685
|
onClick: () => e.append(x, g)
|
|
4659
4686
|
}, {
|
|
4660
|
-
default:
|
|
4687
|
+
default: c(() => [
|
|
4661
4688
|
k("添加")
|
|
4662
4689
|
]),
|
|
4663
4690
|
_: 2
|
|
4664
4691
|
}, 1032, ["onClick"])) : $("", !0),
|
|
4665
|
-
x.children === void 0 || x.children.length === 0 ? (i(),
|
|
4692
|
+
x.children === void 0 || x.children.length === 0 ? (i(), f(s, {
|
|
4666
4693
|
key: 2,
|
|
4667
4694
|
class: "button",
|
|
4668
4695
|
type: "text",
|
|
4669
4696
|
onClick: () => e.remove(x)
|
|
4670
4697
|
}, {
|
|
4671
|
-
default:
|
|
4698
|
+
default: c(() => [
|
|
4672
4699
|
k("删除")
|
|
4673
4700
|
]),
|
|
4674
4701
|
_: 2
|
|
@@ -4684,22 +4711,22 @@ function La(e, t, l, n, o, a) {
|
|
|
4684
4711
|
]),
|
|
4685
4712
|
_: 1
|
|
4686
4713
|
}),
|
|
4687
|
-
|
|
4714
|
+
p(d, {
|
|
4688
4715
|
span: 16,
|
|
4689
4716
|
class: "tree-form"
|
|
4690
4717
|
}, {
|
|
4691
|
-
default:
|
|
4692
|
-
e.type ? (i(),
|
|
4718
|
+
default: c(() => [
|
|
4719
|
+
e.type ? (i(), f(u, {
|
|
4693
4720
|
key: 0,
|
|
4694
4721
|
shadow: "never"
|
|
4695
4722
|
}, {
|
|
4696
|
-
header:
|
|
4697
|
-
_("div",
|
|
4698
|
-
_("span", null,
|
|
4723
|
+
header: c(() => [
|
|
4724
|
+
_("div", Ma, [
|
|
4725
|
+
_("span", null, B(e.formType), 1)
|
|
4699
4726
|
])
|
|
4700
4727
|
]),
|
|
4701
|
-
default:
|
|
4702
|
-
(i(), m
|
|
4728
|
+
default: c(() => [
|
|
4729
|
+
(i(), f(m, F({
|
|
4703
4730
|
key: e.formkey,
|
|
4704
4731
|
modelValue: e.formData,
|
|
4705
4732
|
"onUpdate:modelValue": t[1] || (t[1] = (g) => e.formData = g)
|
|
@@ -4714,18 +4741,18 @@ function La(e, t, l, n, o, a) {
|
|
|
4714
4741
|
_: 1
|
|
4715
4742
|
});
|
|
4716
4743
|
}
|
|
4717
|
-
const Fe = /* @__PURE__ */ I(
|
|
4744
|
+
const Fe = /* @__PURE__ */ I(Ba, [["render", ja]]), Da = {
|
|
4718
4745
|
__name: "tree",
|
|
4719
4746
|
setup(e) {
|
|
4720
|
-
const t = (l,
|
|
4721
|
-
const
|
|
4747
|
+
const t = (l, o) => {
|
|
4748
|
+
const n = Object.keys(Fe.props);
|
|
4722
4749
|
return Object.keys(l).forEach((a) => {
|
|
4723
|
-
|
|
4750
|
+
n.indexOf(a) === -1 && delete l[a];
|
|
4724
4751
|
}), l;
|
|
4725
4752
|
};
|
|
4726
|
-
return (l,
|
|
4727
|
-
default:
|
|
4728
|
-
|
|
4753
|
+
return (l, o) => (i(), f(se, { "schema-handler": t }, {
|
|
4754
|
+
default: c((n) => [
|
|
4755
|
+
p(Fe, G(Y(n)), null, 16)
|
|
4729
4756
|
]),
|
|
4730
4757
|
_: 1
|
|
4731
4758
|
}));
|
|
@@ -4734,14 +4761,14 @@ const Fe = /* @__PURE__ */ I(Ca, [["render", La]]), Ma = {
|
|
|
4734
4761
|
__name: "container",
|
|
4735
4762
|
setup(e) {
|
|
4736
4763
|
const t = M(0);
|
|
4737
|
-
return
|
|
4764
|
+
return pl(() => {
|
|
4738
4765
|
t.value++;
|
|
4739
|
-
}), (l,
|
|
4740
|
-
const
|
|
4741
|
-
return i(),
|
|
4766
|
+
}), (l, o) => {
|
|
4767
|
+
const n = v("router-view");
|
|
4768
|
+
return i(), f(n);
|
|
4742
4769
|
};
|
|
4743
4770
|
}
|
|
4744
|
-
},
|
|
4771
|
+
}, Na = {
|
|
4745
4772
|
title: {
|
|
4746
4773
|
text: ""
|
|
4747
4774
|
},
|
|
@@ -4770,34 +4797,34 @@ const Fe = /* @__PURE__ */ I(Ca, [["render", La]]), Ma = {
|
|
|
4770
4797
|
},
|
|
4771
4798
|
series: []
|
|
4772
4799
|
};
|
|
4773
|
-
function
|
|
4800
|
+
function Va(e, t, l) {
|
|
4774
4801
|
if (l.length === 0)
|
|
4775
4802
|
return {};
|
|
4776
|
-
let
|
|
4777
|
-
if (
|
|
4778
|
-
const
|
|
4779
|
-
let s = a[0],
|
|
4803
|
+
let o = A({}, Na);
|
|
4804
|
+
if (o.title.text = e, $e(t)) {
|
|
4805
|
+
const n = [], a = Object.keys(l[0]);
|
|
4806
|
+
let s = a[0], r = a.filter((d, m) => m > 0), u = t;
|
|
4780
4807
|
if (t.indexOf(":") > -1) {
|
|
4781
|
-
const d = t.split(":"),
|
|
4782
|
-
|
|
4808
|
+
const d = t.split(":"), m = d[1].split(",");
|
|
4809
|
+
u = d[0], s = m[0], r = m.filter((b, g) => g > 0);
|
|
4783
4810
|
}
|
|
4784
|
-
|
|
4785
|
-
const
|
|
4811
|
+
r.forEach((d) => {
|
|
4812
|
+
const m = [];
|
|
4786
4813
|
l.forEach((b) => {
|
|
4787
|
-
|
|
4788
|
-
}),
|
|
4814
|
+
m.push(b[d]);
|
|
4815
|
+
}), o.series.push({
|
|
4789
4816
|
name: d,
|
|
4790
|
-
type:
|
|
4817
|
+
type: u,
|
|
4791
4818
|
smooth: !0,
|
|
4792
|
-
data:
|
|
4793
|
-
}),
|
|
4819
|
+
data: m
|
|
4820
|
+
}), o.legend.data.push(d);
|
|
4794
4821
|
}), l.forEach((d) => {
|
|
4795
|
-
|
|
4796
|
-
}),
|
|
4822
|
+
n.push(d[s]);
|
|
4823
|
+
}), o.xAxis.data = n;
|
|
4797
4824
|
}
|
|
4798
|
-
return X(t) && (
|
|
4825
|
+
return X(t) && (o = A(o, t)), o;
|
|
4799
4826
|
}
|
|
4800
|
-
const
|
|
4827
|
+
const qa = q({
|
|
4801
4828
|
name: "NumberPanel",
|
|
4802
4829
|
props: {
|
|
4803
4830
|
dataList: {
|
|
@@ -4808,27 +4835,27 @@ const Na = q({
|
|
|
4808
4835
|
data() {
|
|
4809
4836
|
return {};
|
|
4810
4837
|
}
|
|
4811
|
-
}),
|
|
4812
|
-
function
|
|
4813
|
-
return i(!0), h(E, null,
|
|
4814
|
-
_("div",
|
|
4815
|
-
(i(!0), h(E, null,
|
|
4838
|
+
}), Ua = { class: "number-panel-title" }, Ha = { class: "number" }, Fa = { class: "name" };
|
|
4839
|
+
function Ga(e, t, l, o, n, a) {
|
|
4840
|
+
return i(!0), h(E, null, O(e.dataList, (s, r) => (i(), h("span", { key: r }, [
|
|
4841
|
+
_("div", Ua, [
|
|
4842
|
+
(i(!0), h(E, null, O(Object.keys(s), (u, d) => (i(), h("div", {
|
|
4816
4843
|
key: d,
|
|
4817
4844
|
class: "title-inner"
|
|
4818
4845
|
}, [
|
|
4819
|
-
_("p",
|
|
4820
|
-
_("p",
|
|
4846
|
+
_("p", Ha, B(s[u]), 1),
|
|
4847
|
+
_("p", Fa, B(u), 1)
|
|
4821
4848
|
]))), 128))
|
|
4822
4849
|
])
|
|
4823
4850
|
]))), 128);
|
|
4824
4851
|
}
|
|
4825
|
-
const
|
|
4852
|
+
const Ja = /* @__PURE__ */ I(qa, [["render", Ga], ["__scopeId", "data-v-cc0d8293"]]), za = {
|
|
4826
4853
|
components: {
|
|
4827
|
-
Chart:
|
|
4828
|
-
Md:
|
|
4854
|
+
Chart: Tl,
|
|
4855
|
+
Md: Rl,
|
|
4829
4856
|
Json: Re,
|
|
4830
4857
|
Table: oe,
|
|
4831
|
-
Number:
|
|
4858
|
+
Number: Ja,
|
|
4832
4859
|
Html: ""
|
|
4833
4860
|
},
|
|
4834
4861
|
props: {
|
|
@@ -4841,29 +4868,29 @@ const Fa = /* @__PURE__ */ I(Na, [["render", Ha], ["__scopeId", "data-v-cc0d8293
|
|
|
4841
4868
|
setup(e) {
|
|
4842
4869
|
const t = () => e.option.chart === "num" ? "number" : e.option.type;
|
|
4843
4870
|
return {
|
|
4844
|
-
compprops: (
|
|
4845
|
-
const
|
|
4846
|
-
if (
|
|
4871
|
+
compprops: (o) => {
|
|
4872
|
+
const n = t();
|
|
4873
|
+
if (n === "number")
|
|
4847
4874
|
return {
|
|
4848
|
-
dataList:
|
|
4875
|
+
dataList: o.data
|
|
4849
4876
|
};
|
|
4850
|
-
if (
|
|
4877
|
+
if (n === "chart")
|
|
4851
4878
|
return {
|
|
4852
|
-
options:
|
|
4879
|
+
options: Va(o.id, o.chart, o.data)
|
|
4853
4880
|
};
|
|
4854
|
-
if (
|
|
4881
|
+
if (n === "md")
|
|
4855
4882
|
return {
|
|
4856
|
-
source:
|
|
4883
|
+
source: o.data
|
|
4857
4884
|
};
|
|
4858
|
-
if (
|
|
4859
|
-
if (!
|
|
4885
|
+
if (n === "table") {
|
|
4886
|
+
if (!tt(o.data))
|
|
4860
4887
|
return { showPagination: !1 };
|
|
4861
4888
|
const a = [];
|
|
4862
|
-
return
|
|
4889
|
+
return o.data[0] && Object.keys(o.data[0]).forEach((s, r) => {
|
|
4863
4890
|
a.push({ field: s, label: s });
|
|
4864
4891
|
}), {
|
|
4865
4892
|
headers: a,
|
|
4866
|
-
list:
|
|
4893
|
+
list: o.data,
|
|
4867
4894
|
showPagination: !1
|
|
4868
4895
|
};
|
|
4869
4896
|
}
|
|
@@ -4873,21 +4900,21 @@ const Fa = /* @__PURE__ */ I(Na, [["render", Ha], ["__scopeId", "data-v-cc0d8293
|
|
|
4873
4900
|
};
|
|
4874
4901
|
}
|
|
4875
4902
|
};
|
|
4876
|
-
function
|
|
4877
|
-
const s = Ae,
|
|
4878
|
-
return ie((i(),
|
|
4903
|
+
function Ka(e, t, l, o, n, a) {
|
|
4904
|
+
const s = Ae, r = Vt("resize");
|
|
4905
|
+
return ie((i(), f(s, {
|
|
4879
4906
|
shadow: "never",
|
|
4880
4907
|
class: "part"
|
|
4881
4908
|
}, {
|
|
4882
|
-
default:
|
|
4883
|
-
(i(),
|
|
4909
|
+
default: c(() => [
|
|
4910
|
+
(i(), f(Ze(o.comptype()), G(Y(o.compprops(l.option))), null, 16))
|
|
4884
4911
|
]),
|
|
4885
4912
|
_: 1
|
|
4886
4913
|
})), [
|
|
4887
|
-
[
|
|
4914
|
+
[r, !0]
|
|
4888
4915
|
]);
|
|
4889
4916
|
}
|
|
4890
|
-
const
|
|
4917
|
+
const Wa = /* @__PURE__ */ I(za, [["render", Ka], ["__scopeId", "data-v-a5a65cc1"]]), Za = /* @__PURE__ */ q({
|
|
4891
4918
|
__name: "index",
|
|
4892
4919
|
props: {
|
|
4893
4920
|
filter: {
|
|
@@ -4901,16 +4928,16 @@ const za = /* @__PURE__ */ I(Ga, [["render", Ja], ["__scopeId", "data-v-a5a65cc1
|
|
|
4901
4928
|
},
|
|
4902
4929
|
setup(e) {
|
|
4903
4930
|
const t = e, l = useRoute();
|
|
4904
|
-
|
|
4931
|
+
Qe(() => {
|
|
4905
4932
|
});
|
|
4906
|
-
const
|
|
4933
|
+
const o = M({});
|
|
4907
4934
|
ze(() => {
|
|
4908
|
-
var
|
|
4909
|
-
(
|
|
4910
|
-
b.default !== null && (
|
|
4935
|
+
var m;
|
|
4936
|
+
(m = t.filter) == null || m.forEach((b) => {
|
|
4937
|
+
b.default !== null && (o.value[b.field] = b.default);
|
|
4911
4938
|
});
|
|
4912
4939
|
});
|
|
4913
|
-
const
|
|
4940
|
+
const n = {
|
|
4914
4941
|
inline: !0,
|
|
4915
4942
|
labelPosition: "right",
|
|
4916
4943
|
labelWidth: "auto",
|
|
@@ -4920,37 +4947,37 @@ const za = /* @__PURE__ */ I(Ga, [["render", Ja], ["__scopeId", "data-v-a5a65cc1
|
|
|
4920
4947
|
cancelButton: {
|
|
4921
4948
|
text: "重置"
|
|
4922
4949
|
}
|
|
4923
|
-
}, a = M(1), s = M(t.filter),
|
|
4924
|
-
let
|
|
4925
|
-
if (!
|
|
4950
|
+
}, a = M(1), s = M(t.filter), r = M(t.dataPart), u = j(() => {
|
|
4951
|
+
let m = l.params.id;
|
|
4952
|
+
if (!m) {
|
|
4926
4953
|
const b = l.path.split("/");
|
|
4927
|
-
|
|
4954
|
+
m = b[b.length - 1];
|
|
4928
4955
|
}
|
|
4929
|
-
return "/focusbi_report/view/" +
|
|
4930
|
-
}), d = (
|
|
4931
|
-
|
|
4932
|
-
s.value = b.filter,
|
|
4956
|
+
return "/focusbi_report/view/" + m;
|
|
4957
|
+
}), d = (m) => {
|
|
4958
|
+
Tt.get(u.value, { params: m }).then(({ data: b }) => {
|
|
4959
|
+
s.value = b.filter, r.value = b.dataPart, a.value++;
|
|
4933
4960
|
});
|
|
4934
4961
|
};
|
|
4935
|
-
return (
|
|
4936
|
-
const g = Ae, x = de, J =
|
|
4937
|
-
return i(),
|
|
4938
|
-
default:
|
|
4939
|
-
|
|
4962
|
+
return (m, b) => {
|
|
4963
|
+
const g = Ae, x = de, J = Oe, U = ae;
|
|
4964
|
+
return i(), f(U, null, {
|
|
4965
|
+
default: c(() => [
|
|
4966
|
+
S(s).length > 0 ? (i(), f(x, {
|
|
4940
4967
|
key: 0,
|
|
4941
4968
|
span: 24
|
|
4942
4969
|
}, {
|
|
4943
|
-
default:
|
|
4944
|
-
|
|
4970
|
+
default: c(() => [
|
|
4971
|
+
p(g, {
|
|
4945
4972
|
shadow: "never",
|
|
4946
4973
|
class: "part-filter"
|
|
4947
4974
|
}, {
|
|
4948
|
-
default:
|
|
4949
|
-
|
|
4950
|
-
modelValue:
|
|
4951
|
-
"onUpdate:modelValue": b[0] || (b[0] = (T) =>
|
|
4952
|
-
"form-items":
|
|
4953
|
-
options:
|
|
4975
|
+
default: c(() => [
|
|
4976
|
+
p(S(z), {
|
|
4977
|
+
modelValue: S(o),
|
|
4978
|
+
"onUpdate:modelValue": b[0] || (b[0] = (T) => qt(o) ? o.value = T : null),
|
|
4979
|
+
"form-items": S(s),
|
|
4980
|
+
options: n,
|
|
4954
4981
|
onSubmit: d
|
|
4955
4982
|
}, null, 8, ["modelValue", "form-items"])
|
|
4956
4983
|
]),
|
|
@@ -4959,26 +4986,26 @@ const za = /* @__PURE__ */ I(Ga, [["render", Ja], ["__scopeId", "data-v-a5a65cc1
|
|
|
4959
4986
|
]),
|
|
4960
4987
|
_: 1
|
|
4961
4988
|
})) : $("", !0),
|
|
4962
|
-
|
|
4963
|
-
default:
|
|
4964
|
-
|
|
4965
|
-
default:
|
|
4966
|
-
(i(!0), h(E, null,
|
|
4989
|
+
p(x, { span: 24 }, {
|
|
4990
|
+
default: c(() => [
|
|
4991
|
+
p(U, { gutter: 20 }, {
|
|
4992
|
+
default: c(() => [
|
|
4993
|
+
(i(!0), h(E, null, O(S(r), (T, Z) => (i(), f(x, {
|
|
4967
4994
|
key: Z,
|
|
4968
4995
|
span: T.col || 24
|
|
4969
4996
|
}, {
|
|
4970
|
-
default:
|
|
4971
|
-
T.errMsg ? (i(),
|
|
4997
|
+
default: c(() => [
|
|
4998
|
+
T.errMsg ? (i(), f(J, {
|
|
4972
4999
|
key: 1,
|
|
4973
5000
|
title: T.id + " 片段执行出错",
|
|
4974
5001
|
type: "error"
|
|
4975
5002
|
}, {
|
|
4976
|
-
default:
|
|
4977
|
-
k(
|
|
5003
|
+
default: c(() => [
|
|
5004
|
+
k(B(T.errMsg), 1)
|
|
4978
5005
|
]),
|
|
4979
5006
|
_: 2
|
|
4980
|
-
}, 1032, ["title"])) : (i(),
|
|
4981
|
-
key:
|
|
5007
|
+
}, 1032, ["title"])) : (i(), f(Wa, {
|
|
5008
|
+
key: S(a),
|
|
4982
5009
|
option: T
|
|
4983
5010
|
}, null, 8, ["option"]))
|
|
4984
5011
|
]),
|
|
@@ -4996,33 +5023,33 @@ const za = /* @__PURE__ */ I(Ga, [["render", Ja], ["__scopeId", "data-v-a5a65cc1
|
|
|
4996
5023
|
};
|
|
4997
5024
|
}
|
|
4998
5025
|
});
|
|
4999
|
-
const
|
|
5026
|
+
const Qa = {
|
|
5000
5027
|
__name: "report",
|
|
5001
5028
|
setup(e) {
|
|
5002
5029
|
const t = useRoute(), l = j(() => {
|
|
5003
|
-
let
|
|
5004
|
-
if (!
|
|
5005
|
-
const
|
|
5006
|
-
|
|
5030
|
+
let o = t.params.id;
|
|
5031
|
+
if (!o) {
|
|
5032
|
+
const n = t.path.split("/");
|
|
5033
|
+
o = n[n.length - 1];
|
|
5007
5034
|
}
|
|
5008
|
-
return "/focusbi_report/view/" +
|
|
5035
|
+
return "/focusbi_report/view/" + o;
|
|
5009
5036
|
});
|
|
5010
|
-
return (
|
|
5011
|
-
default:
|
|
5012
|
-
|
|
5037
|
+
return (o, n) => (i(), f(se, { "schema-api": S(l) }, {
|
|
5038
|
+
default: c((a) => [
|
|
5039
|
+
p(Za, G(Y(a)), null, 16)
|
|
5013
5040
|
]),
|
|
5014
5041
|
_: 1
|
|
5015
5042
|
}, 8, ["schema-api"]));
|
|
5016
5043
|
}
|
|
5017
5044
|
};
|
|
5018
|
-
const
|
|
5019
|
-
card:
|
|
5045
|
+
const Xa = (e) => p("div", null, [e.test]), Ya = {
|
|
5046
|
+
card: al,
|
|
5020
5047
|
form: z,
|
|
5021
5048
|
table: oe,
|
|
5022
|
-
test:
|
|
5023
|
-
row:
|
|
5024
|
-
col:
|
|
5025
|
-
},
|
|
5049
|
+
test: Xa,
|
|
5050
|
+
row: sl,
|
|
5051
|
+
col: il
|
|
5052
|
+
}, es = {
|
|
5026
5053
|
card: {
|
|
5027
5054
|
type: "card",
|
|
5028
5055
|
props: {
|
|
@@ -5043,19 +5070,19 @@ const Za = (e) => u("div", null, [e.test]), Qa = {
|
|
|
5043
5070
|
}
|
|
5044
5071
|
}
|
|
5045
5072
|
};
|
|
5046
|
-
function
|
|
5047
|
-
const t = Object.assign({}, e), l = t.type.split(".").reverse(),
|
|
5073
|
+
function ts(e) {
|
|
5074
|
+
const t = Object.assign({}, e), l = t.type.split(".").reverse(), o = t.span || 24;
|
|
5048
5075
|
delete t.span;
|
|
5049
|
-
let
|
|
5076
|
+
let n = {
|
|
5050
5077
|
...t,
|
|
5051
5078
|
type: l[0]
|
|
5052
5079
|
};
|
|
5053
5080
|
for (let a = 1; a < l.length; a++)
|
|
5054
|
-
|
|
5081
|
+
n = {
|
|
5055
5082
|
type: l[a],
|
|
5056
|
-
children: [
|
|
5083
|
+
children: [n]
|
|
5057
5084
|
};
|
|
5058
|
-
return
|
|
5085
|
+
return n.span = o, De([n]);
|
|
5059
5086
|
}
|
|
5060
5087
|
function De(e) {
|
|
5061
5088
|
const t = {
|
|
@@ -5067,99 +5094,99 @@ function De(e) {
|
|
|
5067
5094
|
children: []
|
|
5068
5095
|
};
|
|
5069
5096
|
return e.forEach((l) => {
|
|
5070
|
-
var s,
|
|
5071
|
-
let
|
|
5072
|
-
if (X((s =
|
|
5073
|
-
let
|
|
5074
|
-
Object.keys((
|
|
5075
|
-
var
|
|
5076
|
-
|
|
5077
|
-
}),
|
|
5097
|
+
var s, r;
|
|
5098
|
+
let o = Object.assign({}, l);
|
|
5099
|
+
if (X((s = o.props) == null ? void 0 : s.style)) {
|
|
5100
|
+
let u = "";
|
|
5101
|
+
Object.keys((r = o.props) == null ? void 0 : r.style).forEach((d) => {
|
|
5102
|
+
var m;
|
|
5103
|
+
u += d + ":" + ((m = o.props) == null ? void 0 : m.style[d]) + ";";
|
|
5104
|
+
}), o.props.style = u;
|
|
5078
5105
|
}
|
|
5079
|
-
const
|
|
5080
|
-
span:
|
|
5106
|
+
const n = {
|
|
5107
|
+
span: o.span ?? 24,
|
|
5081
5108
|
class: "render-col"
|
|
5082
5109
|
};
|
|
5083
|
-
if (delete
|
|
5110
|
+
if (delete o.span, o.type.indexOf(".") > 0) {
|
|
5084
5111
|
t.children.push({
|
|
5085
5112
|
type: "col",
|
|
5086
|
-
props:
|
|
5087
|
-
children:
|
|
5113
|
+
props: n,
|
|
5114
|
+
children: ts(o)
|
|
5088
5115
|
});
|
|
5089
5116
|
return;
|
|
5090
5117
|
}
|
|
5091
|
-
|
|
5118
|
+
o = A({
|
|
5092
5119
|
props: {}
|
|
5093
|
-
},
|
|
5094
|
-
const a =
|
|
5095
|
-
a.length && (
|
|
5120
|
+
}, es[o.type] || {}, o);
|
|
5121
|
+
const a = $t(o.children);
|
|
5122
|
+
a.length && (o.children = De(a)), t.children.push({
|
|
5096
5123
|
type: "col",
|
|
5097
|
-
props:
|
|
5098
|
-
children: [
|
|
5124
|
+
props: n,
|
|
5125
|
+
children: [o]
|
|
5099
5126
|
});
|
|
5100
5127
|
}), [t];
|
|
5101
5128
|
}
|
|
5102
|
-
function
|
|
5103
|
-
return
|
|
5129
|
+
function $t(e) {
|
|
5130
|
+
return tt(e) ? e : X(e) ? [e] : [];
|
|
5104
5131
|
}
|
|
5105
5132
|
let Ee = {};
|
|
5106
|
-
const
|
|
5107
|
-
const t =
|
|
5108
|
-
return
|
|
5109
|
-
default: () =>
|
|
5133
|
+
const It = (e) => {
|
|
5134
|
+
const t = Ya[e.type] || Ee[e.type] || e.type;
|
|
5135
|
+
return Ht(t, e.props, {
|
|
5136
|
+
default: () => $t(e.children).map((l) => It(l))
|
|
5110
5137
|
});
|
|
5111
|
-
},
|
|
5138
|
+
}, ls = (e) => (Object.keys(Ee).length === 0 && (Ee = Ut().appContext.components), De(Object.values(e.schema)).map((l) => It(l))), ns = {
|
|
5112
5139
|
__name: "custom",
|
|
5113
5140
|
setup(e) {
|
|
5114
|
-
const t = M([]), l = (
|
|
5115
|
-
return (
|
|
5116
|
-
default:
|
|
5117
|
-
|
|
5141
|
+
const t = M([]), l = (o, n) => (t.value = Ft(o), o);
|
|
5142
|
+
return (o, n) => (i(), f(se, { "schema-handler": l }, {
|
|
5143
|
+
default: c(() => [
|
|
5144
|
+
p(S(ls), { schema: S(t) }, null, 8, ["schema"])
|
|
5118
5145
|
]),
|
|
5119
5146
|
_: 1
|
|
5120
5147
|
}));
|
|
5121
5148
|
}
|
|
5122
5149
|
};
|
|
5123
5150
|
let te = {};
|
|
5124
|
-
function
|
|
5151
|
+
function Ii(e) {
|
|
5125
5152
|
te = e;
|
|
5126
5153
|
}
|
|
5127
|
-
const
|
|
5154
|
+
const os = (e) => {
|
|
5128
5155
|
const t = (l) => {
|
|
5129
|
-
const
|
|
5130
|
-
return te && te[
|
|
5156
|
+
const o = "./views/" + l + ".vue";
|
|
5157
|
+
return te && te[o] && te[o].default ? te[o].default : (console.error(`自定义组件不存在 ${e.name} ${e.view}`), ge);
|
|
5131
5158
|
};
|
|
5132
5159
|
if (e.path === "#")
|
|
5133
5160
|
return ge;
|
|
5134
5161
|
switch (e.page_type) {
|
|
5135
5162
|
case D.list:
|
|
5136
|
-
return
|
|
5163
|
+
return Et;
|
|
5137
5164
|
case D.form:
|
|
5138
5165
|
return xe;
|
|
5139
5166
|
case D.custom:
|
|
5140
5167
|
case D.localComp:
|
|
5141
5168
|
return t(e.view || "");
|
|
5142
5169
|
case D.tree:
|
|
5143
|
-
return
|
|
5170
|
+
return Da;
|
|
5144
5171
|
case D.report:
|
|
5145
|
-
return
|
|
5172
|
+
return Qa;
|
|
5146
5173
|
case D.customSchema:
|
|
5147
|
-
return
|
|
5174
|
+
return ns;
|
|
5148
5175
|
}
|
|
5149
5176
|
return ge;
|
|
5150
5177
|
};
|
|
5151
|
-
function
|
|
5178
|
+
function as(e) {
|
|
5152
5179
|
let t = e.path;
|
|
5153
5180
|
return e.type === L.menu && e.page_type === D.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;
|
|
5154
5181
|
}
|
|
5155
|
-
function
|
|
5182
|
+
function ss(e) {
|
|
5156
5183
|
return (e.path + e.name).split("/").filter((t) => t).join("_");
|
|
5157
5184
|
}
|
|
5158
|
-
const
|
|
5185
|
+
const Ct = (e) => {
|
|
5159
5186
|
const t = e.type !== L.page, l = {
|
|
5160
|
-
path:
|
|
5161
|
-
name: e.id + "_" +
|
|
5162
|
-
component:
|
|
5187
|
+
path: as(e),
|
|
5188
|
+
name: e.id + "_" + ss(e) + "_" + e.path.replaceAll("/", "_"),
|
|
5189
|
+
component: os(e),
|
|
5163
5190
|
meta: {
|
|
5164
5191
|
id: e.id,
|
|
5165
5192
|
pageId: e.id,
|
|
@@ -5170,13 +5197,13 @@ const Et = (e) => {
|
|
|
5170
5197
|
menuType: e.type,
|
|
5171
5198
|
keepAlive: !1
|
|
5172
5199
|
},
|
|
5173
|
-
children: e.children ? e.children.map((
|
|
5200
|
+
children: e.children ? e.children.map((o) => Ct(o)) : []
|
|
5174
5201
|
};
|
|
5175
5202
|
if (e.page_type === D.entity) {
|
|
5176
|
-
const
|
|
5177
|
-
path:
|
|
5203
|
+
const o = e.path + "/list", n = e.path + "/form", a = e.path + "/:id", s = [{
|
|
5204
|
+
path: o,
|
|
5178
5205
|
name: e.name + "列表" + e.id,
|
|
5179
|
-
component:
|
|
5206
|
+
component: Et,
|
|
5180
5207
|
meta: {
|
|
5181
5208
|
id: e.id + 99999,
|
|
5182
5209
|
title: "列表",
|
|
@@ -5187,7 +5214,7 @@ const Et = (e) => {
|
|
|
5187
5214
|
path: e.path
|
|
5188
5215
|
}
|
|
5189
5216
|
}, {
|
|
5190
|
-
path:
|
|
5217
|
+
path: n,
|
|
5191
5218
|
name: e.name + "新建" + e.id,
|
|
5192
5219
|
component: xe,
|
|
5193
5220
|
meta: {
|
|
@@ -5216,97 +5243,97 @@ const Et = (e) => {
|
|
|
5216
5243
|
l.children = [...s, ...l.children];
|
|
5217
5244
|
}
|
|
5218
5245
|
if (l.children && l.children.length > 0) {
|
|
5219
|
-
let
|
|
5220
|
-
if (l.children.forEach((
|
|
5221
|
-
|
|
5222
|
-
}), l.meta && (l.meta.menuType = t ? L.dir : L.hidden),
|
|
5246
|
+
let o = !0;
|
|
5247
|
+
if (l.children.forEach((n) => {
|
|
5248
|
+
n.meta && !n.meta.hidden && (o = !1);
|
|
5249
|
+
}), l.meta && (l.meta.menuType = t ? L.dir : L.hidden), o) {
|
|
5223
5250
|
l.meta && (l.meta.menuType = L.menu);
|
|
5224
|
-
let
|
|
5251
|
+
let n = "/";
|
|
5225
5252
|
for (let a = 0; a < l.children.length; a++)
|
|
5226
5253
|
if (l.children[a].path.indexOf("/:") === -1) {
|
|
5227
|
-
|
|
5254
|
+
n = l.children[a].path;
|
|
5228
5255
|
break;
|
|
5229
5256
|
}
|
|
5230
|
-
l.redirect =
|
|
5257
|
+
l.redirect = n, l.path = "/" + e.id + "_DIR" + l.redirect.replaceAll("/", "_").toUpperCase();
|
|
5231
5258
|
}
|
|
5232
5259
|
}
|
|
5233
5260
|
return l;
|
|
5234
|
-
},
|
|
5261
|
+
}, is = (e) => {
|
|
5235
5262
|
const t = [];
|
|
5236
5263
|
return e.forEach((l) => {
|
|
5237
|
-
const
|
|
5264
|
+
const o = {
|
|
5238
5265
|
id: l.id,
|
|
5239
5266
|
label: l.label,
|
|
5240
5267
|
routes: []
|
|
5241
5268
|
};
|
|
5242
|
-
l.routes.forEach((
|
|
5243
|
-
|
|
5244
|
-
}), t.push(
|
|
5269
|
+
l.routes.forEach((n) => {
|
|
5270
|
+
o.routes.push(Ct(n));
|
|
5271
|
+
}), t.push(o);
|
|
5245
5272
|
}), t;
|
|
5246
5273
|
};
|
|
5247
|
-
function
|
|
5248
|
-
e.beforeEach(async (t, l,
|
|
5249
|
-
if (
|
|
5250
|
-
|
|
5274
|
+
function rs(e) {
|
|
5275
|
+
e.beforeEach(async (t, l, o) => {
|
|
5276
|
+
if (kt().indexOf(t.path) !== -1) {
|
|
5277
|
+
o();
|
|
5251
5278
|
return;
|
|
5252
5279
|
}
|
|
5253
|
-
if (
|
|
5254
|
-
|
|
5280
|
+
if (fa()) {
|
|
5281
|
+
o();
|
|
5255
5282
|
return;
|
|
5256
5283
|
}
|
|
5257
|
-
await
|
|
5258
|
-
const
|
|
5284
|
+
await w.dispatch("user/info");
|
|
5285
|
+
const n = await w.dispatch("user/loadRemoteRoutes"), a = is(n);
|
|
5259
5286
|
a.forEach((s) => {
|
|
5260
|
-
s.routes.forEach((
|
|
5287
|
+
s.routes.forEach((r) => {
|
|
5261
5288
|
e.addRoute({
|
|
5262
5289
|
path: "/",
|
|
5263
|
-
component:
|
|
5264
|
-
children: [
|
|
5290
|
+
component: vt,
|
|
5291
|
+
children: [r]
|
|
5265
5292
|
});
|
|
5266
5293
|
});
|
|
5267
|
-
}), e.addRoute({ name: "404", path: "/:pathMatch(.*)*", redirect: "/404", hidden: !0 }),
|
|
5294
|
+
}), e.addRoute({ name: "404", path: "/:pathMatch(.*)*", redirect: "/404", hidden: !0 }), w.commit("user/updateRemoteRouter", a), await e.replace(t), o();
|
|
5268
5295
|
});
|
|
5269
5296
|
}
|
|
5270
|
-
function
|
|
5271
|
-
e.beforeEach(async (t, l,
|
|
5272
|
-
var
|
|
5273
|
-
const a = [
|
|
5274
|
-
for (let
|
|
5275
|
-
const d = t.matched[
|
|
5276
|
-
(
|
|
5297
|
+
function cs(e) {
|
|
5298
|
+
e.beforeEach(async (t, l, o) => {
|
|
5299
|
+
var r;
|
|
5300
|
+
const a = [w.state.settings.title || ""], s = t.matched.length;
|
|
5301
|
+
for (let u = s; u > s - 3; u--) {
|
|
5302
|
+
const d = t.matched[u - 1];
|
|
5303
|
+
(r = d == null ? void 0 : d.meta) != null && r.title && a.push(d.meta.title + "");
|
|
5277
5304
|
}
|
|
5278
|
-
a.length > 1 && (document.title = a.reverse().join("-")),
|
|
5279
|
-
}), e.afterEach(async (t, l,
|
|
5280
|
-
Object.keys(t.meta).length > 0 && await
|
|
5305
|
+
a.length > 1 && (document.title = a.reverse().join("-")), o();
|
|
5306
|
+
}), e.afterEach(async (t, l, o) => {
|
|
5307
|
+
Object.keys(t.meta).length > 0 && await w.dispatch("app/setCurrentMeta", t.meta);
|
|
5281
5308
|
});
|
|
5282
5309
|
}
|
|
5283
|
-
function
|
|
5284
|
-
|
|
5310
|
+
function us(e) {
|
|
5311
|
+
va(e), ma(e), rs(e), cs(e);
|
|
5285
5312
|
}
|
|
5286
|
-
|
|
5287
|
-
function
|
|
5288
|
-
return
|
|
5313
|
+
us(K);
|
|
5314
|
+
function ps() {
|
|
5315
|
+
return w.state.user.token;
|
|
5289
5316
|
}
|
|
5290
5317
|
function Ge(e) {
|
|
5291
|
-
|
|
5318
|
+
ln({
|
|
5292
5319
|
message: e,
|
|
5293
5320
|
type: "error",
|
|
5294
5321
|
duration: 5 * 1e3,
|
|
5295
5322
|
grouping: !0
|
|
5296
5323
|
});
|
|
5297
5324
|
}
|
|
5298
|
-
const
|
|
5325
|
+
const ds = {
|
|
5299
5326
|
onFulfilled: function(e) {
|
|
5300
5327
|
var l;
|
|
5301
5328
|
e.headers = e.headers || {};
|
|
5302
|
-
const t =
|
|
5329
|
+
const t = ps();
|
|
5303
5330
|
return t && (e.headers["X-Token"] = t), (l = K.currentRoute.value.meta) != null && l.path && (e.headers["X-Path"] = K.currentRoute.value.meta.path), e;
|
|
5304
5331
|
}
|
|
5305
|
-
},
|
|
5332
|
+
}, ms = {
|
|
5306
5333
|
onFulfilled(e) {
|
|
5307
|
-
var
|
|
5308
|
-
if (!(((
|
|
5309
|
-
const
|
|
5334
|
+
var o, n, a, s, r, u, d;
|
|
5335
|
+
if (!(((o = e.config) == null ? void 0 : o.notHoldApiErr) !== void 0 && ((n = e.config) == null ? void 0 : n.notHoldApiErr) === !0) && e.data.code !== 0) {
|
|
5336
|
+
const m = e.data.message || `接口请求错误 ${e.config.method}::${(a = e.config.url) == null ? void 0 : a.split("?")[0]}`;
|
|
5310
5337
|
if (e.data.code === 401) {
|
|
5311
5338
|
Ue.alert("登录信息已过期或未登录, 是否跳转登录", "操作提醒", {
|
|
5312
5339
|
showClose: !1,
|
|
@@ -5314,17 +5341,17 @@ const us = {
|
|
|
5314
5341
|
showCancelButton: !0,
|
|
5315
5342
|
cancelButtonText: "取消",
|
|
5316
5343
|
callback: (b) => {
|
|
5317
|
-
b === "confirm" && (
|
|
5344
|
+
b === "confirm" && (ft(), location.href = location.origin + location.pathname + location.hash.replace("#", "#/?redirect="), location.reload());
|
|
5318
5345
|
}
|
|
5319
5346
|
});
|
|
5320
5347
|
return;
|
|
5321
5348
|
} else
|
|
5322
|
-
Ge(
|
|
5323
|
-
return Promise.reject(
|
|
5349
|
+
Ge(m);
|
|
5350
|
+
return Promise.reject(m);
|
|
5324
5351
|
}
|
|
5325
|
-
let l = (
|
|
5352
|
+
let l = (r = (s = e.data) == null ? void 0 : s.data) == null ? void 0 : r._message_box;
|
|
5326
5353
|
return l !== void 0 && ($e(l) && (l = {
|
|
5327
|
-
message: (d = (
|
|
5354
|
+
message: (d = (u = e.data) == null ? void 0 : u.data) == null ? void 0 : d._message_box
|
|
5328
5355
|
}), Ue({
|
|
5329
5356
|
title: "提示",
|
|
5330
5357
|
type: "success",
|
|
@@ -5336,27 +5363,27 @@ const us = {
|
|
|
5336
5363
|
var t;
|
|
5337
5364
|
return Ie.isCancel(e) ? Promise.reject("") : (Ge(`${e.message} ${e.config.method}::${(t = e.config.url) == null ? void 0 : t.split("?")[0]}`), Promise.reject(e));
|
|
5338
5365
|
}
|
|
5339
|
-
},
|
|
5366
|
+
}, fs = [
|
|
5340
5367
|
{
|
|
5341
|
-
request:
|
|
5342
|
-
response:
|
|
5368
|
+
request: on,
|
|
5369
|
+
response: an
|
|
5343
5370
|
},
|
|
5344
5371
|
{
|
|
5345
|
-
request:
|
|
5346
|
-
response:
|
|
5372
|
+
request: ds,
|
|
5373
|
+
response: ms
|
|
5347
5374
|
}
|
|
5348
5375
|
];
|
|
5349
5376
|
function Ne(e = {}) {
|
|
5350
|
-
const t = me.axios || {}, l = A(t, e || {}),
|
|
5377
|
+
const t = me.axios || {}, l = A(t, e || {}), o = Ie.create({
|
|
5351
5378
|
...l
|
|
5352
5379
|
// adapter: (c) => cacheAdapter(c, defaultAxios)
|
|
5353
5380
|
});
|
|
5354
|
-
return
|
|
5355
|
-
|
|
5356
|
-
}),
|
|
5381
|
+
return fs.forEach((n) => {
|
|
5382
|
+
o.interceptors.request.use(n.request.onFulfilled, n.request.onRejected), o.interceptors.response.use(n.response.onFulfilled, n.response.onRejected);
|
|
5383
|
+
}), o;
|
|
5357
5384
|
}
|
|
5358
|
-
const
|
|
5359
|
-
const
|
|
5385
|
+
const Tt = Ne();
|
|
5386
|
+
const hs = {
|
|
5360
5387
|
beforeMount(e, t) {
|
|
5361
5388
|
e.clickOutsideEvent = function(l) {
|
|
5362
5389
|
e === l.target || e.contains(l.target) || t.value(l, e);
|
|
@@ -5365,131 +5392,131 @@ const fs = {
|
|
|
5365
5392
|
unmounted(e) {
|
|
5366
5393
|
document.body.removeEventListener("click", e.clickOutsideEvent);
|
|
5367
5394
|
}
|
|
5368
|
-
}, W =
|
|
5395
|
+
}, W = Al(), bs = {
|
|
5369
5396
|
mounted: (e, t) => {
|
|
5370
5397
|
e !== null && (t.value, e.oncontextmenu = (l) => {
|
|
5371
5398
|
l.preventDefault(), l.stopPropagation(), l.cancelBubble = !0, t.value && W.emit("right-click", { event: l, data: t.value });
|
|
5372
5399
|
});
|
|
5373
5400
|
}
|
|
5374
|
-
},
|
|
5401
|
+
}, _s = {
|
|
5375
5402
|
mounted(e) {
|
|
5376
5403
|
}
|
|
5377
5404
|
};
|
|
5378
5405
|
function Je(e, t) {
|
|
5379
|
-
let l = e[`offset${t}`],
|
|
5380
|
-
for (;
|
|
5381
|
-
l +=
|
|
5406
|
+
let l = e[`offset${t}`], o = e.offsetParent;
|
|
5407
|
+
for (; o; )
|
|
5408
|
+
l += o[`offset${t}`], o = o.offsetParent;
|
|
5382
5409
|
return l;
|
|
5383
5410
|
}
|
|
5384
|
-
const
|
|
5411
|
+
const ys = {
|
|
5385
5412
|
mounted: (e, t) => {
|
|
5386
5413
|
if (e === null || !t.value.dev)
|
|
5387
5414
|
return;
|
|
5388
5415
|
let l = e;
|
|
5389
5416
|
if (t.value.parent)
|
|
5390
|
-
for (let
|
|
5417
|
+
for (let u = 0; u < t.value.parent; u++)
|
|
5391
5418
|
l.parentElement && (l = l.parentElement);
|
|
5392
5419
|
l.classList.add("devtool-hover");
|
|
5393
|
-
const
|
|
5394
|
-
|
|
5395
|
-
|
|
5420
|
+
const o = document.createElement("i");
|
|
5421
|
+
o.className = "devtool-item-wrapper", l.onmouseover = () => {
|
|
5422
|
+
o.style.height = l.offsetHeight + 30 + "px", o.style.width = l.offsetWidth + 30 + "px", o.style.top = Je(l, "Top") - 15 + "px", o.style.left = Je(l, "Left") - 15 + "px";
|
|
5396
5423
|
};
|
|
5397
|
-
const
|
|
5398
|
-
|
|
5424
|
+
const n = document.createElement("span");
|
|
5425
|
+
n.className = "dev-action-edit", n.title = "编辑";
|
|
5399
5426
|
const a = document.createElement("i");
|
|
5400
|
-
a.className = "iconfont ra-editor1",
|
|
5401
|
-
W.emit("dev-action", { event:
|
|
5402
|
-
},
|
|
5427
|
+
a.className = "iconfont ra-editor1", n.appendChild(a), n.onclick = (u) => {
|
|
5428
|
+
W.emit("dev-action", { event: u, data: { type: "edit", devId: t.value.devId } });
|
|
5429
|
+
}, o.appendChild(n);
|
|
5403
5430
|
const s = document.createElement("span");
|
|
5404
5431
|
s.className = "dev-action-del", s.title = "删除";
|
|
5405
|
-
const
|
|
5406
|
-
|
|
5407
|
-
W.emit("dev-action", { event:
|
|
5408
|
-
},
|
|
5432
|
+
const r = document.createElement("i");
|
|
5433
|
+
r.className = "iconfont ra-cut", s.appendChild(r), s.onclick = (u) => {
|
|
5434
|
+
W.emit("dev-action", { event: u, data: { type: "del", devId: t.value.devId } });
|
|
5435
|
+
}, o.appendChild(s), l.insertBefore(o, l.firstChild);
|
|
5409
5436
|
}
|
|
5410
|
-
},
|
|
5437
|
+
}, vs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
5411
5438
|
__proto__: null,
|
|
5412
|
-
devtool:
|
|
5413
|
-
outClick:
|
|
5414
|
-
resize:
|
|
5415
|
-
rightClick:
|
|
5439
|
+
devtool: ys,
|
|
5440
|
+
outClick: hs,
|
|
5441
|
+
resize: _s,
|
|
5442
|
+
rightClick: bs
|
|
5416
5443
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
5417
5444
|
let ce;
|
|
5418
|
-
function
|
|
5445
|
+
function Ci(e) {
|
|
5419
5446
|
return e ? Ne(A(me.axios, e)) : ce;
|
|
5420
5447
|
}
|
|
5421
|
-
function
|
|
5422
|
-
const t = A(me, e), l =
|
|
5423
|
-
|
|
5424
|
-
|
|
5425
|
-
}), t != null && t.mock &&
|
|
5448
|
+
function Ti(e) {
|
|
5449
|
+
const t = A(me, e), l = Gt(Ml), o = $s(t), n = t.plugins || [];
|
|
5450
|
+
n.unshift(o), n.forEach((a) => {
|
|
5451
|
+
Es(l, a);
|
|
5452
|
+
}), t != null && t.mock && Jl(), ce = Ne(t.axios), w.dispatch("setHttp", ce).then(), w.dispatch("settings/updateSettings", e == null ? void 0 : e.settings).then(), w.dispatch("app/setBaseAPI", t == null ? void 0 : t.axios.baseURL).then(), l.config.globalProperties.$http = ce, l.config.globalProperties.$router = K, window.App = l, window.OmsOptions = t, Bl(() => ({
|
|
5426
5453
|
"X-Token": Me()
|
|
5427
5454
|
})), K.isReady().then(() => l.mount("#app"));
|
|
5428
5455
|
}
|
|
5429
|
-
function
|
|
5456
|
+
function gs(e, t = {}) {
|
|
5430
5457
|
Object.keys(t).forEach((l) => {
|
|
5431
5458
|
e.component(l, t[l]);
|
|
5432
5459
|
});
|
|
5433
5460
|
}
|
|
5434
|
-
function
|
|
5461
|
+
function ks(e = []) {
|
|
5435
5462
|
e.forEach((t) => {
|
|
5436
5463
|
K.addRoute(t);
|
|
5437
|
-
}),
|
|
5464
|
+
}), w.commit("user/setCustomRoutes", e);
|
|
5438
5465
|
}
|
|
5439
|
-
function
|
|
5466
|
+
function ws(e, t) {
|
|
5440
5467
|
t.forEach((l) => {
|
|
5441
5468
|
X(l) && (l = [l]), e.use(...l);
|
|
5442
5469
|
});
|
|
5443
5470
|
}
|
|
5444
|
-
function
|
|
5471
|
+
function Ss(e, t = {}) {
|
|
5445
5472
|
Object.keys(t).forEach((l) => {
|
|
5446
5473
|
e.directive(l, t[l]);
|
|
5447
5474
|
});
|
|
5448
5475
|
}
|
|
5449
|
-
function
|
|
5476
|
+
function xs(e = {}) {
|
|
5450
5477
|
const t = ["app", "settings", "user"];
|
|
5451
5478
|
Object.keys(e).forEach((l) => {
|
|
5452
5479
|
if (t.indexOf(l) !== -1) {
|
|
5453
5480
|
console.warn(`storeModule name [${l}] is use by base, please change it!`);
|
|
5454
5481
|
return;
|
|
5455
5482
|
}
|
|
5456
|
-
|
|
5483
|
+
w.registerModule(l, e[l]);
|
|
5457
5484
|
});
|
|
5458
5485
|
}
|
|
5459
|
-
function
|
|
5460
|
-
|
|
5486
|
+
function Es(e, t) {
|
|
5487
|
+
gs(e, t.components || {}), ks(t.routes || []), ws(e, t.use || []), Ss(e, t.directives || {}), xs(t.storeModules || {}), dt(t.mockApis || []);
|
|
5461
5488
|
}
|
|
5462
|
-
function
|
|
5489
|
+
function $s(e) {
|
|
5463
5490
|
var t;
|
|
5464
5491
|
return {
|
|
5465
|
-
components: { VIcon:
|
|
5466
|
-
directives:
|
|
5492
|
+
components: { VIcon: Ol },
|
|
5493
|
+
directives: vs,
|
|
5467
5494
|
use: [
|
|
5468
|
-
|
|
5495
|
+
w,
|
|
5469
5496
|
K,
|
|
5470
|
-
[
|
|
5497
|
+
[nl, { locale: nt, ...(t = e.settings) == null ? void 0 : t.ElementPlus }]
|
|
5471
5498
|
]
|
|
5472
5499
|
};
|
|
5473
5500
|
}
|
|
5474
5501
|
export {
|
|
5475
|
-
|
|
5502
|
+
wt as BaseSso,
|
|
5476
5503
|
ge as Container,
|
|
5477
|
-
|
|
5478
|
-
|
|
5479
|
-
|
|
5504
|
+
$i as DingTalk,
|
|
5505
|
+
Ei as Github,
|
|
5506
|
+
vt as Layout,
|
|
5480
5507
|
L as MenuType,
|
|
5481
|
-
|
|
5508
|
+
ln as Message,
|
|
5482
5509
|
Ue as MessageBox,
|
|
5483
5510
|
D as PageType,
|
|
5484
|
-
|
|
5485
|
-
|
|
5511
|
+
_a as allSso,
|
|
5512
|
+
Ti as createAdmin,
|
|
5486
5513
|
W as eventBus,
|
|
5487
|
-
|
|
5514
|
+
sn as getCmp,
|
|
5488
5515
|
ce as http,
|
|
5489
5516
|
Ne as instance,
|
|
5490
|
-
|
|
5491
|
-
|
|
5492
|
-
|
|
5493
|
-
|
|
5517
|
+
Ii as regViews,
|
|
5518
|
+
xi as setCmp,
|
|
5519
|
+
is as transRemoteModules,
|
|
5520
|
+
Ci as useHttp
|
|
5494
5521
|
};
|
|
5495
5522
|
//# sourceMappingURL=index.es.js.map
|