import React, { useEffect } from "react"; import SVG from "react-inlinesvg"; import { useDispatch, useSelector } from "react-redux"; import { Navigate, useNavigate, useParams } from "react-router-dom"; import { currentCandidate, selectCurrentCandidate } from "@redux/outstaffingSlice"; import { LEVELS, SKILLS } from "@utils/constants"; import { urlForLocal } from "@utils/helper"; import { apiRequest } from "@api/request"; import { Footer } from "@components/Common/Footer/Footer"; import Form from "@components/Form/Form"; import { LogoutButton } from "@components/LogoutButton/LogoutButton"; import arrow from "assets/icons/arrows/left-arrow.png"; import telegramIcon from "assets/icons/telegram-icon.svg"; import rectangle from "assets/images/rectangle_secondPage.png"; import "./formPage.scss"; export const FormPage = () => { if (localStorage.getItem("role_status") !== "18") { return ; } const params = useParams(); const navigate = useNavigate(); const dispatch = useDispatch(); const candidate = useSelector(selectCurrentCandidate); const goBack = () => { navigate(-1); }; useEffect(() => { if (!candidate.id) { apiRequest("/profile", { params: Number(params.id) }).then((el) => dispatch(currentCandidate(el))); } }, []); return (
Вернуться к кандидату
{candidate.photo && ( candidate avatar )}
{candidate.specification} {SKILLS[candidate.position_id]},{" "} {LEVELS[candidate.level]}
rectangle Выбранный кандидат
или
Заявка на собеседование через телеграм
); };