From 542700f3c55e670212cc16f001f14851d0c0da7c Mon Sep 17 00:00:00 2001 From: song-cc-rock Date: Wed, 9 Oct 2024 14:51:23 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E6=8E=A5=E5=8F=A3=E6=B5=8B=E8=AF=95):=20?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E5=9C=BA=E6=99=AF=E5=88=97=E8=A1=A8=E9=AB=98?= =?UTF-8?q?=E7=BA=A7=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --task=1016534 --user=宋昌昌 高级筛选-接口测试-接口场景首页 https://www.tapd.cn/55049933/s/1589497 --- .../api/mapper/ExtApiScenarioMapper.java | 4 + .../api/mapper/ExtApiScenarioMapper.xml | 182 +++++++++--------- .../api/mapper/ExtApiTestCaseMapper.xml | 1 + .../bug/dto/request/BugPageRequest.java | 3 + 4 files changed, 101 insertions(+), 89 deletions(-) diff --git a/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.java b/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.java index 3e40552363..d45d8a5c18 100644 --- a/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.java +++ b/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.java @@ -11,13 +11,17 @@ import io.metersphere.project.dto.NodeSortQueryParam; import io.metersphere.request.AssociateOtherCaseRequest; import io.metersphere.request.TestCasePageProviderRequest; import io.metersphere.system.dto.sdk.BaseTreeNode; +import io.metersphere.system.interceptor.BaseConditionFilter; import org.apache.ibatis.annotations.Param; import java.util.List; public interface ExtApiScenarioMapper { + + @BaseConditionFilter List list(@Param("request") ApiScenarioPageRequest request, @Param("isRepeat") boolean isRepeat, @Param("testPlanId") String testPlanId); + @BaseConditionFilter List getIds(@Param("request") ApiScenarioBatchRequest request, @Param("deleted") boolean deleted); List getInfoByIds(@Param("ids") List ids, @Param("deleted") boolean deleted); diff --git a/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.xml b/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.xml index a03d1240b7..b82025f538 100644 --- a/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.xml +++ b/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiScenarioMapper.xml @@ -153,6 +153,9 @@ + + + @@ -178,15 +181,9 @@ - - - - - - - - - + + + @@ -293,93 +290,100 @@ - - and api_scenario.name - - - - - - - and api_scenario.num - - - - - - - and api_scenario.update_time - - - - - - - and api_scenario.create_time - - - - - - - and api_scenario.status - - - - - - - and (api_scenario.tags is null or api_scenario.tags - - - - ) - - - - and api_scenario.tags - - - - - - - - - - and api_scenario.id not in ( - - - and api_scenario.id in ( - - select api_id from api_definition_custom_field where field_id = #{custom.id} - - - and `value` + + + + + - + + - - - and ${custom.value} - - - and left(replace(unix_timestamp(trim(both '"' from `value`)), '.', ''), 13) + + + + + + + + + + + + + + + + + + + + + - + + - - - and trim(both '"' from `value`) + + + - + + - - - ) + + + + + + + + + + + + + + + + + + + + + + + + + + + api_scenario.request_pass_rate is not null and api_scenario.request_pass_rate != '' and api_scenario.request_pass_rate != 'Calculating' + + + api_scenario.request_pass_rate is null or api_scenario.request_pass_rate == '' or api_scenario.request_pass_rate == 'Calculating' + + + 1=2 + + + api_scenario.request_pass_rate ${condition.operator} #{condition.value} + + + + + + + + + + + + + + - - + + diff --git a/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiTestCaseMapper.xml b/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiTestCaseMapper.xml index 6392be0c4f..6ba885e051 100644 --- a/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiTestCaseMapper.xml +++ b/backend/services/api-test/src/main/java/io/metersphere/api/mapper/ExtApiTestCaseMapper.xml @@ -683,6 +683,7 @@ + diff --git a/backend/services/bug-management/src/main/java/io/metersphere/bug/dto/request/BugPageRequest.java b/backend/services/bug-management/src/main/java/io/metersphere/bug/dto/request/BugPageRequest.java index 4c681df466..0d28effccc 100644 --- a/backend/services/bug-management/src/main/java/io/metersphere/bug/dto/request/BugPageRequest.java +++ b/backend/services/bug-management/src/main/java/io/metersphere/bug/dto/request/BugPageRequest.java @@ -6,6 +6,9 @@ import jakarta.validation.constraints.NotBlank; import lombok.Data; import lombok.EqualsAndHashCode; +/** + * @author song-cc-rock + */ @Data @EqualsAndHashCode(callSuper = false) public class BugPageRequest extends BasePageRequest {