diff --git a/mobile/src/pages/xg/xsjcxx/xsqj/leave/index.vue b/mobile/src/pages/xg/xsjcxx/xsqj/leave/index.vue index dca37893..4fc10a90 100644 --- a/mobile/src/pages/xg/xsjcxx/xsqj/leave/index.vue +++ b/mobile/src/pages/xg/xsjcxx/xsqj/leave/index.vue @@ -251,13 +251,15 @@ - + + + @@ -337,6 +339,12 @@ export default { uni.$off('refreshLeaveList', this.handleRefreshEvent); }, + // 页面滚动到底部事件 + onReachBottom() { + console.log('🔄 触发滚动到底部事件,开始加载更多...'); + this.loadMore(); + }, + methods: { // 处理刷新事件 handleRefreshEvent() { @@ -452,8 +460,16 @@ export default { // 加载更多 async loadMore() { - if (this.loadStatus !== 'loadmore') return; + // 防止重复加载和无效加载 + if (this.loadStatus !== 'loadmore' || this.loading) { + console.log('🚫 跳过加载更多:', { + loadStatus: this.loadStatus, + loading: this.loading, + }); + return; + } + console.log('📄 开始加载更多数据...'); this.queryParams.pageNum += 1; await this.loadLeaveList(false); },