From 9c14f1df25ff7578fd25e13a9aa1450f0b69e5f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=B3=B4=EA=B3=A4?= Date: Fri, 27 Feb 2026 09:53:27 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20[attendance]=20=EA=B7=BC=ED=83=9C?= =?UTF-8?q?=ED=98=84=ED=99=A9=20HTMX=20=EB=B6=80=EB=B6=84=20=EB=A1=9C?= =?UTF-8?q?=EB=93=9C=20=EC=8B=9C=20=EC=8A=A4=ED=81=AC=EB=A6=BD=ED=8A=B8=20?= =?UTF-8?q?=EB=AF=B8=EC=8B=A4=ED=96=89=20=EC=98=A4=EB=A5=98=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - index 메서드에 HX-Redirect 추가하여 전체 페이지 로드 보장 - 근태관리→근태현황 이동 시 switchTab null 참조 에러 해결 --- app/Http/Controllers/HR/AttendanceController.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/Http/Controllers/HR/AttendanceController.php b/app/Http/Controllers/HR/AttendanceController.php index d1e6ff76..8dad2083 100644 --- a/app/Http/Controllers/HR/AttendanceController.php +++ b/app/Http/Controllers/HR/AttendanceController.php @@ -18,8 +18,12 @@ public function __construct( /** * 근태현황 목록 페이지 (조회 전용) */ - public function index(): View + public function index(Request $request): View|Response { + if ($request->header('HX-Request')) { + return response('', 200)->header('HX-Redirect', route('hr.attendances.index')); + } + $stats = $this->attendanceService->getMonthlyStats(); $departments = $this->attendanceService->getDepartments(); $statusMap = Attendance::STATUS_MAP;