From 047d49e0eb3d1803676c7449823609cfe2b3279d Mon Sep 17 00:00:00 2001 From: ssongliu <73214554+ssongliu@users.noreply.github.com> Date: Mon, 8 Jul 2024 18:21:23 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E8=B0=83=E6=95=B4=E7=97=85=E6=AF=92?= =?UTF-8?q?=E6=89=AB=E6=8F=8F=E8=AE=BE=E7=BD=AE=E7=95=8C=E9=9D=A2=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=20(#5713)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/api/modules/toolbox.ts | 2 +- frontend/src/lang/modules/en.ts | 1 + frontend/src/lang/modules/tw.ts | 1 + frontend/src/lang/modules/zh.ts | 1 + frontend/src/views/toolbox/clam/index.vue | 2 ++ .../src/views/toolbox/clam/setting/index.vue | 19 ++++++++++++------- 6 files changed, 18 insertions(+), 8 deletions(-) diff --git a/frontend/src/api/modules/toolbox.ts b/frontend/src/api/modules/toolbox.ts index 43010e57c..fbcfa3a2e 100644 --- a/frontend/src/api/modules/toolbox.ts +++ b/frontend/src/api/modules/toolbox.ts @@ -121,7 +121,7 @@ export const searchClamFile = (name: string, tail: string) => { return http.post(`/toolbox/clam/file/search`, { name: name, tail: tail }); }; export const updateClamFile = (name: string, file: string) => { - return http.post(`/toolbox/clam/file/update`, { name: name, file: file }); + return http.post(`/toolbox/clam/file/update`, { name: name, file: file }, TimeoutEnum.T_60S); }; export const searchClamBaseInfo = () => { return http.post(`/toolbox/clam/base`); diff --git a/frontend/src/lang/modules/en.ts b/frontend/src/lang/modules/en.ts index 80706056f..ff5999129 100644 --- a/frontend/src/lang/modules/en.ts +++ b/frontend/src/lang/modules/en.ts @@ -1099,6 +1099,7 @@ const message = { infectedDir: 'Infected Directory', scanDate: 'Scan Date', scanResult: 'Scan log tail', + tail: 'Lines', scanTime: 'Time Taken', infectedFiles: 'Infected Files', log: 'Details', diff --git a/frontend/src/lang/modules/tw.ts b/frontend/src/lang/modules/tw.ts index 7a1bef130..afe814c10 100644 --- a/frontend/src/lang/modules/tw.ts +++ b/frontend/src/lang/modules/tw.ts @@ -1040,6 +1040,7 @@ const message = { infectedDir: '隔離目錄', scanDate: '掃描時間', scanResult: '掃描報告條數', + tail: '日誌顯示行數', scanTime: '耗時', infectedFiles: '感染文件數', log: '詳情', diff --git a/frontend/src/lang/modules/zh.ts b/frontend/src/lang/modules/zh.ts index cabea57a3..87dc30091 100644 --- a/frontend/src/lang/modules/zh.ts +++ b/frontend/src/lang/modules/zh.ts @@ -1042,6 +1042,7 @@ const message = { infectedDir: '隔离目录', scanDate: '扫描时间', scanResult: '扫描报告条数', + tail: '日志显示行数', scanTime: '耗时', infectedFiles: '感染文件数', log: '详情', diff --git a/frontend/src/views/toolbox/clam/index.vue b/frontend/src/views/toolbox/clam/index.vue index d6eadbb95..1fe2ce26b 100644 --- a/frontend/src/views/toolbox/clam/index.vue +++ b/frontend/src/views/toolbox/clam/index.vue @@ -82,12 +82,14 @@ >
- - + + @@ -51,9 +56,9 @@ @ready="handleReady" :extensions="extensions" v-model="content" - :disabled="canUpdate()" + :disabled="!canUpdate()" /> - + {{ $t('commons.button.save') }}
@@ -89,15 +94,15 @@ const content = ref(); const confirmRef = ref(); const loadHeight = () => { - let height = globalStore.openMenuTabs ? '425px' : '395px'; - if (canUpdate()) { + let height = globalStore.openMenuTabs ? '405px' : '375px'; + if (!canUpdate()) { height = globalStore.openMenuTabs ? '383px' : '353px'; } return height; }; const canUpdate = () => { - return activeName.value.indexOf('-log') !== -1; + return activeName.value.indexOf('-log') === -1; }; const search = async (itemName: string) => {