Browse Source

--------

featrue/v4.2
huziyuan 5 years ago
parent
commit
a7b64fa2da
3 changed files with 4 additions and 3 deletions
  1. 2
      app.js
  2. 3
      pages/home/index/index.js
  3. 2
      pages/home/index/index.wxml

2
app.js

@ -1,7 +1,7 @@
//app.js //app.js
App({ App({
//----------------------------------------------globalData-------------------------------------- //----------------------------------------------globalData--------------------------------------
evn: 1,//0:开发环境,1:测试环境,2:生产环境
evn: 2,//0:开发环境,1:测试环境,2:生产环境
tmplIds: ['SUjEgwDopCv9xkkSZ4KbS0L7XbAiVQor6GmPg14K760'], tmplIds: ['SUjEgwDopCv9xkkSZ4KbS0L7XbAiVQor6GmPg14K760'],
agentMsgIds: ['kG8DErWDpyzBHCFaLlSKYMF7xVy8UpgogCwV_WSNt10', 'oLbv-IyJOia2tenh64_Lc8xeAzwgzu3gh1vFJ1Se-ME'], agentMsgIds: ['kG8DErWDpyzBHCFaLlSKYMF7xVy8UpgogCwV_WSNt10', 'oLbv-IyJOia2tenh64_Lc8xeAzwgzu3gh1vFJ1Se-ME'],
version: 152, version: 152,

3
pages/home/index/index.js

@ -48,7 +48,8 @@ Component({
console.log(this.data.height) console.log(this.data.height)
if (app.globalData.userInfo && app.globalData.userInfo.memberExpiredAt) { if (app.globalData.userInfo && app.globalData.userInfo.memberExpiredAt) {
this.setData({ this.setData({
'userInfo.memberExpiredAt': app.globalData.userInfo.memberExpiredAt
'userInfo.memberExpiredAt': app.globalData.userInfo.memberExpiredAt,
userName:app.globalData.userInfo.realName||app.globalData.userInfo.nickname||''
}) })
} }
} }

2
pages/home/index/index.wxml

@ -9,7 +9,7 @@
<view class="topText" bindtap="toUserInfo"> <view class="topText" bindtap="toUserInfo">
<view wx:if="{{userInfo}}" style="height:158rpx"> <view wx:if="{{userInfo}}" style="height:158rpx">
<view> <view>
<text class="textType1">{{userInfo.realName}}</text>
<text class="textType1">{{userInfo.userName}}</text>
<image class="img-auth2" src="{{userInfo.isAuth == 1 ? '/assets/myinfo/ysmicon.png' : '/assets/myinfo/wsmicon.png'}}"> <image class="img-auth2" src="{{userInfo.isAuth == 1 ? '/assets/myinfo/ysmicon.png' : '/assets/myinfo/wsmicon.png'}}">
</image> </image>
</view> </view>

Loading…
Cancel
Save