<?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.xhkjedu.sstudy.mapper.question.QuestionDirectorMapper">
    <!--删除试题关联章节信息-->
    <delete id="deleteByQuestionId">
        delete from t_question_director where questionid=#{questionid}
    </delete>
    <!--批量添加-->
    <insert id="batchSave" parameterType="com.xhkjedu.sstudy.model.question.TQuestionDirector">
        INSERT INTO t_question_director (qdid,questionid,lsbid,directorid,createid,createtime)
        VALUES
        <foreach collection ="list" item="d" index= "index" separator =",">
            (#{d.qdid},#{d.questionid},#{d.lsbid},#{d.directorid},#{d.createid},#{d.createtime})
        </foreach>
    </insert>
</mapper>
