import request from '@/utils/request'

// 查询维修人员-人员列表
export function listUser(query) {
  return request({
    url: '/business/user/list',
    method: 'get',
    params: query
  })
}

// 查询维修人员-人员详细
export function getUser(id) {
  return request({
    url: '/business/user/' + id,
    method: 'get'
  })
}

// 新增维修人员-人员
export function addUser(data) {
  return request({
    url: '/business/user',
    method: 'post',
    data: data
  })
}

// 修改维修人员-人员
export function updateUser(data) {
  return request({
    url: '/business/user',
    method: 'put',
    data: data
  })
}

// 删除维修人员-人员
export function delUser(id) {
  return request({
    url: '/business/user/' + id,
    method: 'delete'
  })
}

// 查询人员工号
export function getUserCode(id) {
  return request({
    url: '/business/user/getUserCode/' + id,
    method: 'get'
  })
}