Commit a9cd94da authored by 盖献康's avatar 盖献康

Merge branch 'gaixiankang' into 'dev'

bug - 总任务-子任务-测试场景

See merge request !196
parents 05d8da55 699e7852
......@@ -326,7 +326,8 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>implements Tas
private List<Long> selectTestScenarioList(Task task) {
List<Long> list = new ArrayList<>();
List<String> taskList = Arrays.asList(task.getTaskList().split(","));
if (taskList.contains(Task.SUB_TASK_TRFIS) && taskList.size() == 1) {
if (taskList.contains(Task.SUB_TASK_TRFIS) && taskList.size() == 1
|| taskList.contains(Task.SUB_TASK_TRFIS) && taskList.contains(Task.SUB_TASK_SRAIF) && taskList.size() == 2) {
list = taskScenarioRelationMapper
.selectList(new QueryWrapper<TaskScenarioRelation>().eq("task_id", task.getId()))
.stream()
......@@ -698,7 +699,12 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>implements Tas
if (request.getTaskList().contains(Task.SUB_TASK_TRFIS) &&
!request.getTaskList().contains(Task.SUB_TASK_GRFIS) &&
!request.getTaskList().contains(Task.SUB_TASK_SRAIF) &&
ObjectUtil.isNotNull(task.getModelTestTaskId())) {
ObjectUtil.isNotNull(task.getModelTestTaskId())
|| request.getTaskList().contains(Task.SUB_TASK_TRFIS) &&
!request.getTaskList().contains(Task.SUB_TASK_GRFIS) &&
request.getTaskList().contains(Task.SUB_TASK_SRAIF) &&
ObjectUtil.isNotNull(task.getModelTestTaskId())
) {
TaskCreateRequest createRequest = new TaskCreateRequest();
BeanUtils.copyBeanProp(createRequest, request);
taskScenarioRelationMapper.delete(new QueryWrapper<TaskScenarioRelation>().lambda().eq(TaskScenarioRelation::getTaskId, task.getId()));
......
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