import request from '@/utils/request'

// 查询入库通知单明细历史表列表
export function listRkWareNoticeTabBak(query) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/list',
    method: 'get',
    params: query
  })
}



//首页查询
export function listRkWareNoticeTabBaks(query) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/syList',
    method: 'get',
    params: query
  })
}

export function listTotal(query) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/listTotal',
    method: 'get',
    params: query
  })
}

// 查询入库通知单明细历史表详细
export function getRkWareNoticeTabBak(id) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/' + id,
    method: 'get'
  })
}

// 新增入库通知单明细历史表
export function addRkWareNoticeTabBak(data) {
  return request({
    url: '/system/rkXnWareNoticeTabBak',
    method: 'post',
    data: data
  })
}

// 修改入库通知单明细历史表
export function updateRkWareNoticeTabBak(data) {
  return request({
    url: '/system/rkXnWareNoticeTabBak',
    method: 'put',
    data: data
  })
}

// 删除入库通知单明细历史表
export function delRkWareNoticeTabBak(id) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/' + id,
    method: 'delete'
  })
}
// 启用
export function enabled(id) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/enable/' + id,
    method: 'delete'
  })
}

// 禁用
export function disabled(id) {
  return request({
    url: '/system/rkXnWareNoticeTabBak/disable/' + id,
    method: 'delete'
  })
}

// 状态修改
export function changeStatus(id, status) {
  const data = {
    id,
    status
  }
  return request({
    url: '/system/rkXnWareNoticeTabBak/changeStatus',
    method: 'put',
    data: data
  })
}
