3
0
Fork 0

fix(specialArea): v0仅会员专区可见

This commit is contained in:
woody 2025-07-12 11:13:41 +08:00
parent 7b52076c44
commit e778f671ca
3 changed files with 20 additions and 59 deletions

View File

@ -28,7 +28,11 @@
</view> </view>
<!-- 复购 --> <!-- 复购 -->
<view key="repurchase" v-if="repurchaseList.length > 0" class="goods-flexs"> <view
key="repurchase"
v-if="repurchaseList.length > 0 && !isZeroLevel"
class="goods-flexs"
>
<view class="goods-view"> <view class="goods-view">
<area-product-list <area-product-list
:list="repurchaseList" :list="repurchaseList"
@ -75,6 +79,10 @@ export default {
default: 'normal', // 'normal' or 'small' default: 'normal', // 'normal' or 'small'
validator: value => ['normal', 'small'].includes(value), validator: value => ['normal', 'small'].includes(value),
}, },
userInfo: {
type: Object,
default: () => {},
},
}, },
components: { components: {
'area-product-list': areaProductList, 'area-product-list': areaProductList,
@ -95,12 +103,13 @@ export default {
...mapGetters(['isZeroLevel']), ...mapGetters(['isZeroLevel']),
}, },
created() { created() {
const userInfo = uni.getStorageSync('userInfo') const userInfo = uni.getStorageSync('userInfo') || this.userInfo
if (userInfo.memberSign != MEMBER_SIGN.ZERO_LEVEL) { if (userInfo.memberSign == MEMBER_SIGN.ZERO_LEVEL) {
this.getAreaListById(REISSUE_AREA.id, this.rescissionList) this.upgrade.name = '会员专区'
this.getAreaListById(REGIEST_AREA.id, this.registList)
} }
this.getAreaListById(UPGRADE_AREA.id, this.upgradeList) this.getAreaListById(UPGRADE_AREA.id, this.upgradeList)
this.getAreaListById(REISSUE_AREA.id, this.rescissionList)
this.getAreaListById(REGIEST_AREA.id, this.registList)
this.getAreaListById(REPURCHASE_AREA.id, this.repurchaseList) this.getAreaListById(REPURCHASE_AREA.id, this.repurchaseList)
}, },
methods: { methods: {

View File

@ -28,58 +28,8 @@
</swiper> </swiper>
</view> </view>
</view> </view>
<special-area-wrapper size="small" /> <view style="padding-bottom: 140rpx">
<view class="goods-sort"> <special-area-wrapper :userInfo="userInfo" size="small" />
<view class="goods_content" style="padding-bottom: 130rpx">
<view
class="goods-center-lists"
v-for="item in goodsList"
:key="item.waresId"
@click="goDetails(item)"
>
<view
class="fly"
v-show="item.preSaleStatus == 3 || item.isSale == 1"
></view>
<view class="goods-flex-s">
<view class="goods-img">
<image :src="item.cover1"></image>
</view>
<view class="padding_s goods-info">
<view class="goods-name">{{ item.waresName }}</view>
<view class="goods-sales-wrapper">
<view class="goods-sales"
>累计销量{{ formatSales(item.sales) }}</view
>
<view
class="goods-price"
v-if="item.specialArea == 31 && userInfo.isMakerSpace == 1"
>
<span v-if="priceSymbolVisible" class="price-symbol">
{{ priceSymbol }}
</span>
<span>{{ formatCurrency(item.vipPrice) }}</span>
</view>
<view class="goods-price" v-if="item.specialArea != 31">
<span v-if="priceSymbolVisible" class="price-symbol">
{{ priceSymbol }}
</span>
<span>{{ formatCurrency(item.waresPrice) }}</span>
</view>
<view
class="goods-price"
v-if="item.specialArea == 31 && userInfo.isMakerSpace == 0"
>
<span v-if="priceSymbolVisible" class="price-symbol">
{{ priceSymbol }}
</span>
<span>{{ formatCurrency(item.waresPrice) }}</span>
</view>
</view>
</view>
</view>
</view>
</view>
</view> </view>
<cl-tabbar :current="0"></cl-tabbar> <cl-tabbar :current="0"></cl-tabbar>
<div> <div>

View File

@ -6,7 +6,7 @@
--> -->
<template> <template>
<view class="content"> <view class="content">
<special-area-wrapper /> <special-area-wrapper :userInfo="userInfo" />
<cl-tabbar :current="1"></cl-tabbar> <cl-tabbar :current="1"></cl-tabbar>
</view> </view>
@ -22,7 +22,9 @@ export default {
}, },
data() { data() {
return {} return {
userInfo: uni.getStorageSync('User'),
}
}, },
onLoad() {}, onLoad() {},