From 8a0e49fde2fd198e45eb70856afaa6091bc7298f Mon Sep 17 00:00:00 2001 From: ldh Date: Fri, 3 Feb 2023 17:28:15 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=8D=95=E8=A7=84=E6=A0=BC?= =?UTF-8?q?=E9=98=B6=E6=A2=AF=E6=8B=BC=E5=9B=A2=E4=BB=B7=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/goods/groupon.vue | 3 +++ .../s-select-groupon-sku.vue | 16 ++++++++++++---- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/pages/goods/groupon.vue b/pages/goods/groupon.vue index 948a7111..20372c00 100644 --- a/pages/goods/groupon.vue +++ b/pages/goods/groupon.vue @@ -218,6 +218,9 @@ if (isEmpty(state.selectedSkuPrice)) { return formatPrice(state.goodsInfo.price); } + if(state.grouponNum === 0 && state.grouponType === 'groupon_ladder') { + return formatPrice(state.goodsInfo.price) + } if (state.grouponType === 'groupon') { return state.selectedSkuPrice.groupon_price; } diff --git a/sheep/components/s-select-groupon-sku/s-select-groupon-sku.vue b/sheep/components/s-select-groupon-sku/s-select-groupon-sku.vue index 3a644610..541be7de 100644 --- a/sheep/components/s-select-groupon-sku/s-select-groupon-sku.vue +++ b/sheep/components/s-select-groupon-sku/s-select-groupon-sku.vue @@ -15,7 +15,8 @@ {{ goodsInfo.title }} {{ goodsPrice }} - + + - 库存{{ state.selectedSkuPrice.stock || goodsInfo.stock }}件 + 库存{{ state.selectedSkuPrice.stock || goodsInfo.stock }}000件 @@ -180,6 +181,10 @@ if (isEmpty(state.selectedSkuPrice)) { return formatPrice(props.goodsInfo.price); } + if(state.grouponNum === 0 && activityType === 'groupon_ladder') { + return formatPrice(props.goodsInfo.price) + } + if (activityType === 'groupon') { return state.selectedSkuPrice.groupon_price; } @@ -195,6 +200,9 @@ if (isEmpty(state.selectedSkuPrice)) { return formatPrice(props.goodsInfo.price); } + + if(state.grouponNum === 0 && activityType === 'groupon_ladder') return; + if (activityType === 'groupon') { return state.selectedSkuPrice.leader_price; } @@ -206,7 +214,7 @@ // 获取阶梯价 function getSkuPriceByLadder() { - return state.selectedSkuPrice.ladders.find((item) => item.ladder == state.grouponNum); + return state.selectedSkuPrice.ladders.find((item) => item.ladder == state.grouponNum); } watch(