package com.yida.data.school.exam.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yida.data.common.core.entity.CurrentUser;
import com.yida.data.common.core.entity.exam.CoreExamination;
import com.yida.data.school.vo.exam.ExamVO;

import java.util.List;

public interface CoreExaminationService extends IService<CoreExamination> {

    /**
     * 考试分页查询
     *
     * @param coreExamination
     * @param
     * @return
     */
    IPage<CoreExamination> findExaminationPageList(CoreExamination coreExamination, CurrentUser currentUser);

    /**
     * 保存考试信息
     */
    void saveExamination(CoreExamination coreExamination, CurrentUser currentUser);

    /**
     * 根据考试id查询考试详细信息
     */
    CoreExamination findExamination(Integer examinationId);

    /**
     * 根据考试主键id查询考试学科数
     */
    Integer countExaminationCourseByExaminationId(Integer examinationId);

    /**
     * 根据考试主键id查询考试班级数
     */
    Integer countExaminationClassByExaminationId(Integer examinationId);

    /**
     * 根据考试主键id查询考试学生数
     */
    Integer countExaminationStudentByExaminationId(Integer examinationId);

    /**
     * 查询学生列表数据
     *
     * @param schoolId
     * @param studentId
     * @return
     */
    List findHistoryExamination(Long schoolId, Long studentId);

    /**
     * 家长查询考试列表数据
     *
     * @param examName
     * @param studentId
     * @return
     */
    List<ExamVO> findHistoryExaminationList(String examName, Long studentId);

    /**
     * 删除考试
     *
     * @param ids
     */
    void delExamBatch(Long[] ids);
}
