he2802 3 лет назад
Родитель
Сommit
4a982eb51b

+ 4 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/bank/bo/ExamQueryBo.java

@@ -44,6 +44,10 @@ public class ExamQueryBo extends BaseEntity {
 	/** 前缀名称 */
 	@ApiModelProperty("前缀名称")
 	private String prefixName;
+
+	/** 前缀名称 */
+	@ApiModelProperty("试卷ID")
+	private Long examId;
 	/** 编码 */
 	@ApiModelProperty("编码")
 	private String code;

+ 4 - 2
zhongzheng-system/src/main/java/com/zhongzheng/modules/bank/service/impl/ExamServiceImpl.java

@@ -51,8 +51,10 @@ public class ExamServiceImpl extends ServiceImpl<ExamMapper, Exam> implements IE
 
     @Override
     public ExamVo queryById(Long examId){
-        Exam db = this.baseMapper.selectById(examId);
-        return BeanUtil.toBean(db, ExamVo.class);
+        ExamQueryBo examQueryBo = new ExamQueryBo();
+        examQueryBo.setExamId(examId);
+        ExamVo examVo = examMapper.getList(examQueryBo).get(0);
+        return examVo;
     }
 
     @Override

+ 3 - 0
zhongzheng-system/src/main/resources/mapper/modules/bank/ExamMapper.xml

@@ -96,6 +96,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="educationTypeId != null and educationTypeId != ''">
             AND cet.id = #{educationTypeId}
         </if>
+        <if test="examId != null and examId != ''">
+            AND e.exam_id = #{examId}
+        </if>
         <if test="subjectId != null and subjectId != ''">
             AND cs.id = #{subjectId}
         </if>

+ 5 - 1
zhongzheng-system/src/main/resources/mapper/modules/course/CourseModuleMapper.xml

@@ -90,13 +90,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         cm.*,
         count( ccs.section_id ) AS section_num,
         count( DISTINCT cc.chapter_id ) AS chapter_num,
-        COALESCE ( SUM( cs.duration_time ), 0 ) AS duration_time
+        COALESCE ( SUM( cs.duration_time ), 0 ) AS duration_time,
+        cmb.education_type_id,
+        cmb.subject_id,
+        cmb.business_id
         FROM
         course_module cm
         LEFT JOIN course_module_chapter cmc ON cm.module_id = cmc.module_id
         LEFT JOIN course_chapter cc ON cmc.chapter_id = cc.chapter_id
         LEFT JOIN course_chapter_section ccs ON cc.chapter_id = ccs.chapter_id
         LEFT JOIN course_section cs ON ccs.section_id = cs.section_id
+        LEFT JOIN course_module_business cmb ON cmb.module_id = cm.module_id
         WHERE
         cm.STATUS !=- 1
         GROUP BY