From e56d199c3c8697c063aae3a21b5d47f8d0a4a836 Mon Sep 17 00:00:00 2001 From: yorn <1057707203@qq.com> Date: Wed, 29 Oct 2025 18:40:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=B5=8B=E8=AF=95=E6=A1=88?= =?UTF-8?q?=E5=8D=B7=E7=9A=84=E6=90=9C=E7=B4=A2=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/api/document-types/document-types.ts | 2 +- app/api/evaluation_points/rules-files.ts | 2 +- app/api/files/documents.ts | 2 +- app/api/files/files-upload.ts | 8 ++++---- app/config/api-config.ts | 24 +++++++++++++----------- app/routes/rules-files.tsx | 2 +- 6 files changed, 21 insertions(+), 19 deletions(-) diff --git a/app/api/document-types/document-types.ts b/app/api/document-types/document-types.ts index f59fa20..dd63bbe 100644 --- a/app/api/document-types/document-types.ts +++ b/app/api/document-types/document-types.ts @@ -262,7 +262,7 @@ export async function getDocumentTypes(searchParams: DocumentTypeSearchParams = filter['id'] = 'eq.1'; } else if (searchParams.reviewType === 'record') { // 如果是卷宗类型,只显示id=2或id=3的文档类型 - filter['id'] = 'in.(2,3)'; + filter['id'] = 'in.(2,3,155)'; } } diff --git a/app/api/evaluation_points/rules-files.ts b/app/api/evaluation_points/rules-files.ts index f809967..7c64a9c 100644 --- a/app/api/evaluation_points/rules-files.ts +++ b/app/api/evaluation_points/rules-files.ts @@ -176,7 +176,7 @@ export async function getReviewFiles(searchParams: DocumentSearchParams = {}, do let p_typeid: number[] | null = null; if (fileType) { if (fileType === 'record') { - p_typeid = [2, 3]; + p_typeid = [2, 3, 155]; } else if (fileType === 'contract') { p_typeid = [1]; } else { diff --git a/app/api/files/documents.ts b/app/api/files/documents.ts index 6dfe3ea..4d6bab6 100644 --- a/app/api/files/documents.ts +++ b/app/api/files/documents.ts @@ -231,7 +231,7 @@ export async function getDocuments(searchParams: DocumentSearchParams = {}): Pro if (reviewType === 'contract') { documentTypes = [1]; } else if (reviewType === 'record') { - documentTypes = [2, 3]; + documentTypes = [2, 3, 155]; } } diff --git a/app/api/files/files-upload.ts b/app/api/files/files-upload.ts index 57445cd..cde004d 100644 --- a/app/api/files/files-upload.ts +++ b/app/api/files/files-upload.ts @@ -594,9 +594,9 @@ export async function getTodayDocuments(userInfo?: { user_id?: number; [key: str if (reviewType === 'record') { // 如果是卷宗类型,只显示type_id=2或type_id=3的文档 if (params.filter) { - params.filter['type_id'] = 'in.(2,3)'; + params.filter['type_id'] = 'in.(2,3,155)'; } else { - params.filter = { 'type_id': 'in.(2,3)' }; + params.filter = { 'type_id': 'in.(2,3,155)' }; } } @@ -651,9 +651,9 @@ export async function getDocumentTypes(reviewType?: string, token?: string): Pro } else if (reviewType === 'record') { // 如果是卷宗类型,只显示id=2或id=3的文档类型 if (params.filter) { - params.filter['id'] = 'in.(2,3)'; + params.filter['id'] = 'in.(2,3,155)'; } else { - params.filter = { 'id': 'in.(2,3)' }; + params.filter = { 'id': 'in.(2,3,155)' }; } } diff --git a/app/config/api-config.ts b/app/config/api-config.ts index 66419aa..255b356 100644 --- a/app/config/api-config.ts +++ b/app/config/api-config.ts @@ -72,12 +72,12 @@ const portConfigs: Record> = { // 主要 // 梅州 '51703': { - baseUrl: 'http://172.16.0.55:8073', - documentUrl: 'http://172.16.0.55:8073/docauditai/', - uploadUrl: 'http://172.16.0.55:8073/admin/documents' - // baseUrl: 'http://nas.7bm.co:8873', - // documentUrl: 'http://nas.7bm.co:8873/docauditai/', - // uploadUrl: 'http://nas.7bm.co:8873/admin/documents' + // baseUrl: 'http://172.16.0.55:8073', + // documentUrl: 'http://172.16.0.55:8073/docauditai/', + // uploadUrl: 'http://172.16.0.55:8073/admin/documents' + baseUrl: 'http://nas.7bm.co:8073', + documentUrl: 'http://nas.7bm.co:8073/docauditai/', + uploadUrl: 'http://nas.7bm.co:8073/admin/documents' }, @@ -136,11 +136,14 @@ const configs: Record = { // 测试环境 testing: { - baseUrl: 'http://nas.7bm.co:8873', - documentUrl: 'http://nas.7bm.co:8873/docauditai/', - uploadUrl: 'http://nas.7bm.co:8873/admin/documents', + // baseUrl: 'http://172.16.0.55:8873', + // documentUrl: 'http://172.16.0.55:8873/docauditai/', + // uploadUrl: 'http://172.16.0.55:8873/admin/documents', + baseUrl: 'http://nas.7bm.co:8073', + documentUrl: 'http://nas.7bm.co:8073/docauditai/', + uploadUrl: 'http://nas.7bm.co:8073/admin/documents', oauth: { - serverUrl: 'http://10.79.112.85', // IDaaS服务器地址 + serverUrl: 'http://10.79.112.85', // IDaaS服务器地址 clientId: '54d2a619fe5c81ae1250434c441fccccqMtKwh7H4fO', clientSecret: 'placeholder', // 需要替换为实际的Client Secret redirectUri: 'http://10.79.97.17/', // 回调地址 @@ -159,7 +162,6 @@ const configs: Record = { oauth: { serverUrl: 'http://10.79.112.85', // IDaaS服务器地址 clientId: '54d2a619fe5c81ae1250434c441fccccqMtKwh7H4fO', - // clientSecret: 'VYk1AC5XIJEfnEXwyq0u9JEY3fi3byCfSD58zANGeb', // 需要替换为实际的Client Secret // ⚠️ 安全警告:clientSecret 不应该硬编码在代码中 // 请在生产环境使用环境变量 OAUTH_CLIENT_SECRET clientSecret: 'placeholder', // 占位符,实际值从环境变量获取 diff --git a/app/routes/rules-files.tsx b/app/routes/rules-files.tsx index 92ab547..b71bed8 100644 --- a/app/routes/rules-files.tsx +++ b/app/routes/rules-files.tsx @@ -206,7 +206,7 @@ export default function RulesFiles() { setDocumentTypes(filteredTypes); } else if (storedReviewType === 'record') { // 只保留 id=2 和 id=3 的选项 - const filteredTypes = allDocumentTypes.filter((type: {id: number}) => type.id === 2 || type.id === 3); + const filteredTypes = allDocumentTypes.filter((type: {id: number}) => type.id === 2 || type.id === 3 || type.id === 155); setDocumentTypes(filteredTypes); }