|
|
|
|
@ -63,6 +63,7 @@ |
|
|
|
|
let userInfo = uni.getStorageSync('userInfo'); |
|
|
|
|
if (userInfo) { |
|
|
|
|
this.userInfo = JSON.parse(userInfo); |
|
|
|
|
console.log(userInfo) |
|
|
|
|
this.userInfo.avatar = this.userInfo.avatar ? this.userInfo.avatar : this.avatarUrl; |
|
|
|
|
} else { |
|
|
|
|
this.userInfo.avatar = this.avatarUrl; |
|
|
|
|
@ -71,10 +72,9 @@ |
|
|
|
|
methods: { |
|
|
|
|
//获取昵称 |
|
|
|
|
formSubmit(e) { |
|
|
|
|
console.log(e.detail) |
|
|
|
|
if(e.detail.value && e.detail.value != this.userInfo.username) { |
|
|
|
|
// if(e.detail.value && e.detail.value != this.userInfo.username) { |
|
|
|
|
this.updateNickname(e.detail.value); |
|
|
|
|
} |
|
|
|
|
// } |
|
|
|
|
}, |
|
|
|
|
//获取头像 |
|
|
|
|
chooseavatar(e) { |
|
|
|
|
|