|
@ -41,6 +41,7 @@ const employeeInformation = (props) => { |
|
|
{ name: "政治面貌", value: "politicsStatus" }, |
|
|
{ name: "政治面貌", value: "politicsStatus" }, |
|
|
{ name: "联系方式", value: "phoneNumber" }, |
|
|
{ name: "联系方式", value: "phoneNumber" }, |
|
|
{ name: "工作地点", value: "workPlace" }, |
|
|
{ name: "工作地点", value: "workPlace" }, |
|
|
|
|
|
{ name: "年龄", value: "age" }, |
|
|
] |
|
|
] |
|
|
}, { |
|
|
}, { |
|
|
title: '学历信息', |
|
|
title: '学历信息', |
|
@ -75,10 +76,8 @@ const employeeInformation = (props) => { |
|
|
localStorage.getItem(EMPLOYEEINFORMATION) == null |
|
|
localStorage.getItem(EMPLOYEEINFORMATION) == null |
|
|
? localStorage.setItem( |
|
|
? localStorage.setItem( |
|
|
EMPLOYEEINFORMATION, |
|
|
EMPLOYEEINFORMATION, |
|
|
JSON.stringify(['userName', 'departmrnt', 'roleName', 'idNumber', 'gender', 'nativePlace', 'birthday', 'marital', 'politicsStatus', 'phoneNumber', 'workPlace', |
|
|
JSON.stringify(['userName', 'departmrnt', 'roleName', 'hiredate', 'age', 'phoneNumber', 'marital', 'politicsStatus', 'educationBackground', |
|
|
'graduatedFrom', 'educationBackground', 'specialty', 'graduationDate', |
|
|
'graduatedFrom', 'employmentLife', 'occupationalHistory']) |
|
|
'hiredate', 'regularDate', 'turnProbationPeriod', 'dimissionDate', 'employmentLife', 'probationPeriodDate', 'experienceYear', |
|
|
|
|
|
'occupationalHistory', 'vitae']) |
|
|
|
|
|
) |
|
|
) |
|
|
: ""; |
|
|
: ""; |
|
|
attribute(); |
|
|
attribute(); |
|
@ -184,8 +183,8 @@ const employeeInformation = (props) => { |
|
|
{ |
|
|
{ |
|
|
r.departmrnt.length > 1 && idx == 1 ? ( |
|
|
r.departmrnt.length > 1 && idx == 1 ? ( |
|
|
<Tooltip content={departmentsArr.join(',')} trigger="click" style={{ lineHeight: 2 }}> |
|
|
<Tooltip content={departmentsArr.join(',')} trigger="click" style={{ lineHeight: 2 }}> |
|
|
<div style={{ padding: '0px 4px 1px 4px ', color: '#FFFFFF', fontSize: 12, background: 'rgba(0,90,189,0.8)', borderRadius: 2, marginRight: 4, cursor: "pointer", }}> |
|
|
<div style={{ padding: '0px 4px 1px 4px ', color: 'rgba(0,90,189,0.8)', fontSize: 12, marginRight: 4, cursor: "pointer", }}> |
|
|
... |
|
|
+{r.departmrnt.length - 1} |
|
|
</div> |
|
|
</div> |
|
|
</Tooltip> |
|
|
</Tooltip> |
|
|
) : ('') |
|
|
) : ('') |
|
@ -207,7 +206,33 @@ const employeeInformation = (props) => { |
|
|
dataIndex: "roleName", |
|
|
dataIndex: "roleName", |
|
|
key: "roleName", |
|
|
key: "roleName", |
|
|
render: (_, r, index) => { |
|
|
render: (_, r, index) => { |
|
|
return (r.roleName ? r.roleName : '-'); |
|
|
return ( |
|
|
|
|
|
<div style={{ color: '#4A4A4A', fontSize: 12, display: 'flex', alignItems: 'center' }}> |
|
|
|
|
|
{ |
|
|
|
|
|
r.role.map((ite, idx) => { |
|
|
|
|
|
let roleArr = [] |
|
|
|
|
|
for (let i = 0; i < r.role.length; i++) { |
|
|
|
|
|
roleArr.push(r.role[i].name) |
|
|
|
|
|
} |
|
|
|
|
|
return ( |
|
|
|
|
|
<div key={idx} style={{ display: 'flex', alignItems: 'center' }}> |
|
|
|
|
|
{idx == 0 ? |
|
|
|
|
|
(ite.name) : ('') |
|
|
|
|
|
} |
|
|
|
|
|
{ |
|
|
|
|
|
r.role.length > 1 && idx == 1 ? ( |
|
|
|
|
|
<Tooltip content={roleArr.join(',')} trigger="click" style={{ lineHeight: 2 }}> |
|
|
|
|
|
<div style={{ color: 'rgba(0,90,189,0.8)', fontSize: 12, marginRight: 4, cursor: "pointer", }}> |
|
|
|
|
|
+{r.role.length - 1} |
|
|
|
|
|
</div> |
|
|
|
|
|
</Tooltip> |
|
|
|
|
|
) : ('') |
|
|
|
|
|
} |
|
|
|
|
|
</div> |
|
|
|
|
|
) |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
</div>); |
|
|
}, |
|
|
}, |
|
|
}, { |
|
|
}, { |
|
|
title: '证件号', |
|
|
title: '证件号', |
|
@ -238,7 +263,6 @@ const employeeInformation = (props) => { |
|
|
width: 120, |
|
|
width: 120, |
|
|
dataIndex: "birthday", |
|
|
dataIndex: "birthday", |
|
|
key: "birthday", |
|
|
key: "birthday", |
|
|
sorter: (a, b) => { }, |
|
|
|
|
|
render: (_, r, index) => { |
|
|
render: (_, r, index) => { |
|
|
return (r.birthday ? r.birthday : '-'); |
|
|
return (r.birthday ? r.birthday : '-'); |
|
|
}, |
|
|
}, |
|
@ -274,6 +298,15 @@ const employeeInformation = (props) => { |
|
|
render: (_, r, index) => { |
|
|
render: (_, r, index) => { |
|
|
return (r.workPlace ? r.workPlace : '-'); |
|
|
return (r.workPlace ? r.workPlace : '-'); |
|
|
}, |
|
|
}, |
|
|
|
|
|
}, { |
|
|
|
|
|
title: '年龄', |
|
|
|
|
|
width: 100, |
|
|
|
|
|
dataIndex: "age", |
|
|
|
|
|
key: "age", |
|
|
|
|
|
sorter: (a, b) => { }, |
|
|
|
|
|
render: (_, r, index) => { |
|
|
|
|
|
return (r.birthday ? moment(new Date()).diff(r.birthday, 'years') + '岁' : '-'); |
|
|
|
|
|
}, |
|
|
}, { |
|
|
}, { |
|
|
title: '毕业院校', |
|
|
title: '毕业院校', |
|
|
width: 200, |
|
|
width: 200, |
|
@ -420,9 +453,9 @@ const employeeInformation = (props) => { |
|
|
<div style={{ display: 'flex' }}> |
|
|
<div style={{ display: 'flex' }}> |
|
|
<div style={{ color: 'rgba(0,0,0,0.45)', fontSize: 14 }}>人事管理</div> |
|
|
<div style={{ color: 'rgba(0,0,0,0.45)', fontSize: 14 }}>人事管理</div> |
|
|
<div style={{ color: 'rgba(0,0,0,0.45)', fontSize: 14, margin: '0px 8px' }}>/</div> |
|
|
<div style={{ color: 'rgba(0,0,0,0.45)', fontSize: 14, margin: '0px 8px' }}>/</div> |
|
|
<div style={{ color: 'rgba(0,0,0,0.45)', fontSize: 14 }}>档案中心</div> |
|
|
<div style={{ color: 'rgba(0,0,0,0.45)', fontSize: 14 }}>员工关系</div> |
|
|
<div style={{ color: '#033C9A', fontSize: 14, margin: '0px 8px' }}>/</div> |
|
|
<div style={{ color: '#033C9A', fontSize: 14, margin: '0px 8px' }}>/</div> |
|
|
<div style={{ color: '#033C9A', fontSize: 14 }}>人员档案</div> |
|
|
<div style={{ color: '#033C9A', fontSize: 14 }}>员工信息</div> |
|
|
</div> |
|
|
</div> |
|
|
<div style={{ background: '#FFFFFF', boxShadow: '0px 0px 12px 2px rgba(220,222,224,0.2)', borderRadius: 2, padding: '20px 0px 20px 19px ', marginTop: 12 }}> |
|
|
<div style={{ background: '#FFFFFF', boxShadow: '0px 0px 12px 2px rgba(220,222,224,0.2)', borderRadius: 2, padding: '20px 0px 20px 19px ', marginTop: 12 }}> |
|
|
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between' }}> |
|
|
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between' }}> |
|
@ -581,11 +614,11 @@ const employeeInformation = (props) => { |
|
|
} else { |
|
|
} else { |
|
|
setOrder({ orderBy: 'code', orderDirection: 'ASC' }) |
|
|
setOrder({ orderBy: 'code', orderDirection: 'ASC' }) |
|
|
} |
|
|
} |
|
|
} else if (sorter.key == 'birthday') { |
|
|
} else if (sorter.key == 'age') { |
|
|
if (sorter.sortOrder == 'descend') { |
|
|
if (sorter.sortOrder == 'descend') { |
|
|
setOrder({ orderBy: 'hiredate', orderDirection: 'DESC' }) |
|
|
setOrder({ orderBy: 'age', orderDirection: 'DESC' }) |
|
|
} else { |
|
|
} else { |
|
|
setOrder({ orderBy: 'hiredate', orderDirection: 'ASC' }) |
|
|
setOrder({ orderBy: 'age', orderDirection: 'ASC' }) |
|
|
} |
|
|
} |
|
|
} else { |
|
|
} else { |
|
|
if (sorter.sortOrder == 'descend') { |
|
|
if (sorter.sortOrder == 'descend') { |
|
|