Commit f8dfc160 authored by Ermolaev Timur's avatar Ermolaev Timur

Merge branch 'task-147-feature/disabled_draganddrop_after_deadline' into 'development'

#147 Реализовал неактивные клетки при драгэнддропе

See merge request !113
parents 1334d0ce 45397aa7
...@@ -56,10 +56,12 @@ const CalendarTask = ({ setCurrentTask, handleOpen, task, setCopyTask, width, le ...@@ -56,10 +56,12 @@ const CalendarTask = ({ setCurrentTask, handleOpen, task, setCopyTask, width, le
const dragStartHandler = useCallback((e, task) => { const dragStartHandler = useCallback((e, task) => {
setCurrentTask(task); setCurrentTask(task);
setCopyTask(task)
},[setCurrentTask]) },[setCurrentTask])
const dragEndHandler = useCallback((e) => { const dragEndHandler = useCallback((e) => {
e.target.style.boxShadow = 'none' e.target.style.boxShadow = 'none'
setCopyTask(null)
},[]) },[])
const onClickCopyIconHandler = useCallback((e) => { const onClickCopyIconHandler = useCallback((e) => {
......
...@@ -66,10 +66,12 @@ function CalendarWeekTask({ height, width, left, top, task, zIndex, handleOpen, ...@@ -66,10 +66,12 @@ function CalendarWeekTask({ height, width, left, top, task, zIndex, handleOpen,
} }
} }
}); });
setCopyTask(task)
} }
const dragEndHandler = (e) => { const dragEndHandler = (e) => {
e.target.style.boxShadow = 'none' e.target.style.boxShadow = 'none'
setCopyTask(null)
} }
const dragOverHandler = (e) => { const dragOverHandler = (e) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment