mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-08 18:36:47 +08:00
加更多的打印日志
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
mounted() {
|
||||
let token=getToken();
|
||||
let $this=this;
|
||||
//console.log(token,'得到token');
|
||||
console.log(token,'得到token');
|
||||
if(!token){
|
||||
console.log('未获得token,转向登录');
|
||||
//this.$router.push({ path: process.env.VUE_APP_LOGIN_URL })
|
||||
@@ -34,8 +34,10 @@
|
||||
title:'获取用户信息',
|
||||
content:openUrl
|
||||
})
|
||||
console.log('获取用户信息');
|
||||
apiLogin.boeLogin(token).then(rs=>{
|
||||
if(rs.status==200){
|
||||
console.log('获取用户信息成功');
|
||||
uni.showModal({
|
||||
title:'获取用户成功',
|
||||
content:openUrl
|
||||
@@ -51,6 +53,7 @@
|
||||
uni.setStorageSync("boe_new_login",1);//记录新登录
|
||||
let openUrl=$this.toUrl;
|
||||
if(openUrl){
|
||||
console.log('跳转url='+openUrl);
|
||||
if(openUrl.startsWith('http')){
|
||||
uni.showModal({
|
||||
title:'跳转url0',
|
||||
@@ -75,12 +78,14 @@
|
||||
}
|
||||
}
|
||||
}else{
|
||||
console.log('跳转到首页');
|
||||
uni.switchTab({
|
||||
url:'/pages/index/index'
|
||||
})
|
||||
}
|
||||
|
||||
}).catch(error => {
|
||||
console.log('加载用户信息错误:',error);
|
||||
uni.showModal({
|
||||
title:'错误',
|
||||
content:error
|
||||
|
||||
Reference in New Issue
Block a user