From 7aaa663cc467a7da9291fbd20d14b8d1ae524a5d Mon Sep 17 00:00:00 2001 From: chengkai3 Date: Sat, 27 Jun 2026 07:50:43 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20[FL-193]=20=E4=BF=AE=E5=A4=8D=20lightnin?= =?UTF-8?q?g-distribution=20=E9=A1=B5=E9=9D=A2=20TypeScript=20=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修正 EventsModal 和 ScatterModal 组件中 fetchWithAuth 参数类型定义 - 添加缺失的 LightningImportBatchEventItem 类型导入 - 确保类型签名与 useAuth hook 返回的 fetchWithAuth 一致 Co-Authored-By: Claude Sonnet 4.6 Co-authored-by: multica-agent --- web/src/app/admin/lightning-distribution/page.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/web/src/app/admin/lightning-distribution/page.tsx b/web/src/app/admin/lightning-distribution/page.tsx index 8901917..778c639 100644 --- a/web/src/app/admin/lightning-distribution/page.tsx +++ b/web/src/app/admin/lightning-distribution/page.tsx @@ -45,6 +45,7 @@ import type { LightningImportBatchSummary, LightningImportBatchListResponse, LightningImportBatchEventsResponse, + LightningImportBatchEventItem, } from "@/types/auth"; type ImportFormValues = { @@ -781,7 +782,7 @@ function EventsModal({ batch: LightningImportBatchSummary | null; open: boolean; onClose: () => void; - fetchWithAuth: (input: RequestInfo, init?: RequestInit) => Promise; + fetchWithAuth: (path: string, init?: RequestInit, retryOnUnauthorized?: boolean) => Promise; }) { const eventsQuery = useQuery({ queryKey: [ @@ -909,7 +910,7 @@ function ScatterModal({ batch: LightningImportBatchSummary | null; open: boolean; onClose: () => void; - fetchWithAuth: (input: RequestInfo, init?: RequestInit) => Promise; + fetchWithAuth: (path: string, init?: RequestInit, retryOnUnauthorized?: boolean) => Promise; distributionFilters: DistributionFilterValues; }) { const distributionStatsPath = useMemo(() => {