module-menu 0.3.0 → 0.3.2
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 +1 -1
- package/src/assets/crbd.png +0 -0
- package/src/assets/dzcrb.png +0 -0
- package/src/assets/ggws.png +0 -0
- package/src/assets/sjzyzx.png +0 -0
- package/src/assets/userLogo1.png +0 -0
- package/src/assets/yjzyk.png +0 -0
- package/src/assets/ztk.png +0 -0
- package/src/pages/ModuleMenu/constData.jsx +32 -0
- package/src/pages/ModuleMenu/index.jsx +10 -4
- package/src/pages/ModuleMenu/index.less +20 -0
- package/src/pages/ModuleUser/index.jsx +6 -1
package/package.json
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -349,3 +349,35 @@ export const sysNameMap = (stash = '') => [
|
|
|
349
349
|
logoSrc: stash !=='LNRD'? require('../../assets/alert_logo.svg'): require('../../assets/alert_logo_LNRD.svg'),
|
|
350
350
|
},
|
|
351
351
|
];
|
|
352
|
+
|
|
353
|
+
export const menuList_HBJK = [{
|
|
354
|
+
name: '数据资源中心',
|
|
355
|
+
url: require('../../assets/sjzyzx.png'),
|
|
356
|
+
children: [
|
|
357
|
+
{
|
|
358
|
+
childName: '公共卫生监测人口库',
|
|
359
|
+
path: '/datamanage',
|
|
360
|
+
url:require('../../assets/ggws.png'),
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
childName: '电子传染病档案库',
|
|
364
|
+
path: '/datamanage',
|
|
365
|
+
url:require('../../assets/dzcrb.png'),
|
|
366
|
+
},
|
|
367
|
+
{
|
|
368
|
+
childName: '应急资源库',
|
|
369
|
+
path: '/datamanage',
|
|
370
|
+
url:require('../../assets/yjzyk.png'),
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
childName: '传染病防控知识库',
|
|
374
|
+
path: '/datamanage',
|
|
375
|
+
url:require('../../assets/crbd.png'),
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
childName: '主题库',
|
|
379
|
+
path: '/datamanage',
|
|
380
|
+
url:require('../../assets/ztk.png'),
|
|
381
|
+
},
|
|
382
|
+
]
|
|
383
|
+
}]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useState, useEffect, useRef, useMemo } from 'react';
|
|
2
2
|
import { Popconfirm, message, Popover } from 'antd';
|
|
3
|
-
import { menuList as menuListInit, menuIconSrc, sysNameMap } from './constData';
|
|
3
|
+
import { menuList as menuListInit, menuIconSrc, sysNameMap, menuList_HBJK} from './constData';
|
|
4
4
|
import HeaderDropdown from '../ModuleUser/HeaderDropdown';
|
|
5
5
|
import { getInfoByName, getUrlByInfo } from './service.js'
|
|
6
6
|
import Axios from '../util/axios';
|
|
@@ -247,6 +247,9 @@ const ModuleMenu = ({ sysName, stash = '' }) => {
|
|
|
247
247
|
newMenuList.splice(index, 1);
|
|
248
248
|
}
|
|
249
249
|
}
|
|
250
|
+
}
|
|
251
|
+
if (stash === 'HBJK') {
|
|
252
|
+
newMenuList = newMenuList.concat(menuList_HBJK);
|
|
250
253
|
}
|
|
251
254
|
return newMenuList;
|
|
252
255
|
};
|
|
@@ -265,7 +268,7 @@ const ModuleMenu = ({ sysName, stash = '' }) => {
|
|
|
265
268
|
}}
|
|
266
269
|
>
|
|
267
270
|
<div
|
|
268
|
-
className=
|
|
271
|
+
className={stash === 'HBJK' ? 'leftMenu_HBJK' : 'leftMenu'}
|
|
269
272
|
style={{
|
|
270
273
|
height:
|
|
271
274
|
item.children.length > 6
|
|
@@ -281,7 +284,10 @@ const ModuleMenu = ({ sysName, stash = '' }) => {
|
|
|
281
284
|
: '70px',
|
|
282
285
|
}}
|
|
283
286
|
>
|
|
284
|
-
<img src={item.url} className={
|
|
287
|
+
<img src={item.url} className={
|
|
288
|
+
stash === 'HBJK' ? 'middle_HBJK' :
|
|
289
|
+
stash !== 'LNRD' ? 'middle' : 'middle_LNRD'
|
|
290
|
+
} />
|
|
285
291
|
<span
|
|
286
292
|
className={cn(stash !== 'LNRD'? 'middle' : 'middle_LNRD', 'textPad')}
|
|
287
293
|
// className=`${{stash !== 'LNRD'? 'middle' : 'middle_LNRD'}} textPad`
|
|
@@ -363,7 +369,7 @@ const ModuleMenu = ({ sysName, stash = '' }) => {
|
|
|
363
369
|
backgroundRepeat: 'no-repeat',
|
|
364
370
|
backgroundSize: '50%',
|
|
365
371
|
backgroundPosition: 'center',
|
|
366
|
-
backgroundColor: stash === 'LNRD'? '#EA1A1A': stash === 'HBJK'? '#
|
|
372
|
+
backgroundColor: stash === 'LNRD'? '#EA1A1A': stash === 'HBJK'? '#1373FF' : '#4091F7'
|
|
367
373
|
|
|
368
374
|
}}
|
|
369
375
|
>
|
|
@@ -39,6 +39,16 @@
|
|
|
39
39
|
font-weight: 400;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
+
.leftMenu_HBJK {
|
|
43
|
+
width: 120px;
|
|
44
|
+
float: left;
|
|
45
|
+
color: rgba(0, 0, 0, 0.85);
|
|
46
|
+
font-size: 16px;
|
|
47
|
+
cursor: pointer;
|
|
48
|
+
text-align: left;
|
|
49
|
+
font-weight: 400;
|
|
50
|
+
}
|
|
51
|
+
|
|
42
52
|
.rightMenu {
|
|
43
53
|
width: 460px;
|
|
44
54
|
float: left;
|
|
@@ -67,9 +77,19 @@
|
|
|
67
77
|
display: inline-block;
|
|
68
78
|
}
|
|
69
79
|
|
|
80
|
+
.childMenu_HBJK {
|
|
81
|
+
width: 30%;
|
|
82
|
+
display: inline-block;
|
|
83
|
+
}
|
|
70
84
|
.middle, .middle_LNRD {
|
|
71
85
|
vertical-align: middle;
|
|
72
86
|
}
|
|
87
|
+
|
|
88
|
+
.middle_HBJK {
|
|
89
|
+
vertical-align: middle;
|
|
90
|
+
width: 20px;
|
|
91
|
+
height: 20px;
|
|
92
|
+
}
|
|
73
93
|
// .middle_sub_LNRD {
|
|
74
94
|
// width: 20px;
|
|
75
95
|
// height: 20px;
|
|
@@ -12,6 +12,7 @@ import Axios from '../util/axios';
|
|
|
12
12
|
import getStore, { getUserName } from '../util/userInfo';
|
|
13
13
|
import './index.less';
|
|
14
14
|
import cn from 'classnames'
|
|
15
|
+
import userLogo1 from '../../assets/userLogo1.png';
|
|
15
16
|
|
|
16
17
|
// stash存在则为一体化,否则为轻量级
|
|
17
18
|
const ModuleUser = ({ stash = '' }) => {
|
|
@@ -226,7 +227,11 @@ const ModuleUser = ({ stash = '' }) => {
|
|
|
226
227
|
{getUserName() ? (
|
|
227
228
|
<HeaderDropdown overlay={menu}>
|
|
228
229
|
<span style={{ display: 'inline-block', marginLeft: '12px' }}>
|
|
229
|
-
|
|
230
|
+
{stash === 'HBJK' ? (
|
|
231
|
+
<Avatar size="small" src={userLogo1} />
|
|
232
|
+
) : (
|
|
233
|
+
<Avatar size="small" icon={<UserOutlined />} />
|
|
234
|
+
)}
|
|
230
235
|
<span
|
|
231
236
|
style={{
|
|
232
237
|
marginLeft: '10px',
|