fix candidate resume

This commit is contained in:
Victor Batischev
2024-04-24 19:20:21 +03:00
parent d49a2eb0c8
commit 3f46d60720
3 changed files with 19 additions and 20 deletions

View File

@ -32,7 +32,7 @@ export const Candidate = () => {
if (localStorage.getItem("role_status") !== "18") {
return <Navigate to="/profile" replace />;
}
// const { id: candidateId } = useParams();
const { id: candidateId } = useParams();
const navigate = useNavigate();
@ -47,7 +47,7 @@ export const Candidate = () => {
}, []);
useEffect(() => {
apiRequest(`/user/me`, {}).then((el) =>
apiRequest(`/resume?userId=${candidateId}`).then((el) =>
dispatch(currentCandidate(el.userCard))
);
}, [dispatch]);
@ -103,9 +103,7 @@ export const Candidate = () => {
link: "/profile/catalog"
},
{
name: `${currentCandidateObj.specification} ${
SKILLS[currentCandidateObj.position_id]
}, ${LEVELS[currentCandidateObj.level]}`,
name: `${currentCandidateObj.fio}`,
link: `/candidate/${currentCandidateObj.id}`
}
]}
@ -115,6 +113,7 @@ export const Candidate = () => {
<div className="col-12 candidate__header">
<div className="candidate__header__left">
<h3>
{currentCandidateObj.fio} &nbsp;{" "}
{currentCandidateObj.specification} &nbsp;{" "}
{SKILLS[currentCandidateObj.position_id]} &nbsp;{" "}
{LEVELS[currentCandidateObj.level]}