yxh
yxh
2024-01-04 a88e19be56fab4f06aae0248575b55fed41eaa1e
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
<?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.ruoyi.project.mapper.ServiceDonatecomporganMapper">
 
    <resultMap type="com.ruoyi.project.domain.ServiceDonatecomporgan" id="ServiceDonatecomporganResult">
        <result property="id" column="ID"/>
        <result property="infoid" column="InfoID"/>
        <result property="organno" column="OrganNo"/>
        <result property="organname" column="OrganName"/>
        <result property="transplantstate" column="transplantstate"/>
        <result property="abandonreason" column="AbandonReason"/>
        <result property="transplanttime" column="TransplantTime"/>
        <result property="transplantdoct" column="TransplantDoct"/>
        <result property="transplanthospitalno" column="TransplantHospitalNo"/>
        <result property="transplanthospitalname" column="TransplantHospitalName"/>
        <result property="name" column="Name"/>
        <result property="sex" column="Sex"/>
        <result property="idcardtype" column="IDCardType"/>
        <result property="idcardno" column="IDCardNo"/>
        <result property="age" column="Age"/>
        <result property="ageunit" column="AgeUnit"/>
        <result property="birthday" column="Birthday"/>
        <result property="phone" column="Phone"/>
        <result property="residenceaddress" column="ResidenceAddress"/>
        <result property="residenceprovince" column="ResidenceProvince"/>
        <result property="residenceprovincename" column="ResidenceProvinceName"/>
        <result property="residencecity" column="ResidenceCity"/>
        <result property="residencecityname" column="ResidenceCityName"/>
        <result property="residencetown" column="ResidenceTown"/>
        <result property="residencetownname" column="ResidenceTownName"/>
        <result property="residencecommunity" column="ResidenceCommunity"/>
        <result property="residencecommunityname" column="ResidenceCommunityName"/>
        <result property="residencecountycode" column="ResidenceCountyCode"/>
        <result property="residencecountyname" column="ResidenceCountyName"/>
        <result property="delFlag" column="del_flag"/>
        <result property="createBy" column="create_by"/>
        <result property="createTime" column="create_time"/>
        <result property="updateBy" column="update_by"/>
        <result property="updateTime" column="update_time"/>
    </resultMap>
 
    <sql id="selectServiceDonatecomporganVo">
        select ID,
               InfoID,
               OrganNo,
               OrganName,
               transplantstate,
               AbandonReason,
               TransplantTime,
               TransplantDoct,
               TransplantHospitalNo,
               TransplantHospitalName,
               Name,
               Sex,
               IDCardType,
               IDCardNo,
               Age,
               AgeUnit,
               Birthday,
               Phone,
               ResidenceAddress,
               ResidenceProvince,
               ResidenceProvinceName,
               ResidenceCity,
               ResidenceCityName,
               ResidenceTown,
               ResidenceTownName,
               ResidenceCommunity,
               ResidenceCommunityName,
               ResidenceCountyCode,
               ResidenceCountyName,
               del_flag,
               create_by,
               create_time,
               update_by,
               update_time
        from service_donatecomporgan
    </sql>
 
    <select id="selectServiceDonatecomporganList" parameterType="com.ruoyi.project.domain.ServiceDonatecomporgan"
            resultMap="ServiceDonatecomporganResult">
        <include refid="selectServiceDonatecomporganVo"/>
        <where>
            <if test="infoid != null ">and InfoID = #{infoid}</if>
            <if test="organno != null  and organno != ''">and OrganNo = #{organno}</if>
            <if test="organname != null  and organname != ''">and OrganName like concat('%', #{organname}, '%')</if>
            <if test="transplantstate != null ">and transplantstate = #{transplantstate}</if>
            <if test="abandonreason != null  and abandonreason != ''">and AbandonReason = #{abandonreason}</if>
            <if test="transplanttime != null ">and TransplantTime = #{transplanttime}</if>
            <if test="transplantdoct != null  and transplantdoct != ''">and TransplantDoct = #{transplantdoct}</if>
            <if test="transplanthospitalno != null  and transplanthospitalno != ''">and TransplantHospitalNo =
                #{transplanthospitalno}
            </if>
            <if test="transplanthospitalname != null  and transplanthospitalname != ''">and TransplantHospitalName like
                concat('%', #{transplanthospitalname}, '%')
            </if>
            <if test="name != null  and name != ''">and Name like concat('%', #{name}, '%')</if>
            <if test="sex != null ">and Sex = #{sex}</if>
            <if test="idcardtype != null ">and IDCardType = #{idcardtype}</if>
            <if test="idcardno != null  and idcardno != ''">and IDCardNo = #{idcardno}</if>
            <if test="age != null ">and Age = #{age}</if>
            <if test="ageunit != null  and ageunit != ''">and AgeUnit = #{ageunit}</if>
            <if test="birthday != null  and birthday != ''">and Birthday = #{birthday}</if>
            <if test="phone != null  and phone != ''">and Phone = #{phone}</if>
            <if test="residenceaddress != null  and residenceaddress != ''">and ResidenceAddress = #{residenceaddress}
            </if>
            <if test="residenceprovince != null  and residenceprovince != ''">and ResidenceProvince =
                #{residenceprovince}
            </if>
            <if test="residenceprovincename != null  and residenceprovincename != ''">and ResidenceProvinceName like
                concat('%', #{residenceprovincename}, '%')
            </if>
            <if test="residencecity != null  and residencecity != ''">and ResidenceCity = #{residencecity}</if>
            <if test="residencecityname != null  and residencecityname != ''">and ResidenceCityName like concat('%',
                #{residencecityname}, '%')
            </if>
            <if test="residencetown != null  and residencetown != ''">and ResidenceTown = #{residencetown}</if>
            <if test="residencetownname != null  and residencetownname != ''">and ResidenceTownName like concat('%',
                #{residencetownname}, '%')
            </if>
            <if test="residencecommunity != null  and residencecommunity != ''">and ResidenceCommunity =
                #{residencecommunity}
            </if>
            <if test="residencecommunityname != null  and residencecommunityname != ''">and ResidenceCommunityName like
                concat('%', #{residencecommunityname}, '%')
            </if>
            <if test="residencecountycode != null  and residencecountycode != ''">and ResidenceCountyCode =
                #{residencecountycode}
            </if>
            <if test="residencecountyname != null  and residencecountyname != ''">and ResidenceCountyName like
                concat('%', #{residencecountyname}, '%')
            </if>
        </where>
    </select>
 
</mapper>