refactor(admin): move event details page to admin section

- Moved EventDetailsPage from /events/:slug/details to /admin/events/:slug/details
- Added admin authentication check with redirect to login/home
- Updated all navigation links across the app:
  - EventsPage: "View details (admin)" button
  - EventChatPage: "View QR Code (admin)" link
  - EventCard: handleViewDetails navigation
- Fixed relative imports after moving to admin folder

This page contains admin-only features (QR codes, participants list,
matching config, scheduler config, matching runs) and should only be
accessible to administrators.
This commit is contained in:
Radosław Gierwiało
2025-12-03 19:52:00 +01:00
parent 179aaa8f16
commit eb5aacd797
5 changed files with 36 additions and 17 deletions

View File

@@ -180,10 +180,10 @@ const EventsPage = () => {
{/* Development mode: Show details link */}
{import.meta.env.DEV && (
<button
onClick={() => navigate(`/events/${event.slug}/details`)}
onClick={() => navigate(`/admin/events/${event.slug}/details`)}
className="w-full px-4 py-2 border border-gray-300 text-gray-700 rounded-md hover:bg-gray-50 transition-colors text-sm"
>
View details (dev)
View details (admin)
</button>
)}
</div>