|
|
|
@@ -41,21 +41,21 @@ class UserTripEventApiToEntityMapper implements MapperInterface |
|
|
|
} |
|
|
|
|
|
|
|
$userTrip = $this->microMapper->map($dto->userTripIri, UserTrip::class, [ |
|
|
|
MicroMapperInterface::MAX_DEPTH => 1, |
|
|
|
MicroMapperInterface::MAX_DEPTH => 3, |
|
|
|
]); |
|
|
|
if (!$userTrip) { |
|
|
|
throw new \Exception('UserTrip not found'); |
|
|
|
} |
|
|
|
|
|
|
|
$event = $this->microMapper->map($dto->eventIri, Event::class, [ |
|
|
|
MicroMapperInterface::MAX_DEPTH => 1, |
|
|
|
MicroMapperInterface::MAX_DEPTH => 3, |
|
|
|
]); |
|
|
|
if (!$event) { |
|
|
|
throw new \Exception('Event not found'); |
|
|
|
} |
|
|
|
|
|
|
|
$location = $this->microMapper->map($dto->locationIri, Location::class, [ |
|
|
|
MicroMapperInterface::MAX_DEPTH => 1, |
|
|
|
MicroMapperInterface::MAX_DEPTH => 3, |
|
|
|
]); |
|
|
|
if (!$location) { |
|
|
|
throw new \Exception('Location not found'); |
|
|
|
@@ -72,7 +72,7 @@ class UserTripEventApiToEntityMapper implements MapperInterface |
|
|
|
assert($entity instanceof UserTripEvent); |
|
|
|
|
|
|
|
$userTrip = $this->microMapper->map($dto->userTripIri, UserTrip::class, [ |
|
|
|
MicroMapperInterface::MAX_DEPTH => 1, |
|
|
|
MicroMapperInterface::MAX_DEPTH => 3, |
|
|
|
]); |
|
|
|
if (!$userTrip) { |
|
|
|
throw new \Exception('UserTrip not found'); |
|
|
|
@@ -80,7 +80,7 @@ class UserTripEventApiToEntityMapper implements MapperInterface |
|
|
|
$entity->setUserTrip($userTrip); |
|
|
|
|
|
|
|
$event = $this->microMapper->map($dto->eventIri, Event::class, [ |
|
|
|
MicroMapperInterface::MAX_DEPTH => 1, |
|
|
|
MicroMapperInterface::MAX_DEPTH => 3, |
|
|
|
]); |
|
|
|
if (!$event) { |
|
|
|
throw new \Exception('Event not found'); |
|
|
|
@@ -88,7 +88,7 @@ class UserTripEventApiToEntityMapper implements MapperInterface |
|
|
|
$entity->setEvent($event); |
|
|
|
|
|
|
|
$location = $this->microMapper->map($dto->locationIri, Location::class, [ |
|
|
|
MicroMapperInterface::MAX_DEPTH => 1, |
|
|
|
MicroMapperInterface::MAX_DEPTH => 3, |
|
|
|
]); |
|
|
|
if (!$location) { |
|
|
|
throw new \Exception('Location not found'); |
|
|
|
|