2020-06-08 15:23:23 +08:00
|
|
|
<template>
|
|
|
|
<view class="information">
|
|
|
|
<view class="info-avatar">
|
2020-08-01 16:36:48 +08:00
|
|
|
<u-avatar :src="userInfo.member_avatar + '?' + new Date().getTime()" :size="120"></u-avatar>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">昵称</view>
|
2020-06-29 08:47:37 +08:00
|
|
|
<view class="value">{{ userInfo.member_nickname }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">性别</view>
|
2020-07-01 17:32:36 +08:00
|
|
|
<view class="value">{{ userInfo.member_sex == 1 ? '男' : '女' }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">生日</view>
|
2020-07-03 17:44:58 +08:00
|
|
|
<view class="value">{{ userInfo.member_birthday }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">手机号</view>
|
2020-06-29 08:47:37 +08:00
|
|
|
<view class="value">{{ userInfo.member_mobile }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">等级</view>
|
2020-07-03 17:44:58 +08:00
|
|
|
<view class="value">{{ userInfo.member_level }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">积分数</view>
|
2020-06-29 08:47:37 +08:00
|
|
|
<view class="value">{{ userInfo.member_points }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
<view class="info-item">
|
|
|
|
<view class="title">经验值</view>
|
2020-06-29 08:47:37 +08:00
|
|
|
<view class="value">{{ userInfo.member_exppoints }}</view>
|
2020-06-08 15:23:23 +08:00
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</template>
|
|
|
|
<script>
|
2020-07-03 09:08:53 +08:00
|
|
|
import common from '@/static/js/common.js'
|
2020-06-08 15:23:23 +08:00
|
|
|
export default {
|
|
|
|
data() {
|
2020-06-29 08:47:37 +08:00
|
|
|
return {
|
|
|
|
userInfo: {}
|
|
|
|
}
|
|
|
|
},
|
2020-07-08 18:14:41 +08:00
|
|
|
onShow() {
|
2020-06-29 08:47:37 +08:00
|
|
|
this.getUserInfo();
|
2020-06-08 15:23:23 +08:00
|
|
|
},
|
|
|
|
onNavigationBarButtonTap() {
|
|
|
|
this.toEditPage();
|
|
|
|
},
|
|
|
|
methods: {
|
2020-06-29 08:47:37 +08:00
|
|
|
getUserInfo() {
|
|
|
|
this.$u.api.getMemberInfo().then(res => {
|
|
|
|
if (res.errCode == 0) {
|
2020-07-14 10:13:27 +08:00
|
|
|
// this.userInfo = res.data.MemberArray;
|
|
|
|
this.$set(this, 'userInfo', res.data.MemberArray);
|
2020-06-29 08:47:37 +08:00
|
|
|
}
|
|
|
|
})
|
|
|
|
},
|
2020-06-08 15:23:23 +08:00
|
|
|
toEditPage() {
|
|
|
|
uni.navigateTo({
|
|
|
|
url: '/pageE/mine/EditUserInfo'
|
|
|
|
});
|
|
|
|
}
|
|
|
|
},
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
.information {
|
|
|
|
min-height: calc(100vh - var(--window-top));
|
|
|
|
background-color: #ECECEC;
|
|
|
|
padding-top: 1rpx;
|
|
|
|
.info-avatar {
|
2020-07-06 17:32:29 +08:00
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
justify-content: center;
|
2020-06-08 15:23:23 +08:00
|
|
|
height: 160rpx;
|
|
|
|
background: rgba(255,255,255,1);
|
|
|
|
}
|
|
|
|
.info-item {
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
padding: 35rpx 30rpx;
|
|
|
|
border-top: 2rpx solid #ECECEC;
|
|
|
|
font-size: 30rpx;
|
|
|
|
height: 98rpx;
|
|
|
|
background: rgba(255,255,255,1);
|
|
|
|
.title {
|
|
|
|
width: 240rpx;
|
|
|
|
color: rgba(51,51,51,1);
|
|
|
|
}
|
|
|
|
.value {
|
|
|
|
color: rgba(102,102,102,1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|