From c4d44e38556bb4bc1ddb1ca5fabaa17d97a11655 Mon Sep 17 00:00:00 2001 From: Z1chi Date: Mon, 9 Jan 2023 20:53:23 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9F=D0=BE=D0=B4=D0=BA=D0=BB=D1=8E=D1=87?= =?UTF-8?q?=D0=B8=D0=BB=20=D1=88=D1=80=D0=B8=D1=84=D1=82=D1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Calendar/Calendar.js | 116 +++---- src/components/Calendar/calendar.scss | 6 +- .../Calendar/calendarComponent.scss | 6 +- .../OutstaffingBlock/outstaffingBlock.scss | 2 + src/components/Profile/profile.scss | 1 + src/components/Profile/profileHeader.scss | 1 + src/components/Profile/summary.scss | 1 + .../ProfileCalendar/profileCalendar.scss | 2 +- src/components/ReportForm/ReportForm.js | 303 +++++++++--------- src/fonts/LabGrotesque-Bold.eot | Bin 0 -> 113402 bytes src/fonts/LabGrotesque-Bold.ttf | Bin 0 -> 113208 bytes src/fonts/LabGrotesque-Bold.woff | Bin 0 -> 51000 bytes src/fonts/LabGrotesque-Bold.woff2 | Bin 0 -> 35508 bytes src/fonts/LabGrotesque-Light.eot | Bin 0 -> 113894 bytes src/fonts/LabGrotesque-Light.ttf | Bin 0 -> 113696 bytes src/fonts/LabGrotesque-Light.woff | Bin 0 -> 51064 bytes src/fonts/LabGrotesque-Light.woff2 | Bin 0 -> 35568 bytes src/fonts/LabGrotesque-Medium.eot | Bin 0 -> 114502 bytes src/fonts/LabGrotesque-Medium.ttf | Bin 0 -> 114300 bytes src/fonts/LabGrotesque-Medium.woff | Bin 0 -> 51968 bytes src/fonts/LabGrotesque-Medium.woff2 | Bin 0 -> 36340 bytes src/fonts/LabGrotesque-Regular.eot | Bin 0 -> 114406 bytes src/fonts/LabGrotesque-Regular.ttf | Bin 0 -> 114200 bytes src/fonts/LabGrotesque-Regular.woff | Bin 0 -> 51924 bytes src/fonts/LabGrotesque-Regular.woff2 | Bin 0 -> 36360 bytes src/fonts/stylesheet.css | 41 +++ src/pages/Profile.js | 48 +-- src/server/server.js | 70 ++-- 28 files changed, 305 insertions(+), 292 deletions(-) create mode 100644 src/fonts/LabGrotesque-Bold.eot create mode 100644 src/fonts/LabGrotesque-Bold.ttf create mode 100644 src/fonts/LabGrotesque-Bold.woff create mode 100644 src/fonts/LabGrotesque-Bold.woff2 create mode 100644 src/fonts/LabGrotesque-Light.eot create mode 100644 src/fonts/LabGrotesque-Light.ttf create mode 100644 src/fonts/LabGrotesque-Light.woff create mode 100644 src/fonts/LabGrotesque-Light.woff2 create mode 100644 src/fonts/LabGrotesque-Medium.eot create mode 100644 src/fonts/LabGrotesque-Medium.ttf create mode 100644 src/fonts/LabGrotesque-Medium.woff create mode 100644 src/fonts/LabGrotesque-Medium.woff2 create mode 100644 src/fonts/LabGrotesque-Regular.eot create mode 100644 src/fonts/LabGrotesque-Regular.ttf create mode 100644 src/fonts/LabGrotesque-Regular.woff create mode 100644 src/fonts/LabGrotesque-Regular.woff2 diff --git a/src/components/Calendar/Calendar.js b/src/components/Calendar/Calendar.js index 1e4dbf20..3c414f38 100644 --- a/src/components/Calendar/Calendar.js +++ b/src/components/Calendar/Calendar.js @@ -1,92 +1,64 @@ -import React, { useEffect, useState } from 'react' -import { useDispatch, useSelector } from 'react-redux' -import { selectCurrentCandidate, auth } from '../../redux/outstaffingSlice' -import { Link, useHistory, useParams } from 'react-router-dom' -import calendarMale from '../../images/medium_male.png' -import rectangle from '../../images/rectangle_secondPage.png' -import CalendarComponent from './CalendarComponent' -import { currentMonth } from './calendarHelper' -import { Footer } from '../Footer/Footer' +import React, {useEffect, useState} from 'react' +import {useSelector} from 'react-redux' +import {selectCurrentCandidate} from '../../redux/outstaffingSlice' +import {Link} from 'react-router-dom' -import { fetchReportList } from '../../server/server' -import { getRole } from '../../redux/roleSlice' +import CalendarComponent from './CalendarComponent' +import {currentMonth} from './calendarHelper' +import {Footer} from '../Footer/Footer' + +import rectangle from '../../images/rectangle_secondPage.png' import './calendar.scss' -const getDateParamString = ({ paramName, value }) => { - return value ? `${paramName}=${value}` : '' -} +const Calendar = ({onSelect}) => { -const Calendar = ({ onSelect }) => { - const dispatch = useDispatch() - const candidateForCalendar = useSelector(selectCurrentCandidate) - const role = useSelector(getRole) - const { userId } = useParams() - const [month, setMonth] = useState('') - const [fromDate, setFromDate] = useState(null) - const [toDate, setToDate] = useState(null) + const candidateForCalendar = useSelector(selectCurrentCandidate); - const history = useHistory() - - // useEffect(() => { - // fetchReportList({ - // link: `${ - // process.env.REACT_APP_API_URL - // }/api/reports/index?user_id=${userId}${getDateParamString({ - // paramName: 'fromDate', - // value: fromDate - // })}${getDateParamString({ - // paramName: 'toDate', - // value: toDate - // })}`, - // history, - // role, - // logout: () => {} - // }) - // }, []) + const [month, setMonth] = useState(''); useEffect(() => { setMonth(currentMonth) - }, [month]) + }, [month]); - const { name, skillsName, photo } = candidateForCalendar + const {name, skillsName, photo} = candidateForCalendar; - const abbreviatedName = name && name.substring(0, name.lastIndexOf(' ')) + const abbreviatedName = name && name.substring(0, name.lastIndexOf(' ')); return ( -
-
-

- Добрый день, Александр ! -

-
-
- img -

{abbreviatedName}

-
-
-

{skillsName} разработчик

- img -
-
- - - +
+
+

+ Добрый день, Александр ! +

+
+
+ img +

{abbreviatedName}

+
+
+

{skillsName} разработчик

+ img +
+
+ + + +
-
-
-
- -

- {month} : 60 часов -

+
+
+ +

+ {month} : 60 часов +

+
-
-
-
+