Fetch reservation with unit
This commit is contained in:
@ -123,7 +123,7 @@ class Reservation extends Ideal\Service\API
|
||||
$date = new DateTimeImmutable($data['date']);
|
||||
} catch (DateMalformedStringException) {}
|
||||
try {
|
||||
$reservation = $this->reservationRepository->fetchByBuyerAndDate($data['buyer_rut'], $date);
|
||||
$reservation = $this->reservationRepository->fetchByBuyerAndUnitAndDate($data['buyer_rut'], (int) $data['units'][0], $date);
|
||||
|
||||
if (array_key_exists('broker_rut', $data) and $data['broker_rut'] !== '') {
|
||||
try {
|
||||
|
Reference in New Issue
Block a user