import request from '@/utils/request'

// 查询文件配置树
export function treeView(query) {
  return request({
    url: '/system/attachmentConfig/treeView',
    method: 'get',
    params: query
  })
}

// 查询文件配置树
export function treeSingleProcessView(query) {
  return request({
    url: '/system/attachmentConfig/treeSingleProcessView',
    method: 'get',
    params: query
  })
}

// 查询附件上传配置列表
export function listAttachmentConfig(query) {
  return request({
    url: '/system/attachmentConfig/list',
    method: 'get',
    params: query
  })
}

// 查询附件上传配置详细
export function getAttachmentConfig(id) {
  return request({
    url: '/system/attachmentConfig/' + id,
    method: 'get'
  })
}

// 新增附件上传配置
export function addAttachmentConfig(data) {
  return request({
    url: '/system/attachmentConfig/add',
    method: 'post',
    data: data
  })
}

// 修改附件上传配置
export function updateAttachmentConfig(data) {
  return request({
    url: '/system/attachmentConfig/edit',
    method: 'post',
    data: data
  })
}

// 删除附件上传配置
export function delAttachmentConfig(id) {
  return request({
    url: '/system/attachmentConfig/remove/' + id,
    method: 'get'
  })
}

// 导出附件上传配置
export function exportAttachmentConfig(query) {
  return request({
    url: '/system/attachmentConfig/export',
    method: 'get',
    params: query
  })
}

// 查询文件配置树
export function getAttachmentConfigTree(query) {
  return request({
    url: '/system/attachmentConfig/getAttachmentConfigTree',
    method: 'get',
    params: query
  })
}
