module-menu 0.2.11 → 0.2.13
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
|
@@ -29,18 +29,26 @@ const ModuleMenu = ({ sysName, stash }) => {
|
|
|
29
29
|
setCanOperatExchange(true);
|
|
30
30
|
}
|
|
31
31
|
} else {
|
|
32
|
-
Axios(
|
|
32
|
+
Axios(
|
|
33
|
+
'get',
|
|
34
|
+
'/admin-api/system/user/get-user-menu-List?menuName=数据平台',
|
|
35
|
+
'',
|
|
36
|
+
{},
|
|
37
|
+
)
|
|
33
38
|
.then((res) => {
|
|
34
39
|
if (res.data.code === 0) {
|
|
35
40
|
let menuGet =
|
|
36
|
-
res.data.data &&
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
(res.data.data &&
|
|
42
|
+
res.data.data[0]?.routes?.map((item) => {
|
|
43
|
+
return {
|
|
44
|
+
...item,
|
|
45
|
+
path:
|
|
46
|
+
item.path.indexOf('/') !== -1
|
|
47
|
+
? item.path
|
|
48
|
+
: '/' + item.path,
|
|
49
|
+
};
|
|
50
|
+
})) ||
|
|
51
|
+
[];
|
|
44
52
|
setSessionMenu(menuGet);
|
|
45
53
|
const menuLists = getNewMenuList(menuGet);
|
|
46
54
|
setMenuList(menuLists);
|
|
@@ -68,6 +76,7 @@ const ModuleMenu = ({ sysName, stash }) => {
|
|
|
68
76
|
message.warning('没有获取到菜单列表,请联系管理员添加权限');
|
|
69
77
|
return;
|
|
70
78
|
}
|
|
79
|
+
|
|
71
80
|
if (nameStr === '政务共享交换平台') {
|
|
72
81
|
Axios('get', '/admin/social/logoutUri', '', {})
|
|
73
82
|
.then((res) => {
|
|
@@ -128,6 +137,10 @@ const ModuleMenu = ({ sysName, stash }) => {
|
|
|
128
137
|
case '资源管理':
|
|
129
138
|
thirdPartyServiceJumpPath = '/admin-ui/resource/tableResource/list';
|
|
130
139
|
break;
|
|
140
|
+
case '供需对接':
|
|
141
|
+
thirdPartyServiceJumpPath =
|
|
142
|
+
'/admin-ui/supply-and-demand-docking/dataRequirement/propose/list';
|
|
143
|
+
break;
|
|
131
144
|
default:
|
|
132
145
|
break;
|
|
133
146
|
}
|
|
@@ -24,7 +24,21 @@ const ModuleUser = ({ stash }) => {
|
|
|
24
24
|
const handleClickmenu = (url) => {
|
|
25
25
|
window.location.href = url;
|
|
26
26
|
};
|
|
27
|
-
|
|
27
|
+
const handleClickSysManage = () => {
|
|
28
|
+
if (!stash) {
|
|
29
|
+
window.location.href = '/#/admin/user/index';
|
|
30
|
+
} else {
|
|
31
|
+
Axios('get', '/admin-api/system/auth/homePage', '', {})
|
|
32
|
+
.then((res) => {
|
|
33
|
+
if (res.data.code === 0) {
|
|
34
|
+
window.location.href = `/admin-ui${res.data.data.path}`;
|
|
35
|
+
} else {
|
|
36
|
+
message.warning(res.data.msg || '获取系统管理页面路由信息失败');
|
|
37
|
+
}
|
|
38
|
+
})
|
|
39
|
+
.catch((e) => console.log('e', e));
|
|
40
|
+
}
|
|
41
|
+
};
|
|
28
42
|
const {
|
|
29
43
|
PersonalCenterSrc,
|
|
30
44
|
MessageCenterSrc,
|
|
@@ -139,7 +153,11 @@ const ModuleUser = ({ stash }) => {
|
|
|
139
153
|
<Menu.Item
|
|
140
154
|
key="personalCenter"
|
|
141
155
|
onClick={() =>
|
|
142
|
-
handleClickmenu(
|
|
156
|
+
handleClickmenu(
|
|
157
|
+
!stash
|
|
158
|
+
? '/#/info/index'
|
|
159
|
+
: '/admin-ui/data-share-portal/personal/info',
|
|
160
|
+
)
|
|
143
161
|
}
|
|
144
162
|
>
|
|
145
163
|
<img
|
|
@@ -147,19 +165,10 @@ const ModuleUser = ({ stash }) => {
|
|
|
147
165
|
alt=""
|
|
148
166
|
style={{ marginRight: '10px', marginTop: '-3px' }}
|
|
149
167
|
/>
|
|
150
|
-
<span
|
|
168
|
+
<span>{!stash ? '个人中心' : '用户中心'}</span>
|
|
151
169
|
</Menu.Item>
|
|
152
170
|
{isHaveSystemManagementPermission && (
|
|
153
|
-
<Menu.Item
|
|
154
|
-
key="systemManage"
|
|
155
|
-
onClick={() =>
|
|
156
|
-
handleClickmenu(
|
|
157
|
-
!stash
|
|
158
|
-
? '/#/admin/user/index'
|
|
159
|
-
: '/admin-ui/bpm/manager/user-group',
|
|
160
|
-
)
|
|
161
|
-
}
|
|
162
|
-
>
|
|
171
|
+
<Menu.Item key="systemManage" onClick={handleClickSysManage}>
|
|
163
172
|
<img
|
|
164
173
|
src={SystemManageSrc}
|
|
165
174
|
alt=""
|
package/src/pages/index.jsx
CHANGED