| | |
| | | </if> |
| | | </select> |
| | | |
| | | <!-- 查询小区信息 add by wuxw 2018-07-03 --> |
| | | <select id="getCommunitys" parameterType="Map" resultType="Map"> |
| | | select t.address,t.nearby_landmarks,t.nearby_landmarks nearbyLandmarks, |
| | | t.city_code,t.city_code cityCode,t.name,t.status_cd,t.status_cd statusCd,t.tel, |
| | | t.community_id,t.community_id communityId,t.b_id,t.b_id bId,t.map_y,t.map_y mapY, |
| | | t.map_x,t.map_x mapX,t.state,ca.area_code areaCode,ca.area_name areaName, |
| | | ca.parent_area_code parentAreaCode,ca.parent_area_name parentAreaName, |
| | | t.community_area communityArea |
| | | from s_community t,city_area ca |
| | | where t.status_cd = '0' |
| | | and t.city_code = ca.area_code |
| | | and ca.status_cd = '0' |
| | | <if test="address !=null and address != ''"> |
| | | and t.address= #{address} |
| | | </if> |
| | | <if test="nearbyLandmarks !=null and nearbyLandmarks != ''"> |
| | | and t.nearby_landmarks= #{nearbyLandmarks} |
| | | </if> |
| | | <if test="cityCode !=null and cityCode != ''"> |
| | | and t.city_code= #{cityCode} |
| | | </if> |
| | | <if test="name !=null and name != ''"> |
| | | and t.name like concat('%',#{name},'%') |
| | | </if> |
| | | <if test="statusCd !=null and statusCd != ''"> |
| | | and t.status_cd= #{statusCd} |
| | | </if> |
| | | <if test="communityId !=null and communityId != ''"> |
| | | and t.community_id= #{communityId} |
| | | </if> |
| | | <if test="communityIds !=null"> |
| | | and t.community_id in |
| | | <foreach collection="communityIds" item="item" open="(" close=")" separator=","> |
| | | #{item} |
| | | </foreach> |
| | | </if> |
| | | <if test="bId !=null and bId != ''"> |
| | | and t.b_id= #{bId} |
| | | </if> |
| | | <if test="mapY !=null and mapY != ''"> |
| | | and t.map_y= #{mapY} |
| | | </if> |
| | | <if test="mapX !=null and mapX != ''"> |
| | | and t.map_x= #{mapX} |
| | | </if> |
| | | <if test="state !=null and state != ''"> |
| | | and t.state= #{state} |
| | | </if> |
| | | order by t.create_time ASC |
| | | <if test="page != -1 and page != null "> |
| | | limit #{page}, #{row} |
| | | </if> |
| | | |
| | | </select> |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | </mapper> |