uniapp/pages/index/index.vue
@@ -122,16 +122,21 @@ } }, onLoad() { this.getCategoryList(); this.getPopBannerInfo(); }, onShow() { if(!this.hasLogin){ setTimeout(function(){ uni.reLaunch({ url:"/pages/login/wxlogin" }) },3000); },1000); return; } var user= uni.getStorageSync('userInfo'); console.log(user); if(!user.invitation_code) { setTimeout(function(){ @@ -139,16 +144,9 @@ uni.reLaunch({ url:"/pages/login/wxlogin" }) },3000); },1000); return; } else { this.getCategoryList(); this.getPopBannerInfo(); } }, onShow() { if(this.categoryList){ this.getCategoryList(); }