<?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="cn.iocoder.yudao.module.rescue.mapper.RescueDriverPositionMapper">



    <select id="selectRescueDriverPositionList"  resultType="cn.iocoder.yudao.module.rescue.domain.RescueDriverPosition">
       select  * from rescue_driver_position
        <where>  
            <if test="vo.rescueInfoId != null "> and rescue_info_id = #{vo.rescueInfoId}</if>
            <if test="vo.driverId != null "> and driver_id = #{vo.driverId}</if>
            <if test="vo.longitude != null  and vo.longitude != ''"> and longitude = #{vo.longitude}</if>
            <if test="vo.latitude != null  and vo.latitude != ''"> and latitude = #{vo.latitude}</if>
            <if test="vo.positionInfo != null  and vo.positionInfo != ''"> and position_info = #{vo.positionInfo}</if>
        </where>
        order by create_time
    </select>
    
    <select id="selectRescueDriverPositionById" resultType="cn.iocoder.yudao.module.rescue.domain.RescueDriverPosition">
        select  * from rescue_driver_position
        where id = #{id}
    </select>

</mapper>