import request from '@/utils/request'

// 查询学员列表
export function listStudent(query) {
  return request({
    url: '/hezhi/student/list',
    method: 'get',
    params: query
  })
}

// 查询学员详细
export function getStudent(studentId) {
  return request({
    url: '/hezhi/student/' + studentId,
    method: 'get'
  })
}

// 查询学员详细
export function importTemplate() {
  return request({
    url: '/hezhi/student/importTemplate',
    method: 'post'
  })
}

// 新增学员
export function addStudent(data) {
  return request({
    url: '/hezhi/student',
    method: 'post',
    data: data
  })
}

// 修改学员
export function updateStudent(data) {
  return request({
    url: '/hezhi/student',
    method: 'put',
    data: data
  })
}

// 删除学员
export function delStudent(studentId) {
  return request({
    url: '/hezhi/student/' + studentId,
    method: 'delete'
  })
}
