package com.qmth.themis.business.dao;

import java.util.List;
import java.util.Map;

import com.qmth.themis.business.base.CustomBaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.qmth.themis.business.bean.admin.OpenExamCourseBean;
import com.qmth.themis.business.dto.response.TEExamCourseDto;
import com.qmth.themis.business.entity.TEExamCourse;

/**
 * @Description: 考试科目 Mapper 接口
 * @Param:
 * @return:
 * @Author: wangliang
 * @Date: 2020/6/25
 */
@Mapper
public interface TEExamCourseMapper extends CustomBaseMapper<TEExamCourse> {

    /**
     * 查询考试科目
     *
     * @param iPage
     * @param id
     * @param examId
     * @param courseCode
     * @param courseName
     * @param hasPaper
     * @return
     */
    public IPage<TEExamCourseDto> examCourseQuery(IPage<Map> iPage, @Param("id") Long id, @Param("examId") Long examId, @Param("courseCode") String courseCode, @Param("courseName") String courseName, @Param("hasPaper") Integer hasPaper);

    public TEExamCourse findByExamIdAndCourseCode(@Param("examId") Long examId, @Param("courseCode") String courseCode);

	public IPage<OpenExamCourseBean> examCourseQueryForOpen(IPage<OpenExamCourseBean> ipage,@Param("examId") Long examId, @Param("courseCode") String courseCode,@Param("hasPaper") Boolean hasPaper);

	public List<TEExamCourse> findByExamId(@Param("examId") Long examId);
}
