From 81a3e6324e2bd9c75c75f49dab42059109542228 Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 09:06:56 +0900 Subject: [PATCH 1/8] =?UTF-8?q?fix:=20=EC=B9=A8=EC=9E=85=EC=88=98,=20RDII?= =?UTF-8?q?=20=EB=B6=84=EC=84=9D=EA=B2=B0=EA=B3=BC=20=EC=83=81=EC=88=98?= =?UTF-8?q?=EC=82=AC=EC=9A=A9=EA=B8=B0=EA=B0=84=20=EC=8B=9C=EC=9E=91=20?= =?UTF-8?q?=EB=85=84=EB=8F=84=20=EB=8B=B9=ED=95=B4=20=EB=85=84=EB=8F=84=20?= =?UTF-8?q?1=EC=9B=94=EB=B6=80=ED=84=B0=EB=A1=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/sn/app/(with-base-layout)/ii/BaseLayout.tsx | 5 +++-- apps/sn/app/(with-base-layout)/ii/rdiiResult/page.tsx | 10 ++++++---- apps/sn/app/(with-base-layout)/ii/result/page.tsx | 10 ++++++---- 3 files changed, 15 insertions(+), 10 deletions(-) diff --git a/apps/sn/app/(with-base-layout)/ii/BaseLayout.tsx b/apps/sn/app/(with-base-layout)/ii/BaseLayout.tsx index 51ac4d291..f0a649ad4 100644 --- a/apps/sn/app/(with-base-layout)/ii/BaseLayout.tsx +++ b/apps/sn/app/(with-base-layout)/ii/BaseLayout.tsx @@ -224,8 +224,9 @@ const BaseLayout = ({ value: aplcnYmFrom || (() => { // aplcnYm이 없으면 현재 연월을 기본값으로 설정 const now = new Date(); const year = now.getFullYear(); - const month = String(now.getMonth() + 1).padStart(2, '0'); - return `${year}${month}`; + // const month = String(now.getMonth() + 1).padStart(2, '0'); + // return `${year}${month}`; + return `${year}01`; })(), // yyyyMM 형식 onChange: (value: string) => { setAplcnYmFrom?.(value); // string 값을 직접 전달 diff --git a/apps/sn/app/(with-base-layout)/ii/rdiiResult/page.tsx b/apps/sn/app/(with-base-layout)/ii/rdiiResult/page.tsx index a5ab55407..08c7a8146 100644 --- a/apps/sn/app/(with-base-layout)/ii/rdiiResult/page.tsx +++ b/apps/sn/app/(with-base-layout)/ii/rdiiResult/page.tsx @@ -22,8 +22,9 @@ const formSchema = z.object({ aplcnYmFrom: z.string().default(() => { // Date에서 string(yyyyMM 형식)으로 변경 const now = new Date(); const year = now.getFullYear(); - const month = String(now.getMonth() + 1).padStart(2, '0'); - return `${year}${month}`; + // const month = String(now.getMonth() + 1).padStart(2, '0'); + // return `${year}${month}`; + return `${year}01`; // 기본값을 1월로 설정 }), // 분석기간 시작연월 aplcnYmTo: z.string().default(() => { // Date에서 string(yyyyMM 형식)으로 변경 const now = new Date(); @@ -66,8 +67,9 @@ const Result = () => { aplcnYmFrom: (() => { // 현재 연월을 yyyyMM 형식으로 설정 const now = new Date(); const year = now.getFullYear(); - const month = String(now.getMonth() + 1).padStart(2, '0'); - return `${year}${month}`; + // const month = String(now.getMonth() + 1).padStart(2, '0'); + // return `${year}${month}`; + return `${year}01`; })(), aplcnYmTo: (() => { // 현재 연월을 yyyyMM 형식으로 설정 const now = new Date(); diff --git a/apps/sn/app/(with-base-layout)/ii/result/page.tsx b/apps/sn/app/(with-base-layout)/ii/result/page.tsx index 30d0ef07c..974f6fa5f 100644 --- a/apps/sn/app/(with-base-layout)/ii/result/page.tsx +++ b/apps/sn/app/(with-base-layout)/ii/result/page.tsx @@ -22,8 +22,9 @@ const formSchema = z.object({ aplcnYmFrom: z.string().default(() => { // Date에서 string(yyyyMM 형식)으로 변경 const now = new Date(); const year = now.getFullYear(); - const month = String(now.getMonth() + 1).padStart(2, '0'); - return `${year}${month}`; + // const month = String(now.getMonth() + 1).padStart(2, '0'); + // return `${year}${month}`; + return `${year}01`; }), // 분석기간 시작연월 aplcnYmTo: z.string().default(() => { // Date에서 string(yyyyMM 형식)으로 변경 const now = new Date(); @@ -62,8 +63,9 @@ const Result = () => { aplcnYmFrom: (() => { // 현재 연월을 yyyyMM 형식으로 설정 const now = new Date(); const year = now.getFullYear(); - const month = String(now.getMonth() + 1).padStart(2, '0'); - return `${year}${month}`; + // const month = String(now.getMonth() + 1).padStart(2, '0'); + // return `${year}${month}`; + return `${year}01`; })(), aplcnYmTo: (() => { // 현재 연월을 yyyyMM 형식으로 설정 const now = new Date(); From 35e12031688ab5a034a4f8b034b11174356f29c4 Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 10:34:35 +0900 Subject: [PATCH 2/8] =?UTF-8?q?fix:=20monthPicker.tsx=20=ED=98=84=EC=9E=AC?= =?UTF-8?q?=20=EC=9B=94=EC=97=90=20hover=20=ED=9A=A8=EA=B3=BC=EA=B0=80=20?= =?UTF-8?q?=EC=A7=80=EC=86=8D=EB=90=98=EB=8A=94=20=EC=BD=94=EB=93=9C=20?= =?UTF-8?q?=EC=A3=BC=EC=84=9D=20=EC=B2=98=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/ui/date_month_picker/mothPicker.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/common/business_components/src/ui/date_month_picker/mothPicker.tsx b/packages/common/business_components/src/ui/date_month_picker/mothPicker.tsx index b5bc10ba5..78c9cb90b 100644 --- a/packages/common/business_components/src/ui/date_month_picker/mothPicker.tsx +++ b/packages/common/business_components/src/ui/date_month_picker/mothPicker.tsx @@ -61,9 +61,9 @@ const selectedYear = parseInt(yearFromProp); "inline-flex h-9 w-16 items-center justify-center rounded-md p-0 text-sm font-normal ring-offset-white transition-colors hover:bg-slate-100 hover:text-slate-900 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-400 focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 aria-selected:opacity-100 dark:ring-offset-slate-950 dark:hover:bg-slate-800 dark:hover:text-slate-50 dark:focus-visible:ring-slate-800", isEqual(month, currentMonth) && "bg-slate-900 text-slate-50 hover:bg-slate-900 hover:text-slate-50 focus:bg-slate-900 focus:text-slate-50 dark:bg-slate-50 dark:text-slate-900 dark:hover:bg-slate-50 dark:hover:text-slate-900 dark:focus:bg-slate-50 dark:focus:text-slate-900", - !isEqual(month, currentMonth) && - isEqual(month, getStartOfCurrentMonth()) && - "bg-slate-100 text-slate-900 dark:bg-slate-800 dark:text-slate-50" + // !isEqual(month, currentMonth) && + // isEqual(month, getStartOfCurrentMonth()) && + // "bg-slate-100 text-slate-900 dark:bg-slate-800 dark:text-slate-50" ); return ( From 07c7947da1c727794a4249f6f662f875ce2fc4d8 Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 10:51:37 +0900 Subject: [PATCH 3/8] =?UTF-8?q?fix:=20gis.layer.js=20=ED=95=98=EC=88=98?= =?UTF-8?q?=ED=8E=8C=ED=94=84=EC=9E=A5=20CQL=20=ED=95=84=ED=84=B0=20?= =?UTF-8?q?=EC=A0=81=EC=9A=A9=20=EC=95=88=EB=90=98=EB=8A=94=20=EC=97=90?= =?UTF-8?q?=EB=9F=AC=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/ui/map/lib/gis.layer.js | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/common/business_components/src/ui/map/lib/gis.layer.js b/packages/common/business_components/src/ui/map/lib/gis.layer.js index 7790aa5dc..9557bcb7d 100644 --- a/packages/common/business_components/src/ui/map/lib/gis.layer.js +++ b/packages/common/business_components/src/ui/map/lib/gis.layer.js @@ -143,7 +143,20 @@ GisOlLayer.prototype = { //레이어 생성 let returnLayer = this.makeLayer(option); //레이어 소스 생성 - let source = this.getVectorSourceGeoserver(option); + let source; + + let lyrTyNm = option.lyrTyNm; + if(lyrTyNm == 'tb_ms_flood_dngr_map' + || lyrTyNm == 'tb_ms_sbmrg_dngr_map' + || lyrTyNm == 'tb_ms_swage_mhl' + || lyrTyNm == 'tb_ms_swage_ppl' + || lyrTyNm == 'tb_ms_swage_pmstn' + ) { + source = this.getVectorSourceBbox(option); + }else { + source = this.getVectorTileSource(option); + } + returnLayer.setSource(source); //스타일 추가 returnLayer.setStyle(this.gisStyle.getLayerStyleFunction(returnLayer, option)); From 895adeef0abc2c5c32d2942f7864d4b82dbd2892 Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 15:36:54 +0900 Subject: [PATCH 4/8] =?UTF-8?q?fix:=20-=20=ED=95=98=EC=88=98=EA=B4=80?= =?UTF-8?q?=EB=A1=9C=20=EC=83=81=EC=84=B8=EC=A0=95=EB=B3=B4=20=EC=BB=AC?= =?UTF-8?q?=EB=9F=BC=20=EC=88=98=EC=A0=95=20-=20=EC=9A=B4=EC=98=81?= =?UTF-8?q?=EC=A0=95=EB=B3=B4=20=EA=B2=80=EC=83=89=20=EC=9D=BC=EB=A0=A8?= =?UTF-8?q?=EB=B2=88=ED=98=B8=20=EC=97=90=EB=9F=AC=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/(map-layout)/map/components/common/table.ts | 12 ++++++------ .../app/(map-layout)/map/searchModal/searchModal.tsx | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/apps/sn/app/(map-layout)/map/components/common/table.ts b/apps/sn/app/(map-layout)/map/components/common/table.ts index 3148b7ea2..84de2b4ab 100644 --- a/apps/sn/app/(map-layout)/map/components/common/table.ts +++ b/apps/sn/app/(map-layout)/map/components/common/table.ts @@ -287,12 +287,12 @@ export const SwtrmtFcltCol = [ { id: 'ycrd', title: 'Y좌표' }, // { id: 'oprtngSttsCd', title: '가동상태코드' }, { id: 'rprs_msrc_cn', title: '대표공법내용' }, - { id: 'stty_crtr_bod', title: '법정기준생물화학적산소요구량(mg/L)' }, - { id: 'stty_crtr_toc', title: '법정기준TOC((mg/L))' }, - { id: 'stty_crtr_ss', title: '법정기준SS(mg/L)' }, - { id: 'stty_crtr_tn', title: '법정기준총질소(mg/L)' }, - { id: 'stty_crtr_tph', title: '법정기준총인(mg/L)' }, - { id: 'stty_crtr_clbcl_cnt', title: '법정기준대장균수(군수/100mL)' }, + // { id: 'stty_crtr_bod', title: '법정기준생물화학적산소요구량(mg/L)' }, + // { id: 'stty_crtr_toc', title: '법정기준TOC((mg/L))' }, + // { id: 'stty_crtr_ss', title: '법정기준SS(mg/L)' }, + // { id: 'stty_crtr_tn', title: '법정기준총질소(mg/L)' }, + // { id: 'stty_crtr_tph', title: '법정기준총인(mg/L)' }, + // { id: 'stty_crtr_clbcl_cnt', title: '법정기준대장균수(군수/100mL)' }, { id: 'bsn_nm', title: '유역명' }, // { id: 'obsrvnSptCd', title: '관측지점코드' }, ]; diff --git a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx index 622fbd63f..a43147f55 100644 --- a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx +++ b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx @@ -227,7 +227,7 @@ const SearchModal: React.FC = ({ } else if (activeTab === 'operation') { const RequestDTO: Record = { page: `${curPage - 1}`, - size: '5', + size: '4', }; if (var1) RequestDTO.bizNm = var1; if (var2 != '0' && var2) RequestDTO.bizTyCd = var2; @@ -480,8 +480,8 @@ const SearchModal: React.FC = ({ try { const RequestDTO: Record = { page: `${detailCurPage - 1}`, - size: '5', - bizId: tableData[index % 5].bizId, + size: '4', + bizId: tableData[index % 4].bizId, }; const res = await getData(`v1/bizInfo/fclts?${new URLSearchParams(RequestDTO).toString()}`); @@ -519,7 +519,7 @@ const SearchModal: React.FC = ({ try { const RequestDTO: Record = { page: `${detailCurPage - 1}`, - size: '5', + size: '4', bizId: String(detailBizId), }; const res = await getData(`v1/bizInfo/fclts?${new URLSearchParams(RequestDTO).toString()}`); @@ -652,7 +652,7 @@ const SearchModal: React.FC = ({ } tableData={tableData} headlist={dynamicHeadlist} - pageSize={5} + pageSize={4} total={tableCount} cellClick={handleOperationCellClick} onPageChange={setCurPage} @@ -674,7 +674,7 @@ const SearchModal: React.FC = ({ } tableData={detailTableData} headlist={dynamicHeadlist2} - pageSize={5} + pageSize={4} total={detailTableCount} cellClick={undefined} onPageChange={setDetailCurPage} From 890e2af79b9cb995c85c358a2429f402f0d8ea56 Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 16:09:22 +0900 Subject: [PATCH 5/8] =?UTF-8?q?fix:=20=EC=83=81=EC=84=B8=20=EC=A0=95?= =?UTF-8?q?=EB=B3=B4=20=ED=8E=98=EC=9D=B4=EC=A7=80=20=EC=BB=AC=EB=9F=BC=20?= =?UTF-8?q?=EB=84=88=EB=B9=84=20=ED=86=B5=EC=9D=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/sn/app/components/ui/verticalTable.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/sn/app/components/ui/verticalTable.tsx b/apps/sn/app/components/ui/verticalTable.tsx index abdad03bb..ee13405fb 100644 --- a/apps/sn/app/components/ui/verticalTable.tsx +++ b/apps/sn/app/components/ui/verticalTable.tsx @@ -121,7 +121,7 @@ export function VerticalTable({ {headlist?.map((head) => ( {/* 컬럼 제목 */} - + {head.title} {/* 데이터 값 또는 입력 필드 */} @@ -168,7 +168,7 @@ export function VerticalTable({ {headlist2?.map((head) => ( {/* 컬럼 제목 */} - + {head.title} {/* 데이터 값 또는 입력 필드 */} From 9759a5250a5c38882f6fff5cb044cd535cd26b2a Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 17:03:36 +0900 Subject: [PATCH 6/8] =?UTF-8?q?fix:=20=EC=82=AC=EC=97=85=20=EA=B5=AC?= =?UTF-8?q?=EB=B6=84=203=EA=B0=9C=EB=A1=9C=20=EB=B0=94=EA=BE=B8=EA=B8=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/(map-layout)/map/searchModal/operationTab.tsx | 11 ++++++----- .../app/(map-layout)/map/searchModal/searchModal.tsx | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx b/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx index c880ed1a4..2170efa1f 100644 --- a/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx +++ b/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx @@ -12,11 +12,12 @@ import React from 'react'; // { val: "inspection", text: "점검 및 진단" }, // ]; export const WORK_TYPES = [ - { val: "200", text: "보수 및 갱신(개대체)" }, - { val: "201", text: "보수 및 갱신(유지보수)" }, - { val: "204", text: "보수 및 갱신(단순보수)" }, - { val: "100", text: "점검 및 진단" }, - { val: "203", text: "청소 및 준설" }, + { val: "[200, 201, 204]", text: "보수 및 갱신" }, + // { val: "200", text: "보수 및 갱신(개대체)" }, + // { val: "201", text: "보수 및 갱신(유지보수)" }, + // { val: "204", text: "보수 및 갱신(단순보수)" }, + { val: "[100]", text: "점검 및 진단" }, + { val: "[203]", text: "청소 및 준설" }, ]; // const BIZ_SE_CD = useBizByFcltStore(state => state.BIZ_SE_CD); export const BIZ_SE_CD = [ diff --git a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx index a43147f55..cae5bb989 100644 --- a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx +++ b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx @@ -248,7 +248,7 @@ const SearchModal: React.FC = ({ RequestDTO.toflfmtEndYmd = endDate; - RequestDTO.bizSeCd = workType; + RequestDTO.workTypes = workType; const params = new URLSearchParams(RequestDTO).toString(); From f550a62f999e89b5f110da0bb8cac8de56441910 Mon Sep 17 00:00:00 2001 From: swcho Date: Mon, 28 Jul 2025 17:32:25 +0900 Subject: [PATCH 7/8] =?UTF-8?q?refactor:=20searchModal.tsx=20=EC=BD=94?= =?UTF-8?q?=EB=93=9C=20=EC=A0=95=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../map/searchModal/searchModal.tsx | 124 +++++++++--------- 1 file changed, 59 insertions(+), 65 deletions(-) diff --git a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx index cae5bb989..200d50cbf 100644 --- a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx +++ b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx @@ -81,7 +81,7 @@ const SearchModal: React.FC = ({ const [yearFilter, setYearFilter] = useState({ start: "", end: "" }); const [filteredSiguns, setFilteredSiguns] = useState([{ val: '0', text: '전체', sido: '0' }]); - + // 오늘 날짜 구하기 const today = new Date(); const todayYear = today.getFullYear().toString(); @@ -179,7 +179,7 @@ const SearchModal: React.FC = ({ setIsLoading(true); // 로딩 시작 setIsResetSelection(true); // 선택 초기화 setIsResetDetailSelection(true); // 선택 초기화 - + try { let cqlFilters: string[] = []; if (activeTab === 'basic') { @@ -272,8 +272,7 @@ const SearchModal: React.FC = ({ setTableCount(res.totalElements || 0); setDetailTableData([]); setDetailTableCount(0); - - } + } setShowTable(true); } catch (err) { @@ -446,12 +445,7 @@ const SearchModal: React.FC = ({ // 조회 버튼 클릭 시 1페이지로 이동 및 데이터 초기화 const handleSearch = () => { - setCurPage(1); // 페이지를 1로 초기화 - // setDetailCurPage(1); // 페이지를 1로 초기화 - // setIsResetPage(false); // 페이지를 초기화 - // setIsResetDetailPage(true); // 디테일 페이지를 초기화 - // setIsResetSelection(true); // 선택 초기화 - // setIsResetDetailSelection(true); // 선택 초기화 + setCurPage(1); // 페이지를 1로 초기화 fetchFilteredData(); setIsResetPage(true); // 페이지를 초기화 setIsResetDetailPage(true); // 디테일 페이지를 초기화 @@ -546,7 +540,7 @@ const SearchModal: React.FC = ({ } } }; - + const renderBody = () => ( <> @@ -560,63 +554,62 @@ const SearchModal: React.FC = ({ onValueChange={(value: string) => setActiveTab(value)} > - {/* 각각의 탭 영역 */} - {/* 기본정보 탭 */} - {activeTab === 'basic' && ( - - )} - {/* 운영정보 탭 */} - {activeTab === 'operation' && ( - - )} - {/* 하수도정비기본계획보고서 탭 */} - {activeTab === 'report' && ( - - )} - {/* */} - + {/* 각각의 탭 영역 */} + {/* 기본정보 탭 */} + {activeTab === 'basic' && ( + + )} + {/* 운영정보 탭 */} + {activeTab === 'operation' && ( + + )} + {/* 하수도정비기본계획보고서 탭 */} + {activeTab === 'report' && ( + + )} + {/* */} + {/* 📋 결과 리스트 */} - {/* 기본정보 탭, 하수도정비기본계획보고서 탭 */} - {(activeTab === 'basic' ) && ( + {/* 하수도정비기본계획보고서 탭 */} + {activeTab === 'basic' && (
- {/* 테이블2 영역 (가로/세로 스크롤 가능) */}
= ({
+ {/* 테이블2 영역 */}
Date: Mon, 28 Jul 2025 17:51:01 +0900 Subject: [PATCH 8/8] =?UTF-8?q?fix:=20=EC=82=AC=EC=97=85=20=EA=B5=AC?= =?UTF-8?q?=EB=B6=84=203=EA=B0=9C=EB=A1=9C=20=EB=B0=94=EA=BE=B8=EA=B8=B02?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../map/searchModal/operationTab.tsx | 9 +++------ .../map/searchModal/searchModal.tsx | 17 ++++++++++------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx b/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx index 2170efa1f..97c0b4c4c 100644 --- a/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx +++ b/apps/sn/app/(map-layout)/map/searchModal/operationTab.tsx @@ -12,12 +12,9 @@ import React from 'react'; // { val: "inspection", text: "점검 및 진단" }, // ]; export const WORK_TYPES = [ - { val: "[200, 201, 204]", text: "보수 및 갱신" }, - // { val: "200", text: "보수 및 갱신(개대체)" }, - // { val: "201", text: "보수 및 갱신(유지보수)" }, - // { val: "204", text: "보수 및 갱신(단순보수)" }, - { val: "[100]", text: "점검 및 진단" }, - { val: "[203]", text: "청소 및 준설" }, + { val: "['200', '201', '204']", text: "보수 및 갱신" }, + { val: "['100']", text: "점검 및 진단" }, + { val: "['203']", text: "청소 및 준설" }, ]; // const BIZ_SE_CD = useBizByFcltStore(state => state.BIZ_SE_CD); export const BIZ_SE_CD = [ diff --git a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx index 200d50cbf..ed6cdd608 100644 --- a/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx +++ b/apps/sn/app/(map-layout)/map/searchModal/searchModal.tsx @@ -106,11 +106,9 @@ const SearchModal: React.FC = ({ const dynamicHeadlist2: { id: string, title: string }[] = useMemo(() => { if (activeTab === 'operation') { - if (workType === '200') return operationMaintenanceTableHeadlist; - if (workType === '201') return operationMaintenanceTableHeadlist; - if (workType === '204') return operationMaintenanceTableHeadlist; - if (workType === '100') return operationCleaningTableHeadlist; - if (workType === '203') return operationInspectionTableHeadlist; + if (workType === WORK_TYPES[0]?.val) return operationMaintenanceTableHeadlist; + if (workType === WORK_TYPES[1]?.val) return operationCleaningTableHeadlist; + if (workType === WORK_TYPES[2]?.val) return operationInspectionTableHeadlist; } return []; @@ -247,8 +245,8 @@ const SearchModal: React.FC = ({ RequestDTO.fromflfmtEndYmd = startDate; RequestDTO.toflfmtEndYmd = endDate; - - RequestDTO.workTypes = workType; + // JSON.parse 사용으로 문자열 -> 배열 변환 + RequestDTO.workTypes = JSON.parse(workType.replace(/'/g, '"')); const params = new URLSearchParams(RequestDTO).toString(); @@ -478,8 +476,11 @@ const SearchModal: React.FC = ({ bizId: tableData[index % 4].bizId, }; + RequestDTO.workTypes = JSON.parse(workType.replace(/'/g, '"')); + const res = await getData(`v1/bizInfo/fclts?${new URLSearchParams(RequestDTO).toString()}`); console.log('운영정보 cellClick 데이터:', res); + console.log('운영정보 cellClick.data:', res.data); console.log('운영정보 length:', res.data.length); const mappedData = (res.data || []).map((item: any, detailIndex: number) => { @@ -495,6 +496,8 @@ const SearchModal: React.FC = ({ }; }); + console.log('운영정보 cellClick mappedData:', mappedData); + setDetailTableData(mappedData); setDetailTableCount(res.count || 0); } catch (error) {