diff --git a/index/user.js b/index/user.js index 46ea032..6b5b03c 100644 --- a/index/user.js +++ b/index/user.js @@ -127,20 +127,20 @@ Page({ * 生命周期函数--监听页面显示 */ onShow: function() { - if (typeof this.getTabBar === 'function' && - this.getTabBar()) { + let that = this; + if (typeof that.getTabBar === 'function' && + that.getTabBar()) { if (ifStoreApp==1){ - this.getTabBar().setData({ + that.getTabBar().setData({ selected: 1 }) }else{ - this.getTabBar().setData({ + that.getTabBar().setData({ selected: 3 }) } } - let that = this; that.checkUserStatus(); that.setData({ appVersion: extConfig.appVersion,