package com.gkhy.exam.system.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.gkhy.exam.system.domain.ExPaperStudent; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import java.util.List; /** *

* 学员与考试题目关系表 Mapper 接口 *

* * @author kzy * @since 2024-06-06 13:53:17 */ @Mapper public interface ExPaperStudentMapper extends BaseMapper { /** * 根据id获取考卷下的学员 * @param paperStudentId * @return */ ExPaperStudent selectPaperStudentById(Long paperStudentId); /** * 根据id获取考卷下的学员,信息较少 * @param paperStudentId * @return */ ExPaperStudent selectSimplePaperStudentById(Long paperStudentId); /** * 分页查询考卷下分配的学员 * @param paperStudent * @return */ List selectPaperStudentList(ExPaperStudent paperStudent); /** * 批量插入 * @param paperStudents * @return */ int batchInsert(List paperStudents); /** * 统计考卷下学员数量 * @param paperId * @return */ int countByPaperId(Long paperId); /** * 查询数量 * @param paperId * @param studentId * @return */ Integer selectCountByPaperStudentId(@Param("paperId") Long paperId, @Param("studentId")Long studentId); /** * 根据试卷id和学员id查询试卷信息 * @param paperStudent * @return */ ExPaperStudent selectByPaperStudentId(ExPaperStudent paperStudent); /** * 根据学员id获取学员分配的考试列表 * @param studentId * @return */ List selectByStudentId(Long studentId); /** * 分页获取未完成考试学生列表 * @param startIndex * @param pageSize * @return */ List selectNoCompleteStudent(int startIndex,int pageSize); /** * 批量更新完成状态 * @param paperStudentIds * @param completed */ void batchUpdateComplete(@Param("paperStudentIds") List paperStudentIds,@Param("completed") Integer completed); }