Compare commits
No commits in common. "1ac1efed228c210b6bdbb451d56909af85cd0f28" and "6ae6d9b7046231b53fcb0499693ec7aacca448d6" have entirely different histories.
1ac1efed22
...
6ae6d9b704
@ -8,7 +8,7 @@ import java.util.List;
|
||||
@Data
|
||||
public class StageResp {
|
||||
//@ApiProperty(name = "stageId",desc="id")
|
||||
private String id;
|
||||
private String stageId;
|
||||
|
||||
//@ApiProperty(name = "stageName",desc="名称")
|
||||
private String stageName;
|
||||
|
@ -8,7 +8,7 @@ import java.time.LocalDateTime;
|
||||
@Data
|
||||
public class TasksResp {
|
||||
//@ApiProperty(name="taskId",desc="配置id")
|
||||
private String id;
|
||||
private String taskId;
|
||||
|
||||
//@ApiProperty(name="createTime",desc="创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
@ -460,7 +460,7 @@ public class PipelineServiceImpl extends ServiceImpl<PipelineDao, PipPipeline> i
|
||||
PipStage childStage = new PipStage();
|
||||
childStage.setPipelineId(pipelineId);
|
||||
childStage.setParentId(o.getId());
|
||||
List<PipStage> pipStageChildList = stageService.getPipStageList(childStage);
|
||||
List<PipStage> pipStageChildList = stageService.getPipStageList(pipStage);
|
||||
|
||||
//对查询结束的stage进行复制
|
||||
o.setId(null);
|
||||
|
@ -14,7 +14,6 @@ import cd.casic.framework.commons.exception.ServiceException;
|
||||
import cd.casic.framework.commons.exception.enums.GlobalErrorCodeConstants;
|
||||
import cd.casic.framework.commons.util.object.BeanUtils;
|
||||
import cd.casic.framework.commons.util.util.WebFrameworkUtils;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import jakarta.annotation.Resource;
|
||||
@ -145,8 +144,9 @@ public class StageServiceImpl extends ServiceImpl<PipStageDao, PipStage> impleme
|
||||
//获取从节点
|
||||
List<PipStage> allStageStage = findSecondStageAndTask(stagesId);
|
||||
List<StageResp> stageRespList = allStageStage.stream().map(it -> {
|
||||
// BeanUtils.copyProperties(it, stageResp);
|
||||
return JSON.parseObject(JSON.toJSONString(it), StageResp.class);
|
||||
StageResp stageResp = new StageResp();
|
||||
BeanUtils.copyProperties(it, stageResp);
|
||||
return stageResp;
|
||||
}).toList();
|
||||
StageResp stageResp = new StageResp();
|
||||
BeanUtils.copyProperties(stage,stageResp);
|
||||
@ -366,7 +366,7 @@ public class StageServiceImpl extends ServiceImpl<PipStageDao, PipStage> impleme
|
||||
List<PipStage> otherStage = findSecondStage(stagesId);
|
||||
List<PipStage> list = new ArrayList<>();
|
||||
List<String> stageIdList = otherStage.stream().map(PipStage::getId).toList();
|
||||
Map<String, List<PipTask>> stageIdTaskMap = taskService.getTaskByStageIdList(stageIdList).stream().collect(Collectors.groupingBy(PipTask::getStageId));
|
||||
Map<String, List<PipTask>> stageIdTaskMap = taskService.listByIds(stageIdList).stream().collect(Collectors.groupingBy(PipTask::getStageId));
|
||||
for (PipStage stage : otherStage) {
|
||||
//获取阶段配置及任务
|
||||
String otherId = stage.getId();
|
||||
|
@ -14,7 +14,6 @@ public interface TaskService extends IService<PipTask> {
|
||||
* */
|
||||
void taskTypeExist(String taskType);
|
||||
List<PipTask> getTask(PipTask pipTask);
|
||||
List<PipTask> getTaskByStageIdList(List<String> stageIdList);
|
||||
TasksResp getRespById(String taskId);
|
||||
|
||||
void copyTask(String taskId);
|
||||
|
@ -50,12 +50,6 @@ public class TaskServiceImpl extends ServiceImpl<PipTaskDao, PipTask> implements
|
||||
return taskDao.selectList(wrapper);
|
||||
}
|
||||
@Override
|
||||
public List<PipTask> getTaskByStageIdList(List<String> stageIdList){
|
||||
LambdaQueryWrapper<PipTask> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.in(PipTask::getStageId,stageIdList);
|
||||
return taskDao.selectList(wrapper);
|
||||
}
|
||||
@Override
|
||||
public TasksResp getRespById(String taskId){
|
||||
PipTask pipTask = new PipTask();
|
||||
pipTask.setId(taskId);
|
||||
|
Loading…
x
Reference in New Issue
Block a user