diff --git a/backend/src/main/java/io/metersphere/api/service/ApiScenarioReportStructureService.java b/backend/src/main/java/io/metersphere/api/service/ApiScenarioReportStructureService.java index 0336dda36f..8eab90a013 100644 --- a/backend/src/main/java/io/metersphere/api/service/ApiScenarioReportStructureService.java +++ b/backend/src/main/java/io/metersphere/api/service/ApiScenarioReportStructureService.java @@ -169,7 +169,8 @@ public class ApiScenarioReportStructureService { StepTreeDTO children = new StepTreeDTO(element.getString("name"), resourceId, element.getString("type"), resourceId, element.getIntValue("index")); if (StringUtils.isNotBlank(children.getType()) && children.getType().equals("MsUiCommand")) { children.setResourceId(resourceId); - children.setLabel(element.getString("command")); + children.setLabel(element.getString("name")); + children.setCmdType(element.getString("commandType")); } else if (StringUtils.isNotEmpty(dto.getAllIndex())) { children.setAllIndex(dto.getAllIndex() + "_" + (children.getIndex() == 0 ? (i + 1) : children.getIndex())); children.setResourceId(resourceId + "_" + children.getAllIndex()); @@ -177,7 +178,6 @@ public class ApiScenarioReportStructureService { children.setAllIndex("" + (children.getIndex() == 0 ? (i + 1) : children.getIndex())); children.setResourceId(resourceId + "_" + children.getAllIndex()); } - children.setCmdType(element.getString("commandType")); dto.getChildren().add(children); if (element.containsKey("hashTree") && !requests.contains(children.getType())) { JSONArray elementJSONArray = element.getJSONArray("hashTree"); diff --git a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiScenarioReportMapper.xml b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiScenarioReportMapper.xml index 4d9dd8b250..fc6ff47e01 100644 --- a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiScenarioReportMapper.xml +++ b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiScenarioReportMapper.xml @@ -261,6 +261,15 @@ AND r.project_id = #{request.projectId} + + + AND r.report_type like 'UI%' + + + + AND r.report_type not like 'UI%' + + diff --git a/frontend/src/business/components/api/automation/report/ApiReportList.vue b/frontend/src/business/components/api/automation/report/ApiReportList.vue index 9e3deb6829..7061d223b9 100644 --- a/frontend/src/business/components/api/automation/report/ApiReportList.vue +++ b/frontend/src/business/components/api/automation/report/ApiReportList.vue @@ -379,6 +379,7 @@ export default { sendParam.selectAllDate = this.isSelectAllDate; sendParam.unSelectIds = this.unSelection; sendParam = Object.assign(sendParam, this.condition); + sendParam.isUi = this.isUI; this.$post('/api/scenario/report/batch/delete', sendParam, () => { this.selectRows.clear(); this.$success(this.$t('commons.delete_success'));