From 7ad9e479cdb2fec98f920aa960384977f353f7a2 Mon Sep 17 00:00:00 2001 From: wren Date: Mon, 23 Mar 2026 20:33:38 +0800 Subject: [PATCH] fix: add pointCode to ReviewPointResult interface to survive build Vite/Remix tree-shaking was stripping pointCode from the return object because it wasn't declared in the ReviewPointResult interface. Also removed debug console.logs. Co-Authored-By: Claude Opus 4.6 (1M context) --- app/api/evaluation_points/reviews.ts | 8 ++------ app/components/reviews/ReviewPointsList.tsx | 7 ------- 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/app/api/evaluation_points/reviews.ts b/app/api/evaluation_points/reviews.ts index daaaa82..ac039b7 100644 --- a/app/api/evaluation_points/reviews.ts +++ b/app/api/evaluation_points/reviews.ts @@ -75,6 +75,7 @@ interface EvaluationPointGroup { interface ReviewPointResult { id: string | number; title: string; + pointCode?: string; groupName: string; status: string; content: string; @@ -364,12 +365,7 @@ export async function getReviewPoints(fileId: string, request: Request) { pointsMap.set(point.id, point); }); - // DEBUG: check if code field exists in point data - if (evaluationPointsData.length > 0) { - const sample = evaluationPointsData[0]; - console.log('[DEBUG] point sample keys:', Object.keys(sample)); - console.log('[DEBUG] point sample code:', sample.code, 'name:', sample.name); - } + // console.log('pointsMap-------', pointsMap); const groupsMap = new Map(); groupsData.forEach(group => { diff --git a/app/components/reviews/ReviewPointsList.tsx b/app/components/reviews/ReviewPointsList.tsx index 0d15ba9..7d053a8 100644 --- a/app/components/reviews/ReviewPointsList.tsx +++ b/app/components/reviews/ReviewPointsList.tsx @@ -781,13 +781,6 @@ export function ReviewPointsList({ * 过滤评查点 * 根据搜索文本和状态过滤条件筛选评查点 */ - // DEBUG: check all keys on first reviewPoint - if (reviewPoints.length > 0) { - console.log('[DEBUG] ALL KEYS:', Object.keys(reviewPoints[0])); - console.log('[DEBUG] pointCode:', reviewPoints[0].pointCode); - console.log('[DEBUG] full object sample:', JSON.stringify(reviewPoints[0]).substring(0, 500)); - } - const filteredReviewPoints = reviewPoints.filter(point => { // 匹配搜索文本 const matchesSearch = searchText === '' ||