import axios from '../utils/request'
// 修改密码
export const updatePwd = (data) => {
  return axios({
    method: 'post',
    url: '/sys/user/updatePwd',
    data
  })
}
// 获取用户列表
export const getUserList = (data) => {
  return axios({
    method: 'post',
    url: '/sys/user/list',
    data
  })
}
// 新增、修改用户
export const userSave = (data) => {
  return axios({
    method: 'post',
    url: '/sys/user/save',
    data
  })
}
// 根据id获取用户详情
export const getUserDetailById = (id) => {
  return axios({
    url: `/sys/user/detail/${id}`
  })
}
// 根据id删除用户
export const delUserById = (id) => {
  return axios({
    url: `/sys/user/removes/${id}`
  })
}
// 重置密码
export const resetPass = (id) => {
  return axios({
    url: `/sys/user/resetPass/${id}`
  })
}
// 获取日志列表
export const getLogList = (data) => {
  return axios({
    method: 'post',
    url: '/sys/log/list',
    data
  })
}
