Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

后台模式接口返回401状态码后,重新登录无法获取后台的菜单数据。 #772

Closed
zuihou opened this issue Jun 17, 2021 · 3 comments

Comments

@zuihou
Copy link

zuihou commented Jun 17, 2021

访问任意后台接口,后台报401,然后执行了checkStatus.ts的代码:

      userStore.setToken(undefined);
      userStore.setSessionTimeout(true);

重新登录后,没有执行src/store/modules/permission.ts 中的 buildRoutesAction 方法的代码,导致没有拉取后台的菜单。

@zuihou
Copy link
Author

zuihou commented Jun 17, 2021

image

#673

跟这个问题有点像。

@mynetfan
Copy link
Collaborator

请将checkStatus.ts中的userStore.setSessionTimeout(true);改为userStore.logout(true);

@anncwb anncwb closed this as completed in 0d07084 Jun 17, 2021
@anncwb
Copy link
Collaborator

anncwb commented Jun 17, 2021

image

@github-actions github-actions bot locked and limited conversation to collaborators Sep 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants