提交 8df02642 编写于 作者: guangjun.yang's avatar guangjun.yang

但没有用户信息,则获取用户信息

上级 7324ad04
......@@ -422,11 +422,11 @@ export default {
localStorage.setItem('returnUrl', this.shareUrl);
const { token, info } = this.$store.state.user;
this.token = getCookie("token") || token;
this.token = token || getCookie("token");
// 如果有token,但没有用户信息,则获取用户信息
if (this.token && !info.id) {
this.$store.dispatch("setToken", this.token);
// this.$store.dispatch('getUserInfo');
// this.$store.dispatch("setToken", this.token);
this.$store.dispatch('getUserInfo');
}
this.queryByUuid(this.uuid);
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册