XiaoRuby
2023-08-26 15e31c6e6550f9e8bf6fb1df5ca5ad4cc726b64f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="com.yuanchu.limslaboratory.mapper.WaitInformationMapper">
    <!--查询待办表列表-->
    <select id="selectWaitInforList" resultType="java.util.Map">
        select id,
        name,
        title,
        text,
        DATE_FORMAT(create_time,'%Y-%m-%d') creatTime,
        type
        from lims_laboratory.wait_information
        where state=1
        and `rename`=#{rename}
        <if test="title!=null and title!=''">
            and title like concat('%',#{title},'%')
        </if>
        <if test="text!=null and text!=''">
            and text like concat('%',#{text},'%')
        </if>
        <if test="type!=null ">
            and type =#{type}
        </if>
    </select>
 
    <!--批量删除-->
    <update id="delAllWaitInfor">
        update lims_laboratory.wait_information
        set state=0
        where `rename`=#{rename}
          and  id in (${ids})
    </update>
 
    <!--批量已读-->
    <update id="writeAllWaitInfor">
        update lims_laboratory.wait_information
        set type=1
        where wait_information.state = 1
          and `rename`=#{rename}
          and id in (${ids})
    </update>
</mapper>