|
@@ -110,9 +110,10 @@ export default {
|
|
if (valid) {
|
|
if (valid) {
|
|
this.loading = true
|
|
this.loading = true
|
|
this.$store.dispatch('user/login', this.loginForm).then(() => {
|
|
this.$store.dispatch('user/login', this.loginForm).then(() => {
|
|
- this.$router.push({ path: '/'})
|
|
|
|
window.setTimeout(() => {
|
|
window.setTimeout(() => {
|
|
|
|
+ this.$router.push({ path: '/'})
|
|
this.$router.go(0)
|
|
this.$router.go(0)
|
|
|
|
+ this.loading = false
|
|
}, 1000)
|
|
}, 1000)
|
|
// this.$router.push({ path: this.redirect || '/' })
|
|
// this.$router.push({ path: this.redirect || '/' })
|
|
// if (this.redirect && this.redirect !== '/dashboard') {
|
|
// if (this.redirect && this.redirect !== '/dashboard') {
|
|
@@ -120,7 +121,6 @@ export default {
|
|
// this.$router.go(0)
|
|
// this.$router.go(0)
|
|
// }, 100)
|
|
// }, 100)
|
|
// }
|
|
// }
|
|
- this.loading = false
|
|
|
|
}).catch(() => {
|
|
}).catch(() => {
|
|
this.loading = false
|
|
this.loading = false
|
|
})
|
|
})
|