浏览代码

取消订单 检查是否支付

yuhongqi 3 天之前
父节点
当前提交
0864264dbc
共有 1 个文件被更改,包括 6 次插入1 次删除
  1. 6 1
      fs-service/src/main/java/com/fs/course/mapper/FsCourseWatchLogMapper.java

+ 6 - 1
fs-service/src/main/java/com/fs/course/mapper/FsCourseWatchLogMapper.java

@@ -761,7 +761,12 @@ public interface FsCourseWatchLogMapper extends BaseMapper<FsCourseWatchLog> {
 
     List<FsSopMyCourseH5LinkVO> getSopCourseH5StudyListByQwExId(@Param("qwExternalId") Long qwExternalId);
 
-    @Select("select * from fs_course_watch_log where user_id=#{param.fsUserId} and company_user_id=#{param.companyUserId} and course_id=#{param.courseId} and video_id=#{param.videoId} and project=#{param.projectId} and period_id=#{param.periodId} limit 1")
+    @Select("<script>" +
+            "select * from fs_course_watch_log where user_id=#{param.fsUserId} and company_user_id=#{param.companyUserId} and course_id=#{param.courseId} and video_id=#{param.videoId} " +
+            "<if test='param.projectId != null'>and project=#{param.projectId} </if>" +
+            "<if test='param.periodId != null'>and period_id=#{param.periodId} </if>" +
+            "limit 1" +
+            "</script>")
     FsCourseWatchLog selectFsCourseWatchLogWithUCCV(@Param("param") FsUserCourseVideoRemainTimeParam param);
 
     /**