Feste Profilfelder in Formularen, Geburtstage, anpassbare Startseite
Some checks failed
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 2m18s
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 2m21s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 2m40s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 2m34s
CI / PHP 8.3 / mysql:8.0 (pull_request) Failing after 3m8s
CI / PHP 8.4 / mysql:8.0 (pull_request) Failing after 3m6s
CI / PHP 8.4 / mysql:8.4 (pull_request) Failing after 2m43s
CI / PHP 8.3 / mysql:8.4 (pull_request) Failing after 2m47s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m1s

- Formulare: Felder fest aus dem Profil (nicht änderbar, Server setzt den
  Profilwert ein), Hinweis bei fehlender Profilangabe
- Geburtstage (optionales Plugin, standardmäßig aus): Tag und Monat freiwillig
  im Profil, Kachel, Liste /geburtstage, Pagebuilder-Block, Glückwunsch am
  eigenen Geburtstag; Sichtbarkeit alle/Abteilung/Standort
- Startseite: Kacheln je Bereich sortieren und ausblenden; eigene Kacheln
  (Bild mit Link, Text, Hinweis) mit Zeitraum und Zielgruppe
- Kern: optionale mitgelieferte Plugins, Startseitenbereich „top“,
  Profilabschnitte für Plugins, Kachel-Bezeichnungen

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Friederich Loheide 2026-09-26 09:51:19 +00:00
parent 435960725d
commit ee8dde93c0
262 changed files with 2385 additions and 692 deletions

View file

@ -0,0 +1,52 @@
<script setup>
import { computed } from 'vue';
import { Link } from '@inertiajs/vue3';
import { Cake } from '@lucide/vue';
import EmptyState from '@/components/EmptyState.vue';
import AppLayout from '@/layouts/AppLayout.vue';
import BirthdayItem from '../components/BirthdayItem.vue';
const props = defineProps({
birthdays: { type: Array, required: true },
scope: { type: String, required: true },
registered: { type: Boolean, default: false },
});
// Nach Tagen gruppiert: „Heute“, dann die folgenden Tage
const groups = computed(() => {
const result = [];
for (const item of props.birthdays) {
const last = result.at(-1);
last && last.date === item.date ? last.items.push(item) : result.push({ date: item.date, today: item.today, items: [item] });
}
return result;
});
const label = (group) => group.today ? 'Heute' : new Intl.DateTimeFormat('de-DE', { weekday: 'long', day: 'numeric', month: 'long' }).format(new Date(`${group.date}T12:00:00`));
</script>
<template>
<AppLayout title="Geburtstage">
<div class="mx-auto max-w-3xl">
<h1 class="text-2xl font-semibold tracking-tight">Geburtstage</h1>
<p class="mt-1 text-sm text-muted-foreground">Die nächsten 30 Tage · {{ scope }}</p>
<p v-if="!registered" class="mt-5 rounded-lg border bg-card px-4 py-3 text-sm">
Sie möchten auch in der Liste stehen? Tragen Sie Tag und Monat unter
<Link href="/profil/bearbeiten" class="font-medium text-brand-text hover:underline">Profil bearbeiten</Link> ein.
</p>
<div v-if="groups.length" class="mt-6 grid gap-5">
<section v-for="group in groups" :key="group.date" class="rounded-lg border bg-card">
<h2 class="border-b px-5 py-3 text-sm font-semibold" :class="group.today ? 'text-brand-text' : ''">{{ label(group) }}</h2>
<div class="divide-y px-5">
<BirthdayItem v-for="item in group.items" :key="item.person.id" :item="item" />
</div>
</section>
</div>
<div v-else class="mt-6 rounded-lg border bg-card"><EmptyState :icon="Cake" title="Keine Geburtstage in den nächsten 30 Tagen" /></div>
</div>
</AppLayout>
</template>