import request from '@/utils/request'

// 查询不分页通用附件列表
export function allFileList(query) {
  return request({
    url: '/rc/commonfile/allFileList',
    method: 'get',
    params: query
  })
}

// 查询通用附件列表
export function listCommonfile(query) {
  return request({
    url: '/rc/commonfile/list',
    method: 'get',
    params: query
  })
}

// 查询通用附件详细
export function getCommonfile(id) {
  return request({
    url: '/rc/commonfile/' + id,
    method: 'get'
  })
}

// 新增通用附件
export function addCommonfile(data) {
  return request({
    url: '/rc/commonfile',
    method: 'post',
    data: data
  })
}

// 修改通用附件
export function updateCommonfile(data) {
  return request({
    url: '/rc/commonfile',
    method: 'put',
    data: data
  })
}

// 删除通用附件
export function delCommonfile(id) {
  return request({
    url: '/rc/commonfile/' + id,
    method: 'delete'
  })
}
