fix: include cost unit when duplicating destination
This commit is contained in:
@@ -22,6 +22,8 @@ class DestinationDto
|
||||
#[Assert\NotBlank(message: 'Bitte angeben')]
|
||||
private ?string $hotelBusProId = null;
|
||||
|
||||
private ?string $costUnit = null;
|
||||
|
||||
private array $pickups = [];
|
||||
|
||||
public static function fromEntity(Destination $destination): static
|
||||
@@ -39,6 +41,7 @@ class DestinationDto
|
||||
->setHotelBusProId($destination->getHotelBusProId())
|
||||
->setCountry($destination->getCountry())
|
||||
->setPickups($pickupIds)
|
||||
->setCostUnit($destination->getCostUnit());
|
||||
;
|
||||
|
||||
return $instance;
|
||||
@@ -104,6 +107,18 @@ class DestinationDto
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getCostUnit(): ?string
|
||||
{
|
||||
return $this->costUnit;
|
||||
}
|
||||
|
||||
public function setCostUnit(?string $costUnit): static
|
||||
{
|
||||
$this->costUnit = $costUnit;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getPickups(): array
|
||||
{
|
||||
return $this->pickups;
|
||||
|
||||
Reference in New Issue
Block a user