| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126 |
- <template>
- <page-theme :theme="theme">
- <template>
- <view class="p-40" style="background-color: white;padding-top: 60px;padding-bottom: 30px;">
- <view class="flex-dir-row flex-y-center flex-x-between">
- <view class="m-l-30">
- <view class="f-34 t-bold m-b-20">{{nickName}}</view>
- <u-icon name="arrow-right" size="15" :color="$u.color['info']" @click="toProfile" label="更新个人信息"
- labelPos="left" labelSize="15" :labelColor="$u.color['info']" />
- </view>
- <u-avatar :src="face" size="60" />
- </view>
- </view>
- <view class="p-30">
- <view v-for="(item,i) in allCells" :key="i">
- <bt-cell :cells="item" />
- </view>
- <!-- <view class="flex-dir-row flex-x-between m-t-20 f-28">
- <view class="flex-dir-row flex-x-center flex-y-center p-b-t-20 border-round-10 c-g-white width-100"
- @click="toLogout">
- <u--image src="/static/images/logout.png" width="20px" height="20px" />
- <view class="m-l-10 col-info">退出登录</view>
- </view>
- </view> -->
- <view class="f-24 col-info-m t-c width-100 m-t-40" @click.stop="clickVersion">当前版本:{{version}}</view>
- </view>
- </template>
- </page-theme>
- </template>
- <script>
- import btCell from '@/pages/components/btcell.vue'
- import {
- version
- } from '@/common/setting'
- import {
- clickEvent
- } from '@/utils/util.js'
- import themeMixins from '../mixins/themeMixins.js';
- export default {
- mixins: [themeMixins],
- components: {
- btCell
- },
- data() {
- return {
- face: '',
- nickName: '',
- version: version,
- allCells: [
- [{
- icon: '',
- text: '名店收藏',
- url: '/pages/yuecai/collection/index?type=restaurant',
- }, {
- icon: '',
- text: '名菜收藏',
- url: '/pages/yuecai/collection/index?type=dish',
- }, {
- icon: '',
- text: '名点收藏',
- url: '/pages/yuecai/collection/index?type=snacks',
- }],
- [{
- icon: '',
- text: '用户协议',
- url: '/pages/yuecai/usercenter/protocol/index',
- }, {
- icon: '',
- text: '了解隐私保护政策',
- url: '/pages/yuecai/usercenter/privacy/index',
- }, {
- icon: '',
- text: '关于我们',
- url: '/pages/yuecai/usercenter/aboutus/index',
- }],
- ],
- }
- },
- methods: {
- toProfile() { //个人信息
- uni.navigateTo({
- url: './profile/index',
- })
- },
- toQuestion() {
- },
- toService() {
- },
- toLogout() {
- this.$u.func.logout()
- },
- clickVersion(e) { //点击版本号
- if (this.userInfo.nick_name == '嘉曦') { //满足条件就支持双击
- clickEvent(e, null, this.showMeTheMoney)
- }
- },
- showMeTheMoney() { //作弊
- if (!this.userInfo.isVIP) { //不是VIP,就作弊
- this.$u.vuex('userInfo.isVIP', true) //给予VIP
- uni.reLaunch({ //跳回登录页,但是不登出,让tab页重新加载
- url: '../../index',
- })
- }
- },
- refresh(face, nickName) {
- this.face = face
- this.nickName = nickName
- },
- },
- onShow() {
- this.face = this.userInfo.avatar || '/static/images/face.png'
- this.nickName = this.userInfo.nick_name || '小机灵鬼'
- },
- onUnload() {},
- }
- </script>
- <style scoped lang="scss">
- .k-pink {
- background-color: #FDEAD2;
- }
- </style>
|