|
|
@ -129,15 +129,17 @@ const Rest = (props) => { |
|
|
|
}, |
|
|
|
]) |
|
|
|
|
|
|
|
const [pepUserCode, setPepUserCode] = useState(''); |
|
|
|
const [pepUserId, setPepUserId] = useState(''); |
|
|
|
const [pepObj, setPepObj] = useState({}); |
|
|
|
const scroll = useMemo(() => ({ y: 248 }), []); |
|
|
|
|
|
|
|
|
|
|
|
const [startDate, setStartDate] = useState('');//开始时间 |
|
|
|
const [endDate, setEndDate] = useState('');//结束时间 |
|
|
|
|
|
|
|
useEffect(() => { |
|
|
|
setPepUserId(history?.location?.search.slice(1)) |
|
|
|
setPepUserCode(history?.location?.search.slice(1).split('-')[0]) |
|
|
|
setPepUserId(history?.location?.search.slice(1).split('-')[1]) |
|
|
|
peopleDetail() |
|
|
|
}, []) |
|
|
|
useEffect(() => { |
|
|
@ -145,7 +147,7 @@ const Rest = (props) => { |
|
|
|
getLeaveOption()//请假信息 |
|
|
|
}, [startDate, endDate]) |
|
|
|
function peopleDetail () { |
|
|
|
dispatch(humanAffairs.getMemberList({ keywordTarget: 'number', keyword: history?.location?.search.slice(1) })).then((res) => {//搜索项企用户 |
|
|
|
dispatch(humanAffairs.getMemberList({ keywordTarget: 'number', keyword: history?.location?.search.slice(1).split('-')[0] })).then((res) => {//搜索项企用户 |
|
|
|
if (res.success) { |
|
|
|
setPepObj(res.payload?.data?.rows[0]) |
|
|
|
} |
|
|
@ -155,7 +157,7 @@ const Rest = (props) => { |
|
|
|
let date = []; |
|
|
|
let showdate = [] |
|
|
|
let showdate1 = [] |
|
|
|
dispatch(humanAffairs.getMemberOvertime({ pepUserId: history?.location?.search.slice(1), startDate: startDate, endDate: endDate })).then((res) => {//搜索项企用户 |
|
|
|
dispatch(humanAffairs.getMemberOvertime({ pepUserId: history?.location?.search.slice(1).split('-')[1], startDate: startDate, endDate: endDate })).then((res) => {//搜索项企用户 |
|
|
|
if (res.success) { |
|
|
|
setTableData(res.payload?.data?.data) |
|
|
|
setTableStatistic(res.payload?.data) |
|
|
@ -279,7 +281,7 @@ const Rest = (props) => { |
|
|
|
function getLeaveOption () {//请假折线图 |
|
|
|
let date = []; |
|
|
|
let showdate = [] |
|
|
|
dispatch(humanAffairs.getMemberVacate({ pepUserId: history?.location?.search.slice(1), startDate: startDate, endDate: endDate })).then((res) => {//搜索项企用户 |
|
|
|
dispatch(humanAffairs.getMemberVacate({ pepUserId: history?.location?.search.slice(1).split('-')[1], startDate: startDate, endDate: endDate })).then((res) => {//搜索项企用户 |
|
|
|
if (res.success) { |
|
|
|
setLeaveData(res.payload?.data?.data) |
|
|
|
let year = 0; |
|
|
@ -430,7 +432,7 @@ const Rest = (props) => { |
|
|
|
<img src="/assets/images/hrImg/back.png" alt="" style={{ width: '100%', height: '100%' }} /> |
|
|
|
</div> |
|
|
|
<div style={{ width: 0, height: 20, borderLeft: '3px solid #0F7EFB', borderTop: '3px solid transparent', borderBottom: '3px solid transparent' }}></div> |
|
|
|
<div style={{ fontFamily: "YouSheBiaoTiHei", fontSize: 24, color: '#033C9A', marginLeft: 8 }}>{pepObj.userName}的个人档案</div> |
|
|
|
<div style={{ fontFamily: "YouSheBiaoTiHei", fontSize: 24, color: '#033C9A', marginLeft: 8 }}>{pepObj?.userName}的个人档案</div> |
|
|
|
</div> |
|
|
|
<div style={{ display: 'flex', marginRight: 20 }}> |
|
|
|
<div style={{ padding: '6px 20px', background: '#0F7EFB', color: '#FFFFFF', fontSize: 14, cursor: "pointer" }} |
|
|
|