diff --git a/pages/index/center.vue b/pages/index/center.vue index 180c761..66e0250 100644 --- a/pages/index/center.vue +++ b/pages/index/center.vue @@ -138,13 +138,12 @@ } }, onShow() { - - }, - onLoad() { if(this.isLogin) { this.$store.commit('getUserInfo') } }, + onLoad() { + }, onPageScroll(e) { if(e.scrollTop > 50) { this.bgColor = '#49070c' diff --git a/pages_login/wxLogin.vue b/pages_login/wxLogin.vue index be20a38..81bb23f 100644 --- a/pages_login/wxLogin.vue +++ b/pages_login/wxLogin.vue @@ -110,9 +110,9 @@ justify-content: center; align-items: center; width: 70%; - background: #05C160; + background: $uni--bg-color-btn; height: 90rpx; - border-radius: 45rpx; + border-radius: 15rpx; color: white; margin-top: 200rpx; @@ -128,6 +128,9 @@ width: 70%; height: 90rpx; padding: 0; + background: rgba($uni--bg-color-btn, 0.2); + color: $uni--bg-color-btn; + border-radius: 15rpx; } //隐私政策 diff --git a/pages_login/wxUserInfo.vue b/pages_login/wxUserInfo.vue index 8688d21..ec1c30e 100644 --- a/pages_login/wxUserInfo.vue +++ b/pages_login/wxUserInfo.vue @@ -92,12 +92,23 @@ }, onShow() {}, onLoad() { - this.userInfoForm.phone = this.userInfo.phone || '' - this.userInfoForm.nickName = this.userInfo.nickName || '' - this.userInfoForm.headImage = this.userInfo.headImage || '' + // this.userInfoForm.phone = this.userInfo.phone || '' + // this.userInfoForm.nickName = this.userInfo.nickName || '' + // this.userInfoForm.headImage = this.userInfo.headImage || '' + this.getUserInfo() }, computed: {}, methods: { + getUserInfo(){ + this.$api('getInfo', res => { + if(res.code == 200){ + this.userInfoForm.phone = res.result.phone || '' + this.userInfoForm.nickName = res.result.nickName || '' + this.userInfoForm.headImage = res.result.headImage || '' + this.userInfoForm.sex = res.result.sex || '' + } + }) + }, onChooseAvatar(res) { let self = this self.$Oss.ossUpload(res.target.avatarUrl) @@ -212,21 +223,19 @@ } .btn { - // background: $uni--bg-color-btn; - background: #05C160; + background: $uni--bg-color-btn; color: #fff; width: 80%; padding: 20rpx 0; text-align: center; - border-radius: 45rpx; + border-radius: 15rpx; margin-top: 10vh; } .getPhoneNumber{ display: flex; justify-content: center; align-items: center; - // background: $uni--bg-color-btn; - background: #05C160; + background: $uni--bg-color-btn; color: #fff; width: 220rpx; height: 60rpx;