add direct invitation link
All checks were successful
deploy / build-and-deploy (push) Successful in 21s

This commit is contained in:
2025-11-02 21:31:17 +01:00
parent 593e76dcb4
commit b2c24f394f
15 changed files with 365 additions and 39 deletions

View File

@@ -0,0 +1,32 @@
<script lang="ts">
import Icon from '@iconify/svelte';
import CrudPopup from '@components/admin/popup/CrudPopup.svelte';
import { addDirectInvitation, fetchDirectInvitations } from '@app/admin/directInvitations/directInvitations.ts';
// states
let createPopupOpen = $state(false);
// lifecycle
$effect(() => {
fetchDirectInvitations();
});
</script>
<div>
<button class="btn btn-soft w-full" onclick={() => (createPopupOpen = true)}>
<Icon icon="heroicons:plus-16-solid" />
<span>Neue direkte Einladung</span>
</button>
</div>
<CrudPopup
texts={{
title: 'Direkte Einladung erstellen',
submitButtonTitle: 'Erstellen',
confirmPopupTitle: 'Direkte Einladung erstellen',
confirmPopupMessage: 'Bist du sicher, dass die direkte Einladung erstellt werden soll?.'
}}
target={null}
onSubmit={addDirectInvitation}
bind:open={createPopupOpen}
/>