上传问题,未解决

This commit is contained in:
gyj
2024-04-19 18:15:23 +08:00
parent 38ac830a62
commit 197677e3c2
14 changed files with 144 additions and 58 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ const server = axios.create({
server.interceptors.request.use(config => {
// config包含了请求相关的所有信息
// 可以同过config对象给请求配置或者修改信息
config.headers.Authorization = sessionStorage.getItem('token');
config.headers.Authorization ="Bearer " + sessionStorage.getItem('token');
return config // 将配置完成的token返回 如果不返回 请求不会继续进行
}, err => {
// 请求发生错误时的回调函数