CleanLocationEventsAgent::getLocationEventsNeededToClean

  1. Bitrix24 API (v. 23.675.0)
  2. calendar
  3. CleanLocationEventsAgent
  4. getLocationEventsNeededToClean
  • Модуль: calendar
  • Путь к файлу: ~/bitrix/modules/calendar/lib/rooms/util/cleanlocationeventsagent.php
  • Класс: BitrixCalendarRoomsUtilCleanLocationEventsAgent
  • Вызов: CleanLocationEventsAgent::getLocationEventsNeededToClean
private function getLocationEventsNeededToClean(): array
{
	$toCleanLocationEvents = $this->getEmptyLocationEvents();
	//for now, we don't do that because of needing to re-save child events after removing booking
	//doing that may cause performance problems
	if (self::DO_CLEAR_DELETED_USER_LOCATION_EVENTS)
	{
		$toCleanLocationEvents = array_unique(
			array_merge($toCleanLocationEvents, $this->getDeletedUsersLocationEvents())
		);
	}

	return array_map(static function($toCleanLocationEvent){
		return (int)$toCleanLocationEvent['ID'];
	}, $toCleanLocationEvents);
}

Добавить комментарий