import request from '@/utils/request'

// 08 学生单次测评排名-按班级排名学生
export function getClassExaminees(params) {
  return request({
    url: '/front/evaluation/getClassExaminees',
    method: 'get',
    params: params
  })
}
// 04 学生测试列表
export function getEvaluationForStudent(params) {
  return request({
    url: '/front/evaluation/getEvaluationForStudent',
    method: 'get',
    params: params
  })
}
// 09 班级测评历史
export function getClassHistory(params) {
  return request({
    url: '/front/evaluation/getClassHistory',
    method: 'get',
    params: params
  })
}
// 05 测评班级统计
export function getClassStat(params) {
  return request({
    url: '/front/evaluation/getClassStat',
    method: 'get',
    params: params
  })
}
// 05.0 测评题目分类
export function getEvaluationQuestionTypes(evaluationClassId) {
  return request({
    url: '/front/evaluation/getEvaluationQuestionTypes',
    method: 'get',
    params: {evaluationClassId: evaluationClassId}
  })
}
//02 测评班级列表
export function getEvaluationClassForStat(params) {
  return request({
    url: '/front/evaluation/getEvaluationClassForStat',
    method: 'get',
    params: params
  })
}
// 03 统计测评列表
export function getEvaluationForStat(params) {
  return request({
    url: '/front/evaluation/getEvaluationForStat',
    method: 'get',
    params: params
  })
}
export function getEvaluationListForStat(params) {
  return request({
    url: '/front/evaluation/getEvaluationListForStat',
    method: 'get',
    params: params
  })
}
// 03 测试测评列表
export function getEvaluationForTest(params) {
  return request({
    url: '/front/evaluation/getEvaluationForTest',
    method: 'get',
    params: params
  })
}
// 06 学生考卷详情
export function getExamineeQuestions(params) {
  return request({
    url: '/front/evaluation/getExamineeQuestions',
    method: 'get',
    params: params
  })
}
// 06 考卷学生详情
export function getExaminee(params) {
  return request({
    url: '/front/evaluation/getExaminee',
    method: 'get',
    params: params
  })
}
// 01 统计热门测评列表
export function getHotEvaluationForStat(params) {
  return request({
    url: '/front/evaluation/getHotEvaluationForStat',
    method: 'get',
    params: params
  })
}
//01 测试热门测评列表
export function getHotEvaluationForTest(params) {
  return request({
    url: '/front/evaluation/getHotEvaluationForTest',
    method: 'get',
    params: params
  })
}
// 07 学生测评历史
export function getStudentHistory(params) {
  return request({
    url: '/front/evaluation/getStudentHistory',
    method: 'get',
    params: params
  })
}
// 20 错题管理-班级知识点统计
export function getClassKnownledgeStats(params) {
  return request({
    url: '/front/wrong/getClassKnownledgeStats',
    method: 'get',
    params: params
  })
}
// 21 错题管理-班级学生统计
export function getClassStudentStats(params) {
  return request({
    url: '/front/wrong/getClassStudentStats',
    method: 'get',
    params: params
  })
}
// 22 错题管理-班级错题列表
export function getClassStudentQuestions(params) {
  return request({
    url: '/front/wrong/getClassStudentQuestions',
    method: 'get',
    params: params
  })
}
// 10 错题管理-学生知识点统计 front/wrong/getStudentKnownledgeStats
export function getStudentKnownledgeStats(params) {
  return request({
    url: '/front/wrong/getStudentKnownledgeStats',
    method: 'get',
    params: params
  })
}
// 11 错题管理-学生错题列表 front/wrong/getStudentDetails
export function getStudentDetails(params) {
  return request({
    url: '/front/wrong/getStudentDetails',
    method: 'get',
    params: params
  })
}
//  预览试卷
export function previewEvaluationForTeacher(params) {
  return request({
    url: '/front/teacher/previewEvaluationForTeacher',
    method: 'get',
    params: params
  })
}
//  01 查找测评
export function getEvaluationsForOpen(params) {
  return request({
    url: '/front/teacher/getEvaluationsForOpen',
    method: 'get',
    params: params
  })
}
//  02 开启测评
export function open(data) {
  return request({
    url: '/front/teacher/open',
    method: 'post',
    data: data
  })
}
//30 打开错题
export function openWrongQuestion(params) {
  return request({
    url: '/front/wrong/openWrongQuestion',
    method: 'get',
    params: params
  })
}
export function openQuestion(params) {
  return request({
    url: '/front/examination/openQuestion',
    method: 'get',
    params: params
  })
}
// 30 举一反三取新题
export function openWrongSimilarQuestion(params) {
  return request({
    url: '/front/wrong/openWrongSimilarQuestion',
    method: 'get',
    params: params
  })
}
//31 提交错题答案
export function commitWrongQuestion(params) {
  return request({
    url: '/front/wrong/commitWrongQuestion',
    method: 'post',
    data: params
  })
}
//32 scoreWrongQuestion 阅卷打分
export function scoreWrongQuestion(params) {
  return request({
    url: '/front/wrong/scoreWrongQuestion',
    method: 'post',
    data: params
  })
}
// 收藏
export function uploadGeneratePicAndBindQuestion(params) {
  return request({
    url: '/front/questionCollection/uploadGeneratePicAndBindQuestion',
    method: 'post',
    data: params
  })
}
// 取消收藏
export function cancelQuestionCollection(params) {
  return request({
    url: '/front/questionCollection/cancelQuestionCollection',
    method: 'DELETE',
    params: params
  })
}
// 纠错
export function correctQuestion(params) {
  return request({
    url: '/front/adjustWrong/correctQuestion',
    method: 'post',
    data: params
  })
}

export function correctQuestion2(params) {
  return request({
    url: '/front/adjustWrong/correctQuestion2',
    method: 'post',
    data: params
  })
}

// 开启测评
export function openExamination(params) {
  return request({
    url: '/front/teacher/openExamination',
    method: 'post',
    data: params
  })
}

// 测评班级人员
export  function getEvaluationStudents(params) {
  return request({
    url: '/front/teacher/getEvaluationStudents',
    method: 'get',
    params: params
  })
}

// 发布成绩
export function publishScores(params) {
  return request({
    url: '/front/teacher/publishScores',
    method: 'post',
    params: params
  })
}

//01 测评单次排名(统计)
export function getEvaluationKnownledge(params) {
  return request({
    url: '/front/wrong/getEvaluationKnownledge',
    method: 'get',
    params: params
  })
}

//02 测评单次排名(明细)
export function getEvaluationStudent(params) {
  return request({
    url: '/front/wrong/getEvaluationStudent',
    method: 'get',
    params: params
  })
}


// 根据token获取用户年级班级学生数据
export function getClassStudents(params) {
  return request({
    url: '/front/teacher/myClassTree',
    method: 'get',
    params: params
  })
}

