From c9d89339356c5975848ccec24c2a32c76a1eedaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9C=A0=EB=AF=BC=ED=98=95?= Date: Thu, 21 Dec 2023 14:37:36 +0900 Subject: [PATCH] =?UTF-8?q?=EA=B1=B4=EC=84=A4=EA=B8=B0=EC=A4=80=EC=BD=94?= =?UTF-8?q?=EB=93=9C=20=EB=8C=80=EB=B6=84=EB=A5=98=20=EB=8F=99=EC=A0=81?= =?UTF-8?q?=EC=9C=BC=EB=A1=9C=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/pages/standardCode/StandardCodeList.jsx | 9 ++++++--- .../kcscbackend/standardCode/StandardCodeController.java | 4 +++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/egovframe-template-simple-react-contribution/src/pages/standardCode/StandardCodeList.jsx b/egovframe-template-simple-react-contribution/src/pages/standardCode/StandardCodeList.jsx index 48d1d25..b80f276 100644 --- a/egovframe-template-simple-react-contribution/src/pages/standardCode/StandardCodeList.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/standardCode/StandardCodeList.jsx @@ -87,6 +87,7 @@ function StandardCodeList(props) { /* 검색기능 추가 변수*/ const [listdata, setlistdata] = useState([]); const [filterData, setfilterData] = useState(''); + const [category1List, setCategory1List] = useState([]); const [category2List, setCategory2List] = useState([]); const [category3List, setCategory3List] = useState([]); const [resultCnt, setResultCnt] = useState(0); @@ -135,6 +136,7 @@ function StandardCodeList(props) { setMasterBoard(resp.result.tnDocumentInfo); /*검색을 위한 리스트 state에 저장*/ setlistdata(resp.result.resultList); + setCategory1List(resp.result.category1List); setCategory2List(resp.result.category2List); setCategory3List(resp.result.category3List); setResultCnt(resp.result.resultCnt); @@ -216,8 +218,9 @@ function StandardCodeList(props) { }} > - - + {category1List.map(category => ( + + ))} @@ -296,7 +299,7 @@ function StandardCodeList(props) { )} -
resultCnt : {resultCnt}
+
전체 {resultCnt} 건
{/* */}
diff --git a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/standardCode/StandardCodeController.java b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/standardCode/StandardCodeController.java index afd7a10..5ba3c82 100644 --- a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/standardCode/StandardCodeController.java +++ b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/standardCode/StandardCodeController.java @@ -168,11 +168,13 @@ public class StandardCodeController extends BaseController { System.out.println("@@@ category3 : " + category3); System.out.println("@@@ searchWrd : " + tnDocumentInfo.getSearchWrd()); - /* 대분류 category1(하드코딩) 중분류 category2 소분류 category3 */ + Integer categorySeq1 = standardCodeService.selectStandardCodeGroupSeq(tab); Integer categorySeq2 = standardCodeService.selectStandardCodeGroupSeq(tab + category1); Integer categorySeq3 = standardCodeService.selectStandardCodeGroupSeq(tab + category1 + category2); + System.out.println("@@@ categorySeq1 : " + categorySeq1); System.out.println("@@@ categorySeq2 : " + categorySeq2); System.out.println("@@@ categorySeq3 : " + categorySeq3); + resultMap.put("category1List", standardCodeService.selectStandardCodeCategoryList(categorySeq1)); resultMap.put("category2List", standardCodeService.selectStandardCodeCategoryList(categorySeq2)); resultMap.put("category3List", standardCodeService.selectStandardCodeCategoryList(categorySeq3));