Files
crmeb-mp/pages/user/components/member/template4.vue
Karlcarlo d9263d2ea2 feat: 微信审核适配 — 移除提现/分销页面 + 分享图片预取 + 登录链路修复
- pages.json 移除 14 个提现/分销页面注册(user_cash/user_spread/spreadData/promoter/distributor),文件保留可恢复
- template4.vue 隐藏'立即提现'区块(用户中心可见入口,分销功能已关闭)
- record.vue 抽奖记录移除提现收款跳转(改 toast 提示)
- web_view 分享图片:太阳码/点击应用时从 box_app 预取 shareImageUrl,H5 postMessage 传图优先
- web_view _fetchOpenidAndLoad 兼容老用户响应(openid 从 userInfo/JWT 兜底解析)并写回缓存
- App.vue 移除 expired=[object Promise] 无意义日志
2026-08-15 16:36:49 +08:00

263 lines
6.5 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<script>
import { HTTP_REQUEST_URL } from '@/config/app';
export default {
props: {
userInfo: {
type: Object,
default: () => {}
},
commission: {
type: Object,
default: () => {}
},
// perShowType 0 手机号 1 ID
perShowType: {
type: Number,
default: 0
}
},
inject: ['intoPage', 'tapQrCode', 'goEdit', 'bindPhone', 'checkApp'],
computed: {
headerBg() {
return `url(${HTTP_REQUEST_URL}/statics/images/users/template4_bg.png)`;
},
showMerBtn(){
return this.$store.state.app.channel_func_status
}
}
};
</script>
<template>
<view class="">
<view class="acea-row row-middle user">
<view class="avatar relative" :class="{'svip-border': userInfo.pay_vip_status}" @click="goEdit">
<image class="avatar-img" :src="userInfo.avatar" mode="aspectFill" v-if="userInfo.avatar"></image>
<image class="avatar-img" src="@/static/images/f.png" mode="aspectFill" v-else></image>
<image class="vip-badge" src="@/static/img/svip_badge.png" v-show="userInfo.pay_vip_status"></image>
</view>
<view class="name-wrap">
<view class="name" v-if="userInfo.nickname">{{ userInfo.nickname }}</view>
<view class="name display-add" v-else @tap="intoPage">请点击授权</view>
<view class="flex-y-center mt-10" v-show="userInfo.is_channel || userInfo.is_service">
<view class="h-42 flex-center fs-22 text--w111-666 pl-16 pr-14 rd-30rpx b-c mr-12"
v-show="userInfo.is_channel && showMerBtn" @tap="checkApp(1)">采购商
<text class="iconfont icon-ic_rightarrow fs-22"></text>
</view>
<view class="h-42 flex-center fs-22 text--w111-666 pl-16 pr-14 rd-30rpx b-c"
v-show="userInfo.is_service" @tap="checkApp(2)">商家管理
<text class="iconfont icon-ic_rightarrow fs-22"></text>
</view>
</view>
<template v-if="!userInfo.is_channel && !userInfo.is_service">
<view class="bind-phone" v-if="!userInfo.phone && userInfo.uid" @tap="bindPhone">绑定手机号</view>
<view class="phone" v-else>{{ perShowType ? 'ID:' + userInfo.uid : userInfo.phone }}</view>
</template>
</view>
<text class="iconfont icon-a-ic_QRcode fs-40" @click="tapQrCode"><text class="tips">会员码</text></text>
<text class="iconfont icon-a-ic_setup1 fs-40 mx-34" @click="intoPage('/pages/users/user_set/index')"></text>
<text class="iconfont icon-ic_message3 fs-40" @click="intoPage('/pages/users/message_center/index')">
<text v-if="userInfo.service_num" class="number">{{ userInfo.service_num >= 100 ? '99+' : userInfo.service_num }}</text>
</text>
</view>
<!-- 分销/提现区块已隐藏(微信审核要求:分销功能关闭,提现页面已移除,待审核通过后可恢复)
<view class="distribution">
<view class="acea-row row-middle row-between withdraw">
<view>
<view>可提现(元)</view>
<view class="value num-fa-semi">{{ userInfo.commissionCount || 0 }}</view>
</view>
<view class="button" @click="intoPage('/pages/users/user_cash/index')">立即提现</view>
</view>
<view class="acea-row">
<view class="item">
<view class="inner">
<view>累计佣金</view>
<view class="value num-fa-semi">{{ commission && commission.brokerage_price || 0 }}</view>
</view>
</view>
<view class="item">
<view class="inner">
<view>推荐人数</view>
<view class="value num-fa-semi">{{ commission && commission.number || 0 }}</view>
</view>
</view>
<view class="item">
<view class="inner">
<view>推荐单数</view>
<view class="value num-fa-semi">{{ commission && commission.order_num || 0 }}</view>
</view>
</view>
</view>
</view>
-->
</view>
</template>
<style scoped lang="scss">
.user {
padding: 60rpx 42rpx 56rpx 30rpx;
background-position: bottom;
background-size: 100%;
background-color: #f5f5f5;
.avatar {
width: 112rpx;
height: 112rpx;
border-radius: 50%;
.avatar-img{
width: 100%;
height:100%;
border-radius: 50%;
display: block;
}
}
.vip-badge{
position: absolute;
top: -10rpx;
right: 0;
width: 30rpx;
height: 30rpx;
}
.svip-border{
border: 2rpx solid #F1BB0D;
}
.name-wrap {
flex: 1;
padding: 0 32rpx;
color: #333333;
}
.name {
font-weight: 500;
font-size: 32rpx;
line-height: 44rpx;
}
.phone {
margin-top: 10rpx;
font-size: 24rpx;
line-height: 34rpx;
}
.bind-phone {
margin-top: 12rpx;
background: #fff;
border-radius: 30px;
width: max-content;
text-align: center;
font-size: 20rpx;
font-weight: 400;
color: #333333;
line-height: 28rpx;
padding: 6rpx 16rpx;
}
.iconfont {
position: relative;
}
.tips {
position: absolute;
bottom: 100%;
left: 50%;
height: 28rpx;
padding: 0 14rpx;
border-radius: 14rpx;
margin-bottom: 4rpx;
background-color: #ffd89c;
transform: translateX(-50%);
white-space: nowrap;
font-size: 16rpx;
line-height: 28rpx;
color: #9e5e1a;
}
.tips::before {
content: '';
position: absolute;
bottom: -6rpx;
left: calc(50% - 6rpx);
width: 0;
height: 0;
border-left: 6rpx solid transparent;
border-right: 6rpx solid transparent;
border-top: 6rpx solid #ffd89c; /* 修改颜色以改变三角形颜色 */
}
.number {
position: absolute;
top: -8rpx;
right: 0;
min-width: 10rpx;
height: 24rpx;
padding: 0 6rpx;
border: 2rpx solid var(--view-theme);
border-radius: 12rpx;
background-color: #ffffff;
transform: translateX(50%);
font-weight: 500;
font-size: 18rpx;
line-height: 24rpx;
color: var(--view-theme);
}
}
.distribution {
border-radius: 24rpx;
margin: 0 20rpx 20rpx;
background-color: #ffffff;
.withdraw {
height: 176rpx;
padding: 0 56rpx 0 48rpx;
background-image: url('@/static/img/black_user_bg.png');
background-position: center;
background-repeat: no-repeat;
background-size: cover;
font-size: 26rpx;
line-height: 36rpx;
color: rgba(255, 231, 198, 0.8);
.value {
margin-top: 16rpx;
font-family: SemiBold;
font-size: 56rpx;
line-height: 56rpx;
color: #ffe7c6;
}
.button {
height: 56rpx;
padding: 0 24rpx;
border-radius: 28rpx;
background-color: #fce6c8;
font-weight: 500;
font-size: 24rpx;
line-height: 56rpx;
color: #9c5a00;
}
}
.item {
flex: 1;
padding: 40rpx 0;
text-align: center;
font-size: 26rpx;
line-height: 30rpx;
color: #999999;
.inner {
display: inline-block;
}
.value {
margin-top: 20rpx;
text-align: left;
font-family: SemiBold;
font-size: 36rpx;
line-height: 36rpx;
color: #333333;
}
}
}
.b-c{
border: 1rpx solid #ccc
}
</style>