BAOLH
2026-11-10 c5dfc09145e4e10f99dbf388a4a1433b5c2973e5
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)
}