<?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="com.yeejoin.amos.fas.business.dao.mapper.PlanVisual3dMapper">
	<!--查询 0-设备类；1-耗材类;2-视频监控;3-灭火器材'-->
<!--	<select id="getResourceListByType" resultType="java.util.HashMap">-->
<!--	-->
<!--		SELECT-->
<!--		 rs.id as `key` ,-->
<!--		 rs.id AS `value`,-->
<!--		 rs.name as label,-->
<!--		 rs.code ,-->
<!--		 'id' as dataType-->
<!--		from-->
<!--		<choose>-->
<!--			<when test="type=='fireCar'">-->
<!--				(SELECT a.id,a.name,a.car_num as code FROM `f_fire_car` a) as rs-->
<!--			</when>-->
<!--			<when test="type=='monitorEquipment'">-->
<!--				(select a.id,a.name,a.code from f_fire_equipment a where a.equip_classify = 0)  as rs-->
<!--			</when>-->
<!--			<when test="type=='fireConsumables'">-->
<!--				(select a.id,a.name,a.code from f_fire_equipment a where a.equip_classify = 1) as rs-->
<!--			</when>-->
<!--			<when test="type=='video'">-->
<!--				(select a.id,a.name,a.code from f_fire_equipment a where a.equip_classify = 2) as rs-->
<!--			</when>-->
<!--			<when test="type=='fireEquipment'">-->
<!--				(select a.id,a.name,a.code from f_fire_equipment a where a.equip_classify = 3) as rs-->
<!--			</when>-->
<!--			<when test="type=='impEquipment'">-->
<!--				(select a.id,a.`name`,a.`code` from f_equipment a) as rs-->
<!--			</when>-->
<!--			<when test="type=='fireStrength'">-->
<!--				(select a.id,a.`username` as name ,a.`code` from f_fire_strength a) as rs-->
<!--			</when>-->
<!--			<when test="type=='fireChamber'">-->
<!--				(select a.id,a.`name`,a.`code` from f_fire_station a where a.type = '1') as rs-->
<!--			</when>-->
<!--			<when test="type=='fireFoamRoom'">-->
<!--				(select a.id,a.`name`,a.`code` from f_fire_station a where a.type = '2') as rs-->
<!--			</when>-->
<!--			<when test="type=='hydrant'">-->
<!--				(SELECT a.id,a.`name`,a.code FROM `f_water_resource` a where a.type = '1') as rs-->
<!--			</when>-->
<!--			<when test="type=='pool'">-->
<!--				(SELECT a.id,a.`name`,a.code FROM `f_water_resource` a where a.type = '2') as rs-->
<!--			</when>-->
<!--		</choose>-->
<!--	</select>-->

<!--	<select id="queryOneByTypeAndId" resultType="hashmap">-->
<!--		SELECT-->
<!--			*-->
<!--		from-->
<!--		<choose>-->
<!--			<when test="type=='fireCar'">-->
<!--				(SELECT * FROM `f_fire_car` a) as rs-->
<!--			</when>-->
<!--			<when test="type=='monitorEquipment'">-->
<!--				(select * from f_fire_equipment a where a.equip_classify = 0)  as rs-->
<!--			</when>-->
<!--			<when test="type=='fireConsumables'">-->
<!--				(select * from f_fire_equipment a where a.equip_classify = 1) as rs-->
<!--			</when>-->
<!--			<when test="type=='video'">-->
<!--				(select * from f_fire_equipment a where a.equip_classify = 2) as rs-->
<!--			</when>-->
<!--			<when test="type=='fireEquipment'">-->
<!--				(select * from f_fire_equipment a where a.equip_classify = 3) as rs-->
<!--			</when>-->
<!--			<when test="type=='impEquipment'">-->
<!--				(select * from f_equipment a) as rs-->
<!--			</when>-->
<!--			<when test="type=='fireStrength'">-->
<!--				(select * from f_fire_strength a) as rs-->
<!--			</when>-->
<!--			<when test="type=='fireChamber'">-->
<!--				(select * from f_fire_station a where a.type = '1') as rs-->
<!--			</when>-->
<!--			<when test="type=='fireFoamRoom'">-->
<!--				(select * from f_fire_station a where a.type = '2') as rs-->
<!--			</when>-->
<!--			<when test="type=='hydrant'">-->
<!--				(SELECT * FROM `f_water_resource` a where a.type = '1') as rs-->
<!--			</when>-->
<!--			<when test="type=='pool'">-->
<!--				(SELECT * FROM `f_water_resource` a where a.type = '2') as rs-->
<!--			</when>-->
<!--		</choose>-->
<!--		where rs.id = #{id}-->
<!--	</select>-->
</mapper>