Add ignored room types
This commit is contained in:
@@ -43,6 +43,11 @@ class ContingentImportService implements SingletonInterface, LoggerAwareInterfac
|
|||||||
|
|
||||||
const ROOMCODE_STATUS = 'BelKal';
|
const ROOMCODE_STATUS = 'BelKal';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var string[]
|
||||||
|
*/
|
||||||
|
protected $ignoredRoomTypes = ['PDGS', 'TEAM'];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var ConfigurationManagerInterface
|
* @var ConfigurationManagerInterface
|
||||||
*/
|
*/
|
||||||
@@ -240,6 +245,9 @@ class ContingentImportService implements SingletonInterface, LoggerAwareInterfac
|
|||||||
}
|
}
|
||||||
$roomType = $roomTypes[$roomTypeBusProId];
|
$roomType = $roomTypes[$roomTypeBusProId];
|
||||||
$roomCode = $roomType['code'];
|
$roomCode = $roomType['code'];
|
||||||
|
if (in_array($roomCode, $this->ignoredRoomTypes, true)) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$availablePax = 0;
|
$availablePax = 0;
|
||||||
$capacity = 0;
|
$capacity = 0;
|
||||||
if ($roomType['ctrl'] === true) {
|
if ($roomType['ctrl'] === true) {
|
||||||
@@ -254,9 +262,6 @@ class ContingentImportService implements SingletonInterface, LoggerAwareInterfac
|
|||||||
$availableRooms = (int) $xmlRoom['frei'] > 0 ? (int) $xmlRoom['frei'] : 0;
|
$availableRooms = (int) $xmlRoom['frei'] > 0 ? (int) $xmlRoom['frei'] : 0;
|
||||||
$availablePax = $availableRooms * $roomType['pax'];
|
$availablePax = $availableRooms * $roomType['pax'];
|
||||||
}
|
}
|
||||||
if ($availablePax === 0 && $roomType['ctrl'] === false) {
|
|
||||||
//continue;
|
|
||||||
}
|
|
||||||
$minPrice = (int) $xmlRoom['abpreis'];
|
$minPrice = (int) $xmlRoom['abpreis'];
|
||||||
$minNights = (int) $xmlRoom['abpreis_naechte'];
|
$minNights = (int) $xmlRoom['abpreis_naechte'];
|
||||||
$additionalNightMinPrice = (int) $xmlRoom['abpreis_verlaengerung'];
|
$additionalNightMinPrice = (int) $xmlRoom['abpreis_verlaengerung'];
|
||||||
|
|||||||
Reference in New Issue
Block a user