Skip to content

Commit

Permalink
Fix pending user broken login and page layout (#127)
Browse files Browse the repository at this point in the history
* Fix to route to /pending

* Remove page header if user has 'pending' role
  • Loading branch information
eli-lim authored Oct 9, 2020
1 parent cb327c2 commit ee15e84
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sadeaf-web/layouts/default.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<div class="layout">
<el-container v-if="user" style="height: 100%">
<el-header>
<el-header v-if="user.role !== 'pending'">
<admin-navbar v-if="userType === 'admin'" />
<client-navbar v-else-if="userType === 'client'" />
<volunteer-navbar v-else-if="userType === 'volunteer'" />
Expand Down
2 changes: 1 addition & 1 deletion sadeaf-web/pages/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export default {
},
methods: {
navigateToRoleHome() {
this.$router.replace(ROLE_PROFILE_PAGE_MAPPING[this.userType]);
this.$router.replace(ROLE_PROFILE_PAGE_MAPPING[this.userType] || '/pending');
},
},
computed: {
Expand Down

0 comments on commit ee15e84

Please sign in to comment.