diff --git a/backend/services/test-plan/src/main/java/io/metersphere/plan/dto/request/TestPlanCaseMinderRequest.java b/backend/services/test-plan/src/main/java/io/metersphere/plan/dto/request/TestPlanCaseMinderRequest.java index e93e86e040..0c82c007dd 100644 --- a/backend/services/test-plan/src/main/java/io/metersphere/plan/dto/request/TestPlanCaseMinderRequest.java +++ b/backend/services/test-plan/src/main/java/io/metersphere/plan/dto/request/TestPlanCaseMinderRequest.java @@ -19,4 +19,7 @@ public class TestPlanCaseMinderRequest extends BasePlanCaseBatchRequest { @Schema(description = "脑图选中的项目id集合") private List minderProjectIds; + + @Schema(description = "脑图选中的测试集id集合") + private List minderCollectionIds; } diff --git a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.java b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.java index 191a780b2d..a2690de29f 100644 --- a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.java +++ b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.java @@ -77,7 +77,7 @@ public interface ExtTestPlanFunctionalCaseMapper { List selectDistinctExecResultByTestPlanIds(@Param("testPlanIds") List testPlanIds); - Collection selectIdsByProjectIds(@Param("request") TestPlanCaseMinderRequest request); + Collection selectIdsByProjectIdsOrCollectionIds(@Param("request") TestPlanCaseMinderRequest request); List selectProjectByModuleIds(@Param("moduleIds") List moduleIds); diff --git a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.xml b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.xml index 2d03309a08..a7e262d2c0 100644 --- a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.xml +++ b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanFunctionalCaseMapper.xml @@ -672,7 +672,7 @@ - SELECT test_plan_functional_case.id FROM @@ -682,10 +682,18 @@ test_plan_functional_case.test_plan_id = #{request.testPlanId} AND functional_case.deleted = false - and functional_case.project_id in - - #{projectId} - + + and functional_case.project_id in + + #{projectId} + + + + and test_plan_functional_case.test_plan_collection_id IN + + #{collectionId} + +