lw-cdp-ui 1.4.68 → 1.4.69
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/components/lwLogin/index.vue +1 -1
- package/dist/lw-cdp-ui.esm.js +34 -33
- package/dist/lw-cdp-ui.umd.js +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/lw-cdp-ui.esm.js
CHANGED
|
@@ -5076,51 +5076,52 @@ const Gd = /* @__PURE__ */ Tc(Ud), Hd = "data:image/svg+xml,%3c?xml%20version='1
|
|
|
5076
5076
|
return n.setPublicKey(e), n.encrypt(t);
|
|
5077
5077
|
},
|
|
5078
5078
|
async login() {
|
|
5079
|
-
var
|
|
5079
|
+
var u;
|
|
5080
5080
|
await this.$refs.loginForm.validate();
|
|
5081
5081
|
let e = {
|
|
5082
5082
|
username: this.ruleForm.user,
|
|
5083
5083
|
password: this.ruleForm.password
|
|
5084
5084
|
};
|
|
5085
5085
|
if (this.isEncryption) {
|
|
5086
|
-
const
|
|
5087
|
-
|
|
5088
|
-
username: this.encrypt(
|
|
5089
|
-
password: this.encrypt(
|
|
5086
|
+
const d = await this.$api.auth.key();
|
|
5087
|
+
d && (e = {
|
|
5088
|
+
username: this.encrypt(d, this.ruleForm.user),
|
|
5089
|
+
password: this.encrypt(d, this.ruleForm.password)
|
|
5090
5090
|
});
|
|
5091
5091
|
}
|
|
5092
|
-
await this.$api.auth.token(e)
|
|
5093
|
-
|
|
5094
|
-
|
|
5092
|
+
let t = await this.$api.auth.token(e);
|
|
5093
|
+
this.$config.ENV && this.$tool.data.set("TOKEN", t), this.islogin = !0;
|
|
5094
|
+
let n = await this.$api.auth.bu();
|
|
5095
|
+
if (n.length == 0)
|
|
5095
5096
|
return this.$message.warning("用户没有应用权限"), !1;
|
|
5096
|
-
this.$tool.data.set("buList",
|
|
5097
|
-
let
|
|
5098
|
-
|
|
5099
|
-
let
|
|
5100
|
-
if (!(
|
|
5097
|
+
this.$tool.data.set("buList", n);
|
|
5098
|
+
let r = this.$tool.data.get("buCode");
|
|
5099
|
+
n.find((d) => d.code == r) || this.$tool.data.set("buCode", n[0].code);
|
|
5100
|
+
let o = await this.$api.auth.user();
|
|
5101
|
+
if (!(o != null && o.userAuthInfo) && ((u = o == null ? void 0 : o.loginPage) != null && u.includes("pwdChange")))
|
|
5101
5102
|
return this.$message.warning("您的密码已过期,请修改密码!"), this.isPassword = !0, this.islogin = !1, !1;
|
|
5102
|
-
let
|
|
5103
|
-
...new Set(
|
|
5103
|
+
let i = [
|
|
5104
|
+
...new Set(o.userAuthInfo.menus.map((d) => d.split(".")[0].split("_")[0]))
|
|
5104
5105
|
];
|
|
5105
|
-
|
|
5106
|
-
(
|
|
5106
|
+
o.userAuthInfo.grantedApplications = o.userAuthInfo.grantedApplications.filter(
|
|
5107
|
+
(d) => i.includes(d.code)
|
|
5107
5108
|
);
|
|
5108
|
-
let
|
|
5109
|
-
...
|
|
5110
|
-
combined:
|
|
5111
|
-
loginPage:
|
|
5112
|
-
logo:
|
|
5113
|
-
menuContent:
|
|
5109
|
+
let l = {
|
|
5110
|
+
...o.userAuthInfo,
|
|
5111
|
+
combined: o.combined,
|
|
5112
|
+
loginPage: o.loginPage,
|
|
5113
|
+
logo: o.logo,
|
|
5114
|
+
menuContent: o.menuContent
|
|
5114
5115
|
};
|
|
5115
|
-
this.$tool.data.set("tenantId",
|
|
5116
|
-
let
|
|
5117
|
-
if (
|
|
5118
|
-
let
|
|
5119
|
-
|
|
5116
|
+
this.$tool.data.set("tenantId", o.userAuthInfo.tenantId), this.$tool.data.set("userAuthInfo", l), this.$store.state.user = l;
|
|
5117
|
+
let s = this.$tool.data.get("MENU_LIST") || {};
|
|
5118
|
+
if (s.menuDynamic = !!(o != null && o.menuDynamic), this.$config.MENU_DYNAMIC && (o != null && o.menuDynamic)) {
|
|
5119
|
+
let d = await this.$api.auth.menu();
|
|
5120
|
+
s.DYNAMIC_MENU = this.exportMenu(d);
|
|
5120
5121
|
}
|
|
5121
|
-
if (this.$tool.data.set("MENU_LIST",
|
|
5122
|
-
let
|
|
5123
|
-
this.$tool.data.set("zoneInitialized",
|
|
5122
|
+
if (this.$tool.data.set("MENU_LIST", s), sessionStorage.setItem("easyweb_session_passport_current_user", JSON.stringify({ v: o })), sessionStorage.setItem("easyweb_session_passport_bu", JSON.stringify({ v: n[0] })), sessionStorage.setItem("easyweb_session_passport_bu_list", JSON.stringify({ v: n })), this.isInitialized) {
|
|
5123
|
+
let d = await this.$api.auth.initialized();
|
|
5124
|
+
this.$tool.data.set("zoneInitialized", d), d ? this.$router.push(this.$config.DASHBOARD_URL) : this.$router.push(this.$config.INIT_URL);
|
|
5124
5125
|
} else
|
|
5125
5126
|
this.$router.push(this.$config.DASHBOARD_URL);
|
|
5126
5127
|
this.$message.success(this.t("loginPage.loginSuccess")), this.islogin = !1;
|
|
@@ -5178,7 +5179,7 @@ const Gd = /* @__PURE__ */ Tc(Ud), Hd = "data:image/svg+xml,%3c?xml%20version='1
|
|
|
5178
5179
|
}), n;
|
|
5179
5180
|
}
|
|
5180
5181
|
}
|
|
5181
|
-
}, Ho = (e) => (It("data-v-
|
|
5182
|
+
}, Ho = (e) => (It("data-v-2316da57"), e = e(), xt(), e), Kd = { class: "login_bg" }, Wd = { class: "video-container" }, Jd = /* @__PURE__ */ Ho(() => /* @__PURE__ */ q("img", {
|
|
5182
5183
|
class: "logo",
|
|
5183
5184
|
src: Hd
|
|
5184
5185
|
}, null, -1)), Xd = {
|
|
@@ -5539,7 +5540,7 @@ function f8(e, t, n, r, a, o) {
|
|
|
5539
5540
|
])
|
|
5540
5541
|
]);
|
|
5541
5542
|
}
|
|
5542
|
-
const p8 = /* @__PURE__ */ re(Yd, [["render", f8], ["__scopeId", "data-v-
|
|
5543
|
+
const p8 = /* @__PURE__ */ re(Yd, [["render", f8], ["__scopeId", "data-v-2316da57"]]), g8 = { class: "svg-icon" }, m8 = ["xlink:href"], A8 = {
|
|
5543
5544
|
__name: "index",
|
|
5544
5545
|
props: {
|
|
5545
5546
|
name: {
|