import axios from "axios"; import {getToken} from "@/utils/auth"; export function downloadFile(fileId) { return axios({ method: 'get', url: process.env.VUE_APP_BASE_API + '/system/file/download/' + fileId, headers: { token: 'Bearer ' + getToken() // 让每个请求携带自定义token 请根据实际情况自行修改 } }) }