|
@@ -194,6 +194,9 @@ export default {
|
|
|
this.twitterAuth();
|
|
|
}
|
|
|
},
|
|
|
+ cancelLogin() {
|
|
|
+ location.href = `/course?useful=${this.useFul ? '1' : '0'}&playType=${this.playType}&rewardType=${this.rewardType}&postId=${this.postId}`;
|
|
|
+ },
|
|
|
async twitterAuth() {
|
|
|
postRequest(`/denet/user/twitterRequestToken`, {
|
|
|
params: {
|
|
@@ -207,6 +210,10 @@ export default {
|
|
|
if (win && win.closed) {
|
|
|
clearInterval(this.timer.value);
|
|
|
this.twitterLogin(data);
|
|
|
+ if (getStorage(storageKey.backFromTwitterLogin)) {
|
|
|
+ removeStorage(storageKey.backFromTwitterLogin);
|
|
|
+ this.cancelLogin();
|
|
|
+ }
|
|
|
}
|
|
|
}, 500);
|
|
|
}
|
|
@@ -232,6 +239,9 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
},
|
|
|
+ unmounted() {
|
|
|
+ removeStorage(storageKey.backFromTwitterLogin);
|
|
|
+ },
|
|
|
components: { FontZoom },
|
|
|
};
|
|
|
</script>
|