|
|
@@ -10,6 +10,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="buildType" column="build_type" />
|
|
|
<result property="subjectId" column="subject_id" />
|
|
|
<result property="examType" column="exam_type" />
|
|
|
+ <result property="teacherId" column="teacher_id" />
|
|
|
<result property="universityId" column="university_id" />
|
|
|
<result property="directKey" column="direct_key" />
|
|
|
<result property="paperId" column="paper_id" />
|
|
|
@@ -19,7 +20,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectLearnTestPaperVo">
|
|
|
- select id, batch_id, build_type, subject_id, exam_type, university_id, direct_key, paper_id, conditions, creator_id, create_time from learn_test_paper
|
|
|
+ select id, batch_id, build_type, subject_id, exam_type, teacher_id, university_id, direct_key, paper_id, conditions, creator_id, create_time from learn_test_paper
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectLearnTestPaperList" parameterType="LearnTestPaper" resultMap="LearnTestPaperResult">
|
|
|
@@ -29,6 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="buildType != null "> and build_type = #{buildType}</if>
|
|
|
<if test="subjectId != null "> and subject_id = #{subjectId}</if>
|
|
|
<if test="examType != null "> and exam_type = #{examType}</if>
|
|
|
+ <if test="teacherId != null "> and teacher_id = #{teacherId}</if>
|
|
|
<if test="universityId != null "> and university_id = #{universityId}</if>
|
|
|
<if test="directKey != null and directKey != ''"> and direct_key = #{directKey}</if>
|
|
|
<if test="paperId != null "> and paper_id = #{paperId}</if>
|
|
|
@@ -40,6 +42,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<select id="selectByBatchAndUniversityIds" resultMap="LearnTestPaperResult">
|
|
|
<include refid="selectLearnTestPaperVo"/>
|
|
|
<where> batch_id = #{batchId} and build_type = #{buildType} and subject_id = #{subjectId}
|
|
|
+ <if test="null != teacherId">and teacher_id = #{teacherId}</if>
|
|
|
<if test="null != universityIds">and university_id in <foreach item="id" collection="universityIds" open="(" separator="," close=")">#{id}</foreach></if>
|
|
|
</where>
|
|
|
</select>
|
|
|
@@ -56,6 +59,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="buildType != null">build_type,</if>
|
|
|
<if test="subjectId != null">subject_id,</if>
|
|
|
<if test="examType != null">exam_type,</if>
|
|
|
+ <if test="teacherId != null">teacher_id,</if>
|
|
|
<if test="universityId != null">university_id,</if>
|
|
|
<if test="directKey != null ">direct_key,</if>
|
|
|
<if test="paperId != null">paper_id,</if>
|
|
|
@@ -68,6 +72,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="buildType != null">#{buildType},</if>
|
|
|
<if test="subjectId != null">#{subjectId},</if>
|
|
|
<if test="examType != null">#{examType},</if>
|
|
|
+ <if test="teacherId != null">#{teacherId},</if>
|
|
|
<if test="universityId != null">#{universityId},</if>
|
|
|
<if test="directKey != null">#{directKey},</if>
|
|
|
<if test="paperId != null">#{paperId},</if>
|
|
|
@@ -84,6 +89,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="buildType != null">build_type = #{buildType},</if>
|
|
|
<if test="subjectId != null">subject_id = #{subjectId},</if>
|
|
|
<if test="examType != null">exam_type = #{examType},</if>
|
|
|
+ <if test="teacherId != null">teacher_id = #{teacherId},</if>
|
|
|
<if test="universityId != null">university_id = #{universityId},</if>
|
|
|
<if test="directKey != null">direct_key = #{directKey},</if>
|
|
|
<if test="paperId != null">paper_id = #{paperId},</if>
|