0630 ljc 修改测试用例管理接口
This commit is contained in:
parent
f817f21c89
commit
8eb34198a5
@ -247,7 +247,9 @@ public class ReportServiceImpl implements ReportService {
|
||||
//映射到报告信息表中去,做存储操作
|
||||
List<PipReportInfo> infoList = setReportInfoToCreate(data,req.getScaTaskId(),req.getTaskId());
|
||||
|
||||
if (!CollectionUtils.isEmpty(infoList)){
|
||||
reportInfoDao.insertBatch(infoList);
|
||||
}
|
||||
} else {
|
||||
log.error("===============根据任务ID查询漏洞列表失败,新增报告信息失败=================");
|
||||
throw new ServiceException(GlobalErrorCodeConstants.INTERNAL_SERVER_ERROR.getCode(),"新增报告信息失败");
|
||||
@ -546,10 +548,10 @@ public class ReportServiceImpl implements ReportService {
|
||||
creator = pipeline.getCreator();
|
||||
}
|
||||
|
||||
if (!ObjectUtils.isEmpty(records)){
|
||||
for (int i = 0; i < records.size(); i++) {
|
||||
JSONObject report = records.getJSONObject(i);
|
||||
PipReportInfo pipReportInfo = new PipReportInfo();
|
||||
Long loginUserId = WebFrameworkUtils.getLoginUserId();
|
||||
|
||||
pipReportInfo.setTaskId(taskId);
|
||||
pipReportInfo.setScaTaskId(scaTaskId);
|
||||
@ -570,6 +572,9 @@ public class ReportServiceImpl implements ReportService {
|
||||
pipReportInfos.add(pipReportInfo);
|
||||
}
|
||||
return pipReportInfos;
|
||||
}else {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user