Route tenant admin PWA via /event-admin

This commit is contained in:
Codex Agent
2025-10-10 15:20:52 +02:00
parent 417b1da484
commit 52197f216d
20 changed files with 112 additions and 75 deletions

View File

@@ -9,6 +9,7 @@ import { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/com
import { AdminLayout } from '../components/AdminLayout';
import { deletePhoto, featurePhoto, getEventPhotos, TenantPhoto, unfeaturePhoto } from '../api';
import { isAuthError } from '../auth/tokens';
import { adminPath } from '../constants';
export default function EventPhotosPage() {
const [searchParams] = useSearchParams();
@@ -81,7 +82,7 @@ export default function EventPhotosPage() {
<Card className="border-0 bg-white/85 shadow-xl shadow-pink-100/60">
<CardContent className="p-6 text-sm text-slate-600">
Kein Slug in der URL gefunden. Kehre zur Event-Liste zurueck und waehle dort ein Event aus.
<Button className="mt-4" onClick={() => navigate('/admin/events')}>
<Button className="mt-4" onClick={() => navigate(adminPath('/events'))}>
Zurueck zur Liste
</Button>
</CardContent>
@@ -93,7 +94,7 @@ export default function EventPhotosPage() {
const actions = (
<Button
variant="outline"
onClick={() => navigate(`/admin/events/view-slug=${encodeURIComponent(slug)}`)}
onClick={() => navigate(adminPath(`/events/view?slug=${encodeURIComponent(slug)}`))}
className="border-pink-200 text-pink-600 hover:bg-pink-50"
>
Zurueck zum Event
@@ -197,3 +198,4 @@ function EmptyGallery() {
</div>
);
}