diff --git a/backend/services/test-plan/src/main/java/io/metersphere/plan/controller/TestPlanController.java b/backend/services/test-plan/src/main/java/io/metersphere/plan/controller/TestPlanController.java index 611c70bd90..ca28aa3344 100644 --- a/backend/services/test-plan/src/main/java/io/metersphere/plan/controller/TestPlanController.java +++ b/backend/services/test-plan/src/main/java/io/metersphere/plan/controller/TestPlanController.java @@ -74,7 +74,7 @@ public class TestPlanController { testPlanCoverageDTO.setErrorCode(109001); return testPlanCoverageDTO; } - return testPlanService.rageByProjectIdAndTimestamp(request.getProjectId(), request.getStartTime(), request.getEndTime()); + return testPlanService.rageByProjectIdAndTimestamp(request.getProjectId()); } @GetMapping("/group-list/{projectId}") diff --git a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.java b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.java index b6688d653d..cd86ac857d 100644 --- a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.java +++ b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.java @@ -94,5 +94,5 @@ public interface ExtTestPlanMapper { */ List getPlanBugList(@Param("projectId") String projectId, @Param("type") String type, @Param("platforms") List platform, @Param("statusList") List statusList); - List selectIdAndStatusByProjectIdAndCreateTimeRangeAndType(@Param("projectId") String projectId, @Param("startTime") long startTime, @Param("endTime") long endTime, @Param("type") String testPlanTypePlan); + List selectIdAndStatusByProjectIdAndCreateTimeRangeAndType(@Param("projectId") String projectId, @Param("startTime") Long startTime, @Param("endTime") Long endTime, @Param("type") String testPlanTypePlan); } diff --git a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.xml b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.xml index 946b88f1e2..a0c9ff08c5 100644 --- a/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.xml +++ b/backend/services/test-plan/src/main/java/io/metersphere/plan/mapper/ExtTestPlanMapper.xml @@ -872,7 +872,9 @@ SELECT id, status FROM test_plan WHERE project_id = #{projectId} - AND create_time BETWEEN #{startTime} AND #{endTime} + + AND create_time BETWEEN #{startTime} AND #{endTime} + AND type = #{type}