|
@@ -36,8 +36,25 @@
|
|
|
<result property="code" column="code"/>
|
|
|
<collection property="businessList" column="question_id" select="findBusinessList" />
|
|
|
<collection property="knowledgeList" column="knowledge_ids" select="findKnowledge"/>
|
|
|
+ <collection property="examList" column="question_id" select="findExamList" />
|
|
|
</resultMap>
|
|
|
|
|
|
+ <resultMap type="com.zhongzheng.modules.bank.vo.ExamVo" id="ExamVoResult">
|
|
|
+ <result property="examId" column="exam_id"/>
|
|
|
+ <result property="examName" column="exam_name"/>
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <select id="findExamList" resultMap="ExamVoResult">
|
|
|
+ SELECT
|
|
|
+ e.exam_id,
|
|
|
+ e.exam_name
|
|
|
+ FROM
|
|
|
+ exam_question eq
|
|
|
+ LEFT JOIN exam e ON eq.exam_id = e.exam_id
|
|
|
+ WHERE
|
|
|
+ eq.question_id = #{question_id} AND e.status !=-1
|
|
|
+ </select>
|
|
|
+
|
|
|
<select id="findKnowledge" resultMap="ExamKnowledge">
|
|
|
SELECT
|
|
|
ek.knowledge_name,
|