• Модуль: timeman
  • Путь к файлу: ~/bitrix/modules/timeman/lib/service/worktime/violation/fixedscheduleviolationbuilder.php
  • Класс: BitrixTimemanServiceWorktimeViolationFixedScheduleViolationBuilder
  • Вызов: FixedScheduleViolationBuilder::buildExactStartViolations
private function buildExactStartViolations($recordedStartSeconds)
{
	$violations = [];
	$violationsConfig = $this->getViolationRules();
	$maxExactStart = $violationsConfig->getMaxExactStart();
	if (!ViolationRules::isViolationConfigured($maxExactStart))
	{
		return [];
	}

	if ($recordedStartSeconds > $maxExactStart)
	{
		$violations[] = $this->createViolation(
			WorktimeViolation::TYPE_LATE_START,
			$this->getRecord()->getRecordedStartTimestamp(),
			$recordedStartSeconds - $maxExactStart
		);
	}

	return $violations;
}