From 02ada9925a2b25ab182ba70233db4c1fa3a17a99 Mon Sep 17 00:00:00 2001 From: jyha00 Date: Mon, 7 Jul 2025 13:12:20 +0900 Subject: [PATCH 1/2] =?UTF-8?q?=ED=95=98=EC=88=98=EC=9E=AC=EC=9D=B4?= =?UTF-8?q?=EC=9A=A9=EC=8B=A4=EC=A0=81=20=ED=98=84=ED=99=A9=20=EC=9B=94?= =?UTF-8?q?=EB=B3=84=20=EC=98=A4=EB=A6=84=EC=B0=A8=EC=88=9C=20=EC=A0=95?= =?UTF-8?q?=EB=A0=AC=20=EB=B3=B5=EA=B5=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../prfmncSttn/pbnstPrfmncSttn/page.tsx | 27 ++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/apps/wr/app/ruseFcltMng/prfmncSttn/pbnstPrfmncSttn/page.tsx b/apps/wr/app/ruseFcltMng/prfmncSttn/pbnstPrfmncSttn/page.tsx index 3e860d744..da0b7871d 100644 --- a/apps/wr/app/ruseFcltMng/prfmncSttn/pbnstPrfmncSttn/page.tsx +++ b/apps/wr/app/ruseFcltMng/prfmncSttn/pbnstPrfmncSttn/page.tsx @@ -306,6 +306,24 @@ export default function PbnstPrfmncSttn() { dnOutData.push({ label: "하천등유지용수", val: rvrKeepUswtr, fill: "#C5D3E8" }); dnOutData.push({ label: "공업용수", val: indstUswtr, fill: "#D0E8C5" }); + // 라인차트 데이터 월별 오름차순 정렬 + const sortFn = (a: { label: string }, b: { label: string }) => parseInt(a.label) - parseInt(b.label); + wshwtrData.sort(sortFn); + coolUswtrData.sort(sortFn); + cleanUswtrData.sort(sortFn); + drwtUswtrData.sort(sortFn); + dltnUswtrData.sort(sortFn); + ithlRswtrData.sort(sortFn); + ithlEtcUswtrData.sort(sortFn); + cleanToilUswtrData.sort(sortFn); + resnData.sort(sortFn); + lndwtrData.sort(sortFn); + hydUswtrData.sort(sortFn); + ugwtChrData.sort(sortFn); + farmUswtrData.sort(sortFn); + rvrKeepUswtrData.sort(sortFn); + indstUswtrData.sort(sortFn); + // 라인차트 데이터 setInLineData({ chartData1: wshwtrData, @@ -326,6 +344,7 @@ export default function PbnstPrfmncSttn() { chartData7: rvrKeepUswtrData, chartData8: indstUswtrData, }); + barData.sort((a, b) => parseInt(a.label) - parseInt(b.label)); setBarData(barData); setChartData(dnData); setDnInUsage(dnInData); @@ -471,7 +490,13 @@ export default function PbnstPrfmncSttn() { }, []); useEffect(() => { - setbdstTable(prfmncRes); + setbdstTable(prfmncRes.map((e, idx) => { + + return ({ + ...e, + number: String(idx + 1) + }) + })) if (prfmncRes?.[0]?.pbnstRuseFcltPk) setChartId(prfmncRes[0].pbnstRuseFcltPk) }, [prfmncRes]); From 37eb11f303233b054afcd80af6a7726596616073 Mon Sep 17 00:00:00 2001 From: jyha00 Date: Mon, 7 Jul 2025 16:25:26 +0900 Subject: [PATCH 2/2] =?UTF-8?q?=ED=95=98=EC=88=98=EC=9E=AC=EC=9D=B4?= =?UTF-8?q?=EC=9A=A9=EC=8B=9C=EC=84=A4=EB=93=B1=EB=A1=9D=20=EA=B2=B0?= =?UTF-8?q?=ED=95=A8=20=EC=88=98=EC=A0=95=20=EC=A4=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ruseFcltMng/fcltReg/pbnstReg/headList.tsx | 2 +- .../ruseFcltMng/fcltReg/pbnstReg/index.tsx | 2 + .../fcltReg/pbnstReg/mngReg/mngRegForm.tsx | 69 ++++++++++--------- .../ui/form/fcltReg/rainReg/rainRegForm.tsx | 4 +- .../fcltReg/bdstRegModal/bdstRegModal.tsx | 6 +- .../ruseMngTableForm/ruseMngTableForm.tsx | 12 ++-- 6 files changed, 50 insertions(+), 45 deletions(-) diff --git a/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/headList.tsx b/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/headList.tsx index d77f4d7f0..bb1cade10 100644 --- a/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/headList.tsx +++ b/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/headList.tsx @@ -50,7 +50,7 @@ export const pbnstOrgwtHeadListRxport: TableUpperProps[] = [ { id: "orgwtWtritQnt", title: "원수취수량" }, { id: "tmsYn", title: "하수처리량TMS 전후" }, { id: "dschgFmYn", title: "하수처리장 방류 유량계 전·후​" }, - { id: "dtlPstnExpln", title: "상세위치 설명" }, + { id: "dtlPstnExpln", title: "상세위치", edit: true }, ]; export const fcOrgwtsHeadListExport: TableUpperProps[] = [ { id: "choose", title: "선택", type: "checkbox" }, diff --git a/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/index.tsx b/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/index.tsx index e4bedff60..66c8c4dc8 100644 --- a/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/index.tsx +++ b/apps/wr/app/store/ruseFcltMng/fcltReg/pbnstReg/index.tsx @@ -124,6 +124,7 @@ if(searchTxt){ const hasuList = rainRes.data.map((item: any) => { return { ...item, + fctCpc: Number(item.fctCpc) || 0, ruse: item.ruse === false ? "N" : "Y", }; }); @@ -181,6 +182,7 @@ export const pubFacActionsExport: (set: any) => pubFacActions = (set: any) => { const pbnstHasuRes = await hasuListFetch(page, sggOrCity); + return set((state: pubFacState) => ({ ...state, pbnst: { diff --git a/apps/wr/components/ui/form/fcltReg/pbnstReg/mngReg/mngRegForm.tsx b/apps/wr/components/ui/form/fcltReg/pbnstReg/mngReg/mngRegForm.tsx index e1454342b..b1bbffc34 100644 --- a/apps/wr/components/ui/form/fcltReg/pbnstReg/mngReg/mngRegForm.tsx +++ b/apps/wr/components/ui/form/fcltReg/pbnstReg/mngReg/mngRegForm.tsx @@ -64,7 +64,7 @@ export function PbnstMngForm({ const { fields: fcOpersField, - append, + prepend, remove, } = useFieldArray({ control: form.control, @@ -77,7 +77,7 @@ export function PbnstMngForm({ }); const plusHist = () => { - append({ + prepend({ choose: false, pbnstRuseFcltFk: form.getValues(`items.${indexMng}.pbnstRuseFcltPk`) ?? "", @@ -310,42 +310,43 @@ export function PbnstMngForm({
+ {/*
*/} +
+ 재이용시설 운영정보 + {formType === "sttn" ? ( + <> + ) : ( +
+ + +
+ )} +
-
- 재이용시설 운영정보 - {formType === "sttn" ? ( - <> - ) : ( -
- - -
- )} -
{ - return { - ...item, - readonly: true, - }; - }) + return { + ...item, + readonly: true, + }; + }) : pbnst.pbnstMngUpHeadList } upHeadList={pbnst.pbnstMngNm} @@ -356,7 +357,7 @@ export function PbnstMngForm({ indexMng={indexMng} form={form} formNm={"fcOpers"} - // ref={ref} + // ref={ref} >
diff --git a/apps/wr/components/ui/form/fcltReg/rainReg/rainRegForm.tsx b/apps/wr/components/ui/form/fcltReg/rainReg/rainRegForm.tsx index 7333f6091..bc3a6a74d 100644 --- a/apps/wr/components/ui/form/fcltReg/rainReg/rainRegForm.tsx +++ b/apps/wr/components/ui/form/fcltReg/rainReg/rainRegForm.tsx @@ -13,7 +13,7 @@ import { } from "@/components/lib/func/commom"; import { DatePicker, FormUi } from "@common/business_components"; import { Form, FormField, SelectBox } from "@common/business_components/ui"; -import { Button, Checkbox, Input, Label } from "@common/components/ui"; +import { Button, Checkbox, Input, Label, ScrollArea } from "@common/components/ui"; import { zodResolver } from "@hookform/resolvers/zod"; import { useEffect, useState } from "react"; import { useForm } from "react-hook-form"; @@ -158,6 +158,7 @@ export default function RainRegForm({ )}
+ {isModal && rainForm != undefined ? : <>} {isModal ? (

@@ -583,6 +584,7 @@ export default function RainRegForm({ /> + diff --git a/apps/wr/components/ui/modal/fcltReg/bdstRegModal/bdstRegModal.tsx b/apps/wr/components/ui/modal/fcltReg/bdstRegModal/bdstRegModal.tsx index c534c38af..25e5ef976 100644 --- a/apps/wr/components/ui/modal/fcltReg/bdstRegModal/bdstRegModal.tsx +++ b/apps/wr/components/ui/modal/fcltReg/bdstRegModal/bdstRegModal.tsx @@ -114,7 +114,7 @@ export function BdstReg({ moType,setIsModal,isModal }: BdstReg > {" "} - + setSearchTxt(e.target.value)}/> @@ -142,7 +142,7 @@ export function BdstReg({ moType,setIsModal,isModal }: BdstReg
- + {/* */}
{ moType === 'RNB'? @@ -152,7 +152,7 @@ export function BdstReg({ moType,setIsModal,isModal }: BdstReg }
-
+ {/*
*/} ); diff --git a/apps/wr/components/ui/table/pbnstReg/ruseMngTableForm/ruseMngTableForm.tsx b/apps/wr/components/ui/table/pbnstReg/ruseMngTableForm/ruseMngTableForm.tsx index 6f4832c68..e746ab1f5 100644 --- a/apps/wr/components/ui/table/pbnstReg/ruseMngTableForm/ruseMngTableForm.tsx +++ b/apps/wr/components/ui/table/pbnstReg/ruseMngTableForm/ruseMngTableForm.tsx @@ -76,20 +76,20 @@ const RuseMngTableForm = React.forwardRef( {tableData.map((item, i) => ( - + {headList.map((head, j) => ( {}} + onClick={() => { }} > = 0 && - typeof indexBiz === "number" && - indexBiz >= 0 + indexMng >= 0 && + typeof indexBiz === "number" && + indexBiz >= 0 ? `items.${indexMng}.fcBizs.${indexBiz}.${formNm}.${i}.${head.id}` : typeof indexMng === "number" && indexMng >= 0 ? `items.${indexMng}.${formNm}.${i}.${head.id}` @@ -134,7 +134,7 @@ const RuseMngTableForm = React.forwardRef( } }} readOnly={head.readonly ? true : false} - // Disabled prop removed as SelectBox does not support it + // Disabled prop removed as SelectBox does not support it > ) : head.type === "date" ? (