|
|
@@ -894,6 +894,7 @@ export default { |
|
|
|
}, |
|
|
|
created() {}, |
|
|
|
mounted() { |
|
|
|
this.initData(); |
|
|
|
/* window.addEventListener("resize", this.onResize, false); */ |
|
|
|
}, |
|
|
|
destroyed(){ |
|
|
@@ -977,18 +978,6 @@ export default { |
|
|
|
async loadParams() { |
|
|
|
let params = this.$route.query; |
|
|
|
if (params) { |
|
|
|
// 获取token |
|
|
|
if (!params.accessToken) { |
|
|
|
this.$toast.loading({ |
|
|
|
message: "数据加载中", |
|
|
|
}); |
|
|
|
let authToken = await this.getAuth(); |
|
|
|
this.$toast.clear() |
|
|
|
this.$store.commit("ssjlToken", authToken); |
|
|
|
} else { |
|
|
|
this.$store.commit("ssjlToken", params.accessToken); |
|
|
|
} |
|
|
|
|
|
|
|
this.emoName = this.$replaceAll(EmotionModel[params.name].name, '抑郁', '忧郁'); |
|
|
|
this.emoType = EmotionModel[params.name].type; |
|
|
|
this.uid = params.uid; |
|
|
@@ -1013,6 +1002,18 @@ export default { |
|
|
|
this.$dayjs(params.date).hour(0).minute(0).second(0).format() |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
|
// 获取token |
|
|
|
if (!params.accessToken) { |
|
|
|
this.$toast.loading({ |
|
|
|
message: "数据加载中", |
|
|
|
}); |
|
|
|
let authToken = await this.getAuth(); |
|
|
|
this.$toast.clear() |
|
|
|
this.$store.commit("ssjlToken", authToken); |
|
|
|
} else { |
|
|
|
this.$store.commit("ssjlToken", params.accessToken); |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
// 获取b端token |
|
|
|