DLC 11 mesiacov pred
rodič
commit
6c512e3544

+ 0 - 1
cx-aps/cx-aps-common/src/main/java/com/rongwei/bscommon/sys/service/impl/ApsProductionOrderServiceImpl.java

@@ -352,7 +352,6 @@ public class ApsProductionOrderServiceImpl extends ServiceImpl<ApsProductionOrde
      */
     @Override
     public void orderOuttimeAudit() {
-        log.info("订单未及时评审提醒开始");
         List<ApsProductionOrderDo> apsProductionOrderDos = this.baseMapper.getOrderOuttimeAudit();
         for (ApsProductionOrderDo apsProductionOrderDo : apsProductionOrderDos) {
             //系统通知(移动端和PC端个人工作台)

+ 12 - 4
cx-aps/cx-aps-server/src/main/java/com/rongwei/bsserver/controller/ApsProductionOrderController.java

@@ -2,11 +2,11 @@ package com.rongwei.bsserver.controller;
 
 import com.rongwei.bscommon.sys.service.ApsProductionOrderService;
 import com.rongwei.bsentity.domain.ApsProductionOrderDo;
-import com.rongwei.bsentity.domain.ApsProductionTechnicalRequirementDo;
 import com.rongwei.bsentity.vo.CheckAndSaveOrUpdateOrderReq;
 import com.rongwei.bsentity.vo.DeleteOrderVo;
 import com.rongwei.bsentity.vo.OrderHaveBeChangedReq;
 import com.rongwei.rwcommon.base.R;
+import lombok.SneakyThrows;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -67,8 +67,16 @@ public class ApsProductionOrderController {
     订单未及时评审提醒
      */
     @PostMapping("/orderOuttimeAudit")
-    public void orderOuttimeAudit() {
-        apsProductionOrderService.orderOuttimeAudit();
+    public R orderOuttimeAudit() {
+        log.info("订单未及时评审提醒开始...");
+        Thread thread = new Thread(new Runnable() {
+            @SneakyThrows
+            public void run() {
+                apsProductionOrderService.orderOuttimeAudit();
+            }
+        });
+        thread.start(); // 启动线程
+        return R.ok();
     }
 
     /**
@@ -129,7 +137,7 @@ public class ApsProductionOrderController {
      * 订单操作之前,判断是否有人更改
      */
     @PostMapping("/haveBeChanged")
-    public R haveBeChanged(@RequestBody OrderHaveBeChangedReq req){
+    public R haveBeChanged(@RequestBody OrderHaveBeChangedReq req) {
         return apsProductionOrderService.haveBeChanged(req);
     }
 }