chore: streamline property naming
This commit is contained in:
@@ -58,14 +58,9 @@ class BookingEditDto implements BookingDtoInterface
|
||||
$participantData->transportationOutbound = $outboundTransportation;
|
||||
$participantData->transportationInbound = $inboundTransportation;
|
||||
|
||||
// Backward compatibility: also set deprecated properties
|
||||
$participantData->transportationServiceTo = $outboundTransportation;
|
||||
$participantData->transportationServiceFro = $inboundTransportation;
|
||||
|
||||
// Pickup handling (currently only supports outbound pickup)
|
||||
$pickupOutbound = $booking->getPickupForParticipant($index);
|
||||
$participantData->pickupOutbound = $pickupOutbound;
|
||||
$participantData->pickup = $pickupOutbound; // Backward compatibility
|
||||
|
||||
$instance->participants[$index] = $participantData;
|
||||
}
|
||||
|
||||
@@ -71,11 +71,6 @@ class ParticipantDto
|
||||
// License plate for participants with parking (optional, visible only when parking is selected)
|
||||
public ?string $licensePlate = null;
|
||||
|
||||
// Deprecated properties for backward compatibility - will be removed in future version
|
||||
public ?Service $transportationServiceTo = null;
|
||||
public ?Service $transportationServiceFro = null;
|
||||
public ?Pickup $pickup = null;
|
||||
|
||||
public static function fromPersonalData(PersonalData $personalData): static
|
||||
{
|
||||
$instance = new static();
|
||||
@@ -98,6 +93,11 @@ class ParticipantDto
|
||||
return $instance;
|
||||
}
|
||||
|
||||
public function isApplicant(): bool
|
||||
{
|
||||
return 0 === $this->index;
|
||||
}
|
||||
|
||||
public function isCanceled(): bool
|
||||
{
|
||||
return 'S' === $this->status;
|
||||
|
||||
Reference in New Issue
Block a user