Commit 8ba11aaa authored by suhuiguang's avatar suhuiguang

1.修改bug设备移交选择多个时,创建的待办任务工作流id、任务id不正确导致撤回报错

parent 3a3e8b2a
...@@ -14,7 +14,6 @@ import com.yeejoin.amos.boot.biz.common.utils.RedisUtils; ...@@ -14,7 +14,6 @@ import com.yeejoin.amos.boot.biz.common.utils.RedisUtils;
import com.yeejoin.amos.boot.module.jg.api.dto.*; import com.yeejoin.amos.boot.module.jg.api.dto.*;
import com.yeejoin.amos.boot.module.jg.api.entity.JgEquipTransfer; import com.yeejoin.amos.boot.module.jg.api.entity.JgEquipTransfer;
import com.yeejoin.amos.boot.module.jg.api.entity.JgEquipTransferEq; import com.yeejoin.amos.boot.module.jg.api.entity.JgEquipTransferEq;
import com.yeejoin.amos.boot.module.jg.api.entity.JgMaintainNotice;
import com.yeejoin.amos.boot.module.jg.api.enums.BusinessTypeEnum; import com.yeejoin.amos.boot.module.jg.api.enums.BusinessTypeEnum;
import com.yeejoin.amos.boot.module.jg.api.mapper.JgEquipTransferEqMapper; import com.yeejoin.amos.boot.module.jg.api.mapper.JgEquipTransferEqMapper;
import com.yeejoin.amos.boot.module.jg.api.mapper.JgEquipTransferMapper; import com.yeejoin.amos.boot.module.jg.api.mapper.JgEquipTransferMapper;
...@@ -347,7 +346,7 @@ public class JgEquipTransferServiceImpl extends BaseService<JgEquipTransferDto, ...@@ -347,7 +346,7 @@ public class JgEquipTransferServiceImpl extends BaseService<JgEquipTransferDto,
// 创建新的代办 // 创建新的代办
this.createNewTodo(transfer, workflowResultDto, taskV2Model, FlowStatusEnum.TO_BE_PROCESSED); this.createNewTodo(transfer, workflowResultDto, taskV2Model, FlowStatusEnum.TO_BE_PROCESSED);
} }
commonService.saveExecuteFlowData2Redis(transfer.getInstanceId(),this.buildInstanceRuntimeData(transfer)); commonService.saveExecuteFlowData2Redis(transfer.getInstanceId(), this.buildInstanceRuntimeData(transfer));
} else { } else {
JgEquipTransfer equipTransfer = new JgEquipTransfer(); JgEquipTransfer equipTransfer = new JgEquipTransfer();
BeanUtils.copyProperties(equipTransferDto, equipTransfer); BeanUtils.copyProperties(equipTransferDto, equipTransfer);
...@@ -591,10 +590,12 @@ public class JgEquipTransferServiceImpl extends BaseService<JgEquipTransferDto, ...@@ -591,10 +590,12 @@ public class JgEquipTransferServiceImpl extends BaseService<JgEquipTransferDto,
if (CollectionUtils.isEmpty(list) || CollectionUtils.isEmpty(workflowResultList)) { if (CollectionUtils.isEmpty(list) || CollectionUtils.isEmpty(workflowResultList)) {
return; return;
} }
List<TaskModelDto> taskModelList = new ArrayList<>();
List<TaskModelDto> taskModelDtoList = list.stream().map(item -> IntStream.range(0, list.size()).forEach(index -> {
this.buildTaskModelDto(item, workflowResultList.get(0))).collect(Collectors.toList()); TaskModelDto taskModelDto = this.buildTaskModelDto(list.get(index), workflowResultList.get(index));
commonService.buildTaskModel(taskModelDtoList); taskModelList.add(taskModelDto);
});
commonService.buildTaskModel(taskModelList);
} }
/** /**
......
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