import { getCurrentUser } from '@/lib/auth'; import { hasPageAccess } from '@/lib/permissions'; import { redirect } from 'next/navigation'; import DashboardLayout from '@/components/DashboardLayout'; import ArchivesTrajets from '@/components/ArchivesTrajets'; export default async function ArchivesPage() { const user = await getCurrentUser(); if (!user) { redirect('/login'); } const hasAccess = await hasPageAccess(user.id, '/dashboard/archives'); if (!hasAccess) { redirect('/dashboard/parametres'); } return (

Archives

Trajets archivés

); }