diff --git a/pageB/video/video.nvue b/pageB/video/video.nvue index 1fc9a5e..8ce85a3 100644 --- a/pageB/video/video.nvue +++ b/pageB/video/video.nvue @@ -177,6 +177,9 @@ onReady() { this.videoBox = uni.createVideoContext("videoId", this); }, + onHide() { + this.videoBox.pause(); + }, onBackPress() { if (this.cart_type) { this.cart_type = !this.cart_type; diff --git a/pages/index/index.vue b/pages/index/index.vue index 360a6d3..03f66cb 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -332,7 +332,7 @@ if (this.live_page == 1) { this.tabLiveLists = res.data.data; this.status = "loadmore"; - if (res.data.data.length < 6) { + if (res.data.data.length < 4) { this.status = "nomore"; } } else if (res.data.data.length == 0 && this.live_page > 1) { @@ -423,26 +423,17 @@ uni.stopPullDownRefresh(); this.status = "loading"; if (res.errCode == 0) { - uni.hideLoading(); - console.log(this.page,res.data.list.length); if (this.page == 1) { - this.articleList = res.data.list; - this.status = "loadmore"; - if (res.data.list.length < 4) { + this.articleList = res.data.list; + if (!res.data.length) { this.status = "nomore"; } - } else if (res.data.length == 0 && this.page > 1) { + } else if (res.data.length == 0) { this.status = "nomore"; } else { this.articleList = this.articleList.concat(res.data.list); } - if (res.data.length == 0 && this.page > 1) { - console.log(111); - } else { - this.page++; - } - } else { - this.status = "nomore" + this.page++; } }) },