【代码评审】积分界面

pull/128/MERGE
YunaiV 2024-12-01 18:19:12 +08:00
parent 9616e660a6
commit 951a52d37b
1 changed files with 14 additions and 11 deletions

View File

@ -7,7 +7,10 @@
<detailSkeleton v-if="state.skeletonLoading" /> <detailSkeleton v-if="state.skeletonLoading" />
<!-- 下架/售罄提醒 --> <!-- 下架/售罄提醒 -->
<s-empty <s-empty
v-else-if="state.goodsInfo === null || state.goodsInfo.activity_type !== PromotionActivityTypeEnum.POINT.type" v-else-if="
state.goodsInfo === null ||
state.goodsInfo.activity_type !== PromotionActivityTypeEnum.POINT.type
"
text="活动不存在或已结束" text="活动不存在或已结束"
icon="/static/soldout-empty.png" icon="/static/soldout-empty.png"
showAction showAction
@ -37,7 +40,9 @@
></image> ></image>
<text class="point-text ss-m-r-16"> <text class="point-text ss-m-r-16">
{{ getShowPrice.point }} {{ getShowPrice.point }}
{{ !getShowPrice.price || getShowPrice.price === 0 ? '' : `+¥${getShowPrice.price}` }} {{
!getShowPrice.price || getShowPrice.price === 0 ? '' : `+¥${getShowPrice.price}`
}}
</text> </text>
</view> </view>
<view class="sales-text"> <view class="sales-text">
@ -87,21 +92,19 @@
<button <button
class="ss-reset-button btn-box ss-flex-col" class="ss-reset-button btn-box ss-flex-col"
@tap="state.showSelectSku = true" @tap="state.showSelectSku = true"
:class=" :class="state.goodsInfo.stock != 0 ? 'check-btn-box' : 'disabled-btn-box'"
state.goodsInfo.stock != 0
? 'check-btn-box'
: 'disabled-btn-box'
"
:disabled="state.goodsInfo.stock === 0" :disabled="state.goodsInfo.stock === 0"
> >
<view class="price-box ss-flex"> <view class="price-box ss-flex">
<image <image
:src="sheep.$url.static('/static/img/shop/goods/score1.svg')" :src="sheep.$url.static('/static/img/shop/goods/score1.svg')"
style="width: 36rpx;height: 36rpx;margin: 0 4rpx;" style="width: 36rpx; height: 36rpx; margin: 0 4rpx"
></image> ></image>
<text class="point-text ss-m-r-16"> <text class="point-text ss-m-r-16">
{{ getShowPrice.point }} {{ getShowPrice.point }}
{{ !getShowPrice.price || getShowPrice.price === 0 ? '' : `+¥${getShowPrice.price}` }} {{
!getShowPrice.price || getShowPrice.price === 0 ? '' : `+¥${getShowPrice.price}`
}}
</text> </text>
</view> </view>
<view v-if="state.goodsInfo.stock === 0"></view> <view v-if="state.goodsInfo.stock === 0"></view>
@ -135,8 +138,7 @@
const seckillBg = sheep.$url.css('/static/img/shop/goods/seckill-tip-bg.png'); const seckillBg = sheep.$url.css('/static/img/shop/goods/seckill-tip-bg.png');
const grouponBg = sheep.$url.css('/static/img/shop/goods/groupon-tip-bg.png'); const grouponBg = sheep.$url.css('/static/img/shop/goods/groupon-tip-bg.png');
onPageScroll(() => { onPageScroll(() => {});
});
const state = reactive({ const state = reactive({
skeletonLoading: true, skeletonLoading: true,
goodsInfo: {}, goodsInfo: {},
@ -178,6 +180,7 @@
title: activity.value.name, title: activity.value.name,
image: sheep.$url.cdn(state.goodsInfo.picUrl), image: sheep.$url.cdn(state.goodsInfo.picUrl),
params: { params: {
// TODO @puhuipage
page: '6', page: '6',
query: activity.value.id, query: activity.value.id,
}, },