1
0
Fork 0
fahrPool/web/app/firma/page.tsx

27 lines
929 B
TypeScript

import { redirect } from "next/navigation";
import { ladeAdminKontext } from "@/lib/firma/admin-kontext";
import { FirmaEinstellungenForm } from "@/components/firma/FirmaEinstellungenForm";
import { LogoForm } from "@/components/firma/LogoForm";
import { Card } from "@/components/ui/Card";
export default async function FirmaPage() {
const kontext = await ladeAdminKontext();
if (!kontext.ok) {
redirect("/dashboard");
}
return (
<div className="mx-auto flex max-w-2xl flex-col gap-6 p-4 md:p-8">
<h1 className="text-xl font-semibold text-asphalt-grey">Firma</h1>
<Card>
<h2 className="mb-4 font-semibold text-asphalt-grey">Allgemein</h2>
<FirmaEinstellungenForm firma={kontext.firma} />
</Card>
<Card>
<h2 className="mb-4 font-semibold text-asphalt-grey">Logo</h2>
<LogoForm hatLogo={Boolean(kontext.firma.logo_pfad)} />
</Card>
</div>
);
}