From 8469f47f43da05588af36f6e418d9e1258ce8ee6 Mon Sep 17 00:00:00 2001 From: guoyuqi Date: Wed, 29 May 2024 13:50:26 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=8A=9F=E8=83=BD=E7=94=A8=E4=BE=8B):=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=8A=9F=E8=83=BD=E7=94=A8=E4=BE=8B=E5=8F=96?= =?UTF-8?q?=E6=B6=88=E5=85=B3=E8=81=94=E9=9C=80=E6=B1=82=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E4=B8=8D=E5=AF=B9=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1041347 --user=郭雨琦 https://www.tapd.cn/55049933/bugtrace/bugs/view?bug_id=1155049933001041347 --- .../functional/service/FunctionalCaseDemandService.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/services/case-management/src/main/java/io/metersphere/functional/service/FunctionalCaseDemandService.java b/backend/services/case-management/src/main/java/io/metersphere/functional/service/FunctionalCaseDemandService.java index 26d1661084..d77640ddea 100644 --- a/backend/services/case-management/src/main/java/io/metersphere/functional/service/FunctionalCaseDemandService.java +++ b/backend/services/case-management/src/main/java/io/metersphere/functional/service/FunctionalCaseDemandService.java @@ -210,8 +210,9 @@ public class FunctionalCaseDemandService { * @param id 需求关系ID */ public void deleteDemand(String id) { + FunctionalCaseDemand functionalCaseDemandInDb= functionalCaseDemandMapper.selectByPrimaryKey(id); FunctionalCaseDemandExample functionalCaseDemandExample = new FunctionalCaseDemandExample(); - functionalCaseDemandExample.createCriteria().andParentEqualTo(id); + functionalCaseDemandExample.createCriteria().andParentEqualTo(functionalCaseDemandInDb.getDemandId()); List functionalCaseDemands = functionalCaseDemandMapper.selectByExample(functionalCaseDemandExample); if (CollectionUtils.isNotEmpty(functionalCaseDemands)) { SqlSession sqlSession = sqlSessionFactory.openSession(ExecutorType.BATCH);