module-menu 0.2.27 → 0.2.28
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
|
@@ -17,8 +17,8 @@ const ModuleMenu = ({ sysName, stash = '' }) => {
|
|
|
17
17
|
const [showMenuList, setshowMenuList] = useState(false);
|
|
18
18
|
const [menuList, setMenuList] = useState([]);
|
|
19
19
|
const [canOperatExchange, setCanOperatExchange] = useState(false); //是否具有政务共享平台权限
|
|
20
|
-
|
|
21
20
|
useEffect(() => {
|
|
21
|
+
localStorage.setItem('stash', stash)
|
|
22
22
|
getSessionMenu();
|
|
23
23
|
}, []);
|
|
24
24
|
|
|
@@ -16,6 +16,7 @@ const ModuleUser = ({ stash = '' }) => {
|
|
|
16
16
|
const [tenantList, setTenantList] = useState([]);
|
|
17
17
|
const [haveAppSystemPermission, setHaveAppSystemPermission] = useState(false);
|
|
18
18
|
useEffect(() => {
|
|
19
|
+
localStorage.setItem('stash', stash)
|
|
19
20
|
if (stash === 'integration') {
|
|
20
21
|
getTenantList();
|
|
21
22
|
allSystemList();
|
package/src/pages/util/axios.js
CHANGED
|
@@ -5,9 +5,10 @@ import getStore from './userInfo';
|
|
|
5
5
|
import { checkToken} from './permessionUtils';
|
|
6
6
|
|
|
7
7
|
let tokenValue='a39090d9-bf94-4342-9a1d-1b885cc5385b';
|
|
8
|
-
// tokenInSessionStor
|
|
8
|
+
// tokenInSessionStor存在为一体化,不存在为轻量级(GZW跳/data-platform/#/login,否则/#/login)
|
|
9
9
|
const tokenInSessionStor = window.sessionStorage.getItem('bigdata-access_token');
|
|
10
|
-
|
|
10
|
+
// stash=GZW为轻量级国资委 stash=integration 为一体化,其余为其他轻量级
|
|
11
|
+
const stash = localStorage.getItem('stash')
|
|
11
12
|
|
|
12
13
|
axios.interceptors.response.use(
|
|
13
14
|
(response) => {
|
|
@@ -24,7 +25,7 @@ axios.interceptors.response.use(
|
|
|
24
25
|
message.error({content:'用户凭证已过期,请重新登录', onClose: ()=>{
|
|
25
26
|
localStorage.clear();
|
|
26
27
|
sessionStorage.clear();
|
|
27
|
-
window.location.href =
|
|
28
|
+
window.location.href = stash==='GZW'?'/data-platform/#/login': '/#/login';
|
|
28
29
|
}});
|
|
29
30
|
}
|
|
30
31
|
|