ソースを参照

优化OA消息提醒

fuyuchuan 1 日 前
コミット
af8ef9ee70

+ 4 - 1
flow-app/src/main/resources/application-test.yml

@@ -126,4 +126,7 @@ mybatis-plus:
       id-type: AUTO
       table-prefix:
       #字符串查询过滤空字符串
-      where-strategy: not_empty
+      where-strategy: not_empty
+logging:
+    level:
+      org.apache.ibatis: DEBUG

+ 2 - 1
flow-file/flow-file-biz/src/main/java/com/flow/utils/FileUtil.java

@@ -5,6 +5,7 @@ import org.slf4j.LoggerFactory;
 import org.springframework.web.multipart.MultipartFile;
 
 import java.io.File;
+import java.io.IOException;
 import java.util.UUID;
 
 public class FileUtil {
@@ -24,7 +25,7 @@ public class FileUtil {
             if (!dest.getParentFile().exists()) {
                 // 创建目录
                 if (!dest.getParentFile().mkdirs()) {
-                    System.out.println("was not successful.");
+                    log.error("创建目录失败: {}", dest.getParentFile().getPath());
                 }
             }
             // 文件写入

+ 2 - 2
flow-workflow/flow-workflow-biz/src/main/java/com/flow/listener/GlobalActivityEventListener.java

@@ -133,7 +133,7 @@ public class GlobalActivityEventListener extends AbstractFlowableEngineEventList
                 Notify notify = new Notify();
                 notify.setSubject("新的审批任务");
                 notify.setContent(String.format("您有一条待处理的审批任务【%s】,请及时处理。", entity.getName()));
-                notify.setSender(SecurityContextUtil.getNickName());
+                notify.setSender(SecurityContextUtil.getUserId());
                 notify.setType(NotifyEnum.TODO);
                 notify.setReceiver(entity.getAssignee());
                 notify.setReceivingTime(LocalDateTime.now());
@@ -182,7 +182,7 @@ public class GlobalActivityEventListener extends AbstractFlowableEngineEventList
                 Notify notify = new Notify();
                 notify.setSubject("申请已通过");
                 notify.setContent(String.format("您申请的流程《%s》已通过", entity.getName()));
-                notify.setSender(SecurityContextUtil.getNickName());
+                notify.setSender(entity.getStartUserId());
                 notify.setType(NotifyEnum.SYSTEM);
                 notify.setReceiver(entity.getStartUserId());
                 notify.setReceivingTime(LocalDateTime.now());