2022-09-16 21:11:44 +02:00
|
|
|
<template>
|
2022-09-19 22:06:26 +02:00
|
|
|
<div class="flex flex-col gap-5 mx-auto p-2 w-full max-w-md">
|
2022-09-16 21:11:44 +02:00
|
|
|
<div>
|
|
|
|
<h1 class="text-xl ml-2 font-bold">Info</h1>
|
|
|
|
<div class="container">
|
|
|
|
<div class="item">
|
2022-09-22 17:10:36 +02:00
|
|
|
Email: <b>{{ user.email }}</b>
|
|
|
|
</div>
|
|
|
|
<div class="divider" />
|
|
|
|
<div class="item">
|
|
|
|
Personen: <b>{{ userPersons.map(a => a.fullName).join(', ')}}</b>
|
|
|
|
</div>
|
|
|
|
<div class="divider" />
|
|
|
|
<div class="item">
|
2023-01-22 15:04:12 +01:00
|
|
|
Groepen: <b>{{ groups.join(', ') }}</b>
|
2022-09-22 17:10:36 +02:00
|
|
|
</div>
|
|
|
|
<div v-if="userPersons.map(a => a.diploma).filter(n => n !== '').join('')" class="divider" />
|
|
|
|
<div v-if="userPersons.map(a => a.diploma).filter(n => n !== '').join('')" class="item">
|
|
|
|
Diploma: <b>{{ userPersons.map(a => a.diploma).filter(n => n !== '').join(', ')}}</b>
|
2022-09-16 21:11:44 +02:00
|
|
|
</div>
|
2022-12-29 12:54:58 +01:00
|
|
|
<div class="divider" />
|
|
|
|
<NuxtLink to="/settings/privacypolicy" class="item-hover py-2 rounded-t flex items-center">
|
2023-01-22 15:04:12 +01:00
|
|
|
<span>Privacybeleid</span>
|
2022-12-29 12:54:58 +01:00
|
|
|
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
|
|
|
</NuxtLink>
|
2022-09-16 21:11:44 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div>
|
|
|
|
<h1 class="text-xl ml-2 font-bold">Account</h1>
|
2022-09-20 15:53:44 +02:00
|
|
|
<div class="container">
|
2022-09-26 16:23:45 +02:00
|
|
|
<NuxtLink to="/settings/config/managerelatiecodes" class="item-hover py-2 rounded-t flex items-center">
|
|
|
|
<span>Beheer Personen</span>
|
|
|
|
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
|
|
|
</NuxtLink>
|
|
|
|
<div class="divider" />
|
|
|
|
<NuxtLink to="/settings/config/changepassword" class="item-hover py-2 flex items-center">
|
2023-01-22 15:12:15 +01:00
|
|
|
<span>Wachtwoord Wijzigen</span>
|
2022-09-26 16:23:45 +02:00
|
|
|
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
|
|
|
</NuxtLink>
|
|
|
|
<div class="divider" />
|
|
|
|
<NuxtLink to="/settings/config/changeemail" class="item-hover py-2 flex items-center">
|
2023-01-22 15:12:15 +01:00
|
|
|
<span>Email Wijzigen</span>
|
2022-09-26 16:23:45 +02:00
|
|
|
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
|
|
|
</NuxtLink>
|
|
|
|
<div class="divider" />
|
|
|
|
<div @click="logout" class="item-hover rounded-b flex items-center">
|
2023-01-22 15:04:12 +01:00
|
|
|
Uitloggen
|
2022-09-20 15:53:44 +02:00
|
|
|
</div>
|
2022-09-16 21:11:44 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
2022-11-06 15:13:58 +01:00
|
|
|
<div v-if="userData.admin">
|
2022-09-16 21:11:44 +02:00
|
|
|
<h1 class="text-xl ml-2 font-bold">Admin</h1>
|
|
|
|
<div class="container">
|
|
|
|
<NuxtLink to="/settings/admin/users" class="rounded-t item-hover py-2 flex items-center">
|
2023-01-22 15:04:12 +01:00
|
|
|
<span>Beheer gebruikers</span>
|
2022-09-16 21:11:44 +02:00
|
|
|
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
|
|
|
</NuxtLink>
|
|
|
|
<div class="divider" />
|
|
|
|
<NuxtLink to="/settings/admin/ledenlijst" class="rounded-b item-hover py-2 flex items-center">
|
|
|
|
<span>Ledenlijst</span>
|
|
|
|
<Icon class="ml-auto" size="2em" name="ion:arrow-forward"/>
|
|
|
|
</NuxtLink>
|
|
|
|
</div>
|
|
|
|
</div>
|
2022-09-20 17:33:15 +02:00
|
|
|
<div>
|
|
|
|
<h2 class="text-center font-bold">Gemaakt door <u><a href="https://xeovalyte.com/">Timo Boomers</a></u></h2>
|
|
|
|
</div>
|
2022-09-16 21:11:44 +02:00
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script setup>
|
2022-09-20 15:53:44 +02:00
|
|
|
import { signOut } from "firebase/auth";
|
|
|
|
|
2022-09-16 21:11:44 +02:00
|
|
|
definePageMeta({
|
|
|
|
title: 'Settings'
|
|
|
|
})
|
2022-09-20 15:53:44 +02:00
|
|
|
|
2022-09-22 17:10:36 +02:00
|
|
|
const { auth, userData, userPersons, user } = inject('firebase')
|
|
|
|
|
|
|
|
const groups = computed(() => {
|
|
|
|
return [...new Set(userPersons.value.map(a => a.groups.join()).join().split(','))]
|
|
|
|
})
|
2022-09-20 15:53:44 +02:00
|
|
|
|
|
|
|
const logout = () => {
|
|
|
|
signOut(auth.value)
|
|
|
|
.catch((error) => {
|
|
|
|
console.log(error)
|
|
|
|
})
|
|
|
|
}
|
2022-12-29 12:54:58 +01:00
|
|
|
</script>
|