he2802 2 years ago
parent
commit
e2a8a7067d

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

@@ -228,7 +228,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
           and up.chapter_id=#{chapterId}
           and up.section_id=#{typeId}
           and up.course_id=#{courseId}
-            <if test="examId != null ">
+            <if test="examId != null and examId > 0">
                 and up.exam_id=#{examId}
                 and up.`type` = 2
             </if>
@@ -250,7 +250,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
           and up.chapter_id=#{chapterId}
           and up.course_id=#{courseId}
           and up.section_id=#{typeId}
-            <if test="examId != null ">
+            <if test="examId != null and examId > 0">
                 and up.exam_id=#{examId}
                 and up.`type` = 2
             </if>