module-menu 0.3.14 → 0.3.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "module-menu",
3
- "version": "0.3.14",
3
+ "version": "0.3.15",
4
4
  "description": "城市大数据平台公共头部及尾部",
5
5
  "main": "src/pages/index.jsx",
6
6
  "scripts": {
@@ -2,7 +2,7 @@ import { message } from 'antd';
2
2
  import axios from 'axios';
3
3
  import baseCof from './config';
4
4
  import getStore from './userInfo';
5
- import { checkToken, getLoginUrl } from './permessionUtils';
5
+ import { checkToken } from './permessionUtils';
6
6
  import CONSTANT from './constant';
7
7
 
8
8
  let tokenValue = '5de3ef8171364d6ba756221655fe1310';
@@ -16,23 +16,6 @@ const stash = localStorage.getItem('stash');
16
16
  axios.interceptors.response.use(
17
17
  (response) => {
18
18
  if (response.status === 200) {
19
- if (!tokenInSessionStor && response?.data?.code === 401) {
20
- getLoginUrl()
21
- .then((res) => {
22
- if (res?.data?.data?.loginoutUrl) {
23
- console.log('Login URL found:', res.data.data.loginoutUrl);
24
- window.location.replace(res.data.data.loginoutUrl);
25
- } else {
26
- console.log('No login URL found, redirect to default login page.');
27
- window.location.replace('/admin-ui/login');
28
- }
29
- })
30
- .catch((e) => {
31
- console.log('GetLoginUrl error: ', e);
32
- window.location.replace('/admin-ui/login');
33
- });
34
- return
35
- }
36
19
  return response;
37
20
  } else if (
38
21
  response.status === 401 ||