• Модуль: timeman
  • Путь к файлу: ~/bitrix/modules/timeman/lib/model/schedule/schedule.php
  • Класс: BitrixTimemanModelScheduleSchedule
  • Вызов: Schedule::obtainShifts
public function obtainShifts()
{
	foreach (['SHIFTS', 'ALL_SHIFTS'] as $key)
	{
		try
		{
			$shifts = $this->get($key);
			if ($shifts === null)
			{
				continue;
			}
			$result = [];
			foreach ($shifts as $shift)
			{
				$result[] = $shift;
			}
			return $result;
		}
		catch (Exception $exc)
		{
		}
	}
	return [];
}