#41 Ids for the users and route fix

This commit is contained in:
Dominic Villemure
2024-05-13 22:49:52 -04:00
parent f8e221a194
commit 83695b663c
5 changed files with 17 additions and 7 deletions

View File

@@ -19,7 +19,7 @@
<img src="/images/usersmedia/anonyme/profilepictures/profileAnonymeSquare.png"
class="header-profile-icon mr-2" alt="Logo">
<v-btn flat style="min-width: 200px; font-size: 1.3rem;" dark v-bind="props">
INVITÉ
{{ currentUserName }}
</v-btn>
</div>
</v-col>
@@ -87,9 +87,19 @@
</body>
</template>
<script setup>
import { ref } from 'vue';
<script async setup>
import { onBeforeMount, ref } from 'vue';
import {useClient} from "@/plugins/api.js";
const client = useClient();
const drawer = ref(false);
const currentUserName = ref("INVITÉ");
onBeforeMount(async () => {
const myUser = await client.get("/api/GetMyUser");
currentUserName.value = myUser.data.firstName + " " + myUser.data.lastName;
})
</script>