xiangpei
2025-02-28 669536d2b2f602a1871e482677fdab1ed53e637c
business/src/main/java/com/ycl/service/impl/FlowTaskServiceImpl.java
@@ -74,6 +74,7 @@
import java.io.InputStream;
import java.lang.reflect.Field;
import java.math.BigDecimal;
import java.nio.charset.StandardCharsets;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
@@ -160,7 +161,14 @@
                newV.put(task.getTaskDefinitionKey() + "&" + key, variables.get(key));
                //字典里有就放入流程变量中
                if (!CollectionUtils.isEmpty(dictList) && dictList.contains(key)) {
                    processVariables.put(key,variables.get(key));
                    if ("money".equals(key)) {
                        // 万元转元
                        Object w = variables.get(key);
                        BigDecimal y = new BigDecimal(w.toString()).multiply(new BigDecimal(10000));
                        processVariables.put(key, y);
                    } else {
                        processVariables.put(key,variables.get(key));
                    }
                }
            }
        }
@@ -1264,13 +1272,14 @@
        // 判断前置任务是不是和当前任务为同一个executeId
        // 判断当前任务是否被挂起中
        String finalProcessInsId = processInsId;
        beforeNodes.stream().filter(node -> {
        beforeNodes = beforeNodes.stream().filter(node -> {
            if (node.getCurrent()) {
                return Boolean.TRUE;
            }
            HistoricTaskInstance beforeTask = historyService.createHistoricTaskInstanceQuery().processInstanceId(finalProcessInsId).finished().taskDefinitionKey(node.getBeforeNodeDefId()).singleResult();
            return Objects.nonNull(beforeTask);
        }).forEach(node -> {
        }).collect(Collectors.toList());
        beforeNodes.forEach(node -> {
            if (node.getCurrent()) {
                if (processLogService.taskIsHangup(taskId, finalProcessInsId)) {
                    node.setTaskStatus(TaskStatusEnum.HANGUP);