feat: centralize create/edit flow contexts, extract edit submit service

This commit is contained in:
Björn Fromme
2026-04-12 10:17:04 +02:00
parent f903f17ebd
commit 69705052b3
28 changed files with 1342 additions and 423 deletions
+29
View File
@@ -0,0 +1,29 @@
<?php
declare(strict_types=1);
namespace App\Form\Model;
use App\BusProNet\Model\BaseData;
use App\BusProNet\Model\Booking;
/**
* Bundles the data needed to render the booking edit flow.
*/
class BookingEditContext
{
/**
* @param array<int, ParticipantCardDataDto>|null $cardsData
*/
public function __construct(
public readonly BookingDto $bookingDto,
public readonly ?Booking $bookingData,
public readonly ?BaseData $mutableData,
public readonly BookingSummaryDto $summaryData,
public readonly ?array $cardsData = null,
public readonly bool $isDirty = false,
public readonly bool $isSubmitted = false,
public readonly bool $hasValidationErrors = false,
) {
}
}