WIP 1.51.12: tickets, scan locks, attendance, allocations on v2

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ls1vMdg2GYqbnKZmPaX1ot
This commit is contained in:
2026-10-29 13:52:31 +02:00
co-authored by Claude Opus 5.5
parent 254a5daebd
commit a7231aad0c
28 changed files with 8048 additions and 96 deletions
@@ -346,7 +346,7 @@ export default function ReportsV2({ backHref }: { backHref?: string } = {}) {
const result: Record<string, { used: number; unused: number }> = {};
for (const id of eventIds) {
try {
const tickets = await apiFetch<Ticket[]>(`/api/tickets/event/${encodeURIComponent(id)}`, { authToken: token });
const tickets = await (apiV2Data("get", "/events/{id}/tickets", { params: { id: id }, authToken: token }) as Promise<Ticket[]>);
result[id] = { used: tickets.filter(t => t.isUsed).length, unused: tickets.filter(t => !t.isUsed).length };
} catch {
result[id] = { used: 0, unused: 0 };