package com.xhkjedu.sstudy.mapper.paper;

import com.xhkjedu.base.TkMapper;
import com.xhkjedu.sstudy.model.paper.TPaperQtypeQuestion;
import com.xhkjedu.sstudy.model.question.TQuestion;
import com.xhkjedu.sstudy.vo.paperreport.PaperRQuestionVo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

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

@Repository
public interface PaperQtypeQuestionMapper extends TkMapper<TPaperQtypeQuestion> {
    /**
     * 上传试卷按题型统计(只统计母题)
     * @Param [paperid]
     * @Author ywx
     * @Date 2020/6/6 17:26
     * @return java.util.List<java.util.Map<java.lang.String,java.lang.Object>>
     **/
    List<Map<String, Object>> paperTypeAnalyze(@Param("paperid") Integer paperid);

    /**
     * 上传试卷按难易度统计(只统计母题)
     * @Param [paperid]
     * @Author ywx
     * @Date 2020/6/6 17:28
     * @return java.util.List<java.util.Map<java.lang.String,java.lang.Object>>
     **/
    List<Map<String, Object>> complexityRateAnalyze(@Param("paperid") Integer paperid);

    /**
     * 上传试卷按知识点统计(只统计母题)
     * @Param [paperid]
     * @Author ywx
     * @Date 2020/6/6 17:29
     * @return java.util.List<java.util.Map<java.lang.String,java.lang.Object>>
     **/
    List<Map<String, Object>> pointRateAnalyze(@Param("paperid") Integer paperid);

    /**
     *功能描述  获取试卷中主观题数量
     * @author WN
     * @date 2020/9/5
     * @param  * @param paperid
     * @return java.lang.Integer
     */
    Integer getQuestionCountCtype(@Param("paperid") Integer paperid);

    //据试卷id获取试卷中所有试题（试题和分值）
    List<TPaperQtypeQuestion> listQuestionByPaperid(@Param("paperid") Integer paperid);

    //根据试卷id获取试卷中所有试题及详情
    List<TQuestion> listQuestionsDetilByPaperid(@Param("paperid") Integer paperid);

    //作业关联试题及处理题型
    List<PaperRQuestionVo> listPaperQuesitonsByPaperid(@Param("paperid") Integer paperid);
}
