forked from baron/baron-sso
샘플 adminfront, devfront 구성. ory-keto-migrate 오류 해결
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { useQuery } from "@tanstack/react-query";
|
||||
import type { AxiosError } from "axios";
|
||||
import { Filter, ListChecks, Search, Terminal } from "lucide-react";
|
||||
import { fetchAuditLogs } from "../../lib/adminApi";
|
||||
|
||||
@@ -22,7 +23,8 @@ function AuditLogsPage() {
|
||||
|
||||
if (error) {
|
||||
const errMsg =
|
||||
(error as any).response?.data?.error || (error as Error).message;
|
||||
(error as AxiosError<{ error?: string }>).response?.data?.error ??
|
||||
(error as Error).message;
|
||||
return (
|
||||
<div className="p-8 text-center text-red-500">
|
||||
Error loading logs: {errMsg}
|
||||
@@ -88,10 +90,9 @@ function AuditLogsPage() {
|
||||
No audit logs found.
|
||||
</div>
|
||||
) : (
|
||||
logs.map((row, idx) => (
|
||||
logs.map((row) => (
|
||||
<div
|
||||
// biome-ignore lint/suspicious/noArrayIndexKey: simple list
|
||||
key={`${row.event_type}-${idx}`}
|
||||
key={`${row.event_type}-${row.user_id}-${row.timestamp}`}
|
||||
className="grid grid-cols-[1.2fr,1fr,1fr,1fr] items-center gap-2 py-3 text-sm"
|
||||
>
|
||||
<div className="font-semibold">{row.event_type}</div>
|
||||
|
||||
Reference in New Issue
Block a user