From e40889177c25035496c526dbc12a9665d5b61ceb Mon Sep 17 00:00:00 2001
From: wuxw <928255095@qq.com>
Date: 星期四, 20 三月 2025 12:00:53 +0800
Subject: [PATCH] 优化小区房屋和小区业主 支持按小区查询数据
---
java110-db/src/main/resources/mapper/user/OrgCommunityV1ServiceDaoImplMapper.xml | 169 +++++++++++++++++++++++++++----------------------------
1 files changed, 83 insertions(+), 86 deletions(-)
diff --git a/java110-db/src/main/resources/mapper/user/OrgCommunityV1ServiceDaoImplMapper.xml b/java110-db/src/main/resources/mapper/user/OrgCommunityV1ServiceDaoImplMapper.xml
index 3765f9b..8790585 100644
--- a/java110-db/src/main/resources/mapper/user/OrgCommunityV1ServiceDaoImplMapper.xml
+++ b/java110-db/src/main/resources/mapper/user/OrgCommunityV1ServiceDaoImplMapper.xml
@@ -5,111 +5,108 @@
<mapper namespace="orgCommunityV1ServiceDaoImpl">
-
-
-
<!-- 淇濆瓨缁勭粐灏忓尯淇℃伅 add by wuxw 2018-07-03 -->
<insert id="saveOrgCommunityInfo" parameterType="Map">
insert into u_org_community(
-org_name,community_name,community_id,store_id,org_id,org_community_id
-) values (
-#{orgName},#{communityName},#{communityId},#{storeId},#{orgId},#{orgCommunityId}
-)
+ org_name,community_name,community_id,store_id,org_id,org_community_id
+ ) values (
+ #{orgName},#{communityName},#{communityId},#{storeId},#{orgId},#{orgCommunityId}
+ )
</insert>
-
<!-- 鏌ヨ缁勭粐灏忓尯淇℃伅 add by wuxw 2018-07-03 -->
<select id="getOrgCommunityInfo" parameterType="Map" resultType="Map">
- select t.org_name,t.org_name orgName,t.community_name,t.community_name communityName,t.status_cd,t.status_cd statusCd,t.community_id,t.community_id communityId,t.store_id,t.store_id storeId,t.org_id,t.org_id orgId,t.org_community_id,t.org_community_id orgCommunityId
-from u_org_community t
-where 1 =1
-<if test="orgName !=null and orgName != ''">
- and t.org_name= #{orgName}
-</if>
-<if test="communityName !=null and communityName != ''">
- and t.community_name= #{communityName}
-</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="storeId !=null and storeId != ''">
- and t.store_id= #{storeId}
-</if>
-<if test="orgId !=null and orgId != ''">
- and t.org_id= #{orgId}
-</if>
-<if test="orgCommunityId !=null and orgCommunityId != ''">
- and t.org_community_id= #{orgCommunityId}
-</if>
-order by t.create_time desc
-<if test="page != -1 and page != null ">
- limit #{page}, #{row}
-</if>
+ select t.org_name,t.org_name orgName,t.community_name,t.community_name communityName,t.status_cd,t.status_cd
+ statusCd,t.community_id,t.community_id communityId,t.store_id,t.store_id storeId,t.org_id,t.org_id
+ orgId,t.org_community_id,t.org_community_id orgCommunityId
+ from u_org_community t
+ where 1 =1
+ <if test="orgName !=null and orgName != ''">
+ and t.org_name= #{orgName}
+ </if>
+ <if test="communityName !=null and communityName != ''">
+ and t.community_name= #{communityName}
+ </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="storeId !=null and storeId != ''">
+ and t.store_id= #{storeId}
+ </if>
+ <if test="orgId !=null and orgId != ''">
+ and t.org_id= #{orgId}
+ </if>
+ <if test="orgCommunityId !=null and orgCommunityId != ''">
+ and t.org_community_id= #{orgCommunityId}
+ </if>
+ order by t.create_time desc
+ <if test="page != -1 and page != null ">
+ limit #{page}, #{row}
+ </if>
</select>
-
-
<!-- 淇敼缁勭粐灏忓尯淇℃伅 add by wuxw 2018-07-03 -->
<update id="updateOrgCommunityInfo" parameterType="Map">
- update u_org_community t set t.status_cd = #{statusCd}
-<if test="newBId != null and newBId != ''">
-,t.b_id = #{newBId}
-</if>
-<if test="orgName !=null and orgName != ''">
-, t.org_name= #{orgName}
-</if>
-<if test="communityName !=null and communityName != ''">
-, t.community_name= #{communityName}
-</if>
-<if test="communityId !=null and communityId != ''">
-, t.community_id= #{communityId}
-</if>
-<if test="storeId !=null and storeId != ''">
-, t.store_id= #{storeId}
-</if>
-<if test="orgId !=null and orgId != ''">
-, t.org_id= #{orgId}
-</if>
- where 1=1 <if test="orgCommunityId !=null and orgCommunityId != ''">
-and t.org_community_id= #{orgCommunityId}
-</if>
+ update u_org_community t set t.status_cd = #{statusCd}
+ <if test="newBId != null and newBId != ''">
+ ,t.b_id = #{newBId}
+ </if>
+ <if test="orgName !=null and orgName != ''">
+ , t.org_name= #{orgName}
+ </if>
+ <if test="communityName !=null and communityName != ''">
+ , t.community_name= #{communityName}
+ </if>
+ <if test="communityId !=null and communityId != ''">
+ , t.community_id= #{communityId}
+ </if>
+ <if test="storeId !=null and storeId != ''">
+ , t.store_id= #{storeId}
+ </if>
+ <if test="orgId !=null and orgId != ''">
+ , t.org_id= #{orgId}
+ </if>
+ where 1=1
+ <if test="orgCommunityId !=null and orgCommunityId != ''">
+ and t.org_community_id= #{orgCommunityId}
+ </if>
</update>
<!-- 鏌ヨ缁勭粐灏忓尯鏁伴噺 add by wuxw 2018-07-03 -->
- <select id="queryOrgCommunitysCount" parameterType="Map" resultType="Map">
- select count(1) count
-from u_org_community t
-where 1 =1
-<if test="orgName !=null and orgName != ''">
- and t.org_name= #{orgName}
-</if>
-<if test="communityName !=null and communityName != ''">
- and t.community_name= #{communityName}
-</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="storeId !=null and storeId != ''">
- and t.store_id= #{storeId}
-</if>
-<if test="orgId !=null and orgId != ''">
- and t.org_id= #{orgId}
-</if>
-<if test="orgCommunityId !=null and orgCommunityId != ''">
- and t.org_community_id= #{orgCommunityId}
-</if>
+ <select id="queryOrgCommunitysCount" parameterType="Map" resultType="Map">
+ select count(1) count
+ from u_org_community t
+ where 1 =1
+ <if test="orgName !=null and orgName != ''">
+ and t.org_name= #{orgName}
+ </if>
+ <if test="communityName !=null and communityName != ''">
+ and t.community_name= #{communityName}
+ </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="storeId !=null and storeId != ''">
+ and t.store_id= #{storeId}
+ </if>
+ <if test="orgId !=null and orgId != ''">
+ and t.org_id= #{orgId}
+ </if>
+ <if test="orgCommunityId !=null and orgCommunityId != ''">
+ and t.org_community_id= #{orgCommunityId}
+ </if>
- </select>
+ </select>
</mapper>
--
Gitblit v1.8.0