@gonsin/gview 2.0.124 → 2.0.125
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.mjs +12 -27
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -85,21 +85,7 @@ function Zt(t, e, u) {
|
|
|
85
85
|
// 标记当前层级
|
|
86
86
|
isGroup: !o.url
|
|
87
87
|
// 标记当前是否为分组
|
|
88
|
-
}))
|
|
89
|
-
const n = Object.keys(o);
|
|
90
|
-
if (n.indexOf("show") > -1) {
|
|
91
|
-
if (typeof o.show < "u")
|
|
92
|
-
return o.show === !0;
|
|
93
|
-
} else if (n.indexOf("whetherShow") > -1 || n.indexOf("menuMold") > -1) {
|
|
94
|
-
if (o.whetherShow !== null)
|
|
95
|
-
return o.whetherShow === !0;
|
|
96
|
-
if (o.menuMold == 1)
|
|
97
|
-
return (o.url ?? "") != "";
|
|
98
|
-
if (o.menuMold == 2)
|
|
99
|
-
return o.children && o.children.length;
|
|
100
|
-
} else
|
|
101
|
-
return o;
|
|
102
|
-
});
|
|
88
|
+
}));
|
|
103
89
|
}
|
|
104
90
|
function rn(t) {
|
|
105
91
|
return t.map((e) => (e.children && e.children.length > 0 && (e.children = rn(e.children)), e.url && !e.path && (e.path = e.url), e));
|
|
@@ -890,20 +876,18 @@ const dn = Uu("column", {
|
|
|
890
876
|
},
|
|
891
877
|
setUserPermission(t) {
|
|
892
878
|
let e = [];
|
|
893
|
-
|
|
879
|
+
this.userPermission = e, Te.setItem(Co, e);
|
|
894
880
|
},
|
|
895
881
|
/**
|
|
896
882
|
* @description 用户登录后初始化配置
|
|
897
883
|
*/
|
|
898
884
|
async initUserConfig(t) {
|
|
899
|
-
var
|
|
900
|
-
Te.setItem(St, t), this.userConfig = { ...t };
|
|
901
|
-
const e =
|
|
902
|
-
this.setUserPermission(
|
|
903
|
-
const {
|
|
904
|
-
this.
|
|
905
|
-
const { listHeaderSetting: a } = t.userInfo;
|
|
906
|
-
dn().initColumnData(a), this.setUserLoginStatus(!0);
|
|
885
|
+
var n;
|
|
886
|
+
Te.setItem(St, t), this.userConfig = { ...t }, (n = t.userInfo) == null || n.username;
|
|
887
|
+
const e = Be(t.userMenu ?? []);
|
|
888
|
+
this.setUserPermission(e), this.setSideMenuTree(e, !1), t.userInfo;
|
|
889
|
+
const { listHeaderSetting: u } = t.userInfo;
|
|
890
|
+
dn().initColumnData(u), this.setUserLoginStatus(!0);
|
|
907
891
|
},
|
|
908
892
|
/**
|
|
909
893
|
* @description: 退出登录时初始化本地存储值
|
|
@@ -1961,8 +1945,9 @@ const In = { render: vi }, Ui = { class: "username" }, Qi = /* @__PURE__ */ ne({
|
|
|
1961
1945
|
item: {}
|
|
1962
1946
|
},
|
|
1963
1947
|
setup(t) {
|
|
1964
|
-
|
|
1965
|
-
|
|
1948
|
+
return de(), (e, u) => (g(), R("span", {
|
|
1949
|
+
title: e.item.title
|
|
1950
|
+
}, oe(e.item.title), 9, Yi));
|
|
1966
1951
|
}
|
|
1967
1952
|
}), Bi = /* @__PURE__ */ ne({
|
|
1968
1953
|
__name: "GLayoutSideMenuIcon",
|
|
@@ -12266,7 +12251,7 @@ const qn = /* @__PURE__ */ tu(Xl, [["__scopeId", "data-v-75fdffa5"]]), lr = /* @
|
|
|
12266
12251
|
t.directive(e, Ko[e]);
|
|
12267
12252
|
});
|
|
12268
12253
|
}
|
|
12269
|
-
}, tM = "@gonsin/gview", oM = "2.0.
|
|
12254
|
+
}, tM = "@gonsin/gview", oM = "2.0.125", nM = "dist/index.mjs", aM = "dist/types/index.d.ts", iM = [
|
|
12270
12255
|
"dist",
|
|
12271
12256
|
"README.md",
|
|
12272
12257
|
"CHANGELOG.md"
|