1
This commit is contained in:
@@ -142,7 +142,14 @@ export default {
|
||||
Cookies.remove('rememberMe')
|
||||
}
|
||||
this.$store.dispatch("Login", this.loginForm).then(() => {
|
||||
this.$router.push({ path: this.redirect || "/sloworder/index" }).catch(()=>{})
|
||||
// 获取用户信息和生成路由后再跳转
|
||||
this.$store.dispatch('GetInfo').then(() => {
|
||||
this.$store.dispatch('GenerateRoutes').then(() => {
|
||||
this.$router.push({ path: this.redirect || "/sloworder/index" }).catch(()=>{})
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$router.push({ path: this.redirect || "/user/profile" }).catch(()=>{})
|
||||
})
|
||||
}).catch(() => {
|
||||
this.loading = false
|
||||
if (this.captchaEnabled) {
|
||||
|
||||
Reference in New Issue
Block a user