| | |
| | | ) |
| | | </select> |
| | | |
| | | <!--查询公安相关的区域数据--> |
| | | <select id="getPoliceList" resultType="org.springblade.modules.system.entity.Region"> |
| | | SELECT id as code,parentId as parent_code,name,'' as ancestors,null as region_level,1 as sort FROM police_region |
| | | </select> |
| | | |
| | | |
| | | <!--查询公安对应的辖区树--> |
| | | <select id="getPoliceTreeList" resultType="org.springblade.common.node.TreeStringNode"> |
| | | SELECT |
| | | CODE AS id, |
| | | parent_code AS parentId, |
| | | NAME |
| | | FROM jczz_police_station |
| | | WHERE is_deleted = 0 |
| | | UNION ALL |
| | | SELECT |
| | | jw_grid_code AS id, |
| | | pcs_code AS parentId, |
| | | community_name AS NAME |
| | | FROM jczz_police_affairs_grid |
| | | WHERE is_deleted = 0 AND pcs_code IS NOT NULL |
| | | </select> |
| | | |
| | | </mapper> |