From 8d8c7da4e91028fc877f101dcd244bef3e18c197 Mon Sep 17 00:00:00 2001
From: linwe <872216996@qq.com>
Date: Sun, 12 Nov 2023 07:34:21 +0800
Subject: [PATCH] 标签报事+通知公告

---
 src/main/java/org/springblade/modules/house/mapper/HouseholdMapper.xml |   30 ++++++++++++++++++++++++------
 1 files changed, 24 insertions(+), 6 deletions(-)

diff --git a/src/main/java/org/springblade/modules/house/mapper/HouseholdMapper.xml b/src/main/java/org/springblade/modules/house/mapper/HouseholdMapper.xml
index 792e251..a67e880 100644
--- a/src/main/java/org/springblade/modules/house/mapper/HouseholdMapper.xml
+++ b/src/main/java/org/springblade/modules/house/mapper/HouseholdMapper.xml
@@ -44,6 +44,7 @@
         <collection property="householdLabelList" javaType="java.util.List"
                     ofType="org.springblade.modules.house.vo.HouseholdLabelVO" autoMapping="true">
             <id property="id" column="cid"/>
+            <result property="remark" column="cremark"/>
         </collection>
     </resultMap>
 
@@ -54,22 +55,39 @@
 
     <!--查询房屋集合信息-->
     <select id="selectHouseNodeList" resultType="org.springblade.common.node.TreeNode" >
-        select jh.house_code as id,jda.address_name as name,false as hasChildren from jczz_household jh
-        left join jczz_doorplate_address jda on jh.house_code = jda.address_code
-        where 1=1
-        and associated_user_id = #{userId}
+        select jh.house_code    as id,
+               jh.house_code    as houseCode,
+               jda.address_name as name,
+               false            as hasChildren,
+               jda.doorplate_type  doorplateType,
+               jda.address_level   addressLevel
+        from jczz_household jh
+                 left join jczz_doorplate_address jda on jh.house_code = jda.address_code
+        where 1 = 1
+          and associated_user_id = #{userId}
     </select>
 
     <!--查询房屋集合信息-->
     <select id="getHouseholdListByCode" resultMap="householdAndLabelMap" >
         select
             jh.*,
-            jhl.id as cid,jhl.*
+            jhl.id as cid,jhl.*,jhl.remark as cremark
         from jczz_household jh
         left join jczz_household_label jhl on jh.id = jhl.household_id
-        where 1=1
+        where 1=1 and is_deleted = 0
         and house_code = #{code}
     </select>
 
+    <!--查询房屋集合信息-按id-->
+    <select id="getHouseholdListById" resultMap="householdAndLabelMap" >
+        select
+            jh.*,
+            jhl.id as cid,jhl.*,jhl.remark as cremark
+        from jczz_household jh
+        left join jczz_household_label jhl on jh.id = jhl.household_id
+        where 1=1 and is_deleted = 0
+        and jh.id = #{household.id}
+    </select>
+
 
 </mapper>

--
Gitblit v1.9.3