修改用户详情接口传参,增加userId参数,暂时剔除请求401重新登录
This commit is contained in:
parent
eb2b6c15f2
commit
bf3dc320c0
|
|
@ -47,8 +47,8 @@ http.interceptors.request.use(config => {
|
||||||
*/
|
*/
|
||||||
http.interceptors.response.use(response => {
|
http.interceptors.response.use(response => {
|
||||||
if (response.data && response.data.code === 401) { // 401, token失效
|
if (response.data && response.data.code === 401) { // 401, token失效
|
||||||
clearLoginInfo()
|
// clearLoginInfo()
|
||||||
router.push({name: 'login'})
|
// router.push({name: 'login'})
|
||||||
}
|
}
|
||||||
return response
|
return response
|
||||||
}, error => {
|
}, error => {
|
||||||
|
|
|
||||||
|
|
@ -1380,7 +1380,10 @@ export default {
|
||||||
this.$http({
|
this.$http({
|
||||||
url: this.$http.adornUrl(`user/${userId}`),
|
url: this.$http.adornUrl(`user/${userId}`),
|
||||||
method: "get",
|
method: "get",
|
||||||
params: this.$http.adornParams({}),
|
params: {
|
||||||
|
...this.$http.adornParams({}),
|
||||||
|
userId: userId,
|
||||||
|
},
|
||||||
}).then(({ data }) => {
|
}).then(({ data }) => {
|
||||||
if (data.code === 0) {
|
if (data.code === 0) {
|
||||||
console.log("data", data);
|
console.log("data", data);
|
||||||
|
|
|
||||||
|
|
@ -1311,7 +1311,10 @@
|
||||||
this.$http({
|
this.$http({
|
||||||
url: this.$http.adornUrl(`user/${userId}`),
|
url: this.$http.adornUrl(`user/${userId}`),
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params: this.$http.adornParams({})
|
params: {
|
||||||
|
...this.$http.adornParams({}),
|
||||||
|
userId: userId,
|
||||||
|
},
|
||||||
}).then(({
|
}).then(({
|
||||||
data
|
data
|
||||||
}) => {
|
}) => {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue