he2802 vor 3 Jahren
Ursprung
Commit
2c0a017a34

+ 1 - 1
zhongzheng-system/src/main/java/com/zhongzheng/modules/course/service/impl/CourseSectionServiceImpl.java

@@ -213,7 +213,7 @@ public class CourseSectionServiceImpl extends ServiceImpl<CourseSectionMapper, C
                 }
             }else{
                 if(this.baseMapper.checkCrossLiveTime(entity.getLiveStartTime(),entity.getLiveEndTime(),null,entity.getLiveUrl())>0){
-                    throw new CustomException("存在开播时间同房间号的直播节");
+                    throw new CustomException("存在开播时间同频道号的直播节");
                 }
             }
         }

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

@@ -239,9 +239,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
     <select id="checkCrossLiveTime" parameterType="map" resultType="long">
-        SELECT count(*) from course_section cs where  (#{startTime} >= cs.live_start_time and cs.live_end_time >= #{startTime})
+        SELECT count(*) from course_section cs where  ((#{startTime} >= cs.live_start_time and cs.live_end_time >= #{startTime})
                                                   or (cs.live_end_time >= #{endTime} and #{endTime} >= cs.live_start_time) or (cs.live_start_time >= #{startTime} and
-                                                                                                                            #{endTime} >= cs.live_end_time)
+                                                                                                                            #{endTime} >= cs.live_end_time))
         <if test="sectionId != null and sectionId != ''">
             AND cs.section_id != #{sectionId}
         </if>

+ 2 - 2
zhongzheng-system/src/main/resources/mapper/modules/exam/ExamBeforeApplyMapper.xml

@@ -38,8 +38,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                 LEFT JOIN exam_apply ea ON eba.apply_id = ea.apply_id
         WHERE
               1=1
-        <if test="beforeId != null and beforeId != '' and beforeId != -1">
-            eba.before_id = #{beforeId}
+        <if test="beforeId != null and beforeId >0 ">
+            AND eba.before_id = #{beforeId}
         </if>
     </select>
 </mapper>