登录滑动验证

prod
CTP 2 years ago
parent d76b850ecc
commit c7e39f1320

@ -233,32 +233,6 @@ export default {
type: "warning",
});
}
this.loading = true;
if (this.loginForm.rememberMe) {
Cookies.set("username", this.loginForm.username, { expires: 30 });
Cookies.set("password", encrypt(this.loginForm.password), {
expires: 30,
});
// Cookies.set('rememberMe', this.loginForm.rememberMe, {expires: 30});
} else {
Cookies.remove("username");
Cookies.remove("password");
// Cookies.remove('rememberMe');
}
this.$store
.dispatch("Login", this.loginForm)
.then((res) => {
this.$router
.push({ path: this.redirect || "/" })
.catch((res) => {});
})
.catch((res) => {
this.loading = false;
this.$message.error(res);
if (this.captchaEnabled) {
this.getCode();
}
});
}
});
},

Loading…
Cancel
Save