wuxw
2022-07-19 05683f2b2bdbdbe21cf17ad523c21ab338bd1c54
java110-db/src/main/resources/mapper/user/OwnerServiceDaoImplMapper.xml
@@ -125,7 +125,7 @@
        t.user_id,t.user_id userId,t.age,t.member_id,t.member_id memberId,t.owner_type_cd,
        t.owner_type_cd ownerTypeCd,t.create_time createTime,t.community_id,
        t.community_id communityId,t.id_card, t.id_card idCard,t.state,td.name ownerTypeName,
        t.owner_flag,t.owner_flag ownerFlag,
        t.owner_flag,t.owner_flag ownerFlag
        <if test="roomIds != null">
            , borr.room_id roomId
        </if>
@@ -180,9 +180,6 @@
        <if test="bId !=null and bId != ''">
            and t.b_id= #{bId}
        </if>
        <if test="userId !=null and userId != ''">
            and t.user_id= #{userId}
        </if>
        <if test="ownerFlag !=null and ownerFlag != ''">
            and t.owner_flag= #{ownerFlag}
        </if>
@@ -214,7 +211,6 @@
        <if test="page != -1 and page != null ">
            limit #{page}, #{row}
        </if>
    </select>
    <!-- 查询业主信息 add by wuxw 2018-07-03 -->
@@ -267,9 +263,6 @@
        </if>
        <if test="bId !=null and bId != ''">
            and t.b_id= #{bId}
        </if>
        <if test="userId !=null and userId != ''">
            and t.user_id= #{userId}
        </if>
        <if test="ownerFlag !=null and ownerFlag != ''">
            and t.owner_flag= #{ownerFlag}
@@ -374,9 +367,6 @@
        <if test="bId !=null and bId != ''">
            and t.b_id= #{bId}
        </if>
        <if test="userId !=null and userId != ''">
            and t.user_id= #{userId}
        </if>
        <if test="ownerFlag !=null and ownerFlag != ''">
            and t.owner_flag= #{ownerFlag}
        </if>
@@ -391,6 +381,12 @@
        </if>
        <if test="ownerTypeCd !=null and ownerTypeCd != ''">
            and t.owner_type_cd= #{ownerTypeCd}
        </if>
        <if test="ownerTypeCds != null ">
            and t.owner_type_cd in
            <foreach collection="ownerTypeCds" item="item" open="(" close=")" separator=",">
                #{item}
            </foreach>
        </if>
@@ -429,9 +425,6 @@
        <if test="bId !=null and bId != ''">
            and t.b_id= #{bId}
        </if>
        <if test="userId !=null and userId != ''">
            and t.user_id= #{userId}
        </if>
        <if test="ownerFlag !=null and ownerFlag != ''">
            and t.owner_flag= #{ownerFlag}
        </if>
@@ -443,6 +436,12 @@
        </if>
        <if test="ownerTypeCd !=null and ownerTypeCd != ''">
            and t.owner_type_cd= #{ownerTypeCd}
        </if>
        <if test="ownerTypeCds != null ">
            and t.owner_type_cd in
            <foreach collection="ownerTypeCds" item="item" open="(" close=")" separator=",">
                #{item}
            </foreach>
        </if>
@@ -486,9 +485,6 @@
        <if test="bId !=null and bId != ''">
            and t.b_id= #{bId}
        </if>
        <if test="userId !=null and userId != ''">
            and t.user_id= #{userId}
        </if>
        <if test="ownerFlag !=null and ownerFlag != ''">
            and t.owner_flag= #{ownerFlag}
        </if>
@@ -507,6 +503,13 @@
        <if test="ownerTypeCd !=null and ownerTypeCd != ''">
            and t.owner_type_cd= #{ownerTypeCd}
        </if>
        <if test="ownerTypeCds != null ">
            and t.owner_type_cd in
            <foreach collection="ownerTypeCds" item="item" open="(" close=")" separator=",">
                #{item}
            </foreach>
        </if>
        order by t.create_time desc
        <if test="page != -1 and page != null ">
            limit #{page}, #{row}
        </if>
@@ -530,7 +533,7 @@
        SELECT t.sex,t.name,t.link,t.status_cd,t.status_cd statusCd,t.remark,t.owner_id,t.owner_id ownerId,t.b_id,t.b_id
        bId,
        t.user_id,t.user_id userId,t.age,t.member_id,t.member_id memberId,t.owner_type_cd,t.owner_type_cd ownerTypeCd,
        r.`room_id` roomId,r.`room_num` roomNum,t.community_id,t.community_id communityId,t.id_card, t.id_card idCard
        r.`room_id` roomId,r.`room_num` roomNum,t.community_id,t.community_id communityId,t.id_card, t.id_card idCard,orr.start_time startTime ,orr.end_time endTime
        FROM building_room r,building_owner_room_rel orr,building_owner t
        WHERE r.`room_id` = orr.`room_id`
        AND orr.`owner_id` = t.`owner_id`
@@ -589,7 +592,8 @@
        t.room_id roomId
        FROM
        business_building_owner_room_rel t
        INNER JOIN building_owner bo ON t.owner_id = bo.owner_id AND bo.status_cd = '0' AND bo.community_id = #{communityId}
        INNER JOIN building_owner bo ON t.owner_id = bo.owner_id AND bo.status_cd = '0' AND bo.community_id =
        #{communityId}
        WHERE
        t.operate = 'ADD'
        AND t.room_id = #{roomId}