diff --git a/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php b/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php index b3c7b967..453a3876 100644 --- a/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php +++ b/public/typo3conf/ext/ep_products/Classes/Domain/Repository/ProductRepository.php @@ -165,6 +165,7 @@ class ProductRepository extends AbstractRepository ->addGroupBy('date.hotel') ->addGroupBy('date.date_start') ->addGroupBy('date.nights') + ->having('available > 0') ->orderBy('important', 'DESC') ->addOrderBy('concept_sorting') ->addOrderBy('date_start') diff --git a/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php b/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php index c04d519b..adf410c3 100644 --- a/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php +++ b/public/typo3conf/ext/ep_products/Classes/Service/DateImportService.php @@ -561,7 +561,7 @@ class DateImportService implements SingletonInterface, LoggerAwareInterface $pax = (int) $roomXml->attributes()['MaxPax']; $availableTotal += $available * $pax; - if ($code !== static::CODE_BABYROOM && ($minPrice === 0 || $price < $minPrice)) { + if ($code !== static::CODE_BABYROOM && $available > 0 && ($minPrice === 0 || $price < $minPrice)) { $minPrice = $price; }