Files
var-monorepo/apps/dispatch/app/pilot/layout.tsx
PxlLoewe 50f42e99d3 feat: Implement connected user API and integrate chat and report components
- Added API routes for fetching connected users, keywords, missions, and stations.
- Created a new QueryProvider component for managing query states and socket events.
- Introduced connection stores for dispatch and pilot, managing socket connections and states.
- Updated Prisma schema for connected aircraft model.
- Enhanced UI with toast notifications for status updates and chat interactions.
- Implemented query functions for fetching connected users and keywords with error handling.
2025-05-07 00:43:45 -07:00

27 lines
553 B
TypeScript

import type { Metadata } from "next";
import Navbar from "./_components/navbar/Navbar";
import { redirect } from "next/navigation";
import { getServerSession } from "../api/auth/[...nextauth]/auth";
export const metadata: Metadata = {
title: "VAR v2: Disponent",
description: "Die neue VAR Leitstelle.",
};
export default async function RootLayout({
children,
}: Readonly<{
children: React.ReactNode;
}>) {
const session = await getServerSession();
if (!session) {
redirect("/login");
}
return (
<>
<Navbar />
{children}
</>
);
}