From c9eb9527b5c111a34a347fa195bb0d776c10b3b5 Mon Sep 17 00:00:00 2001 From: wangfukang <15630117759@163.com> Date: Tue, 19 May 2026 17:20:19 +0800 Subject: [PATCH] 1 --- pages/index/index.vue | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/pages/index/index.vue b/pages/index/index.vue index c910403..afdc968 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -1117,6 +1117,10 @@ }, getDelivery() { let that = this + that.waimaiCount = 0 + that.kuaidiCount = 0 + that.paotuiCount = 0 + that.zhipaiCount = 0 this.tui.request("/mall/delivery/page", "POST", this.searchForm, false, false).then((res) => { that.loadStatus = 'nomore'; if (res.code == 200) { @@ -1142,7 +1146,7 @@ } else { that.deliveryItem = [...that.deliveryItem, ...res.result.records] } - if (res.result.orderCount != null) { + if (res.result.orderCount != null && res.result.orderCount.length > 0) { for (let i = 0; i < res.result.orderCount.length; i++) { if (res.result.orderCount[i].deliveryType == 1) { that.waimaiCount = res.result.orderCount[i].orderCount @@ -1152,7 +1156,12 @@ that.paotuiCount = res.result.orderCount[i].orderCount } } + }else{ + that.waimaiCount = 0 + that.kuaidiCount = 0 + that.paotuiCount = 0 } + if (res.result.zhipaiCount != undefined && res.result.zhipaiCount != null) { that.zhipaiCount = res.result.zhipaiCount }