| | |
| | | </view> |
| | | <view class="info"> |
| | | <view class="info-box"> |
| | | <view class="info-box-head" @click="jump(1)"> |
| | | <view class="info-box-head" @click="jump(isLogin?1:0)"> |
| | | <view class="info-box-head-image"> |
| | | <image src="/static/logo.png" mode="widthFix"></image> |
| | | <image v-if="userInfo.fullCoverImage&&userInfo.fullCoverImage !=''" :src="userInfo.fullCoverImage" mode="widthFix"></image> |
| | | <image v-else src="/static/logo.png" mode="widthFix"></image> |
| | | </view> |
| | | <view class="info-box-head-info"> |
| | | <view class="info-box-head-info-name">杨婷瑞</view> |
| | | <view class="info-box-head-info" v-if="isLogin"> |
| | | <view class="info-box-head-info-name">{{userInfo.nickName||'匿名'}}</view> |
| | | <view class="info-box-head-info-type"> |
| | | <view class="info-box-head-info-type-val">用工发布方</view> |
| | | <view class="info-box-head-info-type-wz">切换</view> |
| | | </view> |
| | | </view> |
| | | <view class="info-box-head-info" v-else> |
| | | <view class="info-box-head-info-name">点击登录</view> |
| | | <view class="info-box-head-info-type"> |
| | | <view class="info-box-head-info-type-wz">微信授权登录</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="info-box-label">账户余额</view> |
| | | <view class="info-box-price"> |
| | | <text>¥1000.00</text> |
| | | <text>¥{{isLogin?(userInfo.amount || 0) :0.00}}</text> |
| | | <view class="info-box-price-btn" @click="jumpTX">去提现</view> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="statistics"> |
| | | <view class="statistics-box"> |
| | | <view class="statistics-item"> |
| | | <text>248</text> |
| | | <view class="statistics-box" v-if="!isLogin || userInfo.useIdentity !=1"> |
| | | <view class="statistics-item" > |
| | | <text>{{isLogin?(userInfo.userCenterVO.releaseTaskTotal||0):'-'}}</text> |
| | | <text>总发单数</text> |
| | | </view> |
| | | <view class="statistics-x"></view> |
| | | <view class="statistics-item"> |
| | | <text>1</text> |
| | | <text>{{isLogin?(userInfo.userCenterVO.waitReceiveTotal||0):'-'}}</text> |
| | | <text>待接单</text> |
| | | </view> |
| | | <view class="statistics-item"> |
| | | <text>2</text> |
| | | <text>{{isLogin?(userInfo.userCenterVO.doingTotal||0):'-'}}</text> |
| | | <text>进行中</text> |
| | | </view> |
| | | <view class="statistics-item"> |
| | | <text>2</text> |
| | | <text>{{isLogin?(userInfo.userCenterVO.waitCommentTotal||0):'-'}}</text> |
| | | <text>待评价</text> |
| | | </view> |
| | | </view> |
| | | <view class="statistics-box" v-else> |
| | | <view class="statistics-item" > |
| | | <text>{{isLogin?(userInfo.userCenterVO.receiveTotal||0):'-'}}</text> |
| | | <text>已接单</text> |
| | | </view> |
| | | <view class="statistics-x"></view> |
| | | <view class="statistics-item"> |
| | | <text>{{isLogin?(userInfo.userCenterVO.taskingTotal||0):'-'}}</text> |
| | | <text>进行中</text> |
| | | </view> |
| | | <view class="statistics-item"> |
| | | <text>{{isLogin?(userInfo.userCenterVO.doneTotal||0):'-'}}</text> |
| | | <text>已完成</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="guanggao"> |
| | |
| | | import { mapState } from 'vuex' |
| | | export default { |
| | | computed: { |
| | | ...mapState(['navHeight', 'statusbarHeight']) |
| | | ...mapState(['navHeight', 'statusbarHeight','userInfo','token','openid']) |
| | | }, |
| | | data() { |
| | | return { |
| | | value: false |
| | | value: false, |
| | | isLogin:false |
| | | } |
| | | }, |
| | | onShow(options){ |
| | | this.isLogin=false |
| | | if(this.token &&this.token!='' && this.userInfo && JSON.stringify(this.userInfo) != '{}'){ |
| | | this.isLogin=true |
| | | this.getUserInfo() |
| | | } |
| | | }, |
| | | methods: { |
| | | getUserInfo() { |
| | | var that = this; |
| | | this.$u.api.getMemberInfo({}).then(res =>{ |
| | | if (res.code ===200) { |
| | | that.$store.commit('setUserInfo', res.data) |
| | | that.$isResolve() |
| | | }else{ |
| | | that.$store.commit('setToken','') |
| | | that.$store.commit('setUserInfo',{}) |
| | | that.$isResolve() |
| | | } |
| | | }) |
| | | }, |
| | | jumpTX() { |
| | | uni.navigateTo({ |
| | | url: '/pages/withdrawal/withdrawal' |
| | |
| | | uni.navigateTo({ |
| | | url: '/pages/catering-certification/catering-certification' |
| | | }) |
| | | |
| | | break; |
| | | case 5: |
| | | uni.navigateTo({ |
| | | url: '/pages/login/login' |
| | | }) |
| | | break; |
| | | } |
| | | } |