From 0c55115635ec84ae850534c68f8ed965d5733451 Mon Sep 17 00:00:00 2001 From: zyq Date: Sun, 21 Jul 2019 14:07:02 +0800 Subject: [PATCH 1/2] show title when image load error --- quasar.conf.js | 2 ++ src/pages/VideoList.vue | 33 ++++++++++++++++++++++++++++----- 2 files changed, 30 insertions(+), 5 deletions(-) diff --git a/quasar.conf.js b/quasar.conf.js index 7577845..0e337ed 100644 --- a/quasar.conf.js +++ b/quasar.conf.js @@ -62,6 +62,8 @@ module.exports = function (ctx) { 'QPageSticky', 'QInput', 'QSeparator', + 'QChip', + 'QTooltip', ], directives: ['Ripple'], diff --git a/src/pages/VideoList.vue b/src/pages/VideoList.vue index 2a48982..c52e753 100644 --- a/src/pages/VideoList.vue +++ b/src/pages/VideoList.vue @@ -3,7 +3,7 @@
-
{{video.name}}
+
{{video.name}}
-
{{video.type}}
-
{{ video.last }}
+
+ {{video.name}} + {{video.name}} +
+ {{video.type}} + {{video.last}}
@@ -130,9 +149,13 @@ export default { }; - From 8d1792dfde1f95e5bf7995c2458849debcc1ab38 Mon Sep 17 00:00:00 2001 From: zyq Date: Sun, 21 Jul 2019 14:12:25 +0800 Subject: [PATCH 2/2] fix pagination --- src/pages/VideoList.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/pages/VideoList.vue b/src/pages/VideoList.vue index c52e753..9dfa345 100644 --- a/src/pages/VideoList.vue +++ b/src/pages/VideoList.vue @@ -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); } }, @@ -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(() => {