<?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.casic.missiles.mapper.meter.MeterTrainStaffMapper">

    <update id="updateForStaff">
        <foreach collection="trainStaffList" item="item" separator=";">
            UPDATE meter_train_staff
            SET exam_result = #{item.examResult}
            WHERE staff_id = #{item.staffId} AND plan_id = #{item.planId}
        </foreach>
    </update>

    <update id="updateStaffForSignIn">
        UPDATE meter_train_staff
        SET sign_time = NOW()
        WHERE staff_id = #{request.staffId} AND plan_id = #{request.planId}
    </update>
</mapper>
