eight
2024-09-19 d78710765c31d449bef4f1af3de285221eb12080
update
已修改8个文件
37 ■■■■ 文件已修改
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/call/vo/CallRespVO.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/call/vo/CallSaveReqVO.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/dataobject/call/CallDO.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/call/CallMapper.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/queueMapper.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/callingscreen/CallingScreenServiceImpl.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
sql/mysql/jh.sql 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/call/vo/CallRespVO.java
@@ -2,6 +2,8 @@
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.time.LocalDate;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
@@ -28,6 +30,10 @@
    @ExcelProperty("患者性别")
    private Integer patGender;
    @Schema(description = "预约日期")
    @ExcelProperty("预约日期")
    private LocalDate bookDate;
    @Schema(description = "排队序号")
    @ExcelProperty("排队序号")
    private Integer seqNum;
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/call/vo/CallSaveReqVO.java
@@ -4,6 +4,8 @@
import lombok.*;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.time.LocalDate;
import java.util.*;
@Schema(description = "管理后台 - 叫号新增/修改 Request VO")
@@ -24,6 +26,9 @@
    @Schema(description = "患者性别")
    private Integer patGender;
    @Schema(description = "预约日期", requiredMode = Schema.RequiredMode.REQUIRED)
    private LocalDate bookDate;
    @Schema(description = "排队序号")
    private Integer seqNum;
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/dataobject/call/CallDO.java
@@ -1,6 +1,8 @@
package cn.lihu.jh.module.ecg.dal.dataobject.call;
import lombok.*;
import java.time.LocalDate;
import java.util.*;
import java.time.LocalDateTime;
import java.time.LocalDateTime;
@@ -40,6 +42,10 @@
     */
    private Integer patGender;
    /**
     * 预约日期
     */
    private LocalDate bookDate;
    /**
     * 排队序号
     */
    private Integer seqNum;
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/call/CallMapper.java
@@ -6,10 +6,8 @@
import cn.lihu.jh.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.lihu.jh.framework.mybatis.core.mapper.BaseMapperX;
import cn.lihu.jh.module.ecg.dal.dataobject.call.CallDO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.*;
import cn.lihu.jh.module.ecg.controller.admin.call.vo.*;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
/**
 * 叫号 Mapper
@@ -41,4 +39,7 @@
    @Select("select * from lihu.call_patient where called = 0 order by id limit 1")
    CallDO getNextCall();
    @Update("TRUNCATE TABLE lihu.call_patient")
    void clearCall();
}
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/queue/queueMapper.java
@@ -135,7 +135,8 @@
            " where status = #{curStatus} and pat_id = #{patId}")
    Integer queueJump(@Param("patId")String patId, @Param("curStatus")Byte curStatus, @Param("jumped")Byte jumped );
    @Delete("delete from lihu.queue where TO_DAYS(book_date) != TO_DAYS(NOW())")
    Integer clearQueue();
    //@Delete("delete from lihu.queue where TO_DAYS(book_date) != TO_DAYS(NOW())")
    @Update("TRUNCATE TABLE lihu.queue")
    void clearQueue();
}
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/callingscreen/CallingScreenServiceImpl.java
@@ -57,7 +57,6 @@
        if (listWaiting.size() < bigScreenConfig.waitingSize && waitingFrom != 0) {
            List<QueueDO> listWaiting_next = queueMapper.getPartialQueueByStatus( queueStatusList, 0, bigScreenConfig.waitingSize - listWaiting.size());
            listWaiting.addAll(listWaiting_next);
            waitingFrom = listWaiting.getLast().getId() + 1;
        }
        if (listWaiting.size() < bigScreenConfig.waitingSize) {
            waitingFrom = 0;
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/queue/QueueServiceImpl.java
@@ -6,6 +6,7 @@
import javax.annotation.Resource;
import cn.lihu.jh.module.ecg.controller.admin.room.vo.MonitorInfoVO;
import cn.lihu.jh.module.ecg.dal.mysql.call.CallMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils;
@@ -46,6 +47,9 @@
    @Resource
    private RoomMapper roomMapper;
    @Resource
    private CallMapper callMapper;
    AtomicInteger openingFlag = new AtomicInteger(0);
    AtomicInteger curSeqNum = new AtomicInteger(0);
@@ -468,6 +472,8 @@
        // 清除非当天的排队人员
        queueMapper.clearQueue();
        // 清除非当天的语音叫号记录
        callMapper.clearCall();
        // 从DB 获取 工位列表
        List<BedStatusEnum> bedStatusEnumList = new ArrayList<BedStatusEnum>();
sql/mysql/jh.sql
@@ -198,6 +198,7 @@
  `pat_id` varchar(30) NOT NULL COMMENT '患者编号',
  `pat_name` varchar(10) NOT NULL COMMENT '患者姓名',
  `pat_gender` int DEFAULT NULL COMMENT '患者性别',
  `book_date` date NOT NULL COMMENT '预约日期',
  `seq_num` int DEFAULT NULL COMMENT '排队序号',
  `passed` int DEFAULT '0' COMMENT '过号标记',
  `expired` int DEFAULT '0' COMMENT '预约过期标记',