BAOLH
2026-10-26 8d4c799953eefe40067fbdd8a3aa06fda2810dcc
1
2
3
4
5
6
7
8
9
10
11
import axios from 'axios'
import { getToken } from '@/utils/auth'
 
export function upload(api, file) {
  var data = new FormData()
  data.append('file', file)
  const config = {
    headers: { 'Authorization': getToken() }
  }
  return axios.post(api, data, config)
}