import { httpApp } from "@/plugins/axiosApp";
import { StudentObjectiveInfo } from "@/types";

/** 获取学生客观题数据 */
export async function studentObjectiveConfirmData(studentId) {
  return httpApp.post<StudentObjectiveInfo>(
    "/api/admin/mark/inspected/objective/getTask",
    {},
    { params: { studentId } }
  );
}
/** 保存考生客观题数据 */
export async function saveStudentObjectiveConfirmData({ studentId, answers }) {
  return httpApp.post<StudentObjectiveInfo>(
    "/api/admin/mark/inspected/objective/saveTask",
    {},
    { params: { studentId, answers } }
  );
}

/** 获取学生客观题数据 */
export async function studentSubjectiveConfirmData(studentId) {
  return httpApp.post<StudentSubjectiveInfo>(
    "/api/admin/mark/inspected/subjective/getTask",
    {},
    { params: { studentId } }
  );
}
/** 保存考生客观题数据 */
export async function saveStudentSubjectiveConfirmData(data) {
  return httpApp.post<StudentSubjectiveInfo>(
    "/api/admin/mark/inspected/subjective/saveTask",
    data
  );
}
