import request from '@/utils/request'

// 查询公司级培训列表
export function listCompanylevel(query) {
  return request({
    url: '/training/companylevel/list',
    method: 'get',
    params: query
  })
}

export function updateScore(query) {
  return request({
    url: '/training/companylevel/updateScore',
    method: 'get',
    params: query
  })
}
// 查询公司级培训详细
export function getCompanylevel(id) {
  return request({
    url: '/training/companylevel/' + id,
    method: 'get'
  })
}

// 新增公司级培训
export function addCompanylevel(data) {
  return request({
    url: '/training/companylevel',
    method: 'post',
    data: data
  })
}

// 修改公司级培训
export function updateCompanylevel(data) {
  return request({
    url: '/training/companylevel',
    method: 'put',
    data: data
  })
}

// 重置公司级培训
export function resetCompanylevel() {
  return request({
    url: '/training/companylevel/resetAll',
    method: 'delete',
  })
}

// 删除公司级培训
export function delCompanylevel(id) {
  return request({
    url: '/training/companylevel/' + id,
    method: 'delete'
  })
}

// 导出公司级培训
export function exportCompanylevel(query) {
  return request({
    url: '/training/companylevel/export',
    method: 'get',
    params: query
  })
}
