mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-09 19:06:46 +08:00
解决无returnUrl的问题
This commit is contained in:
@@ -15,16 +15,19 @@
|
||||
},
|
||||
onLoad(options) {
|
||||
this.toUrl=options.returnUrl;
|
||||
|
||||
var pvArray=Object.keys(options);
|
||||
var params='';
|
||||
pvArray.forEach(pv=>{
|
||||
if(pv!='returnUrl'){
|
||||
params+='&'+pv+'='+options[pv];
|
||||
if(this.toUrl){
|
||||
if(this.toUrl=='/'){
|
||||
this.toUrl='';
|
||||
}
|
||||
});
|
||||
this.toUrl=this.toUrl+params;
|
||||
|
||||
var pvArray=Object.keys(options);
|
||||
var params='';
|
||||
pvArray.forEach(pv=>{
|
||||
if(pv!='returnUrl'){
|
||||
params+='&'+pv+'='+options[pv];
|
||||
}
|
||||
});
|
||||
this.toUrl=this.toUrl+params;
|
||||
}
|
||||
console.log(this.toUrl,'options.returnUrl');
|
||||
},
|
||||
mounted() {
|
||||
@@ -60,7 +63,6 @@
|
||||
// })
|
||||
uni.setStorageSync("boe_new_login",1);//记录新登录
|
||||
let openUrl=$this.toUrl;
|
||||
console.log(openUrl);
|
||||
//http://localhost:8081/mobile/pages/login/loading?returnUrl=/pages/study/courseStudy?id=1028700304503054336
|
||||
if(openUrl){
|
||||
//如果openUrl的页面不存在,或不对,就会出现跳转不动的问题,这个情况
|
||||
|
||||
Reference in New Issue
Block a user