diff --git a/src/components/popup/SuitableDetailPopupButton.tsx b/src/components/popup/SuitableDetailPopupButton.tsx index 8340f94..06bb8d0 100644 --- a/src/components/popup/SuitableDetailPopupButton.tsx +++ b/src/components/popup/SuitableDetailPopupButton.tsx @@ -9,10 +9,12 @@ export default function SuitableDetailPopupButton() { const popupController = usePopupController() const { downloadSuitablePdf } = useSuitable() + /* 상세 팝업 닫기 */ const handleClosePopup = () => { popupController.setSuitableDetailPopup(false) } + /* 페이지 이동 */ const handleRedirectPage = (path: string) => { handleClosePopup() router.push(path) diff --git a/src/components/suitable/SuitableButton.tsx b/src/components/suitable/SuitableButton.tsx index b651a26..3ce8a3c 100644 --- a/src/components/suitable/SuitableButton.tsx +++ b/src/components/suitable/SuitableButton.tsx @@ -9,10 +9,12 @@ export default function SuitableButton() { const { getSuitableIds, clearSuitableStore, downloadSuitablePdf } = useSuitable() const { selectedItems, addAllSelectedItem } = useSuitableStore() + /* 데이터 전체 선택 */ const handleSelectAll = async () => { addAllSelectedItem(await getSuitableIds()) } + /* 상세 팝업 열기 */ const handleOpenPopup = () => { if (selectedItems.size === 0) { alert('屋根材を選択してください。') @@ -21,6 +23,7 @@ export default function SuitableButton() { popupController.setSuitableDetailPopup(true) } + /* pdf 다운로드 */ const handleRedirectPdfDownload = () => { if (selectedItems.size === 0) { alert('屋根材を選択してください。')