“djh”
3 天以前 9bc1958825de5c9427659a8824a9e86864c2a457
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
package com.gkhy.exam.system.mapper;
 
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.gkhy.exam.system.domain.ExCourseChapter;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
 
import java.util.List;
 
/**
 * <p>
 * 课程章节表 Mapper 接口
 * </p>
 *
 * @author kzy
 * @since 2024-06-05 15:07:36
 */
@Mapper
public interface ExCourseChapterMapper extends BaseMapper<ExCourseChapter> {
    /**
     * 根据条件分页查询课程章节
     * @param chapter
     * @return
     */
    List<ExCourseChapter> selectChapterList(ExCourseChapter chapter);
 
    /**
     * 根据id获取章节信息
     * @param chapterId
     * @return
     */
    ExCourseChapter selectChapterById(Long chapterId);
 
    /**
     * 校验章节名称是否唯一
     * @param name
     * @param courseId
     * @return
     */
    ExCourseChapter checkNameUnique(@Param("name") String name, @Param("courseId")Long courseId);
 
    /**
     * 根据课程id查询章节列表
     * @param courseId
     * @return
     */
    List<ExCourseChapter> selectChapterByCourseId(Long courseId,Integer status);
 
    /**
     * 根据课程id查询章节数量
     * @param courseId
     * @return
     */
    Integer selectCountByCourseId(Long courseId);
 
    /**
     * 查看章节下绑定的课时信息数量
     * @param chapterId
     * @return
     */
    int selectPeriodCountById(Long chapterId);
}