Skip to content

Commit

Permalink
fix pagination
Browse files Browse the repository at this point in the history
  • Loading branch information
ZyqGitHub1 committed Jul 21, 2019
1 parent 0c55115 commit 8d1792d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/pages/VideoList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,13 +90,16 @@ export default {
this.getVideoList(value);
},
currentSite() {
this.pagination.page = 1;
this.getVideoList(1);
},
currentClass() {
this.pagination.page = 1;
this.getVideoList(1);
},
keyWord(newKeyWord, oldKeyWord) {
if (newKeyWord !== oldKeyWord) {
this.pagination.page = 1;
this.getVideoList(1);
}
},
Expand Down Expand Up @@ -125,7 +128,7 @@ export default {
.then(res => parseStringSync(res.data, { explicitArray: false }))
.then((data) => {
this.videoList = data.rss.list.video;
this.pagination.total = _toInteger(data.rss.list.$.recordcount);
this.pagination.total = _toInteger(data.rss.list.$.pagecount);
})
.catch(console.error)
.finally(() => {
Expand Down

0 comments on commit 8d1792d

Please sign in to comment.