API 로그 필터 개선: 메서드 다중선택, 즉시 반영

This commit is contained in:
2025-12-17 19:04:14 +09:00
parent f7a8839ded
commit c15b2426d3
2 changed files with 26 additions and 12 deletions

View File

@@ -28,9 +28,14 @@ public function index(Request $request): View
$query->orderByDesc('created_at'); // 최신순
}
// 필터: HTTP 메서드
// 필터: HTTP 메서드 (다중 선택 가능)
if ($request->filled('method')) {
$query->where('method', $request->method);
$methods = $request->input('method');
if (is_array($methods)) {
$query->whereIn('method', $methods);
} else {
$query->where('method', $methods);
}
}
// 필터: 상태 코드