|
@ -112,13 +112,14 @@ Page({ |
|
|
}) |
|
|
}) |
|
|
const para = { |
|
|
const para = { |
|
|
pageIndex: this.data.pageNo, |
|
|
pageIndex: this.data.pageNo, |
|
|
pageSize: this.data.pageSize |
|
|
pageSize: this.data.pageSize, |
|
|
|
|
|
timestamp: getTimestamp() |
|
|
} |
|
|
} |
|
|
api.getMyTopicList(para).then(res => { |
|
|
api.getMyTopicListV2(para).then(res => { |
|
|
console.log('我的话题列表', res) |
|
|
console.log('我的话题列表', res) |
|
|
this.setData({ |
|
|
this.setData({ |
|
|
topicList: [...res.data], |
|
|
topicList: [...res.data.topicList], |
|
|
nomoreStatus: res.data.length === 10 ? 'loading' : 'none', |
|
|
nomoreStatus: res.data.topicList.length === 10 ? 'loading' : 'none', |
|
|
preloadVisible: false |
|
|
preloadVisible: false |
|
|
}) |
|
|
}) |
|
|
}).catch(err => { |
|
|
}).catch(err => { |
|
@ -134,13 +135,14 @@ Page({ |
|
|
loadMoreTopicList() { |
|
|
loadMoreTopicList() { |
|
|
const para = { |
|
|
const para = { |
|
|
pageIndex: this.data.pageNo, |
|
|
pageIndex: this.data.pageNo, |
|
|
pageSize: this.data.pageSize |
|
|
pageSize: this.data.pageSize, |
|
|
|
|
|
timestamp: getTimestamp() |
|
|
} |
|
|
} |
|
|
api.getMyTopicList(para).then(res => { |
|
|
api.getMyTopicListV2(para).then(res => { |
|
|
console.log('我的话题列表', res) |
|
|
console.log('我的话题列表', res) |
|
|
const topicList = [...this.data.topicList, ...res.data] |
|
|
const topicList = [...this.data.topicList, ...res.data.topicList] |
|
|
this.setData({ |
|
|
this.setData({ |
|
|
nomoreStatus: res.data.length === 10 ? 'loading' : 'none', |
|
|
nomoreStatus: res.data.topicList.length === 10 ? 'loading' : 'none', |
|
|
preloadVisible: false, |
|
|
preloadVisible: false, |
|
|
topicList, |
|
|
topicList, |
|
|
}) |
|
|
}) |
|
|