File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,6 @@ import { Link } from "react-router-dom";
1919
2020// type
2121import { projectData } from "@/types/projectData" ;
22- import { projects } from "@/types/deleteProject" ;
2322
2423const ProjectPage = ( ) => {
2524 // value
@@ -33,7 +32,6 @@ const ProjectPage = () => {
3332 const [ editedTitle , setEditedTitle ] = useState < string > ( "" ) ;
3433 const menuRef = useRef < HTMLUListElement | null > ( null ) ;
3534 const orderRef = useRef < HTMLDivElement | null > ( null ) ;
36- const [ deleteProjectList , setDeleteProjectList ] = useState < projects [ ] > ( [ ] ) ;
3735
3836 // modal
3937 type ModalType = "dwn" | "share" | null ;
@@ -48,9 +46,10 @@ const ProjectPage = () => {
4846
4947 const clickProjectDelete = ( projectID : Array < string > ) => {
5048 if ( confirm ( "정말 프로젝트를 삭제하시겠습니까?" ) ) {
51- setDeleteProjectList ( [ { projectId : projectID , type : "project" } ] ) ;
49+ const updatedList = [ { projectId : projectID , type : "project" } ] ;
5250
53- deleteProject ( deleteProjectList ) . then ( ( ) => {
51+ console . log ( updatedList ) ;
52+ deleteProject ( updatedList ) . then ( ( ) => {
5453 alert ( "프로젝트가 정상적으로 삭제되었습니다." ) ;
5554 window . location . reload ( ) ;
5655 } ) ;
You can’t perform that action at this time.
0 commit comments