|
|
@@ -128,7 +128,13 @@ where 1 =1
|
|
|
</if>
|
|
|
<if test="memberId !=null and memberId != ''">
|
|
|
and t.member_id= #{memberId}
|
|
|
-</if>
|
|
|
+</if>
|
|
|
+ <if test="ownerIds != null and ownerIds != ''">
|
|
|
+ and t.owner_id in
|
|
|
+ <foreach collection="ownerIds" item="item" open="(" close=")" separator=",">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
<if test="page != -1 and page != null ">
|
|
|
limit #{page}, #{row}
|
|
|
</if>
|
|
|
@@ -176,9 +182,8 @@ and t.member_id= #{memberId}
|
|
|
|
|
|
<!-- 查询业主数量 add by wuxw 2018-07-03 -->
|
|
|
<select id="queryOwnersCount" parameterType="Map" resultType="Map">
|
|
|
- select count(1) count
|
|
|
-from building_owner t
|
|
|
-where 1 =1
|
|
|
+ select count(1) count
|
|
|
+ FROM building_owner t
|
|
|
<if test="sex !=null and sex != ''">
|
|
|
and t.sex= #{sex}
|
|
|
</if>
|
|
|
@@ -213,4 +218,97 @@ where 1 =1
|
|
|
|
|
|
</select>
|
|
|
|
|
|
+
|
|
|
+ <!-- 查询业主数量 add by wuxw 2018-07-03 -->
|
|
|
+ <select id="queryOwnersCountByCondition" parameterType="Map" resultType="Map">
|
|
|
+ select count(1) count
|
|
|
+ FROM building_owner t , s_community_member cm
|
|
|
+ WHERE t.`member_id` = cm.`member_id`
|
|
|
+ AND cm.`community_id` = #{communityId}
|
|
|
+ AND cm.`status_cd` = '0'
|
|
|
+ AND t.`status_cd` = '0'
|
|
|
+ <if test="sex !=null and sex != ''">
|
|
|
+ and t.sex= #{sex}
|
|
|
+ </if>
|
|
|
+ <if test="name !=null and name != ''">
|
|
|
+ and t.name= #{name}
|
|
|
+ </if>
|
|
|
+ <if test="link !=null and link != ''">
|
|
|
+ and t.link= #{link}
|
|
|
+ </if>
|
|
|
+ <if test="statusCd !=null and statusCd != ''">
|
|
|
+ and t.status_cd= #{statusCd}
|
|
|
+ </if>
|
|
|
+ <if test="remark !=null and remark != ''">
|
|
|
+ and t.remark= #{remark}
|
|
|
+ </if>
|
|
|
+ <if test="ownerId !=null and ownerId != ''">
|
|
|
+ and t.owner_id= #{ownerId}
|
|
|
+ </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="age !=null and age != ''">
|
|
|
+ and t.age= #{age}
|
|
|
+ </if>
|
|
|
+ <if test="memberId !=null and memberId != ''">
|
|
|
+ and t.member_id= #{memberId}
|
|
|
+ </if>
|
|
|
+
|
|
|
+
|
|
|
+ </select>
|
|
|
+
|
|
|
+
|
|
|
+ <!-- 查询业主信息 add by wuxw 2018-07-03 -->
|
|
|
+ <select id="getOwnerInfoByCondition" parameterType="Map" resultType="Map">
|
|
|
+ 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
|
|
|
+ FROM building_owner t , s_community_member cm
|
|
|
+ WHERE t.`member_id` = cm.`member_id`
|
|
|
+ AND cm.`community_id` = #{communityId}
|
|
|
+ AND cm.`status_cd` = '0'
|
|
|
+ AND t.`status_cd` = '0'
|
|
|
+ <if test="sex !=null and sex != ''">
|
|
|
+ and t.sex= #{sex}
|
|
|
+ </if>
|
|
|
+ <if test="name !=null and name != ''">
|
|
|
+ and t.name= #{name}
|
|
|
+ </if>
|
|
|
+ <if test="link !=null and link != ''">
|
|
|
+ and t.link= #{link}
|
|
|
+ </if>
|
|
|
+ <if test="statusCd !=null and statusCd != ''">
|
|
|
+ and t.status_cd= #{statusCd}
|
|
|
+ </if>
|
|
|
+ <if test="remark !=null and remark != ''">
|
|
|
+ and t.remark= #{remark}
|
|
|
+ </if>
|
|
|
+ <if test="ownerId !=null and ownerId != ''">
|
|
|
+ and t.owner_id= #{ownerId}
|
|
|
+ </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="age !=null and age != ''">
|
|
|
+ and t.age= #{age}
|
|
|
+ </if>
|
|
|
+ <if test="memberId !=null and memberId != ''">
|
|
|
+ and t.member_id= #{memberId}
|
|
|
+ </if>
|
|
|
+ <if test="ownerIds != null and ownerIds != ''">
|
|
|
+ and t.owner_id in
|
|
|
+ <foreach collection="ownerIds" item="item" open="(" close=")" separator=",">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ <if test="page != -1 and page != null ">
|
|
|
+ limit #{page}, #{row}
|
|
|
+ </if>
|
|
|
+ </select>
|
|
|
+
|
|
|
</mapper>
|