From c362b9f2e9fa6cc141c981fb45677558a6b39298 Mon Sep 17 00:00:00 2001 From: fanfan Date: Tue, 12 Mar 2024 16:47:18 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E7=BB=86=E8=8A=82=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/goods/detail.vue | 2 +- pages/goods/list.vue | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/pages/goods/detail.vue b/pages/goods/detail.vue index 86cd238..7cbedc2 100644 --- a/pages/goods/detail.vue +++ b/pages/goods/detail.vue @@ -338,7 +338,7 @@ {{goods.goods_name}} - ¥{{goods.goods_price_min}} + ¥{{goods.goods_price_min?Number(goods.goods_price_min):goods.goods_price_min}} diff --git a/pages/goods/list.vue b/pages/goods/list.vue index d8f65e7..0980fc3 100644 --- a/pages/goods/list.vue +++ b/pages/goods/list.vue @@ -267,8 +267,9 @@ categoryId: app.options.categoryId || 0, goodsName: app.options.search || '', page: pageNo, - keywords: keywords + keywords: keywords.length>0?keywords.join(','):'' } + console.log(param) return new Promise((resolve, reject) => { GoodsApi.list(param) .then(result => { From 70be2ae2ab3c03b6af0d81b418b261b565d021a8 Mon Sep 17 00:00:00 2001 From: fanfan Date: Tue, 12 Mar 2024 17:09:01 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E7=BB=86=E8=8A=82=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/goods/list.vue | 34 ++++++++++++++++++++++++++-------- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/pages/goods/list.vue b/pages/goods/list.vue index 0980fc3..4e1e600 100644 --- a/pages/goods/list.vue +++ b/pages/goods/list.vue @@ -81,7 +81,8 @@ - ¥{{ item.goods_price_min>0?Number(item.goods_price_min):'' }} + ¥{{ item.goods_price_min>0?Number(item.goods_price_min):'' }} ¥{{ item.line_price_min>0?Number(item.line_price_min):'' }} @@ -115,8 +116,9 @@ - ¥{{ item.goods_price_min>0?Number(item.goods_price_min):'' }} 到手价 + ¥{{ item.goods_price_min>0?Number(item.goods_price_min):'' }} + 到手价 ¥{{ item.line_price_min>0?Number(item.line_price_min):'' }} @@ -126,6 +128,7 @@ + @@ -217,13 +220,24 @@ }, onChage(item, type) { if (type == 1) { - this.isBanrdActive = item.category_id; - this.keyName1 = item.name + if (item.category_id == this.isBanrdActive) { + this.isBanrdActive = ''; + this.keyName1 = '' + } else { + this.isBanrdActive = item.category_id; + this.keyName1 = item.name + } } if (type == 2) { - this.isActive = item.category_id - this.keyName2 = item.name + if (item.category_id == this.isActive) { + this.isActive = ''; + this.keyName2 = '' + } else { + this.isActive = item.category_id; + this.keyName2 = item.name + } } + this.getGoodsList() }, /** @@ -267,7 +281,7 @@ categoryId: app.options.categoryId || 0, goodsName: app.options.search || '', page: pageNo, - keywords: keywords.length>0?keywords.join(','):'' + keywords: keywords.length > 0 ? keywords.join(',') : '' } console.log(param) return new Promise((resolve, reject) => { @@ -362,6 +376,10 @@