Bläddra i källkod

保利威同步

change 3 år sedan
förälder
incheckning
13dd102257

+ 3 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/goods/vo/GoodsUserVo.java

@@ -261,4 +261,7 @@ public class GoodsUserVo {
 
 	@ApiModelProperty("课程数量")
 	private Long courseNum;
+
+	@ApiModelProperty("是否确认重修 1已经确认  0未确认")
+	private Long rebuildStatus;
 }

+ 2 - 0
zhongzheng-system/src/main/resources/mapper/modules/course/CourseMapper.xml

@@ -148,6 +148,7 @@
         <result property="goodsPlayConfig" column="goods_play_config"/>
         <result property="goodsExamConfig" column="goods_exam_config"/>
         <result property="gradeId" column="grade_id"/>
+        <result property="rebuildStatus" column="rebuild_status"/>
 
         <result property="supplyName" column="supply_name"/>
         <result property="educationName" column="education_name"/>
@@ -410,6 +411,7 @@
         (SELECT cet.project_name FROM  course_project_type cet where cet.id = g.project_id) as project_name,
         (SELECT cet.business_name FROM  course_business cet  where cet.id = g.business_id) as business_name,
         (SELECT COUNT(1) FROM goods_course gc where gc.goods_id = g.goods_id) as course_num,
+        (case WHEN (SELECT COUNT(1) FROM user_period up LEFT JOIN user_period_status ups on up.id = ups.period_id where up.goods_id = g.goods_id AND ups.period_status =1 and ups.`status` =0) >0 then 0 ELSE 1 end) as rebuild_status,
         (case WHEN (SELECT COUNT(1) FROM exam_apply_goods eag LEFT JOIN exam_apply ea on eag.apply_id = ea.apply_id where eag.goods_id = g.goods_id and ea.`status` = 1 and unix_timestamp(now()) BETWEEN ea.apply_start_time and ea.apply_end_time) >0 then 1 ELSE 0 end) as apply_status,
         (case WHEN (SELECT COUNT(1) FROM exam_before_goods ebg LEFT JOIN exam_before eb on ebg.before_id = eb.before_id where ebg.goods_id = g.goods_id and eb.`status` = 1 and unix_timestamp(now()) BETWEEN eb.before_start_time and eb.before_end_time) >0 then 1 ELSE 0 end) as before_status,
         (SELECT ea.apply_name FROM exam_apply_goods eag LEFT JOIN exam_apply ea on eag.apply_id = ea.apply_id where eag.goods_id = g.goods_id and ea.`status` = 1 and unix_timestamp(now()) BETWEEN ea.apply_start_time and ea.apply_end_time) as apply_name,