|
@@ -23,5 +23,61 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<result property="sort" column="sort"/>
|
|
<result property="sort" column="sort"/>
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
|
|
+ <resultMap type="com.zhongzheng.modules.bank.vo.ExamVo" id="ExamVoResult">
|
|
|
|
+ <result property="examId" column="exam_id"/>
|
|
|
|
+ <result property="status" column="status"/>
|
|
|
|
+ <result property="createTime" column="create_time"/>
|
|
|
|
+ <result property="updateTime" column="update_time"/>
|
|
|
|
+ <result property="prefixName" column="prefix_name"/>
|
|
|
|
+ <result property="code" column="code"/>
|
|
|
|
+ <result property="examName" column="exam_name"/>
|
|
|
|
+ <result property="publishStatus" column="publish_status"/>
|
|
|
|
+ <result property="year" column="year"/>
|
|
|
|
+ <result property="cityId" column="city_id"/>
|
|
|
|
+ <result property="provinceId" column="province_id"/>
|
|
|
|
+ <result property="examPaperId" column="exam_paper_id"/>
|
|
|
|
+ <result property="answerTime" column="answer_time"/>
|
|
|
|
+ <result property="examPaperId" column="exam_paper_id"/>
|
|
|
|
+ <result property="answerNum" column="answer_num"/>
|
|
|
|
+ <result property="sort" column="sort"/>
|
|
|
|
+ <result property="educationName" column="education_name"/>
|
|
|
|
+ <result property="projectName" column="project_name"/>
|
|
|
|
+ <result property="businessName" column="business_name"/>
|
|
|
|
+ <result property="educationTypeId" column="education_type_id"/>
|
|
|
|
+ <result property="businessId" column="business_id"/>
|
|
|
|
+ <result property="subjectId" column="subject_id"/>
|
|
|
|
+ <result property="projectId" column="project_id"/>
|
|
|
|
+ <result property="subjectName" column="subject_name"/>
|
|
|
|
+ </resultMap>
|
|
|
|
|
|
|
|
+ <select id="getList" parameterType="com.zhongzheng.modules.bank.bo.ExamQueryBo" resultMap="ExamVoResult">
|
|
|
|
+ SELECT
|
|
|
|
+ e.*,
|
|
|
|
+ qb.education_type_id,
|
|
|
|
+ qb.business_id,
|
|
|
|
+ qb.project_id,
|
|
|
|
+ qb.subject_id,
|
|
|
|
+ cet.education_name,
|
|
|
|
+ cpt.project_name,
|
|
|
|
+ cb.business_name,
|
|
|
|
+ cs.subject_name
|
|
|
|
+ FROM
|
|
|
|
+ exam e
|
|
|
|
+ LEFT JOIN question_business qb ON e.exam_id = qb.major_id
|
|
|
|
+ AND qb.type = 2
|
|
|
|
+ LEFT JOIN course_education_type cet ON qb.education_type_id = cet.id
|
|
|
|
+ LEFT JOIN course_project_type cpt ON qb.project_id = cpt.id
|
|
|
|
+ LEFT JOIN course_business cb ON qb.business_id = cb.id
|
|
|
|
+ LEFT JOIN course_subject cs ON cs.id = qb.subject_id
|
|
|
|
+ <if test="educationTypeId != null and educationTypeId != ''">
|
|
|
|
+ AND qb.education_type_id = #{educationTypeId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="subjectId != null and subjectId != ''">
|
|
|
|
+ AND qb.subject_id = #{subjectId}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="businessId != null and businessId != ''">
|
|
|
|
+ AND qb.business_id = #{businessId}
|
|
|
|
+ </if>
|
|
|
|
+ ORDER BY e.exam_id DESC
|
|
|
|
+ </select>
|
|
</mapper>
|
|
</mapper>
|