Compare commits

..

No commits in common. "4ea80eb4601fbc222840e66c53ec7e656d77b5d4" and "ef6d8f4331116373ed9b4df7a40318fe034712cd" have entirely different histories.

5 changed files with 13 additions and 23 deletions

View File

@ -120,9 +120,9 @@ const App = () => {
<Route exact path="payouts" element={<Payouts />} /> <Route exact path="payouts" element={<Payouts />} />
<Route exact path="settings" element={<PartnerSettings />} /> <Route exact path="settings" element={<PartnerSettings />} />
<Route exact path="requests" element={<PartnerRequests />} /> <Route exact path="requests" element={<PartnerRequests />} />
<Route exact path="requests-add" element={<PartnerAddRequest />} /> <Route exact path="add-request" element={<PartnerAddRequest />} />
<Route exact path="requests-edit" element={<PartnerAddRequest />} /> <Route exact path="edit-request" element={<PartnerAddRequest />} />
<Route exact path="requests-bid" element={<PartnerBid />} /> <Route exact path="bid" element={<PartnerBid />} />
<Route exact path="employees" element={<PartnerCategories />} /> <Route exact path="employees" element={<PartnerCategories />} />
<Route exact path="employees/report/:uuid" element={<PartnerEmployeeReport />} /> <Route exact path="employees/report/:uuid" element={<PartnerEmployeeReport />} />
<Route exact path="treaties" element={<PartnerTreaties />} /> <Route exact path="treaties" element={<PartnerTreaties />} />

View File

@ -45,7 +45,6 @@ export const Navigation = () => {
partner: [ partner: [
{ {
path: "/catalog", path: "/catalog",
active: "candidate",
name: "Каталог" name: "Каталог"
}, },
{ {
@ -54,7 +53,6 @@ export const Navigation = () => {
}, },
{ {
path: "/employees", path: "/employees",
active: "calendar",
name: "Персонал" name: "Персонал"
}, },
{ {
@ -82,12 +80,7 @@ export const Navigation = () => {
key={index} key={index}
end end
to={link.path === "/Quiz" ? link.path : `/profile${link.path}`} to={link.path === "/Quiz" ? link.path : `/profile${link.path}`}
className={ className={currentPath.includes(link.path) ? "active" : ""}
currentPath.includes(link.path) ||
currentPath.includes(link.active)
? "active"
: ""
}
> >
{link.name} {link.name}
</NavLink> </NavLink>

View File

@ -49,7 +49,7 @@ export const PartnerAddRequest = () => {
const [inputs, setInputs] = useState({ title: "", description: "" }); const [inputs, setInputs] = useState({ title: "", description: "" });
if ( if (
currentUrl[0] === "/profile/requests-edit" && currentUrl[0] === "/profile/edit-request" &&
!Object.keys(partnerRequestInfo).length !Object.keys(partnerRequestInfo).length
) { ) {
return <Navigate to="/profile/requests" replace />; return <Navigate to="/profile/requests" replace />;
@ -69,7 +69,7 @@ export const PartnerAddRequest = () => {
useEffect(() => { useEffect(() => {
if ( if (
currentUrl[0] === "/profile/requests-edit" && currentUrl[0] === "/profile/edit-request" &&
Object.keys(partnerRequestInfo).length Object.keys(partnerRequestInfo).length
) { ) {
setInputs({ setInputs({
@ -102,7 +102,7 @@ export const PartnerAddRequest = () => {
}; };
const handler = () => { const handler = () => {
if (currentUrl[0] === "/profile/requests-edit") { if (currentUrl[0] === "/profile/edit-request") {
apiRequest("/request/update-request", { apiRequest("/request/update-request", {
method: "PUT", method: "PUT",
data: { data: {
@ -180,7 +180,7 @@ export const PartnerAddRequest = () => {
name: `${ name: `${
editRequest ? "Редактирование заявки" : "Создание новой заявки" editRequest ? "Редактирование заявки" : "Создание новой заявки"
}`, }`,
link: "/profile/requests-add" link: "/profile/add-request"
} }
]} ]}
/> />

View File

@ -107,10 +107,7 @@ export const PartnerBid = () => {
links={[ links={[
{ name: "Главная", link: "/profile" }, { name: "Главная", link: "/profile" },
{ name: "Запросы и открытые позиции", link: "/profile/requests" }, { name: "Запросы и открытые позиции", link: "/profile/requests" },
{ { name: "Просмотр заявки - PHP разработчик", link: "/profile/bid" }
name: "Просмотр заявки - PHP разработчик",
link: "/profile/requests-bid"
}
]} ]}
/> />
<h2 className="partner-bid__title">Страница заявки </h2> <h2 className="partner-bid__title">Страница заявки </h2>
@ -120,7 +117,7 @@ export const PartnerBid = () => {
<div className="partner-bid__qualification"> <div className="partner-bid__qualification">
<h3>{requestInfo.title}</h3> <h3>{requestInfo.title}</h3>
<div className="partner-bid__qualification__buttons"> <div className="partner-bid__qualification__buttons">
<Link to="/profile/requests-edit">Редактировать</Link> <Link to="/profile/edit-request">Редактировать</Link>
<img <img
src={deleteBtn} src={deleteBtn}
alt="delete" alt="delete"

View File

@ -60,7 +60,7 @@ export const PartnerRequests = () => {
return ( return (
<Link <Link
key={index} key={index}
to={"/profile/requests-bid"} to={"/profile/bid"}
className="partner-requests__section__item" className="partner-requests__section__item"
onClick={() => { onClick={() => {
dispatch(setPartnerRequestId(item.id)); dispatch(setPartnerRequestId(item.id));
@ -85,7 +85,7 @@ export const PartnerRequests = () => {
параметры: количество сотрудников, стек, уровень специалиста параметры: количество сотрудников, стек, уровень специалиста
</p> </p>
<BaseButton> <BaseButton>
<Link to={"/profile/requests-add"}> <Link to={"/profile/add-request"}>
<span>+</span> <span>+</span>
Создать запрос Создать запрос
</Link> </Link>
@ -100,7 +100,7 @@ export const PartnerRequests = () => {
<img src={cursorImg} alt="cursor" /> <img src={cursorImg} alt="cursor" />
<p>У вас ещё нет запросов на сотрудников</p> <p>У вас ещё нет запросов на сотрудников</p>
<BaseButton> <BaseButton>
<Link to={"/profile/requests-add"}> <Link to={"/profile/add-request"}>
<span>+</span> <span>+</span>
Создать запрос Создать запрос
</Link> </Link>