zhongrj
2024-05-17 cd92c8e582d55bdb683be4003a37caa2c6c3ed6c
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
29
30
31
32
33
34
35
<?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.police.mapper.PoliceStationMapper">
 
    <!-- 通用查询映射结果 -->
    <resultMap id="policeStationResultMap" type="org.springblade.modules.police.entity.PoliceStationEntity">
        <result column="id" property="id"/>
        <result column="code" property="code"/>
        <result column="name" property="name"/>
        <result column="geom" property="geom"/>
        <result column="sort" property="sort"/>
        <result column="create_time" property="createTime"/>
        <result column="create_user" property="createUser"/>
        <result column="update_time" property="updateTime"/>
        <result column="update_user" property="updateUser"/>
        <result column="remark" property="remark"/>
        <result column="is_deleted" property="isDeleted"/>
    </resultMap>
 
 
    <select id="selectPoliceStationPage" resultMap="policeStationResultMap">
        select * from jczz_police_station where is_deleted = 0
    </select>
 
    <!--派出所树查询-->
    <select id="tree" resultType="org.springblade.common.node.TreeStringNode">
        SELECT
        code as id,
        parent_code as parentId,
        name
        FROM jczz_police_station
    </select>
 
 
</mapper>