From fb91efe81dc6b0298b53d27fb2458acab090106d Mon Sep 17 00:00:00 2001
From: wuxw <928255095@qq.com>
Date: 星期二, 17 九月 2019 17:26:35 +0800
Subject: [PATCH] 优化小区信息菜单信息
---
java110-db/src/main/resources/mapper/community/CommunityServiceDaoImplMapper.xml | 21 ++++++++++++++++++++-
1 files changed, 20 insertions(+), 1 deletions(-)
diff --git a/java110-db/src/main/resources/mapper/community/CommunityServiceDaoImplMapper.xml b/java110-db/src/main/resources/mapper/community/CommunityServiceDaoImplMapper.xml
index 4981c72..f9dbfac 100644
--- a/java110-db/src/main/resources/mapper/community/CommunityServiceDaoImplMapper.xml
+++ b/java110-db/src/main/resources/mapper/community/CommunityServiceDaoImplMapper.xml
@@ -358,7 +358,10 @@
<!-- 鏌ヨ灏忓尯淇℃伅 add by wuxw 2018-07-03 -->
<select id="getCommunityInfoNew" 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.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
+ 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.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,if(t.state='1000','寰呭鏍�','瀹℃牳瀹屾垚') stateName
from s_community t
where 1 =1
<if test="address !=null and address != ''">
@@ -387,6 +390,14 @@
</if>
<if test="mapX !=null and mapX != ''">
and t.map_x= #{mapX}
+ </if>
+ <if test="memberId !=null and memberId !=''">
+ and exists(
+ select 1 from s_community_member cm
+ where cm.community_id = t.community_id
+ and cm.member_id = #{memberId}
+ and cm.status_cd = '0'
+ )
</if>
<if test="page != -1 and page != null ">
limit #{page}, #{row}
@@ -428,6 +439,14 @@
<if test="mapX !=null and mapX != ''">
and t.map_x= #{mapX}
</if>
+ <if test="memberId !=null and memberId !=''">
+ and exists(
+ select 1 from s_community_member cm
+ where cm.community_id = t.community_id
+ and cm.member_id = #{memberId}
+ and cm.status_cd = '0'
+ )
+ </if>
</select>
--
Gitblit v1.8.0