陈昶聿
4 天以前 eb845e8be695ed1280a7cbf854a4d1dedf9db30d
smartor/src/main/resources/mapper/smartor/PatArchiveMapper.xml
@@ -286,6 +286,14 @@
        where id = #{id} and del_flag=0
    </select>
    <!-- 串行化同一患者的人工随访创建,避免并发重复校验失效 -->
    <select id="lockPatArchiveByPatid" resultType="java.lang.Long">
        select id
        from pat_archive
        where id = #{patid} and del_flag = 0
        for update
    </select>
    <select id="selectPatArchiveByPatnos" resultMap="PatArchiveResult">
        SELECT id, patientno
        FROM pat_archive