diff --git a/src/project/qujing/AppContentQj/contentDetail.vue b/src/project/qujing/AppContentQj/contentDetail.vue
index 3e7aaa9..ed871d0 100644
--- a/src/project/qujing/AppContentQj/contentDetail.vue
+++ b/src/project/qujing/AppContentQj/contentDetail.vue
@@ -8,14 +8,14 @@
- 共{{ commentList.length }}条评论
-
+
共{{ total || 0 }}条评论
+
+
@@ -77,6 +77,9 @@ export default {
commentList: [],
id: '',
flag: false,
+ current: 1,
+ pages: 2,
+ total: 0
}
},
onLoad({id}) {
@@ -98,9 +101,12 @@ export default {
},
// 评论集合
getComment() {
- this.$instance.post(`/app/appcontentcomment/listForWX?contentId=${this.id}`).then(res=> {
+ if(this.current > this.pages) return
+ this.$instance.post(`/app/appcontentcomment/listForWX?contentId=${this.id}¤t=${this.current}`).then(res=> {
if(res?.data) {
- this.commentList = res.data.records
+ this.commentList = this.current==1? res.data.records: [...this.commentList,...res.data.records]
+ this.total = res.data.total
+ this.pages = res.data.pages
}
})
},
@@ -131,6 +137,10 @@ export default {
this.$u.toast(err.msg)
})
},
+ scrollLower() {
+ this.current++
+ this.getComment()
+ },
},
onShareAppMessage() {
return {
@@ -146,7 +156,7 @@ export default {