|
@@ -103,17 +103,18 @@
|
|
console.log('backUrl',that.backUrl);
|
|
console.log('backUrl',that.backUrl);
|
|
}
|
|
}
|
|
});
|
|
});
|
|
- console.log('accessToken=====',this.vuex_user_info.accessToken);
|
|
|
|
|
|
+ // console.log('accessToken=====',this.vuex_user_info.accessToken);
|
|
let accessToken = this.vuex_user_info.accessToken;
|
|
let accessToken = this.vuex_user_info.accessToken;
|
|
if(accessToken){
|
|
if(accessToken){
|
|
this.$u.api.teamLoginCheck().then(res=>{
|
|
this.$u.api.teamLoginCheck().then(res=>{
|
|
- if(this.backUrl.includes('login/login')){
|
|
|
|
|
|
+ if(this.backUrl.includes('login/login')||this.backUrl.includes('main/index')){
|
|
this.backUrl = '/pages/index/index'
|
|
this.backUrl = '/pages/index/index'
|
|
}
|
|
}
|
|
uni.reLaunch({url: this.backUrl});
|
|
uni.reLaunch({url: this.backUrl});
|
|
}).catch(err=>{
|
|
}).catch(err=>{
|
|
console.log('teamLoginCheck',err);
|
|
console.log('teamLoginCheck',err);
|
|
uni.$u.vuex('vuex_member_info', {});
|
|
uni.$u.vuex('vuex_member_info', {});
|
|
|
|
+ uni.$u.vuex('vuex_user_info', {});
|
|
this.$u.toast(err.msg)
|
|
this.$u.toast(err.msg)
|
|
this.redirectToAuth()
|
|
this.redirectToAuth()
|
|
})
|
|
})
|
|
@@ -125,15 +126,11 @@
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
-
|
|
|
|
-
|
|
|
|
// 测试环境填充用户名密码
|
|
// 测试环境填充用户名密码
|
|
if(process.env.NODE_ENV=='development'){
|
|
if(process.env.NODE_ENV=='development'){
|
|
this.form.mobile = '13682277062';
|
|
this.form.mobile = '13682277062';
|
|
this.form.password = '123456';
|
|
this.form.password = '123456';
|
|
}
|
|
}
|
|
-
|
|
|
|
-
|
|
|
|
},
|
|
},
|
|
onShow() {
|
|
onShow() {
|
|
|
|
|
|
@@ -141,7 +138,12 @@
|
|
methods: {
|
|
methods: {
|
|
/** 公众号 微信授权登录 */
|
|
/** 公众号 微信授权登录 */
|
|
redirectToAuth() {
|
|
redirectToAuth() {
|
|
- window.location.href = this.$commonConfig.authUrl;
|
|
|
|
|
|
+ try{
|
|
|
|
+ window.location.href = this.$commonConfig.authUrl;
|
|
|
|
+ }catch(e){
|
|
|
|
+ alert(`redirectToAuth e:${e}`)
|
|
|
|
+ }
|
|
|
|
+
|
|
},
|
|
},
|
|
/**
|
|
/**
|
|
*
|
|
*
|