From 6e9a55146866cd357592a0e0e8aa7b73cf9f036d Mon Sep 17 00:00:00 2001 From: eight <641137800@qq.com> Date: 星期三, 13 十一月 2024 11:10:57 +0800 Subject: [PATCH] 领用界面 患者队列顺序 @检查项目亲和性 --- jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/QueueMapper.java | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) 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 2b6d132..8f4a3b2 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 @@ -156,7 +156,7 @@ " <foreach collection='statusList' separator=',' item='status'>" + " #{status} " + " </foreach> )" + - " order by status desc, seq_num" + + " order by seq_num, status desc" + "</script>") List<QueueDO> getBedQueueByStatus(@Param("roomId")Long roomId, @Param("bedNo")String bedNo, @Param("statusList")List<Integer> statusList); @@ -165,11 +165,13 @@ // 鏌愪釜璇婂鑼冨洿鍐� [宸查鐢╙ [宸插彫鍥�-瀹夎] 浜哄憳 鎶㈠崰, 浼氭洿鏂� [宸ヤ綅鍙穄 // 娌℃湁闄愬畾妫�鏌ョ被鍨嬶紝涓嶈浣跨敤鏃堕棿妲� - @Select("select * from lihu.queue where room_id = #{roomId} and status in ( " + + @Select("<script> " + + "select * from lihu.queue where room_id = #{roomId} and status in ( " + " <foreach collection='curStatusList' separator=',' item='status'>" + " #{status} " + " </foreach> )" + - " order by seq_num, create_time limit 1 " ) + " order by seq_num, create_time limit 1 " + + "</script>" ) QueueDO getFirstItemByRoomAndStatus(@Param("roomId")Long roomId, @Param("curStatusList")List<Integer> curStatusList); @Update("update lihu.queue set status = #{newStatus} where status = #{curStatus} and seq_num = \n" + -- Gitblit v1.9.3