Fix: Adjust end dates of unavailabilities for Groups.swiss
This commit is contained in:
@@ -144,8 +144,10 @@ class GroupsSwissService implements SingletonInterface, LoggerAwareInterface
|
||||
'status' => $contingentStatus,
|
||||
];
|
||||
} elseif (null !== $item && $itemStatus !== $contingentStatus) {
|
||||
// Set end date of current chart item to previous contingent's date
|
||||
$item['to'] = $contingent->getEnd();
|
||||
// Set end date of current chart item to previous day when following
|
||||
// status is OK
|
||||
$item['to'] = Contingent::STATUS_OK !== $contingentStatus ?
|
||||
$contingent->getEnd() : $contingent->getEnd()->modify('-1 day');
|
||||
// Translate status code for Groups.swiss
|
||||
$statusCode = Contingent::STATUS_ONREQUEST === $item['status'] ? 1 : 2;
|
||||
// Post chart item to API
|
||||
|
||||
Reference in New Issue
Block a user