Authored by yyq

preload

@@ -60,9 +60,9 @@ export default { @@ -60,9 +60,9 @@ export default {
60 } 60 }
61 }, 61 },
62 serverPrefetch() { 62 serverPrefetch() {
63 - const articleId = parseInt(this.$route.params.id, 10); 63 + this.id = parseInt(this.$route.params.id, 10);
64 64
65 - return articleId > 0 ? this.syncServiceArticleDetail(true) : Promise.resolve(); 65 + return this.id > 0 ? this.syncServiceArticleDetail(true) : Promise.resolve();
66 }, 66 },
67 mounted() { 67 mounted() {
68 this.colWidthForTwo = Math.floor(this.$el.offsetWidth / 2); 68 this.colWidthForTwo = Math.floor(this.$el.offsetWidth / 2);
@@ -90,7 +90,7 @@ export default { @@ -90,7 +90,7 @@ export default {
90 syncServiceArticleDetail(thumb) { 90 syncServiceArticleDetail(thumb) {
91 const articleId = parseInt(this.id, 10); 91 const articleId = parseInt(this.id, 10);
92 92
93 - this.fetchArticleList({ 93 + return this.fetchArticleList({
94 articleId, 94 articleId,
95 singleDetail: 'Y', 95 singleDetail: 'Y',
96 thumb 96 thumb
@@ -86,7 +86,7 @@ export default { @@ -86,7 +86,7 @@ export default {
86 mounted() { 86 mounted() {
87 let {clientHeight, clientWidth} = document.documentElement; 87 let {clientHeight, clientWidth} = document.documentElement;
88 88
89 - if (!this.$yoho.isiOS && (clientHeight / clientWidth) < 1.8) { 89 + if (!this.$yoho.isiOS) {
90 this.downgrade = true; 90 this.downgrade = true;
91 } 91 }
92 }, 92 },