fix(测试跟踪): 用例导入失败后点击继续导入,没有将合规数据导入
--bug=1040765 --user=陈建星 [测试跟踪] github#30910导入用例时报失败(模板字段写的有问题),然后再点继续导入会提示导入成功 https://www.tapd.cn/55049933/s/1518238
This commit is contained in:
parent
f84e8e00f8
commit
cc443521b0
|
@ -1142,12 +1142,16 @@ public class TestCaseService {
|
|||
return extTestCaseMapper.getTestCaseNames(queryTestCaseRequest);
|
||||
}
|
||||
|
||||
private ExcelResponse getImportResponse(List<ExcelErrData<TestCaseExcelData>> errList, boolean isUpdated) {
|
||||
private ExcelResponse getImportResponse(List<ExcelErrData<TestCaseExcelData>> errList, boolean isUpdated, boolean isIgnore) {
|
||||
ExcelResponse excelResponse = new ExcelResponse();
|
||||
excelResponse.setIsUpdated(isUpdated);
|
||||
//如果包含错误信息就导出错误信息
|
||||
if (!errList.isEmpty()) {
|
||||
excelResponse.setSuccess(false);
|
||||
if (isIgnore) {
|
||||
excelResponse.setSuccess(true);
|
||||
} else {
|
||||
excelResponse.setSuccess(false);
|
||||
}
|
||||
excelResponse.setErrList(errList);
|
||||
} else {
|
||||
excelResponse.setSuccess(true);
|
||||
|
@ -1243,7 +1247,7 @@ public class TestCaseService {
|
|||
errData.setRowNum(errorNum++);
|
||||
}
|
||||
}
|
||||
return getImportResponse(errList, true);
|
||||
return getImportResponse(errList, true, request.isIgnore());
|
||||
}
|
||||
|
||||
private ExcelResponse testCaseExcelImport(MultipartFile multipartFile, TestCaseImportRequest request,
|
||||
|
@ -1303,7 +1307,7 @@ public class TestCaseService {
|
|||
LogUtil.error(e.getMessage(), e);
|
||||
MSException.throwException(e.getMessage());
|
||||
}
|
||||
return getImportResponse(errList, isUpdated);
|
||||
return getImportResponse(errList, isUpdated, request.isIgnore());
|
||||
}
|
||||
|
||||
private static List<CustomFieldDao> getProjectCustomFields(String projectId) {
|
||||
|
|
Loading…
Reference in New Issue