queryService->buildDailyAttendanceData( (string)$request->query('semester', $this->attendanceService->currentSemester()), (string)$request->query('school_year', $this->attendanceService->currentSchoolYear()) ) ); } public function updateManagement(UpdateAttendanceManagementRequest $request): JsonResponse { try { return response()->json( $this->attendanceService->updateAttendanceManagement(auth()->user(), $request->validated()) ); } catch (Throwable $e) { return response()->json(['message' => $e->getMessage()], 422); } } public function addEntry(AdminAddAttendanceEntryRequest $request): JsonResponse { try { return response()->json( $this->attendanceService->adminAddEntry(auth()->user(), $request->validated()) ); } catch (Throwable $e) { return response()->json(['message' => $e->getMessage()], 422); } } }