Add home page component; fix user state issues
must be sure to keep "anonymous" user represented as {} instead of null, otherwise getting errors. this also fixes the menu upon user login; previously it wasn't showing most options
This commit is contained in:
parent
2a1f5764a1
commit
721600b12d
7 changed files with 93 additions and 7 deletions
|
@ -2,7 +2,7 @@
|
|||
<section>
|
||||
<nav class="level is-mobile">
|
||||
|
||||
<div v-if="user"
|
||||
<div v-if="user.uuid"
|
||||
class="level-item">
|
||||
|
||||
<b-dropdown aria-role="menu">
|
||||
|
@ -43,7 +43,7 @@
|
|||
</b-dropdown>
|
||||
</div>
|
||||
|
||||
<div v-if="!user && showLoginButton"
|
||||
<div v-if="!user.uuid && showLoginButton"
|
||||
class="level-item">
|
||||
<b-button type="is-primary"
|
||||
tag="router-link" to="/login">
|
||||
|
@ -137,7 +137,7 @@ export default {
|
|||
if (this.allowFeedback !== null) {
|
||||
return this.allowFeedback
|
||||
}
|
||||
if (!this.allowAnonymousFeedback && !this.user) {
|
||||
if (!this.allowAnonymousFeedback && !this.user.uuid) {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue