Discord account Linkage, penalty update

This commit is contained in:
PxlLoewe
2026-01-06 03:07:09 +01:00
parent b16b719c74
commit 0ac943c63f
19 changed files with 388 additions and 49 deletions

View File

@@ -8,6 +8,7 @@ import { deleteBookingAPI, getBookingsAPI } from "(app)/_querys/bookings";
import { Button } from "@repo/shared-components";
import { formatTimeRange } from "../../helper/timerange";
import toast from "react-hot-toast";
import Link from "next/link";
interface BookingTimelineModalProps {
isOpen: boolean;
@@ -298,7 +299,17 @@ export const BookingTimelineModal = ({
? "LST"
: booking.Station.bosCallsignShort || booking.Station.bosCallsign}
</span>
<span className="text-sm font-medium">{booking.User.fullName}</span>
{currentUser?.permissions.includes("ADMIN_USER") ? (
<Link
href={`/admin/user/${booking.User.publicId}`}
className="link link-hover text-xs opacity-70"
>
{booking.User.fullName}
</Link>
) : (
<span className="text-sm font-medium">{booking.User.fullName}</span>
)}
</div>
<div className="flex items-center gap-2">
<div className="text-right">

View File

@@ -49,13 +49,13 @@ export default function SortableTable<TData>({
return (
<div className="overflow-x-auto">
<table className="table table-zebra w-full">
<table className="table-zebra table w-full">
<thead>
{table.getHeaderGroups().map((headerGroup) => (
<tr key={headerGroup.id}>
{headerGroup.headers.map((header) => (
<th key={header.id} onClick={header.column.getToggleSortingHandler()}>
<div className="flex items-center gap-1 cursor-pointer">
<div className="flex cursor-pointer items-center gap-1">
{flexRender(header.column.columnDef.header, header.getContext())}
{header.column.getIsSorted() === "asc" && <ChevronUp size={16} />}
{header.column.getIsSorted() === "desc" && <ChevronDown size={16} />}
@@ -75,7 +75,7 @@ export default function SortableTable<TData>({
))}
{table.getRowModel().rows.length === 0 && (
<tr>
<td colSpan={columns.length} className="text-center font-bold text-sm text-gray-500">
<td colSpan={columns.length} className="text-center text-sm font-bold text-gray-500">
Keine Daten gefunden
</td>
</tr>
@@ -104,6 +104,8 @@ export const RowsPerPage = ({
<option value={50}>50</option>
<option value={100}>100</option>
<option value={300}>300</option>
<option value={1000}>1000</option>
<option value={5000}>5000</option>
</select>
);
};