feat: 1. 将交叉评查转移在入口页。

2. 交叉评查渲染的pdf预览组件复用评查点详情的,同时在评查结果中的数据也添加坐标信息。
This commit is contained in:
2025-11-26 10:49:15 +08:00
parent d1f764028c
commit fe75b4fabd
8 changed files with 181 additions and 93 deletions
+9 -9
View File
@@ -181,18 +181,18 @@ export function FilePreview({ fileContent, activeReviewPointResultId, targetPage
}, [targetPage, numPages, fileContent, activeReviewPointResultId, isStructuredView, isPdf]);
// 调试日志
console.log('[FilePreview] 组件渲染', {
real_path,
fileExtension,
isDocx,
isPdf,
hasPath: !!fileContent.path,
hasTemplatePath: !!fileContent.template_contract_path
});
// console.log('[FilePreview] 组件渲染', {
// real_path,
// fileExtension,
// isDocx,
// isPdf,
// hasPath: !!fileContent.path,
// hasTemplatePath: !!fileContent.template_contract_path
// });
// 如果是PDF文件,直接使用PdfPreview组件
if (isPdf && real_path) {
console.log('[FilePreview] 渲染PDF预览', { real_path, targetPage, charPositions });
// console.log('[FilePreview] 渲染PDF预览', { real_path, targetPage, charPositions });
const pageOffset = fileContent.ocrResult?.__meta?.page_offset || 0;
return (
<PdfPreview
@@ -56,14 +56,14 @@ export function PdfPreview({
onZoomChange
}: PdfPreviewProps) {
// 调试日志
console.log('[PdfPreview] 组件渲染', {
filePath,
targetPage,
charPositions,
isStructuredView,
activeReviewPointResultId,
pageOffset
});
// console.log('[PdfPreview] 组件渲染', {
// filePath,
// targetPage,
// charPositions,
// isStructuredView,
// activeReviewPointResultId,
// pageOffset
// });
// ============ 状态管理 ============
const [numPages, setNumPages] = useState<number | null>(null);