From cd678de1a9956fd3337e477da814ffbfaffec841 Mon Sep 17 00:00:00 2001 From: THK3121 Date: Mon, 25 Sep 2023 18:59:53 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/nongKe/food/index.vue | 3 +- pages/nongKe/specialty/index.vue | 3 +- pages/nongKe/supply_chain/supplier.vue | 39 ++++++++++++++++++-------- pages/nongKe/tourism/index.vue | 3 +- 4 files changed, 33 insertions(+), 15 deletions(-) diff --git a/pages/nongKe/food/index.vue b/pages/nongKe/food/index.vue index ea4bca3..b82b9df 100644 --- a/pages/nongKe/food/index.vue +++ b/pages/nongKe/food/index.vue @@ -9,7 +9,8 @@ - + diff --git a/pages/nongKe/specialty/index.vue b/pages/nongKe/specialty/index.vue index 7c056cf..9338cc6 100644 --- a/pages/nongKe/specialty/index.vue +++ b/pages/nongKe/specialty/index.vue @@ -9,7 +9,8 @@ - + diff --git a/pages/nongKe/supply_chain/supplier.vue b/pages/nongKe/supply_chain/supplier.vue index 9bb3a07..7f48e11 100644 --- a/pages/nongKe/supply_chain/supplier.vue +++ b/pages/nongKe/supply_chain/supplier.vue @@ -141,7 +141,7 @@ - + @@ -414,6 +414,7 @@ menuList: [], street: "", showPicker: false, + status: "loadmore", // 下拉菜单 downMenu: [{ title: '默认', @@ -920,19 +921,33 @@ }, //上划加载更多 onReachBottom() { - if (this.count === this.storeList.length) { - if (this.count === 0) { + this.sotreParam.page += 1 + + let rqData = { + keyword: this.sotreParam.keyword, + page: this.sotreParam.page, + limit: 10, + order: this.sotreParam.order, + category_id: this.sotreParam.category_id, + type_id: this.sotreParam.type_id, + street_id: this.sotreParam.street_id, + credit_buy: this.credit_buy + } + if (this.latitude) { + rqData.location = this.latitude + ',' + this.longitude + } + // console.log(rqData) + storeMerchantList(rqData).then(res => { + if (res.data.list == 0) { + this.status = "nomore" return } - uni.showToast({ - title: '已加载全部', - icon: 'none', - duration: 1000 - }); - } else { - this.sotreParam.page += 1 - this.storeMerchantList() - } + this.count = res.data.count + this.storeList.push(...res.data.list) + + }) + + } } diff --git a/pages/nongKe/tourism/index.vue b/pages/nongKe/tourism/index.vue index 29f86fd..5350b0a 100644 --- a/pages/nongKe/tourism/index.vue +++ b/pages/nongKe/tourism/index.vue @@ -9,7 +9,8 @@ - +