From 003513b047fcae16e2125ff7a59e6d46ad048ce4 Mon Sep 17 00:00:00 2001
From: liusheng <337615773@qq.com>
Date: 星期四, 16 十月 2025 18:03:36 +0800
Subject: [PATCH] 代码提交
---
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/config/EcgConfigServiceImpl.java | 34 +++++++++++++++++++++++++++++-----
1 files changed, 29 insertions(+), 5 deletions(-)
diff --git a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/config/EcgConfigServiceImpl.java b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/config/EcgConfigServiceImpl.java
index 7659720..3f969ff 100644
--- a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/config/EcgConfigServiceImpl.java
+++ b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/config/EcgConfigServiceImpl.java
@@ -2,7 +2,10 @@
import cn.lihu.jh.module.ecg.Utils;
import cn.lihu.jh.module.ecg.config.DynamicSchedulingConfig;
+import cn.lihu.jh.module.ecg.dal.dataobject.checktype.CheckTypeDO;
+import cn.lihu.jh.module.ecg.dal.mysql.queuesequence.QueueSequenceMapper;
import cn.lihu.jh.module.ecg.service.queue.QueueService;
+import cn.lihu.jh.module.ecg.service.queuesequence.QueueSequenceService;
import cn.lihu.jh.module.ecg.service.room.RoomService;
import cn.lihu.jh.module.infra.api.config.ConfigApi;
import lombok.extern.slf4j.Slf4j;
@@ -16,11 +19,7 @@
import javax.annotation.Resource;
import java.time.LocalTime;
import java.util.List;
-import java.util.concurrent.Executors;
-import java.util.concurrent.ScheduledExecutorService;
-
-import static cn.lihu.jh.module.ecg.Constants.ECG_OPENING_TIME_KEY;
-import static cn.lihu.jh.module.ecg.Constants.ECG_ROOM_RESET_TIME_KEY;
+import static cn.lihu.jh.module.ecg.Constants.*;
@Service
@Validated
@@ -35,6 +34,12 @@
@Resource
private QueueService queueService;
+
+ @Resource
+ private QueueSequenceService queueSequenceService;
+
+ List<LocalTime> timeslotList = null;
+ Integer timeslotLength = 0;
ScheduledTask startBizTask = null;
ScheduledTask closeBizTask = null;
@@ -72,9 +77,28 @@
resetRoomTask = taskRegistrar.scheduleCronTask(new CronTask(() -> {
System.out.println("Room Reset Task executed at: " + System.currentTimeMillis());
roomService.resetRoom(false);
+ queueSequenceService.resetQueueSequence();
}, roomResetCronExpression));
taskRegistrar.afterPropertiesSet();
}
+ @Override
+ public void readTimeSlotConfig() {
+ String strBookTimeslotLength = configApi.getConfigValueByKey(BOOK_TIMESLOT_LENGTH);
+ timeslotLength = Integer.valueOf(strBookTimeslotLength);
+ //String strBookTimeslotList = configApi.getConfigValueByKey(BOOK_TIMESLOT_LIST);
+ //timeslotList = Utils.parseTimeSlotList(strBookTimeslotList, Integer.valueOf(strBookTimeslotLength));
+ }
+
+ @Override
+ public List<LocalTime> listTimeslot() {
+ return timeslotList;
+ }
+
+ @Override
+ public Integer getTimeslotLength() {
+ return timeslotLength;
+ }
+
}
--
Gitblit v1.9.3