Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
planner-team-one
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
21
Issues
21
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Евгений Положенцев
planner-team-one
Commits
aeb834b4
Commit
aeb834b4
authored
Dec 21, 2022
by
Ibadullina Inabat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
начала реализовать удаление проекта, продолжу в другой ветке
parent
7e02a2b3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
20 deletions
+28
-20
ProjectItem.js
...c/components/ProjectComponents/ProjectItem/ProjectItem.js
+28
-20
No files found.
planner-front/src/components/ProjectComponents/ProjectItem/ProjectItem.js
View file @
aeb834b4
...
...
@@ -2,33 +2,41 @@ import { Card, CardActions, CardContent, Grid, IconButton } from "@mui/material"
import
{
Link
}
from
"react-router-dom"
;
import
ArrowForwardIcon
from
"@mui/icons-material/ArrowForward"
;
import
{
useDispatch
,
useSelector
}
from
"react-redux"
;
import
DeleteIcon
from
"@mui/icons-material/Delete"
;
const
ProjectItem
=
({
title
,
tasks
,
id
})
=>
{
const
user
=
useSelector
(
state
=>
state
.
users
.
user
);
const
dispatch
=
useDispatch
();
console
.
log
(
user
)
return
<>
<
Grid
item
xs
=
{
12
}
sm
=
{
12
}
md
=
{
6
}
lg
=
{
4
}
>
<
Card
>
<
CardContent
>
<
strong
>
<
br
><
/br
>
Название
проекта
:
{
title
}
<
/strong
>
<
strong
>
<
br
><
/br
>
{
/* Задачи: {tasks} */
}
<
/strong
>
<
/CardContent
>
<
CardActions
>
return
<>
<
Grid
item
xs
=
{
12
}
sm
=
{
12
}
md
=
{
6
}
lg
=
{
4
}
>
<
Card
>
<
CardContent
>
<
strong
>
<
br
><
/br
>
Название
проекта
:
{
title
}
<
/strong
>
<
strong
>
<
br
><
/br
>
{
/* Задачи: {tasks} */
}
<
/strong
>
<
/CardContent
>
<
CardActions
>
<
IconButton
component
=
{
Link
}
to
=
{
"/projects/"
+
id
}
>
<
ArrowForwardIcon
/>
<
/IconButton>
<
/CardActions
>
<
/Card
>
<
/Grid>
<
ArrowForwardIcon
/>
<
/IconButton
>
<
IconButton
onClick
=
{(
id
)
=>
{
// deleteHandle(userId);
}}
>
{(
title
!==
"Личные дела"
)
?
<
DeleteIcon
/>
:
null
}
<
/IconButton
>
<
/CardActions
>
<
/Card
>
<
/Grid
>
<
/
>
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment