fix: 全量删除UI报告会删除接口报告
This commit is contained in:
parent
e12ec631a1
commit
f4aaccee4a
|
@ -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");
|
||||
|
|
|
@ -261,6 +261,15 @@
|
|||
<if test="request.projectId != null">
|
||||
AND r.project_id = #{request.projectId}
|
||||
</if>
|
||||
|
||||
<if test="request.isUi">
|
||||
AND r.report_type like 'UI%'
|
||||
</if>
|
||||
|
||||
<if test="!request.isUi">
|
||||
AND r.report_type not like 'UI%'
|
||||
</if>
|
||||
|
||||
<if test="request.filters != null and request.filters.size() > 0">
|
||||
<foreach collection="request.filters.entrySet()" index="key" item="values">
|
||||
<if test="values != null and values.size() > 0">
|
||||
|
|
|
@ -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'));
|
||||
|
|
Loading…
Reference in New Issue