doum
2025-09-15 a1c569d40b5d1d6571a197467a41fd3421c393ce
small-program/pages/mine/mine.vue
@@ -10,13 +10,14 @@
               <view class="info-box-head" >
                  <view class="info-box-head-image" @click="jump(isLogin?1:5)">
                     <image v-if="userInfo.fullCoverImage&&userInfo.fullCoverImage !=''" :src="userInfo.fullCoverImage" mode="widthFix"></image>
                     <image v-else src="/static/logo.png" mode="widthFix"></image>
                     <image v-else src="/static/icon/img@2x.png" mode="widthFix"></image>
                  </view>
                  <view class="info-box-head-info" v-if="isLogin">
                     <view class="info-box-head-info-name"  @click="jump(1)">{{userInfo.nickName||'匿名'}}</view>
                     <view class="info-box-head-info-type">
                        <view class="info-box-head-info-type-val">{{userInfo.useIdentity==1?'用工接单方':'用工发布方'}}</view>
                        <view class="info-box-head-info-type-wz" @click="editUseIdentity">切换</view>
                        <view class="info-box-head-info-type-val1" v-if="userInfo.useIdentity==1">用工接单方</view>
                        <view class="info-box-head-info-type-val" v-else>用工发布方</view>
                        <!-- <view class="info-box-head-info-type-wz" @click="editUseIdentity">切换</view> -->
                     </view> 
                  </view>
                  <view class="info-box-head-info" v-else @click="jump(5)">
@@ -24,6 +25,10 @@
                     <view class="info-box-head-info-type">
                        <view class="info-box-head-info-type-wz">微信授权登录</view>
                     </view>
                  </view>
                  <view class="info-box-head-qiehuan" @click="editUseIdentity">
                     <image src="/static/icon/ic_change@2x.png" mode="widthFix"></image>
                     <text>切换身份</text>
                  </view>
               </view>
               <view class="info-box-label">账户余额</view>
@@ -35,35 +40,35 @@
         </view>
         <view class="statistics">
            <view class="statistics-box" v-if="!isLogin || userInfo.useIdentity !=1">
               <view class="statistics-item" >
               <view class="statistics-item" @click="jumpOrderList('0')" >
                  <text>{{isLogin?(userInfo.userCenterVO.releaseTaskTotal||0):'-'}}</text>
                  <text>总发单数</text>
               </view>
               <view class="statistics-x"></view>
               <view class="statistics-item">
               <view class="statistics-item" @click="jumpOrderList('1')" >
                  <text class="redtxt">{{isLogin?(userInfo.userCenterVO.waitReceiveTotal||0):'-'}}</text>
                  <text>待接单</text>
               </view>
               <view class="statistics-item">
               <view class="statistics-item" @click="jumpOrderList('2')" >
                  <text>{{isLogin?(userInfo.userCenterVO.doingTotal||0):'-'}}</text>
                  <text>进行中</text>
               </view>
               <view class="statistics-item">
               <view class="statistics-item" @click="jumpOrderList('3')" >
                  <text>{{isLogin?(userInfo.userCenterVO.waitCommentTotal||0):'-'}}</text>
                  <text>待评价</text>
               </view>
            </view>
            <view class="statistics-box" v-else>
               <view class="statistics-item" >
               <view class="statistics-item" @click="jumpOrderList('4')" >
                  <text>{{isLogin?(userInfo.userCenterVO.receiveTotal||0):'-'}}</text>
                  <text>已接单</text>
               </view>
               <view class="statistics-x"></view>
               <view class="statistics-item">
               <view class="statistics-item" @click="jumpOrderList('5')">
                  <text>{{isLogin?(userInfo.userCenterVO.taskingTotal||0):'-'}}</text>
                  <text>进行中</text>
               </view>
               <view class="statistics-item">
               <view class="statistics-item" @click="jumpOrderList('6')">
                  <text>{{isLogin?(userInfo.userCenterVO.doneTotal||0):'-'}}</text>
                  <text>已完成</text>
               </view> 
@@ -164,6 +169,13 @@
         }
      },
      methods: {
         jumpOrderList(flag){
            const app = getApp();
            app.globalData.orderStatus = flag;
            uni.switchTab({
               url: '/pages/demand-hall/demand-hall'
            })
         },
         getUserInfo() {
            var that = this;
            this.$u.api.getMemberInfo({}).then(res =>{ 
@@ -186,17 +198,17 @@
            switch(type) {
               case 1:
                  uni.navigateTo({
                     url: '/pages/set-up/set-up'
                     url: '/packageA/pages/set-up/set-up'
                  })
                  break;
               case 2:
                  if(!this.userInfo.workerIdentity ||this.userInfo.workerIdentity ==0){
                     uni.navigateTo({
                        url:  '/pages/employment-certification/employment-certification?flag=0'
                        url:  '/packageA/pages/employment-certification/employment-certification?flag=0'
                     })
                  }else{
                     uni.navigateTo({
                        url: '/pages/certification-results/certification-results?flag=0'
                        url: '/packageA/pages/certification-results/certification-results?flag=0'
                     })
                  }
                  break;
@@ -204,22 +216,22 @@
               case 3:
                  if(!this.userInfo.driverIdentity ||this.userInfo.driverIdentity ==0){
                     uni.navigateTo({
                        url: '/pages/employment-certification/employment-certification?flag=1'
                        url: '/packageA/pages/employment-certification/employment-certification?flag=1'
                     })
                  }else{
                     uni.navigateTo({
                        url: '/pages/certification-results/certification-results?flag=1'
                        url: '/packageA/pages/certification-results/certification-results?flag=1'
                     })
                  }
                  break;
               case 4:
                  if(!this.userInfo.chefIdentity ||this.userInfo.chefIdentity ==0){
                     uni.navigateTo({
                        url: '/pages/employment-certification/employment-certification?flag=2'
                        url: '/packageA/pages/employment-certification/employment-certification?flag=2'
                     })
                  }else{
                     uni.navigateTo({
                        url: '/pages/certification-results/certification-results?flag=2'
                        url: '/packageA/pages/certification-results/certification-results?flag=2'
                     })
                  }
                  break;
@@ -230,12 +242,12 @@
                  break;
               case 6:
                  uni.navigateTo({
                     url: '/pages/withdrawal/withdrawal'
                     url: '/packageA/pages/withdrawal/withdrawal'
                  })
                  break;
               case 7:
                  uni.navigateTo({
                     url: '/pages/certification-results/certification-results'
                     url: '/packageA/pages/certification-results/certification-results'
                  })
                  break;
            }
@@ -260,6 +272,7 @@
                console.log(222,res)
               if(res.code ===200){
                  that.userInfo.useIdentity = param.useIdentity
                  that.$store.commit('setUserInfo', that.userInfo)
                  uni.$emit('refresh')
               } 
            }).finally(() => {
@@ -476,7 +489,6 @@
                  width: 100%;
                  height: 108rpx;
                  display: flex;
                  align-items: center;
                  margin-bottom: 30rpx;
                  .info-box-head-image {
                     width: 108rpx;
@@ -490,6 +502,20 @@
                     margin-right: 24rpx;
                     image {
                        width: 100%;
                     }
                  }
                  .info-box-head-qiehuan {
                     flex-shrink: 0;
                     display: flex;
                     image {
                        width: 32rpx;
                        height: 32rpx;
                        margin-right: 10rpx;
                     }
                     text {
                        font-weight: 400;
                        font-size: 28rpx;
                        color: #00BC12;
                     }
                  }
                  .info-box-head-info {
@@ -520,6 +546,19 @@
                           border: 2rpx solid #FD9E24;
                           margin-right: 20rpx;
                        }
                        .info-box-head-info-type-val1 {
                           width: 144rpx;
                           height: 42rpx;
                           line-height: 42rpx;
                           text-align: center;
                           background: rgba(91,190,56,0.06);
                           border-radius: 8rpx;
                           font-weight: 400;
                           font-size: 24rpx;
                           color: #00BC12;
                           border: 2rpx solid #00BC12;
                           margin-right: 20rpx;
                        }
                        .info-box-head-info-type-wz {
                           font-weight: 400;
                           font-size: 24rpx;