<?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.ningdatech.carapi.safe.mapper.AlarmDataVideoMapper">

    <insert id="saveBatchForSql" parameterType="java.util.List">
        INSERT INTO nd_alarm_data_video
        (orgin_video_id,
        vehicle_index_code,
        plate_no,
        vehicle_self_no,
        region_index_code,
        region_name,
        camera_index_code,
        camera_name,
        service_index_code,
        begin_time,
        end_time,
        stream_begin_time,
        stream_end_time,
        video_length,
        alarm_id,
        alarm_time,
        alarm_type,
        alarm_type_name,
        record_index_code,
        url,
        cover_url
        )
        values
        <foreach collection="list" item="item" separator="," index="index">
            (
            #{item.orginVideoId},
            #{item.vehicleIndexCode},
            #{item.plateNo},
            #{item.vehicleSelfNo},
            #{item.regionIndexCode},
            #{item.regionName},
            #{item.cameraIndexCode},
            #{item.cameraName},
            #{item.serviceIndexCode},
            #{item.beginTime},
            #{item.endTime},
            #{item.streamBeginTime},
            #{item.streamEndTime},
            #{item.videoLength},
            #{item.alarmId},
            #{item.alarmTime},
            #{item.alarmType},
            #{item.alarmTypeName},
            #{item.recordIndexCode},
            #{item.url},
            #{item.coverUrl}
            )
        </foreach>
    </insert>
</mapper>
