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() {