|
@@ -37,13 +37,13 @@ export default {
|
|
|
return `translateX(${-this.active * 100}vw)`;
|
|
|
},
|
|
|
isLottaryCpd() {
|
|
|
- return this.playType === PlayType.lottery;
|
|
|
+ return +getQueryString('playType') === PlayType.lottery;
|
|
|
},
|
|
|
isCommonCpd() {
|
|
|
- return this.playType === PlayType.common;
|
|
|
+ return +getQueryString('playType') === PlayType.common;
|
|
|
},
|
|
|
isTreasureCpd() {
|
|
|
- return this.playType === PlayType.Treasure;
|
|
|
+ return +getQueryString('playType') === PlayType.Treasure;
|
|
|
},
|
|
|
isUsefulCpd() {
|
|
|
return getQueryString('useful') === '1';
|
|
@@ -51,7 +51,7 @@ export default {
|
|
|
tipTextCpd() {
|
|
|
if (this.isLottaryCpd) {
|
|
|
return 'Install DeNet chrome extension to claim your prize';
|
|
|
- } else if (this.isCommonCpd || this.is) {
|
|
|
+ } else if (this.isCommonCpd || this.isTreasureCpd) {
|
|
|
return 'Install Denet Chrome Extension to complete the quest';
|
|
|
} else {
|
|
|
return 'How to install Denet Chrome Extension';
|
|
@@ -60,17 +60,15 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
next() {
|
|
|
- if (this.active < this.course.length - 1) {
|
|
|
- this.active++;
|
|
|
- } else {
|
|
|
- window.location.replace(`https://twitter.com/intent/retweet?tweet_id=${this.postId}`);
|
|
|
- }
|
|
|
+ this.active++;
|
|
|
},
|
|
|
back() {
|
|
|
this.active--;
|
|
|
},
|
|
|
retweer() {
|
|
|
- window.open(`https://twitter.com/intent/retweet?tweet_id=${this.postId}`);
|
|
|
+ if (getQueryString('postId')) {
|
|
|
+ window.open(`https://twitter.com/intent/retweet?tweet_id=${getQueryString('postId')}`);
|
|
|
+ }
|
|
|
},
|
|
|
},
|
|
|
async asyncData(params) {
|
|
@@ -88,11 +86,6 @@ export default {
|
|
|
};
|
|
|
}
|
|
|
},
|
|
|
- mounted() {
|
|
|
- this.playType = getQueryString('playType');
|
|
|
- this.rewardType = getQueryString('rewardType');
|
|
|
- this.postId = getQueryString('postId');
|
|
|
- },
|
|
|
};
|
|
|
</script>
|
|
|
|