diff --git a/src/pages/index/home/index.vue b/src/pages/index/home/index.vue index b72f833..73e8f66 100644 --- a/src/pages/index/home/index.vue +++ b/src/pages/index/home/index.vue @@ -121,7 +121,6 @@ export default { this.$bus.$on("pullDownRefresh", () => { this.paramter.currentPage = 1; this.isReachBottom = false; - this.obtainLocation(); }); }, @@ -168,8 +167,8 @@ export default { this.isReachBottom = true; } this.tableList = this.tableList.concat(res.data.list); - uni.stopPullDownRefresh(); } + uni.stopPullDownRefresh(); }); }, sift(params) { diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue index e782a5b..88843e6 100644 --- a/src/pages/index/index.vue +++ b/src/pages/index/index.vue @@ -47,9 +47,7 @@ export default { this.$bus.$emit("pullDownRefresh"); } if (this.currentTab === "user") { - setTimeout(() => { - uni.stopPullDownRefresh(); - }, 500); + this.$bus.$emit("userPullDownRefresh"); } }, onReachBottom() { diff --git a/src/pages/index/user/index.vue b/src/pages/index/user/index.vue index 6f03303..d615318 100644 --- a/src/pages/index/user/index.vue +++ b/src/pages/index/user/index.vue @@ -106,6 +106,15 @@ export default { }, created() { if (this.userInfo.id) { + this.statisticOrderTotalData(); + + this.$bus.$on("userPullDownRefresh", () => { + this.statisticOrderTotalData(); + }); + } + }, + methods: { + statisticOrderTotalData() { serve .statisticOrderTotalData({ customerId: this.userInfo.id, @@ -114,10 +123,9 @@ export default { if (res.code === 20000) { this.statisticInfo = res.data; } + uni.stopPullDownRefresh(); }); - } - }, - methods: { + }, jumpOrder(status = "") { uni.navigateTo({ url: `/subPackages/order/list/index?status=${status}`, diff --git a/src/subPackages/order/list/index.vue b/src/subPackages/order/list/index.vue index 05586f5..78307f2 100644 --- a/src/subPackages/order/list/index.vue +++ b/src/subPackages/order/list/index.vue @@ -16,7 +16,9 @@