/** * get work shift length * @return int */ private function getWorkShiftLength() { $employeeService = new EmployeeService(); $employeeWorkShift = $employeeService->getEmployeeWorkShift($this->getEmployeeNumber()); if ($employeeWorkShift != null) { return $employeeWorkShift->getWorkShift()->getHoursPerDay(); } else { return WorkShift::DEFAULT_WORK_SHIFT_LENGTH; } }