linwe
2023-12-18 ede1ff3b4482bb7e712d1a8563a56a66d349321c
src/main/java/org/springblade/modules/house/mapper/HouseholdMapper.xml
@@ -89,8 +89,31 @@
        </collection>
    </resultMap>
    <resultMap id="householdPageAndLabelMap" type="org.springblade.modules.house.vo.HouseholdVO" autoMapping="true">
        <id property="id" column="id"/>
        <collection property="householdLabelList" javaType="java.util.List" select="selectHouseLabelPage"  column="id"
                    ofType="org.springblade.modules.house.vo.HouseholdLabelVO" autoMapping="true">
        </collection>
    </resultMap>
    <select id="selectHouseLabelPage" resultType="org.springblade.modules.house.vo.HouseholdLabelVO">
        select
        id,
        house_code,
        label_id,
        label_name,
        color,
        remark cremark,
        user_id,
        lable_type,
        household_id
        from
        jczz_user_house_label
        where household_id = #{id} and lable_type = 1
    </select>
    <!--自定义分页数据查询-->
    <select id="selectHouseholdPage" resultType="org.springblade.modules.house.vo.HouseholdVO">
    <select id="selectHouseholdPage" resultMap="householdPageAndLabelMap">
        select
        jh.*,
        jhs.district_name aoiName,