|
|
@@ -92,6 +92,7 @@ import org.flowable.bpmn.model.FlowElementsContainer; |
|
|
|
import org.flowable.bpmn.model.SubProcess; |
|
|
|
import org.flowable.engine.HistoryService; |
|
|
|
import org.flowable.engine.RepositoryService; |
|
|
|
import org.flowable.engine.RuntimeService; |
|
|
|
import org.flowable.engine.TaskService; |
|
|
|
import org.flowable.engine.history.HistoricProcessInstance; |
|
|
|
import org.flowable.task.api.Task; |
|
|
@@ -583,16 +584,22 @@ public class TodoCenterManage { |
|
|
|
res.setStatus(progressInstanceDetail.getStatus()); |
|
|
|
res.setCanWithdraw(withDrawHandle.checkCanWithdraw(instanceId, progressInstanceDetail, request.getTaskId())); |
|
|
|
res.setIsHighLine(isHighLine); |
|
|
|
res.setConstructionSuggestions(checkConstructionSuggestionsByNodeId(nodeId)); |
|
|
|
res.setConstructionSuggestions(checkConstructionSuggestionsByNodeId(taskId)); |
|
|
|
passHandle.checkCanPassOrSeal(request.getInstanceId(), request.getTaskId(), employeeCode, res); |
|
|
|
//是不是被 驳回|退回 |
|
|
|
res.setIsChange(todoService.isChangeRecord(projectId)); |
|
|
|
return res; |
|
|
|
} |
|
|
|
|
|
|
|
private Boolean checkConstructionSuggestionsByNodeId(String nodeId) { |
|
|
|
if(StringUtils.isNotBlank(nodeId)){ |
|
|
|
return nodeId.endsWith(StrPool.DASH + ProcessConstant.Field.CONSTRUCTION); |
|
|
|
private Boolean checkConstructionSuggestionsByNodeId(String taskId) { |
|
|
|
if(StringUtils.isNotBlank(taskId)){ |
|
|
|
List<Task> tasks = taskService.createTaskQuery() |
|
|
|
.taskId(taskId) |
|
|
|
.orderByTaskId().desc().list(); |
|
|
|
if(CollUtil.isNotEmpty(tasks)){ |
|
|
|
return tasks.get(0).getTaskDefinitionKey() |
|
|
|
.endsWith(StrPool.DASH + ProcessConstant.Field.CONSTRUCTION); |
|
|
|
} |
|
|
|
} |
|
|
|
return Boolean.FALSE; |
|
|
|
} |
|
|
|