diff --git a/src/components/Modal/ModalRegistration/ModalRegistration.jsx b/src/components/Modal/ModalRegistration/ModalRegistration.jsx index 1c6fba03..bbe925d3 100644 --- a/src/components/Modal/ModalRegistration/ModalRegistration.jsx +++ b/src/components/Modal/ModalRegistration/ModalRegistration.jsx @@ -33,8 +33,8 @@ export const ModalRegistration = ({ active, setActive }) => { userName: "", email: "", password: "", - }) - } + }); + }; const { showNotification } = useNotification(); const submitHandler = () => { @@ -47,7 +47,7 @@ export const ModalRegistration = ({ active, setActive }) => { }, }).then(() => { setActive(false); - resetInputsValue() + resetInputsValue(); showNotification({ show: true, text: "Аккаунт успешно создан", diff --git a/src/components/Navigation/Navigation.jsx b/src/components/Navigation/Navigation.jsx index cac1c4ae..b0c92e9b 100644 --- a/src/components/Navigation/Navigation.jsx +++ b/src/components/Navigation/Navigation.jsx @@ -77,7 +77,11 @@ export const Navigation = () => { return; } apiRequest(`/user/me`).then((profileInfo) => - dispatch(setProfileInfo(profileInfo.userCard ? profileInfo.userCard : profileInfo)) + dispatch( + setProfileInfo( + profileInfo.userCard ? profileInfo.userCard : profileInfo + ) + ) ); }, [dispatch]); diff --git a/src/components/ProfileCalendar/ProfileCalendar.jsx b/src/components/ProfileCalendar/ProfileCalendar.jsx index 9100e55f..55c701ff 100644 --- a/src/components/ProfileCalendar/ProfileCalendar.jsx +++ b/src/components/ProfileCalendar/ProfileCalendar.jsx @@ -22,8 +22,9 @@ import { Navigation } from "@components/Navigation/Navigation"; import { ProfileBreadcrumbs } from "@components/ProfileBreadcrumbs/ProfileBreadcrumbs"; import { ProfileHeader } from "@components/ProfileHeader/ProfileHeader"; -import { ProfileCalendarComponent } from "./ProfileCalendarComponent"; import avatarMok from "assets/images/avatarMok.png"; + +import { ProfileCalendarComponent } from "./ProfileCalendarComponent"; import "./profileCalendar.scss"; export const ProfileCalendar = () => { @@ -95,14 +96,15 @@ export const ProfileCalendar = () => {
avatar

- {profileInfo?.fio ? profileInfo?.fio : profileInfo?.username}, {profileInfo.specification} разработчик + {profileInfo?.fio ? profileInfo?.fio : profileInfo?.username},{" "} + {profileInfo.specification} разработчик

diff --git a/src/components/ProfileHeader/ProfileHeader.jsx b/src/components/ProfileHeader/ProfileHeader.jsx index dce0506f..ea7d98bd 100644 --- a/src/components/ProfileHeader/ProfileHeader.jsx +++ b/src/components/ProfileHeader/ProfileHeader.jsx @@ -2,7 +2,7 @@ import React, { useEffect, useState } from "react"; import { useDispatch, useSelector } from "react-redux"; import { NavLink, useNavigate } from "react-router-dom"; -import {auth, getProfileInfo, setProfileInfo} from "@redux/outstaffingSlice"; +import { auth, getProfileInfo, setProfileInfo } from "@redux/outstaffingSlice"; import { getRole } from "@redux/roleSlice"; import { apiRequest } from "@api/request"; @@ -30,7 +30,11 @@ export const ProfileHeader = () => { return; } apiRequest(`/user/me`).then((profileInfo) => { - dispatch(setProfileInfo(profileInfo.userCard ? profileInfo.userCard : profileInfo)) + dispatch( + setProfileInfo( + profileInfo.userCard ? profileInfo.userCard : profileInfo + ) + ); }); }, [dispatch]); diff --git a/src/pages/Profile/Profile.js b/src/pages/Profile/Profile.js index 6ba757d1..e8be662a 100644 --- a/src/pages/Profile/Profile.js +++ b/src/pages/Profile/Profile.js @@ -121,7 +121,8 @@ export const Profile = () => {

{user === "developer" ? ( - {profileInfo?.fio ? profileInfo?.fio : profileInfo?.username}, {profileInfo?.specification} разработчик + {profileInfo?.fio ? profileInfo?.fio : profileInfo?.username},{" "} + {profileInfo?.specification} разработчик ) : ( "ООО НДВ Консалтинг" diff --git a/src/pages/Summary/Summary.js b/src/pages/Summary/Summary.js index 8144a31c..8027eedb 100644 --- a/src/pages/Summary/Summary.js +++ b/src/pages/Summary/Summary.js @@ -16,9 +16,9 @@ import { ProfileHeader } from "@components/ProfileHeader/ProfileHeader"; import rightArrow from "assets/icons/arrows/arrowRight.svg"; import arrow from "assets/icons/arrows/left-arrow.png"; import gitImgItem from "assets/icons/gitItemImg.svg"; +import avatarMok from "assets/images/avatarMok.png"; import "./summary.scss"; -import avatarMok from "assets/images/avatarMok.png"; export const Summary = () => { if (localStorage.getItem("role_status") === "18") { @@ -58,13 +58,16 @@ export const Summary = () => {

avatar

- {profileInfo?.fio ? profileInfo?.fio : profileInfo?.username}, {profileInfo.specification} разработчик + {profileInfo?.fio ? profileInfo?.fio : profileInfo?.username},{" "} + {profileInfo.specification} разработчик

{!openGit && (