From c663b36cebeed7b40498a4e676559b62c0d4bee6 Mon Sep 17 00:00:00 2001
From: eight <641137800@qq.com>
Date: 星期一, 31 三月 2025 15:37:02 +0800
Subject: [PATCH] 预约确认、加急 都触发 抢排队中 患者
---
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java | 10 +++++-----
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/QueueMapper.java | 9 +++++----
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueService.java | 2 +-
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/queue/QueueController.java | 3 ++-
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceTxFunctions.java | 9 +++++----
5 files changed, 18 insertions(+), 15 deletions(-)
diff --git a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/queue/QueueController.java b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/queue/QueueController.java
index 5089924..6324462 100644
--- a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/queue/QueueController.java
+++ b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/queue/QueueController.java
@@ -135,9 +135,10 @@
@PreAuthorize("@ss.hasPermission('ecg:queue:jump')")
public CommonResult<String> queueJump(
@RequestParam("patId") String patId,
+ @RequestParam("bookCheckType") Integer bookCheckType,
@RequestParam("jumpFlag") Byte jumpFlag)
{
- Integer result = queueService.patientJump(patId, jumpFlag);
+ Integer result = queueService.patientJump(patId, bookCheckType, jumpFlag);
if (null == result || 0 == result)
return error( new ErrorCode(201, "鎵句笉鍒版偅鑰�") );
diff --git a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/QueueMapper.java b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/QueueMapper.java
index bd19244..a037c4f 100644
--- a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/QueueMapper.java
+++ b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/QueueMapper.java
@@ -42,8 +42,8 @@
@Select("SELECT * FROM lihu.queue where seq_num = #{seqNum}")
QueueDO getQueueItemBySeqNum(@Param("seqNum")Integer seqNum);
- @Select("SELECT * FROM lihu.queue where pat_id = #{patId}")
- QueueDO getQueueByPatId(@Param("patId")String patId);
+ @Select("SELECT * FROM lihu.queue where pat_id = #{patId} and book_check_type = #{bookCheckType}")
+ QueueDO getQueueByPatId(@Param("patId")String patId, @Param("bookCheckType")Integer bookCheckType);
@Select("<script>" +
"SELECT * FROM lihu.queue " +
@@ -286,8 +286,9 @@
@Param("curStatus")Integer curStatus, @Param("newStatus")Integer newStatus);
@Update("update lihu.queue set jump_flag = #{jumped} " +
- " where status = #{curStatus} and pat_id = #{patId}")
- Integer queueJump(@Param("patId")String patId, @Param("curStatus")Integer curStatus, @Param("jumped")Byte jumped );
+ " where status = #{curStatus} and pat_id = #{patId} and book_check_type=#{bookCheckType}")
+ Integer queueJump(@Param("patId")String patId, @Param("bookCheckType")Integer bookCheckType,
+ @Param("curStatus")Integer curStatus, @Param("jumped")Byte jumped );
//@Update("TRUNCATE TABLE lihu.queue")
@Delete("delete from lihu.queue where TO_DAYS(book_date) != TO_DAYS(NOW())")
diff --git a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueService.java b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueService.java
index 035857f..1a973c1 100644
--- a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueService.java
+++ b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueService.java
@@ -137,7 +137,7 @@
Integer recallInstallPatient(Long roomId, String bedNo, String patId, Integer checkType, Long roomId_operator, String bedNo_operator);
- Integer patientJump(String patId, Byte jumped );
+ Integer patientJump(String patId, Integer bookCheckType, Byte jumped );
List<RoomDO> getDocRoomInfo(Long docId);
diff --git a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java
index be3023e..50c0a46 100644
--- a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java
+++ b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java
@@ -338,7 +338,7 @@
devRent.setCheckType( queueSaveReqVO.getBookCheckType() );
devRentMapper.insert(devRent);
- //startHurryUpOneCheckType( queue.getBookCheckType() );
+ startHurryUpOneCheckType( queue.getBookCheckType() );
}
@Override
@@ -570,11 +570,11 @@
* @return
*/
@Override
- public Integer patientJump(String patId, Byte jumped) {
- Integer updateNum = queueMapper.queueJump(patId, QueueStatusEnum.WAITING.getStatus(), jumped);
+ public Integer patientJump(String patId, Integer bookCheckType, Byte jumped) {
+ Integer updateNum = queueMapper.queueJump(patId, bookCheckType, QueueStatusEnum.WAITING.getStatus(), jumped);
- //QueueDO queueDO = queueMapper.getQueueByPatId(patId);
- //startHurryUpOneCheckType(Integer.valueOf(queueDO.getBookCheckType()));
+ QueueDO queueDO = queueMapper.getQueueByPatId(patId, bookCheckType);
+ startHurryUpOneCheckType(Integer.valueOf(queueDO.getBookCheckType()));
return updateNum;
}
diff --git a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceTxFunctions.java b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceTxFunctions.java
index 10399ac..4f22cfb 100644
--- a/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceTxFunctions.java
+++ b/jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceTxFunctions.java
@@ -422,9 +422,10 @@
}
/**
- * Deprecated 浠g爜淇濈暀锛屽疄闄呭凡缁忎笉鍐嶄娇鐢�
- * 鍘熷洜: 鍚屼竴宸ヤ綅鍙互鍚屾椂澶勭悊澶氫釜妫�鏌ラ」鐩紝鎵�浠ラ渶瑕佷繚璇佸涓鏌ラ」鐩殑灏辫瘖鏃堕棿鍏堝悗椤哄簭
+ * 涓�涓伐浣嶅彲浠ユ敮鎸佸涓鏌ラ」鐩紝鎵�浠ラ渶瑕佷繚璇佸涓鏌ラ」鐩殑灏辫瘖鏃堕棿鍏堝悗椤哄簭
* 鎸夌収涓�涓鏌ラ」鐩潵澶勭悊锛屽氨涓嶈兘淇濊瘉鍚屼竴涓伐浣嶇殑澶氫釜妫�鏌ラ」鐩殑灏辫瘖鏃堕棿鐨勫厛鍚庨『搴�
+ * 鎵�浠ュ疄鐜伴�昏緫鏄� 璁╂敮鎸佽妫�鏌ラ」鐩殑鎵�鏈夊伐浣嶅幓鎶㈠崰 銆愭帓闃熶腑銆戙�愬伐浣嶆敮鎸佺殑妫�鏌ラ」鐩�戠殑鎮h��
+ * 瀹為檯鎶㈠崰鐨勬湭蹇呮槸 鍙傛暟涓殑妫�鏌ラ」鐩殑鎮h�咃紝鍙兘鏄叾浠栨鏌ラ」鐩殑鎮h��
* @param checkType
*/
public void hurryupOneCheckType(Integer checkType) {
@@ -446,14 +447,14 @@
return;
// 鏌ョ湅 鏄惁鏈夋帓闃熶腑鐨勬偅鑰�
- Integer updateNum = queueMapper.preemptWaitingPatient(
+ Integer updateNum = queueMapper.preemptWaitingPatientWithBedCheckTypes(
bedQueueBO.getRoomId(),
bedQueueBO.getRoomName(),
bedQueueBO.getBedNo(),
curSeqNum.get() + 1,
QueueStatusEnum.WAITING.getStatus(),
QueueStatusEnum.READY.getStatus(),
- checkType);
+ bedQueueBO.checkTypes); //鍏抽敭鐐� 鍏抽敭鐐� 鍏抽敭鐐� checkType
// 娌℃湁鎶㈠埌鎺掗槦鎮h��
if (null == updateNum || 0 == updateNum) {
--
Gitblit v1.9.3