he2802 2 年之前
父节点
当前提交
48d411ec65
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      zhongzheng-system/src/main/resources/mapper/modules/user/UserStudyRecordMapper.xml

+ 1 - 1
zhongzheng-system/src/main/resources/mapper/modules/user/UserStudyRecordMapper.xml

@@ -341,7 +341,7 @@
             and c.tenant_id=#{tenantId}
         </if>
         and c.user_id=#{userId} and c.status = 1 and c.goods_id = #{goodsId}) as record_num,
-        (SELECT count(*) from user_study_record usr where usr.user_id = #{userId} and usr.grade_id = #{gradeId} and usr.current_status = 1 and usr.course_id = r.course_id) as study_status,
+        (SELECT count(*) from user_study_record usr where usr.user_id = #{userId} and usr.grade_id = #{gradeId} and usr.order_goods_id = #{orderGoodsId} and usr.current_status = 1 and usr.course_id = r.course_id) as study_status,
         (SELECT IFNULL(SUM(cs.duration_time),0) from (select DISTINCT c.section_id,c.course_id FROM user_study_record c where 1=1
         and c.current_status=1
         <if test="gradeId != null and gradeId !=''">