feat: Add trust bridge and user activation
This commit is contained in:
parent
74afc805dc
commit
0f1cd98a80
8 changed files with 78 additions and 52 deletions
|
@ -1,20 +1,8 @@
|
|||
<template>
|
||||
<div>
|
||||
<b-notification
|
||||
v-if="!user.username"
|
||||
type="is-warning"
|
||||
aria-close-label="Close notification"
|
||||
>
|
||||
Um dein Konto zu aktivieren, musst du einen
|
||||
<strong>Benutzernamen</strong> festlegen.
|
||||
</b-notification>
|
||||
<b-notification
|
||||
v-if="!user.confidant_email"
|
||||
type="is-warning"
|
||||
aria-close-label="Close notification"
|
||||
>
|
||||
Um dein Konto zu aktivieren, musst du eine
|
||||
<strong>Vertrauensperson</strong> angeben.
|
||||
<b-notification type="is-info" aria-close-label="Close notification">
|
||||
Dein Konto ist noch nicht aktiv.
|
||||
<a @click="activate()">Jetzt aktivieren</a>
|
||||
</b-notification>
|
||||
<table class="table is-fullwidth">
|
||||
<tbody>
|
||||
|
@ -34,10 +22,6 @@
|
|||
<inline-editor v-model="user.confidantEmail" @input="user.save()" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>E-Mail-Adresse</td>
|
||||
<td>{{ user.email }} (bestätigt)</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
@ -53,5 +37,9 @@ import InlineEditor from "@/components/InlineEditor.vue";
|
|||
})
|
||||
export default class UserTable extends Vue {
|
||||
@Prop() private user!: User;
|
||||
|
||||
async activate(): Promise<void> {
|
||||
await this.user.activate();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
Reference in a new issue