Commit a4299d94 by dqjdda

取消拼接token 前缀,由后端处理

parent 11d1a803
......@@ -15,7 +15,7 @@ const service = axios.create({
service.interceptors.request.use(
config => {
if (getToken()) {
config.headers['Authorization'] = 'Bearer ' + getToken() // 让每个请求携带自定义token 请根据实际情况自行修改
config.headers['Authorization'] = getToken() // 让每个请求携带自定义token 请根据实际情况自行修改
}
config.headers['Content-Type'] = 'application/json'
return config
......
......@@ -15,7 +15,7 @@ export default {
data() {
return {
headers: {
'Authorization': 'Bearer ' + getToken()
'Authorization': getToken()
},
editorContent:
`<h3 style="text-align: center;">欢迎使用 wangEditor 富文本编辑器!</h3>
......
......@@ -42,7 +42,7 @@ export default {
url: this.imagesUploadApi,
method: 'post',
data: formdata,
headers: { 'Content-Type': 'multipart/form-data', 'Authorization': 'Bearer ' + getToken() }
headers: { 'Content-Type': 'multipart/form-data', 'Authorization': getToken() }
}).then((data) => {
this.data = data.data
this.$refs.md.$img2Url(pos, this.data.data[0])
......
......@@ -38,7 +38,7 @@ export default {
apps: [],
servers: [],
headers: {
Authorization: 'Bearer ' + getToken()
Authorization: getToken()
},
deployInfo: {},
form: {
......
......@@ -99,7 +99,7 @@ export default {
Avatar: Avatar,
ico: 'el-icon-refresh',
headers: {
'Authorization': 'Bearer ' + getToken()
'Authorization': getToken()
}
}
},
......
......@@ -30,7 +30,7 @@ export default {
data() {
return {
headers: {
'Authorization': 'Bearer ' + getToken()
'Authorization': getToken()
},
loading: false, form: { subject: '', tos: [], content: '' },
tos: [{
......
......@@ -134,7 +134,7 @@ export default {
title: '图片',
crudMethod: { ...crudPic },
headers: {
'Authorization': 'Bearer ' + getToken()
'Authorization': getToken()
},
dialogImageUrl: '',
dialogVisible: false,
......
......@@ -168,7 +168,7 @@ export default {
title: '文件',
crudMethod: { ...crudFile },
delAllLoading: false,
headers: { 'Authorization': 'Bearer ' + getToken() },
headers: { 'Authorization': getToken() },
form: { id: null, name: null }
}
},
......
......@@ -129,7 +129,7 @@ export default {
title: '文件',
crudMethod: { ...crudQiNiu },
icon: 'el-icon-refresh',
url: '', headers: { 'Authorization': 'Bearer ' + getToken() }, dialog: false,
url: '', headers: { 'Authorization': getToken() }, dialog: false,
dialogImageUrl: '', dialogVisible: false, fileList: [], files: [], newWin: null
}
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment