diff --git a/src/app/dashboard/kalender/_components/calendar-overview-client.tsx b/src/app/dashboard/kalender/_components/calendar-overview-client.tsx index 889df2a..2009011 100644 --- a/src/app/dashboard/kalender/_components/calendar-overview-client.tsx +++ b/src/app/dashboard/kalender/_components/calendar-overview-client.tsx @@ -62,6 +62,8 @@ const categories = [ { label: "Fest", type: TerminType.KITA_FEST, color: "var(--good)" }, { label: "Geburtstag", type: TerminType.GEBURTSTAG_INTERN, color: "oklch(0.50 0.10 320)" }, { label: "Elterndienst", type: "elterndienst", color: "oklch(0.60 0.15 160)" }, + { label: "Mein Notdienst", type: "mein-notdienst", color: "oklch(0.60 0.18 45)" }, + { label: "Notdienst", type: "notdienst", color: "oklch(0.75 0.10 50)" }, { label: "Sonstiges", type: TerminType.SONSTIGES, color: "var(--ink-muted)" }, ]; @@ -113,15 +115,26 @@ export function CalendarOverviewClient({ ? item.description.toLowerCase().includes(query) : false; const familyMatch = - item.kind === "duty" && item.familyName + (item.kind === "duty" || item.kind === "notdienst") && item.familyName ? item.familyName.toLowerCase().includes(query) : false; - if (!titleMatch && !descMatch && !familyMatch) return false; + const childMatch = + item.kind === "notdienst" && item.childName + ? item.childName.toLowerCase().includes(query) + : false; + if (!titleMatch && !descMatch && !familyMatch && !childMatch) return false; } // 2. Category filter if (activeTypes.size > 0) { - const itemType = item.kind === "duty" ? "elterndienst" : item.type; + const itemType = + item.kind === "duty" + ? "elterndienst" + : item.kind === "notdienst" + ? item.isOwn + ? "mein-notdienst" + : "notdienst" + : item.type; if (!activeTypes.has(itemType)) return false; } @@ -309,6 +322,59 @@ export function CalendarOverviewClient({ )} + ) : item.kind === "notdienst" ? ( +
+ Kind: {item.childName} (Familie: {item.familyName}) +
+
+
{item.description}
@@ -697,7 +791,7 @@ function AgendaView({
+