Additional event informations can be added

This commit is contained in:
2026-08-12 15:01:35 +02:00
parent 554166803b
commit 9581176a0c
28 changed files with 675 additions and 39 deletions
@@ -4,6 +4,8 @@ namespace App\Domains\Event\Controllers;
use App\Domains\Event\Actions\SetParticipationFees\SetParticipationFeesCommand;
use App\Domains\Event\Actions\SetParticipationFees\SetParticipationFeesRequest;
use App\Domains\Event\Actions\SetParticipationOptions\SetParticipationOptionsCommand;
use App\Domains\Event\Actions\SetParticipationOptions\SetParticipationOptionsRequest;
use App\Domains\Event\Actions\SetPaymentMethods\SetPaymentMethodsCommand;
use App\Domains\Event\Actions\SetPaymentMethods\SetPaymentMethodsRequest;
use App\Domains\Event\Actions\UpdateEvent\UpdateEventCommand;
@@ -142,6 +144,17 @@ class DetailsController extends CommonController {
return response()->json(['status' => $response->success ? 'success' : 'error']);
}
public function updateParticipationOptions(int $eventId, Request $request): JsonResponse
{
$event = $this->events->getById($eventId);
$setRequest = new SetParticipationOptionsRequest($event, (array)$request->input('questions', []));
$setCommand = new SetParticipationOptionsCommand($setRequest);
$response = $setCommand->execute();
return response()->json(['status' => $response->success ? 'success' : 'error', 'message' => $response->message]);
}
public function downloadPdfList(string $eventId, string $listType, Request $request): Response
{
$event = $this->events->getByIdentifier($eventId);
@@ -142,6 +142,7 @@ class SignupController extends CommonController {
$amount,
$registrationData['paymentMethod'] ?? null,
(array)($registrationData['paymentOptions'] ?? []),
(array)($registrationData['participationOptions'] ?? []),
);
$signupCommand = new SignUpCommand($signupRequest);