From 94e9dc3adb80baf6e1d7d56e54a93917996bc339 Mon Sep 17 00:00:00 2001
From: luodangjia <luodangjia>
Date: 星期日, 28 四月 2024 11:21:49 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 rest/src/main/java/cn/stylefeng/rest/modular/work/OrderOutTimeCancelWork.java |   18 ++++++++++++++++--
 1 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/rest/src/main/java/cn/stylefeng/rest/modular/work/OrderOutTimeCancelWork.java b/rest/src/main/java/cn/stylefeng/rest/modular/work/OrderOutTimeCancelWork.java
index 510c6cb..7777e11 100644
--- a/rest/src/main/java/cn/stylefeng/rest/modular/work/OrderOutTimeCancelWork.java
+++ b/rest/src/main/java/cn/stylefeng/rest/modular/work/OrderOutTimeCancelWork.java
@@ -449,7 +449,7 @@
                 .ge(CounsellingOrderReservation::getReservationBeginTime,startTime).le(CounsellingOrderReservation::getReservationBeginTime,nowDate)
                 .eq(CounsellingOrderReservation::getStauts,2));
         if (CollectionUtil.isNotEmpty(waitList)){
-            //更新为待服务
+            //更新为服务中
             List<Long> idList = waitList.stream().map(CounsellingOrderReservation::getId).collect(Collectors.toList());
             log.info("自动更新待服务的咨询,ids:"+idList.toString());
             this.counsellingOrderReservationService.update(new LambdaUpdateWrapper<CounsellingOrderReservation>().set(CounsellingOrderReservation::getStauts,3)
@@ -457,9 +457,23 @@
                     .in(CounsellingOrderReservation::getId,idList));
 
         }
+
+//        //查询结束的预约
+//        List<CounsellingOrderReservation> waitList1 = this.counsellingOrderReservationService.list(new LambdaQueryWrapper<CounsellingOrderReservation>()
+//                .le(CounsellingOrderReservation::getReservationEndTime,startTime).eq(CounsellingOrderReservation::getStauts,2));
+//
+//        if (CollectionUtil.isNotEmpty(waitList1)){
+//            //更新为已完成
+//            List<Long> idList = waitList1.stream().map(CounsellingOrderReservation::getId).collect(Collectors.toList());
+//            log.info("自动更新待服务的咨询,ids:"+idList.toString());
+//            this.counsellingOrderReservationService.update(new LambdaUpdateWrapper<CounsellingOrderReservation>().set(CounsellingOrderReservation::getStauts,4)
+//                    .set(CounsellingOrderReservation::getServiceBeginTime,new Date())
+//                    .in(CounsellingOrderReservation::getId,idList));
+
+//        }
         //查询服务中的预约
         List<CounsellingOrderReservation> serviceList = this.counsellingOrderReservationService.list(new LambdaQueryWrapper<CounsellingOrderReservation>()
-                .ge(CounsellingOrderReservation::getReservationEndTime,startTime).le(CounsellingOrderReservation::getReservationEndTime,nowDate)
+                .le(CounsellingOrderReservation::getReservationEndTime,nowDate)
                 .eq(CounsellingOrderReservation::getStauts,3));
         if (CollectionUtil.isNotEmpty(serviceList)){
             log.info("自动更新服务中的咨询,ids:"+serviceList.stream().map(CounsellingOrderReservation::getId).collect(Collectors.toList()).toString());

--
Gitblit v1.7.1