Penalty Übersicht für Nutzer und Penalty-Log

This commit is contained in:
PxlLoewe
2025-06-21 22:05:16 -07:00
parent 4732ecb770
commit 93962a9ce4
15 changed files with 402 additions and 25 deletions

View File

@@ -0,0 +1,30 @@
import { ExclamationTriangleIcon } from "@radix-ui/react-icons";
import { prisma } from "@repo/db";
import { Error } from "_components/Error";
export default async function Page({ params }: { params: Promise<{ id: string }> }) {
const { id } = await params;
const penalty = await prisma.penalty.findUnique({
where: {
id: Number(id),
},
include: {
User: true,
CreatedUser: true,
},
});
if (!penalty) return <Error statusCode={404} title="User not found" />;
return (
<div className="grid grid-cols-6 gap-4">
<div className="col-span-full">
<p className="text-2xl font-semibold text-left flex items-center gap-2">
<ExclamationTriangleIcon className="w-5 h-5" />
Strafe #{penalty.id}
</p>
</div>
</div>
);
}