From bbe315fb45cf7d8f1d088bda4986b6d7e3223606 Mon Sep 17 00:00:00 2001 From: paulGao Date: Wed, 11 Jan 2023 11:28:51 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=BC=98=E5=8C=96=E4=BC=98=E6=83=A0?= =?UTF-8?q?=E5=88=B8=E4=BD=BF=E7=94=A8=E8=B7=B3=E8=BD=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/cart/coupon/myCoupon.vue | 119 +- pages/navigation/search/searchPage.vue | 1388 ++++++++++++------------ 2 files changed, 780 insertions(+), 727 deletions(-) diff --git a/pages/cart/coupon/myCoupon.vue b/pages/cart/coupon/myCoupon.vue index ac59a4a..fe029a7 100644 --- a/pages/cart/coupon/myCoupon.vue +++ b/pages/cart/coupon/myCoupon.vue @@ -2,28 +2,63 @@ - {{ + {{ item.text - }} + }} - - - + + + - + - + - + - {{ coupon.discount }}折 + {{ coupon.discount }}折 {{ coupon.price }}元 - 满{{ coupon.consumeThreshold | unitPrice }}可用 + 满{{ coupon.consumeThreshold | unitPrice }}可用 @@ -31,27 +66,47 @@ {{ coupon.title }} - 使用平台:{{ - coupon.scopeType == 'ALL' && coupon.storeId == '0' + 使用平台:{{ + coupon.scopeType == "ALL" && coupon.storeId == "0" ? "全平台" : coupon.scopeType == "PORTION_CATEGORY" ? "仅限品类" - : coupon.storeName == 'platform' ? '全平台' :coupon.storeName+'' - }}使用 - {{ - coupon.endTime - }} - 详细说明 - + : coupon.storeName == "platform" + ? "全平台" + : coupon.storeName + "" + }}使用 + {{ coupon.endTime }} + 详细说明 + 新到 - 将过期 + 将过期 - - - + + + 立即
使用
@@ -116,7 +171,7 @@ export default { }, onShow() { - this.navList[this.tabCurrentIndex].params.pageNumber = 1 + this.navList[this.tabCurrentIndex].params.pageNumber = 1; this.navList[this.tabCurrentIndex].dataList = []; this.getData(); }, @@ -188,15 +243,9 @@ export default { * 立即使用优惠券 */ useItNow(item) { - if (item.storeId && item.storeId!='0') { - uni.navigateTo({ - url: `/pages/product/shopPage?id=${item.storeId}`, - }); - } else { - uni.switchTab({ - url: "/pages/navigation/search/searchPage", - }); - } + uni.navigateTo({ + url: `/pages/navigation/search/searchPage?promotionsId=${item.couponId}&promotionType=COUPON`, + }); }, /** diff --git a/pages/navigation/search/searchPage.vue b/pages/navigation/search/searchPage.vue index 765834c..12c6470 100644 --- a/pages/navigation/search/searchPage.vue +++ b/pages/navigation/search/searchPage.vue @@ -1,747 +1,751 @@