import request from '@/utils/request'
import qs from 'qs'

export function getList(query, current = 1, size = 20) {
  return request({
    url: `/article/category/search`,
    method: 'post',
    data: qs.stringify({
      query,
      current,
      size
    })
  })
}

export function uploadFile(file) {
  var form = new FormData()
  form.append('file', file)
  return request({
    url: `/article/category/search`,
    // headers: { 'Content-Type': 'multipart/form-data' },
    method: 'post',
    data: form
  })
}
