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);
|
|
/**
|
* 根据课程id查询章节数量
|
* @param courseId
|
* @return
|
*/
|
Integer selectCountByCourseId(Long courseId);
|
|
/**
|
* 查看章节下绑定的课时信息数量
|
* @param chapterId
|
* @return
|
*/
|
int selectPeriodCountById(Long chapterId);
|
}
|