前端访问的是login路径,但是到后端路径就变成/$%7Bbase%7D$%7Burl%7D
前端访问
this.$postRequest('/login',this.loginFrom).then(resp=>{
if(resp){
this.loading = false;
//存储用户token
const tokenStr = resp.obj.tokenHead +resp.obj.token;
window.sessionStorage.setItem('tokenStr',tokenStr);
//跳转首页
this.$router.replace('/about');
}
})