Log in functionality

This commit is contained in:
Peter Papp
2021-03-15 09:23:53 +01:00
parent 6b67f861c3
commit ba902a30b3
16 changed files with 182 additions and 160 deletions
@@ -86,10 +86,7 @@ export default {
if (!this.$store.getters.user) return true
// Check if user has storage
return (
this.$store.getters.user.relationships.storage.data.attributes.used <=
100
)
return this.$store.getters.user.data.attributes.storage.used <= 100
},
directoryName() {
return this.currentFolder
@@ -1,7 +1,7 @@
<template>
<div class="user-avatar" :class="size">
<span v-if="isIncompletePayment || isNearlyFullStorageCapacity" class="notification"></span>
<img :src="user.data.attributes.avatar" :alt="user.data.attributes.name">
<img :src="user.data.relationships.settings.data.attributes.avatar" :alt="user.data.relationships.settings.data.attributes.name">
</div>
</template>
@@ -19,7 +19,7 @@
return this.user.data.attributes.incomplete_payment
},
isNearlyFullStorageCapacity() {
return this.config.storageLimit && this.user.relationships.storage.data.attributes.used > 95
return this.config.storageLimit && this.user.data.attributes.storage.used > 95
}
},
}