mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-08 02:16:46 +08:00
两次编码url
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
},
|
||||
onLoad(options) {
|
||||
this.toUrl=options.returnUrl;
|
||||
console.log(this.toUrl,'options.returnUrl');
|
||||
},
|
||||
mounted() {
|
||||
let token=getToken();
|
||||
@@ -31,7 +32,7 @@
|
||||
//console.log('this.toUrl',this.toUrl);
|
||||
//console.log('this.$config.loginPath',this.$config.loginPath);
|
||||
if(this.toUrl){
|
||||
location.href=this.$config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+'/pages/login/loading?returnUrl='+this.toUrl);
|
||||
location.href=this.$config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+'/pages/login/loading?returnUrl='+encodeURIComponent(this.toUrl));
|
||||
}else{
|
||||
location.href=this.$config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+'/pages/login/loading');
|
||||
}
|
||||
@@ -78,7 +79,7 @@
|
||||
// #endif
|
||||
// #ifdef H5
|
||||
if(this.toUrl){
|
||||
location.href=this.$config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+'/pages/login/loading?returnUrl='+this.toUrl);
|
||||
location.href=this.$config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+'/pages/login/loading?returnUrl='+encodeURIComponent(this.toUrl));
|
||||
}else{
|
||||
location.href=this.$config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+'/pages/login/loading');
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ export function toLogin(ajaxUrl) {
|
||||
if(process.env.NODE_ENV === 'development'){
|
||||
location.href=config.loginPath+"?returnUrl="+encodeURIComponent(returnPage);
|
||||
}else{
|
||||
location.href=config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+urlContext+'/pages/login/loading?returnUrl='+returnPage);
|
||||
location.href=config.loginPath+"?returnUrl="+encodeURIComponent(urlPre+urlContext+'/pages/login/loading?returnUrl='+encodeURIComponent(returnPage));
|
||||
}
|
||||
//location.href=config.loginPath
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user