傅行帆 před 4 roky
rodič
revize
88c2e2ed19

+ 5
- 9
src/main/resources/mapper/property/TaUserVerifyMapper.xml Zobrazit soubor

@@ -10,24 +10,20 @@
10 10
 
11 11
     <select id="selectAllByPhoneAndUserNameAndIdCard" resultType="com.huiju.estateagents.property.model.TaUserVerify" >
12 12
         select
13
-            tav.*,
14
-            tu.user_name as userName,
15
-            tu.login_name as phone,
16
-            tu.id_card as idCard,
17
-            tu.gender as gender
13
+            tav.*
18 14
         from
19
-          ta_user_verify tav LEFT JOIN ta_user tu on tav.user_id = tu.id
15
+          ta_user_verify tav
20 16
         <where>
21 17
             <trim suffixOverrides="and | or">
22 18
                 tav.verify_status = 0
23 19
                 <if test="phone != null and phone != ''">
24
-                    and tu.login_name like CONCAT('%',#{phone},'%')
20
+                    and tav.phone like CONCAT('%',#{phone},'%')
25 21
                 </if>
26 22
                 <if test="userName != null and userName != ''">
27
-                    and tu.user_name like CONCAT('%',#{userName},'%')
23
+                    and tav.owner_name like CONCAT('%',#{userName},'%')
28 24
                 </if>
29 25
                 <if test="idCard != null and idCard != ''">
30
-                    and tu.id_card like CONCAT('%',#{idCard},'%')
26
+                    and tav.id_card like CONCAT('%',#{idCard},'%')
31 27
                 </if>
32 28
                 <if test="orgId != null and orgId != ''">
33 29
                     and tav.org_id = #{orgId,jdbcType=INTEGER}

+ 6
- 9
src/main/resources/mapper/property/TpBuildingOwnerInfoMapper.xml Zobrazit soubor

@@ -68,17 +68,14 @@
68 68
             u.room_no_name,
69 69
             u.id AS userVerifyId,
70 70
             u.org_id AS orgId,
71
-            t.login_name AS ownerTel,
72
-            t.user_name AS ownerName,
73
-            t.id_card AS idCard,
74
-            r.description AS roleName,
71
+            u.phone AS ownerTel,
72
+            u.owner_name AS ownerName,
73
+            u.id_card AS idCard,
75 74
             u.verify_status AS verifyStatus,
76 75
             u.verify_name AS updateName,
77 76
             u.create_date AS createDate
78 77
         FROM
79 78
             ta_user_verify u
80
-            LEFT JOIN ta_user t ON t.id = u.user_id
81
-            LEFT JOIN ta_sys_role r ON u.role_id = r.id
82 79
         WHERE
83 80
 
84 81
         u.org_id=#{tpBuildingOwnerInfo.orgId,jdbcType=INTEGER}
@@ -98,13 +95,13 @@
98 95
             and u.room_no_id = #{tpBuildingOwnerInfo.roomNoId,jdbcType=INTEGER}
99 96
         </if>
100 97
         <if test="tpBuildingOwnerInfo.ownerName != null and tpBuildingOwnerInfo.ownerName != ''">
101
-            and t.user_name like concat('%',#{tpBuildingOwnerInfo.ownerName,jdbcType=VARCHAR},'%')
98
+            and u.owner_name like concat('%',#{tpBuildingOwnerInfo.ownerName,jdbcType=VARCHAR},'%')
102 99
         </if>
103 100
         <if test="tpBuildingOwnerInfo.ownerTel != null and tpBuildingOwnerInfo.ownerTel != ''">
104
-            and t.login_name like concat('%',#{tpBuildingOwnerInfo.ownerTel,jdbcType=VARCHAR},'%')
101
+            and u.phone like concat('%',#{tpBuildingOwnerInfo.ownerTel,jdbcType=VARCHAR},'%')
105 102
         </if>
106 103
         <if test="tpBuildingOwnerInfo.idCard != null and tpBuildingOwnerInfo.idCard != ''">
107
-            and t.id_card like concat('%',#{tpBuildingOwnerInfo.idCard,jdbcType=VARCHAR},'%')
104
+            and u.id_card like concat('%',#{tpBuildingOwnerInfo.idCard,jdbcType=VARCHAR},'%')
108 105
         </if>
109 106
         order by u.create_date desc
110 107
     </select>