|
@@ -86,6 +86,7 @@ export default {
|
|
|
amountUsdValue: '',
|
|
|
totalCount: '',
|
|
|
},
|
|
|
+ headers: {},
|
|
|
config: {},
|
|
|
title: 'Treasure Hunt',
|
|
|
isMobile: false,
|
|
@@ -132,8 +133,8 @@ export default {
|
|
|
],
|
|
|
};
|
|
|
},
|
|
|
- async asyncData(params) {
|
|
|
- let { route } = params;
|
|
|
+ async asyncData({ route, req }) {
|
|
|
+ const headers = req && req.headers ? Object.assign({}, req.headers) : {};
|
|
|
let { data } = await axios.post(`${baseURL}/denet/post/treasure/invite/detail`, {
|
|
|
baseInfo: {
|
|
|
appVersionCode: appVersionCode,
|
|
@@ -152,6 +153,7 @@ export default {
|
|
|
return {
|
|
|
detail: data.data,
|
|
|
pageLink,
|
|
|
+ headers,
|
|
|
};
|
|
|
}
|
|
|
},
|
|
@@ -159,6 +161,7 @@ export default {
|
|
|
this.getConfig();
|
|
|
},
|
|
|
mounted() {
|
|
|
+ console.log('header', this.headers);
|
|
|
this.setCookieMid();
|
|
|
Cookies.set(this.detail.postId, JSON.stringify({ inviteCode: this.$route.params.id, channel: this.$route.params.channel }), { expires: 100 });
|
|
|
this.setTreasureInfo();
|