import request from '@/utils/request'

import download from '@/plugins/download'
// 通用上传(单文件)
export function uploadFile(data) {
  return request({
    url: '/common/upload',
    method: 'post',
    data: data,
    timeout: 2000000
  })
}

// 通用上传(多文件)
export function uploadFiles(data) {
  return request({
    url: '/common/uploads',
    method: 'post',
    data: data,
    timeout: 2000000
  })
}

// 下载
export function downloadFiles(data) {
  download.resource(data);
}
