From c8957ce0da3d14dc6df7ea0676c9c3ec22324ae5 Mon Sep 17 00:00:00 2001 From: leedj312 Date: Mon, 25 Aug 2025 14:31:16 +0900 Subject: [PATCH] =?UTF-8?q?=EC=8B=9C=EC=84=A4=20=ED=98=84=ED=99=A9=20?= =?UTF-8?q?=EB=B0=8F=20=EA=B1=B4=EC=B6=95=EB=AC=BC=20=EA=B4=80=EB=A0=A8=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../splyPopup/searchBar/searchBar.tsx | 9 +- .../ruseFcltMng/fcltSttn/htdflSttn/page.tsx | 11 +- .../ruseFcltMng/fcltSttn/rainSttn/page.tsx | 18 +- .../ruseFcltMng/fcltSttn/rswtSttn/page.tsx | 15 +- apps/wr/app/store/common/code/basicCode.tsx | 31 +-- apps/wr/app/store/common/code/index.ts | 184 ++++++++---------- .../ruseFcltMng/fcltSttn/htdflSttn/index.tsx | 12 +- .../ruseFcltMng/fcltSttn/rainSttn/index.tsx | 14 +- .../ruseFcltMng/fcltSttn/rswtSttn/index.tsx | 13 +- 9 files changed, 152 insertions(+), 155 deletions(-) diff --git a/apps/wr/app/(popUp-layout)/splyPopup/searchBar/searchBar.tsx b/apps/wr/app/(popUp-layout)/splyPopup/searchBar/searchBar.tsx index ce5c6d1ae..0f5430771 100644 --- a/apps/wr/app/(popUp-layout)/splyPopup/searchBar/searchBar.tsx +++ b/apps/wr/app/(popUp-layout)/splyPopup/searchBar/searchBar.tsx @@ -5,7 +5,7 @@ import { type SelectDataType, } from "@common/business_components/ui"; import { Button, Label } from "@common/components/ui"; -import { useCallback, useEffect, useState } from "react"; +import { useCallback, useState } from "react"; import SearchInputText from "../SearchInputText/SearchInputText"; export function SearchBar({ @@ -15,7 +15,7 @@ export function SearchBar({ setHasuPk: (hasuPk: any) => void; onApply: () => void; }) { - const { map, code, codeInit, findRuseFclt } = useWrStore( + const { map, code, findRuseFclt } = useWrStore( (state) => state ); const [sidoValue, setSidoValue] = useState(""); @@ -24,10 +24,7 @@ export function SearchBar({ { text: "전체", val: "0" }, ]); - useEffect(() => { - //codeInit(); - }, [codeInit]); - + const initializeSigunData = useCallback( (sidoCd: string) => { if (sidoCd === "0") { diff --git a/apps/wr/app/(with-layout)/ruseFcltMng/fcltSttn/htdflSttn/page.tsx b/apps/wr/app/(with-layout)/ruseFcltMng/fcltSttn/htdflSttn/page.tsx index 46528bcf7..beaa71569 100644 --- a/apps/wr/app/(with-layout)/ruseFcltMng/fcltSttn/htdflSttn/page.tsx +++ b/apps/wr/app/(with-layout)/ruseFcltMng/fcltSttn/htdflSttn/page.tsx @@ -5,6 +5,7 @@ import { btnClass } from "@/app/store/common/code"; import type { customRainBdst } from "@/app/store/ruseFcltMng/fcltReg/rainReg"; +import { htdflSttnSize } from "@/app/store/ruseFcltMng/fcltSttn/htdflSttn"; import { excelDownload, getCity, @@ -57,7 +58,7 @@ export default function HtdflSttn() { const [fcltNm, setFcltNm] = useState(""); useEffect(() => { - htdflSttnSearch(false, pageNation, "20", String(getConValue()), fcltNm, code.cityCd, code.sggCd); + htdflSttnSearch(false, pageNation, htdflSttnSize, String(getConValue()), fcltNm, code.cityCd, code.sggCd); isResetPage(false) }, [pageNation]); @@ -102,7 +103,7 @@ export default function HtdflSttn() { const excelClick = useCallback(() => { isDownloadTriggered.current = true; - htdflSttnSearch(true, 1, String(htdflSttnResCount), String(getConValue()), fcltNm, code.cityCd, code.sggCd); + htdflSttnSearch(true, 1, htdflSttnResCount, String(getConValue()), fcltNm, code.cityCd, code.sggCd); }, [htdflSttnSearch, objSearch, code.cityCd, code.sggCd, fcltNm, htdflSttnResCount]); useEffect(() => { @@ -124,7 +125,7 @@ export default function HtdflSttn() { useEffect(() => { if (!htdflSttn.isInit) { - initHtdfl(false, 1, "20", "0", fcltNm, code.cityCd, code.sggCd); + initHtdfl(false, 1, htdflSttnSize, "0", fcltNm, code.cityCd, code.sggCd); } }, [htdflSttn.isInit, initHtdfl]); @@ -185,7 +186,7 @@ export default function HtdflSttn() {