From a0f704b6f62ad4aa97a696c1c53bece85ee6bdd2 Mon Sep 17 00:00:00 2001 From: song-cc-rock Date: Wed, 6 Mar 2024 15:24:18 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E7=BC=BA=E9=99=B7=E7=AE=A1=E7=90=86):=20?= =?UTF-8?q?=E7=BC=BA=E9=99=B7=E5=85=B3=E8=81=94=E7=94=A8=E4=BE=8B=E5=B7=A6?= =?UTF-8?q?=E4=BE=A7=E6=A8=A1=E5=9D=97=E6=A0=91=E5=B1=95=E7=A4=BA=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E6=9C=89=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1036504 --user=宋昌昌 【缺陷管理】缺陷详情-关联用例-列表有数据不展示-无法关联 https://www.tapd.cn/55049933/s/1470107 --- .../bug/mapper/ExtBugRelateCaseMapper.xml | 11 +++++------ .../bug/service/BugRelateCaseCommonService.java | 2 ++ .../functional/mapper/ExtFunctionalCaseMapper.xml | 1 - frontend/src/api/modules/bug-management/index.ts | 15 ++++++++++----- .../business/ms-case-associate/utils.ts | 4 ++++ .../bug-management/components/bugCaseTab.vue | 2 +- 6 files changed, 22 insertions(+), 13 deletions(-) diff --git a/backend/services/bug-management/src/main/java/io/metersphere/bug/mapper/ExtBugRelateCaseMapper.xml b/backend/services/bug-management/src/main/java/io/metersphere/bug/mapper/ExtBugRelateCaseMapper.xml index d87dd0f0d5..13c5c0d0be 100644 --- a/backend/services/bug-management/src/main/java/io/metersphere/bug/mapper/ExtBugRelateCaseMapper.xml +++ b/backend/services/bug-management/src/main/java/io/metersphere/bug/mapper/ExtBugRelateCaseMapper.xml @@ -3,7 +3,7 @@ select - fcm.id as moduleId, + fc.module_id AS moduleId, count(fc.id) as dataCount - from functional_case_module fcm left join functional_case fc on fc.module_id = fcm.id + from functional_case fc where fc.deleted = #{deleted} and fc.project_id = #{request.projectId} - and fc.version_id = #{request.versionId} and fc.id not in ( select brc.case_id from bug_relation_case brc where brc.bug_id = #{request.sourceId} and brc.case_type = #{request.sourceType} ) - group by fcm.id + group by fc.module_id