Skip to content

Commit 940b4ed

Browse files
committed
Comment out stall registration button in the template and restrict stall routes.
1 parent 7e37c2c commit 940b4ed

2 files changed

Lines changed: 13 additions & 8 deletions

File tree

src/Controller/StallController.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ public function __construct(private readonly EntityManagerInterface $em, private
2626
#[Route('/stall/create', name: 'app_stall_create')]
2727
public function create(Request $request): Response
2828
{
29+
throw $this->createAccessDeniedException();
30+
2931
$stall = new Stall();
3032

3133
$form = $this->createForm(StallType::class, $stall);
@@ -74,6 +76,9 @@ public function edit(
7476
Request $request,
7577
#[MapEntity(mapping: ['uuid' => 'privateUuid'])] Stall $stall
7678
): Response {
79+
80+
return $this->redirectToRoute('index');
81+
7782
$form = $this->createForm(StallType::class, $stall);
7883
$form->handleRequest($request);
7984

templates/index/index.html.twig

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@
1010
<p class="text-gray-700 font-medium sm:text-xl dark:text-gray-200">Am 31. Oktober 2025 von 10 Uhr bis 17 Uhr</p>
1111
<p class="mb-1 text-lg font-medium text-gray-700 lg:text-xl sm:px-16 xl:px-48 dark:text-gray-200">Die Stadt entdecken 🏡, Nachbarn kennenlernen 🤝, Trödeln 🛍️</p>
1212

13-
<div class="mt-5">
14-
<a href="{{ path('app_stall_create') }}" class="inline-flex items-center gradient-button hover:opacity-90 focus:ring-4 focus:ring-primary-300 font-bold rounded-lg text-base px-6 py-3.5 me-2 mb-2 focus:outline-none dark:focus:ring-primary-800 gap-2">
15-
<svg class="w-6 h-6 text-gray-800 dark:text-white" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24">
16-
<path fill-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Zm11-4.243a1 1 0 1 0-2 0V11H7.757a1 1 0 1 0 0 2H11v3.243a1 1 0 1 0 2 0V13h3.243a1 1 0 1 0 0-2H13V7.757Z" clip-rule="evenodd"/>
17-
</svg>
13+
{# <div class="mt-5">#}
14+
{# <a href="{{ path('app_stall_create') }}" class="inline-flex items-center gradient-button hover:opacity-90 focus:ring-4 focus:ring-primary-300 font-bold rounded-lg text-base px-6 py-3.5 me-2 mb-2 focus:outline-none dark:focus:ring-primary-800 gap-2">#}
15+
{# <svg class="w-6 h-6 text-gray-800 dark:text-white" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24">#}
16+
{# <path fill-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10-4.477 10-10 10S2 17.523 2 12Zm11-4.243a1 1 0 1 0-2 0V11H7.757a1 1 0 1 0 0 2H11v3.243a1 1 0 1 0 2 0V13h3.243a1 1 0 1 0 0-2H13V7.757Z" clip-rule="evenodd"/>#}
17+
{# </svg>#}
1818

19-
Melde deinen Stand an
20-
</a>
21-
</div>
19+
{# Melde deinen Stand an#}
20+
{# </a>#}
21+
{# </div>#}
2222
</div>
2323

2424
<div class="px-4 map-controls" {{ stimulus_controller('map-controls') }}>

0 commit comments

Comments
 (0)