Commit a40f69eb authored by wdy's avatar wdy

Merge branch 'wangdingyi' into 'dev'

用例编号添加

See merge request !417
parents 18705aea 67a5f26e
...@@ -31,6 +31,9 @@ public class CaseResultVO { ...@@ -31,6 +31,9 @@ public class CaseResultVO {
@ApiModelProperty("用例编号") @ApiModelProperty("用例编号")
private String serial_number; private String serial_number;
@ApiModelProperty("用例编号")
private String sequence;
@ApiModelProperty("用例开始时间") @ApiModelProperty("用例开始时间")
private Integer start_time; private Integer start_time;
......
...@@ -171,6 +171,17 @@ public class StrategyModelTestTaskNew implements StrategyModelTestTask, Initiali ...@@ -171,6 +171,17 @@ public class StrategyModelTestTaskNew implements StrategyModelTestTask, Initiali
List<ModelTestViewVO> list = jsonObject.getList("regulation_item_result_list",ModelTestViewVO.class); List<ModelTestViewVO> list = jsonObject.getList("regulation_item_result_list",ModelTestViewVO.class);
if (list != null && !list.isEmpty()) {
// 遍历 ModelTestViewVO 列表
for (ModelTestViewVO viewVO : list) {
// 遍历 case_result_list
for (ModelTestResultVO resultVO : viewVO.getCase_result_list()) {
// 将 sequence 的值赋给 serial_number
resultVO.setSerial_number(resultVO.getSequence());
}
}
}
response.setStandardNum((Integer) jsonObject.get("regulation_item_count")); response.setStandardNum((Integer) jsonObject.get("regulation_item_count"));
response.setModelTestTaskViewResponseList(list); response.setModelTestTaskViewResponseList(list);
......
...@@ -87,7 +87,7 @@ public class TestRecordsServiceImpl extends ServiceImpl<TestRecordsMapper, TestR ...@@ -87,7 +87,7 @@ public class TestRecordsServiceImpl extends ServiceImpl<TestRecordsMapper, TestR
testRecords.setRiskLevel(caseResultVO.getRisk_level() + "_risk"); testRecords.setRiskLevel(caseResultVO.getRisk_level() + "_risk");
testRecords.setTestResult(caseResultVO.getStatus()); testRecords.setTestResult(caseResultVO.getStatus());
testRecords.setRemediation(caseResultVO.getRemediation()); testRecords.setRemediation(caseResultVO.getRemediation());
testRecords.setUsecaseNo(caseResultVO.getSerial_number()); testRecords.setUsecaseNo(caseResultVO.getSequence());
//测试开始时间 //测试开始时间
if (caseResultVO.getStart_time() != null) { if (caseResultVO.getStart_time() != null) {
Date date = new Date(caseResultVO.getStart_time()); Date date = new Date(caseResultVO.getStart_time());
...@@ -192,7 +192,7 @@ public class TestRecordsServiceImpl extends ServiceImpl<TestRecordsMapper, TestR ...@@ -192,7 +192,7 @@ public class TestRecordsServiceImpl extends ServiceImpl<TestRecordsMapper, TestR
testRecords.setRiskLevel(caseResultVO.getRisk_level() + "_risk"); testRecords.setRiskLevel(caseResultVO.getRisk_level() + "_risk");
testRecords.setTestResult(caseResultVO.getStatus()); testRecords.setTestResult(caseResultVO.getStatus());
testRecords.setRemediation(caseResultVO.getRemediation()); testRecords.setRemediation(caseResultVO.getRemediation());
testRecords.setUsecaseNo(caseResultVO.getSerial_number()); testRecords.setUsecaseNo(caseResultVO.getSequence());
//测试开始时间 //测试开始时间
if (caseResultVO.getStart_time() != null) { if (caseResultVO.getStart_time() != null) {
Date date = new Date(caseResultVO.getStart_time()); Date date = new Date(caseResultVO.getStart_time());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment