add user email in topbar

This commit is contained in:
Gabriel Massadas
2022-07-05 22:30:05 +01:00
parent 029d9e6989
commit fffccb3f3f
3 changed files with 5 additions and 5 deletions
+2 -2
View File
@@ -4,10 +4,10 @@
<ul class="list-unstyled topnav-menu float-end mb-0">
<li class="dropdown notification-list topbar-dropdown">
<a v-if="$store.user && $store.user.email" class="nav-link dropdown-toggle nav-user me-0 waves-effect waves-light" data-bs-toggle="dropdown" href="#"
<a v-if="$store.state.user" class="nav-link dropdown-toggle nav-user me-0 waves-effect waves-light" data-bs-toggle="dropdown" href="#"
role="button" aria-haspopup="false" aria-expanded="false">
<span class="pro-user-name ms-1">
{{$store.user.email}} <i class="mdi mdi-chevron-down"></i>
{{$store.state.user}} <i class="mdi mdi-chevron-down"></i>
</span>
</a>
<div class="dropdown-menu dropdown-menu-end profile-dropdown ">
+2 -3
View File
@@ -4,9 +4,7 @@ import repo from '@/repo'
export default createStore({
state: {
user: {
email: null
},
user: null,
activeBucket: null,
currentFolder: '',
files: [],
@@ -28,6 +26,7 @@ export default createStore({
},
loadUserDisks (state, data) {
state.buckets = data.Buckets
state.user = data.user
this.commit('changeBucket', data.Buckets[0].Name)
this.dispatch('refreshObjects')
}
+1
View File
@@ -20,6 +20,7 @@
<div class="card-body">
<h3>Please enter your R2 tokens to continue</h3>
<span>These tokens will be securely stored in your account KV store and reused when you log in again in the future. <a href="https://developers.cloudflare.com/r2/platform/s3-compatibility/tokens/" target="_blank">See here on how to obtain the R2 tokens</a>.</span>
<div>
<div class="form-group">