|
@@ -29,6 +29,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="educationName" column="education_name"/>
|
|
|
<result property="projectName" column="project_name"/>
|
|
|
<result property="businessName" column="business_name"/>
|
|
|
+ <result property="cancelPeople" column="cancel_people"/>
|
|
|
+ <result property="people" column="people"/>
|
|
|
</resultMap>
|
|
|
|
|
|
<resultMap type="com.zhongzheng.modules.exam.vo.ExamNumberGoodsVo" id="ExamNumberGoodsVoResult">
|
|
@@ -143,4 +145,23 @@ and (SELECT COUNT(eay.apply_id) FROM exam_apply eay LEFT JOIN exam_apply_goods e
|
|
|
where 1=1
|
|
|
and ea.apply_id = #{applyId}
|
|
|
</select>
|
|
|
+
|
|
|
+ <select id="queryExam" parameterType="com.zhongzheng.modules.exam.bo.ExamApplyQueryBo" resultMap="ExamApplyVo">
|
|
|
+ SELECT
|
|
|
+ * ,
|
|
|
+ (select cet.education_name FROM course_education_type cet where ea.education_type_id= cet.id) as education_name,
|
|
|
+ (select cpt.project_name FROM course_project_type cpt where ea.project_id= cpt.id) as project_name,
|
|
|
+ (select cb.business_name FROM course_business cb where ea.business_id= cb.id) as business_name,
|
|
|
+ (SELECT COUNT(us.apply_id) FROM user_subscribe us where us.apply_id = ea.apply_id and us.subscribe_status = 1) as people,
|
|
|
+ (SELECT COUNT(us.apply_id) FROM user_subscribe us where us.apply_id = ea.apply_id and us.subscribe_status = 2) as cancel_people
|
|
|
+ FROM
|
|
|
+ exam_apply ea
|
|
|
+ where 1=1
|
|
|
+ <if test="status != null and status.size()!=0 ">
|
|
|
+ AND ea.status in
|
|
|
+ <foreach collection="status" item="item" index="index" open="(" close=")" separator=",">
|
|
|
+ #{item}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
+ </select>
|
|
|
</mapper>
|