Browse Source

Fix DashboardHome.vue not appearing on initial page load

main
Haris Razis 4 years ago
parent
commit
3593165e2b
  1. 4
      web/src/views/Login.vue

4
web/src/views/Login.vue

@ -61,14 +61,14 @@ export default class Login extends Vue {
private currentSession() {
this.$store.dispatch('user_currentSession')
.then((res: any) => this.$router.push({name: 'Dashboard', params: {username: res.data.username}}))
.then((res: any) => this.$router.push({name: 'DashboardHome', params: {username: res.data.username}}))
.catch(() => {
});
}
private user_login() {
this.$store.dispatch('user_login', {username: this.username, password: this.password})
.then(() => this.$router.push({name: 'Dashboard', params: {username: this.username}}))
.then(() => this.$router.push({name: 'DashboardHome', params: {username: this.username}}))
.catch(() => {
this.msg = this.$store.getters.user_err.response.data.errors.message || 'Something went wrong!'
});

Loading…
Cancel
Save