From 4b54e31dcbd8842dcb158543e97cd6d3a0a46914 Mon Sep 17 00:00:00 2001 From: qinjian Date: Wed, 27 Aug 2025 17:57:35 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E7=A7=BB=E9=99=A4=E9=BB=98=E8=AE=A4?= =?UTF-8?q?=E9=98=88=E5=80=BC=EF=BC=8C=E7=A1=AE=E4=BF=9D=E4=BB=8E=E7=9B=AE?= =?UTF-8?q?=E6=A0=87=E6=95=B0=E6=8D=AE=E4=B8=AD=E8=8E=B7=E5=8F=96=E6=A2=AF?= =?UTF-8?q?=E5=BA=A6=E5=92=8C=E9=94=9A=E7=82=B9=E9=98=88=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wuyuanbiaoba/components/TargetDetailModal.jsx | 4 ++-- .../sections/wuyuanbiaoba/components/TemplateModal.jsx | 1 - .../src/sections/wuyuanbiaoba/hooks/useTargetStorage.js | 8 ++++---- client/src/utils/parseProcessData.js | 1 - 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/client/src/sections/wuyuanbiaoba/components/TargetDetailModal.jsx b/client/src/sections/wuyuanbiaoba/components/TargetDetailModal.jsx index 7648fd3..64d1505 100644 --- a/client/src/sections/wuyuanbiaoba/components/TargetDetailModal.jsx +++ b/client/src/sections/wuyuanbiaoba/components/TargetDetailModal.jsx @@ -34,8 +34,8 @@ const TargetDetailModal = ({ name: targetData.name || "", radius: targetData.radius || "", isReferencePoint: targetData.isReferencePoint || false, - gradientThreshold: targetData.gradientThreshold || 100, - anchorThreshold: targetData.anchorThreshold || 80, + gradientThreshold: targetData.gradientThreshold, + anchorThreshold: targetData.anchorThreshold, gaussianBlurThreshold: targetData.gaussianBlurThreshold || 3, }); // 默认高级配置不展开 diff --git a/client/src/sections/wuyuanbiaoba/components/TemplateModal.jsx b/client/src/sections/wuyuanbiaoba/components/TemplateModal.jsx index e9e4b5d..3407d1b 100644 --- a/client/src/sections/wuyuanbiaoba/components/TemplateModal.jsx +++ b/client/src/sections/wuyuanbiaoba/components/TemplateModal.jsx @@ -158,7 +158,6 @@ const TemplateModal = ({ const handleOk = async () => { try { - debugger; const values = await form.validateFields(); // 检查是否上传了图片 diff --git a/client/src/sections/wuyuanbiaoba/hooks/useTargetStorage.js b/client/src/sections/wuyuanbiaoba/hooks/useTargetStorage.js index 65ba6dc..ca9c958 100644 --- a/client/src/sections/wuyuanbiaoba/hooks/useTargetStorage.js +++ b/client/src/sections/wuyuanbiaoba/hooks/useTargetStorage.js @@ -87,8 +87,8 @@ export const useTargetStorage = () => { radius: info.radius || 40.0, isReferencePoint: info.base || false, // 根据实际数据结构映射阈值 - gradientThreshold: threshold.gradient || 100, // 梯度阈值 - anchorThreshold: threshold.anchor || 80, // 锚点阈值 + gradientThreshold: threshold.gradient , // 梯度阈值 + anchorThreshold: threshold.anchor, // 锚点阈值 gaussianBlurThreshold: threshold.gauss || 3, binaryThreshold: threshold.binary || 120, // 保留二值化阈值 hasAdvancedConfig: true, // 有配置数据的都认为是有高级配置 @@ -145,8 +145,8 @@ export const useTargetStorage = () => { threshold: { binary: target.binaryThreshold || 120, gauss: target.gaussianBlurThreshold || 1, - gradient: target.gradientThreshold || 100, - anchor: target.anchorThreshold || 80, + gradient: target.gradientThreshold, + anchor: target.anchorThreshold, }, radius: parseFloat(target.radius) || 40.0, id: target.id || target.key, diff --git a/client/src/utils/parseProcessData.js b/client/src/utils/parseProcessData.js index 1d5279d..06f1dcb 100644 --- a/client/src/utils/parseProcessData.js +++ b/client/src/utils/parseProcessData.js @@ -53,7 +53,6 @@ const dataRecursionObj = (dataObj, index, needData, lastKeyObj, nd) => { return gotValue } else { if (keyObj.isGroup) { - debugger for (let item of dataObj[keyObj.prKey]) { const gotValue = dataRecursionObj(item, index + 1, needData, lastKeyObj, nd) if (gotValue) {