/** * Patient Dashboard Page * E2.S3: Default view showing patient overview and status */ import Link from 'next/link'; import { User, ClipboardList, FileText, ArrowRight, AlertCircle, Calendar, } from 'lucide-react'; import { getIntakesByPatientId } from './intakes/actions'; import { format } from 'date-fns'; import { nl } from 'date-fns/locale'; export default async function PatientDashboardPage({ params, }: { params: Promise<{ id: string }>; }) { const { id } = await params; // Fetch recent intakes (optional) let recentIntakes = []; try { const intakes = await getIntakesByPatientId(id); recentIntakes = intakes.slice(0, 3); // Get up to 3 most recent } catch (error) { // Silently fail - intakes are optional for dashboard console.error('Failed to fetch intakes for dashboard:', error); } return (
{/* Page Header */}

Dashboard

Overzicht van cliëntgegevens en voortgang

{/* Quick Actions Grid */}
{/* Basisgegevens Card */}

Basisgegevens

NAW & contactgegevens

{/* Screening Card */}

Screening

Activiteiten & besluit

{/* Intake Card */}

Intake

Gesprekken & registraties

{/* Recent Intakes Section */} {recentIntakes.length > 0 && (

Recente Intakes

Bekijk alle →
{recentIntakes.map((intake) => (

{intake.title}

{intake.department}
{format(new Date(intake.start_date), 'd MMM yyyy', { locale: nl })}
{intake.status}
))}
)} {/* Next Steps Section */}

Volgende stappen

  • • Controleer en vul basisgegevens aan indien nodig
  • • Start screening door activiteiten te loggen
  • • Upload relevante documenten (verwijsbrief, etc.)
  • • Neem screeningsbesluit om door te gaan naar intake
  • • Start een nieuwe intake via de{' '} Intake module
); }