From efbff69a91e0e3510b006d9e901514564af5865c Mon Sep 17 00:00:00 2001 From: super <2903208875@qq.com> Date: Sun, 29 Mar 2026 13:41:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E6=88=90=E5=88=A0=E9=99=A4=E5=93=81?= =?UTF-8?q?=E7=89=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/.env | 3 +- app/__pycache__/config.cpython-312.pyc | Bin 2137 -> 2140 bytes app/config.py | 4 +- .../brand/components/BrandDeleteBrandTab.vue | 40 +++++++++++++----- 4 files changed, 33 insertions(+), 14 deletions(-) diff --git a/app/.env b/app/.env index 0b38d5f..bda0ef7 100644 --- a/app/.env +++ b/app/.env @@ -7,6 +7,7 @@ proxy_url=https://api.jikip.com/ip-get?num=1&minute=1&format=json&area=all&proto proxy_mode=2 client_name=NanriAI -java_api_base=http://127.0.0.1:18080 +java_api_base=http://8.136.19.173:18080 +# java_api_base=http://127.0.0.1:18080 diff --git a/app/__pycache__/config.cpython-312.pyc b/app/__pycache__/config.cpython-312.pyc index db8fad9428a836dc02a348153f6b0ff53c4d9282..419f847b3ecf22aeae8cafca5268d5b8792e7002 100644 GIT binary patch delta 57 zcmca9a7TdmG%qg~0}x#5K9QNTk@qjNh-5}dNr9EVzJ;Elv6-HsrJkX=@n&h3Nz5#6 Mmj&D>Z)9Hq0QkZYJ^%m! delta 54 zcmca3a8rQyG%qg~0}zP!9?MkT$orRBP%NXQq`*pF-_Xch&j1JwH_Ne1VrFr^EZ{PE H3;PNHp)?PO diff --git a/app/config.py b/app/config.py index bfdfd2a..ce6fe05 100644 --- a/app/config.py +++ b/app/config.py @@ -18,8 +18,8 @@ proxy_url = os.getenv("proxy_url") proxy_mode = int(os.getenv("proxy_mode",1)) client_name=os.getenv("client_name") + ".exe" -JAVA_API_BASE = os.getenv("java_api_base", "http://127.0.0.1:18080") - +JAVA_API_BASE = os.getenv("java_api_base", "http://8.136.19.173:18080") +# JAVA_API_BASE = os.getenv("java_api_base", "http://127.0.0.1:18080") cache_path = "./user_data" diff --git a/frontend-vue/src/pages/brand/components/BrandDeleteBrandTab.vue b/frontend-vue/src/pages/brand/components/BrandDeleteBrandTab.vue index 2169a15..207f579 100644 --- a/frontend-vue/src/pages/brand/components/BrandDeleteBrandTab.vue +++ b/frontend-vue/src/pages/brand/components/BrandDeleteBrandTab.vue @@ -111,20 +111,20 @@
平台:{{ item.platform }}
国家数:{{ item.countryCount }}
去重后 {{ item.totalRows }} 条
-
+
任务进度 - {{ formatProgressPercent(item.taskId) }}% + {{ formatProgressPercent(item.taskId!) }}%
-
+
-
{{ formatProgress(item.taskId) }}
+
{{ formatProgress(item.taskId!) }}
{{ formatPreview(item.previewRows) }}
-
错误信息:{{ item.error }}
+
错误信息:{{ getDisplayError(item) }}
@@ -175,20 +175,20 @@
平台:{{ item.platform }}
国家数:{{ item.countryCount }}
去重后 {{ item.totalRows }} 条
-
+
任务进度 - {{ formatProgressPercent(item.taskId) }}% + {{ formatProgressPercent(item.taskId!) }}%
-
+
-
{{ formatProgress(item.taskId) }}
+
{{ formatProgress(item.taskId!) }}
{{ formatPreview(item.previewRows) }}
-
错误信息:{{ item.error }}
+
错误信息:{{ getDisplayError(item) }}
@@ -239,7 +239,6 @@ import { expandBrandFolderRecursive, type BrandExpandFolderItem } from '@/shared import { deleteDeleteBrandHistory, getDeleteBrandHistory, - getDeleteBrandTaskDetail, getDeleteBrandTaskDetails, getDeleteBrandTaskDownloadUrl, runDeleteBrand, @@ -276,6 +275,25 @@ const historySectionItems = computed(() => ) const hasVisibleItems = computed(() => currentSectionItems.value.length > 0 || historySectionItems.value.length > 0) +function getTaskStatus(taskId?: number) { + if (!taskId) return '' + return taskDetails.value[taskId]?.task?.status || '' +} + +function getDisplayError(item: DeleteBrandResultItem) { + if (item.error) return item.error + const taskId = item.taskId + if (!taskId) return '' + return taskDetails.value[taskId]?.task?.errorMessage || '' +} + +function shouldShowProgress(item: DeleteBrandResultItem) { + const taskId = item.taskId + if (!taskId || item.matched !== true) return false + const status = getTaskStatus(taskId) + return status === 'RUNNING' +} + function normalizeDeleteBrandItems(items: DeleteBrandResultItem[]) { return items.map((item) => { if (item.matched === false) {