linwe
2023-11-12 8d8c7da4e91028fc877f101dcd244bef3e18c197
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.springblade.modules.house.mapper.HouseTenantMapper">
 
    <!-- 通用查询映射结果 -->
    <resultMap id="houseTenantResultMap" type="org.springblade.modules.house.entity.HouseTenantEntity">
        <result column="id" property="id"/>
        <result column="housing_rental_id" property="housingRentalId"/>
        <result column="name" property="name"/>
        <result column="phone" property="phone"/>
        <result column="id_card" property="idCard"/>
        <result column="domicile" property="domicile"/>
        <result column="work_unit" property="workUnit"/>
        <result column="remark" property="remark"/>
        <result column="is_deleted" property="isDeleted"/>
    </resultMap>
 
 
    <select id="selectHouseTenantPage" resultMap="houseTenantResultMap">
        select * from jczz_house_tenant where is_deleted = 0
    </select>
 
    <!--根据租房id删除租户信息-->
    <update id="removeByHousingRentalId">
        update jczz_house_tenant set is_deleted = 1 where housing_rental_id = #{housingRentalId}
    </update>
 
</mapper>