diff --git a/egovframe-template-simple-react-contribution/src/css/page.css b/egovframe-template-simple-react-contribution/src/css/page.css index 29a13cb..16e70b4 100644 --- a/egovframe-template-simple-react-contribution/src/css/page.css +++ b/egovframe-template-simple-react-contribution/src/css/page.css @@ -86,7 +86,7 @@ .P_MAIN .banner_bot > div.b2 > div {background: url(css/images/ico_bn02.png) no-repeat center 60px;} .P_MAIN .banner_bot > div.b3 > div {background: url(css/images/ico_bn03.png) no-repeat center 60px;} .P_MAIN .banner_bot > div.b4 > div {background: url(css/images/ico_bn04.png) no-repeat center 60px;} - + /* 오늘의 행사 */ .BRD001 .head > span:nth-child(1) {width: 150px;} @@ -141,16 +141,16 @@ .BRD005 .result .list_item > div:nth-child(4) {width: 120px;} .BRD005 .result .list_item > div:nth-child(5) {width: 100px;} - /* 게시판생성 관리 */ - .BRD006 .head > span:nth-child(1) {width: 70px;} + /* 게시판 관리 */ + .BRD006 .head > span:nth-child(1) {width: 75px;} .BRD006 .head > span:nth-child(3) {width: 160px;} .BRD006 .head > span:nth-child(4) {width: 168px;} - .BRD006 .head > span:nth-child(5) {width: 140px;} + .BRD006 .head > span:nth-child(5) {width: 70px;} .BRD006 .head > span:nth-child(6) {width: 140px;} - .BRD006 .result .list_item > div:nth-child(1) {width: 70px;} + .BRD006 .result .list_item > div:nth-child(1) {width: 75px;} .BRD006 .result .list_item > div:nth-child(3) {width: 160px;} .BRD006 .result .list_item > div:nth-child(4) {width: 168px;} - .BRD006 .result .list_item > div:nth-child(5) {width: 140px;} + .BRD006 .result .list_item > div:nth-child(5) {width: 70px;} .BRD006 .result .list_item > div:nth-child(6) {width: 140px;} /* 사이트관리 > 사용자관리 > 사용자목록 */ @@ -254,13 +254,17 @@ .PDS_LIST .tit_5 {margin-top: 42px;} .PDS_LIST .board_list {margin-top: 50px;} .BRD007 .head > span:nth-child(1) {width: 70px;} - .BRD007 .head > span:nth-child(3) {width: 90px;} - .BRD007 .head > span:nth-child(4) {width: 90px;} - .BRD007 .head > span:nth-child(5) {width: 120px;} + .BRD007 .head > span:nth-child(3) {width: 160px;} + .BRD007 .head > span:nth-child(4) {width: 120px;} + .BRD007 .head > span:nth-child(5) {width: 70px;} + .BRD007 .head > span:nth-child(6) {width: 120px;} + .BRD007 .head > span:nth-child(7) {width: 140px;} .BRD007 .result .list_item > div:nth-child(1) {width: 70px;} - .BRD007 .result .list_item > div:nth-child(3) {width: 90px;} - .BRD007 .result .list_item > div:nth-child(4) {width: 90px;} - .BRD007 .result .list_item > div:nth-child(5) {width: 120px;} + .BRD007 .result .list_item > div:nth-child(3) {width: 160px;} + .BRD007 .result .list_item > div:nth-child(4) {width: 120px;} + .BRD007 .result .list_item > div:nth-child(5) {width: 70px;} + .BRD007 .result .list_item > div:nth-child(6) {width: 120px;} + .BRD007 .result .list_item > div:nth-child(7) {width: 140px;} .PDS_REG .pds_desc_edit {margin: 14px 0 30px 0;} diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtEdit.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtEdit.jsx index c12a9a8..985c38c 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtEdit.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtEdit.jsx @@ -131,7 +131,6 @@ function AdminPostMgtEdit({props, reloadFunction}) { }, (resp) => { if (Number(resp.resultCode) === Number(CODE.RCV_SUCCESS)) { - alert("삭제되었습니다.") reloadFunction(); } else if (Number(resp.resultCode) === Number(CODE.RCV_ERROR_AUTH)) { console.log("토큰 갱신중.") diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtList.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtList.jsx index be33693..1c0fbaf 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtList.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/board/AdminPostMgtList.jsx @@ -14,6 +14,7 @@ import AdminPostMgtEdit from "./AdminPostMgtEdit"; import Modal from "react-bootstrap/Modal"; import {format} from "date-fns"; import {Form} from "react-bootstrap"; +const fileIconPath = require('../../../css/images/ico_file.png'); function AdminPostMgtList(props) { console.group("EgovAdminPostList"); @@ -44,7 +45,7 @@ function AdminPostMgtList(props) { console.groupCollapsed("EgovAdminPostList.retrieveList()"); const retrieveListURL = '/admin/boards/post-list' + params; - + const requestOptions = { method: "GET", headers: { @@ -58,21 +59,37 @@ function AdminPostMgtList(props) { (resp) => { setPaginationInfo(resp.result.paginationInfo); setCategoryList(resp.result.categoryList); + console.log("@@@ resultCnt : " + resp.result.resultCnt); let mutListTag = []; setListTag([]); + resp.result.fixedList.forEach(function (item) { + const finalModifiedDate = item?.lastChgDt ? item?.lastChgDt : item?.frstCrtDt; + const formattedDate = finalModifiedDate ? format(finalModifiedDate, "yyyy-MM-dd HH:mm") : ""; + mutListTag.push( +
+
공지
+
{item?.bbsContTitle}
+
{item?.frstCrtId}
+
{formattedDate}
+
{item?.bbsReadCnt}
+
{item?.fileGrpId && File Icon}
+
+
+ ); + }); resp.result.postList.forEach(function (item, index) { const finalModifiedDate = item?.lastChgDt ? item?.lastChgDt : item?.frstCrtDt; const formattedDate = finalModifiedDate ? format(finalModifiedDate, "yyyy-MM-dd HH:mm") : ""; mutListTag.push(
-
{item?.bbsContSeq}
+
{resp.result.resultCnt - (resp.result.paginationInfo.pageIndex -1) * resp.result.paginationInfo.rowCnt - index}
{item?.bbsContTitle}
{item?.frstCrtId}
{formattedDate}
{item?.bbsReadCnt}
-
{item?.fileGrpId}
+
{item?.fileGrpId && File Icon}
); @@ -159,7 +176,7 @@ function AdminPostMgtList(props) { {/* */} {/* */} -
+
번호 제목 diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/board/EgovAdminBoardEdit.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/board/EgovAdminBoardEdit.jsx index dea18ac..8bf595d 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/board/EgovAdminBoardEdit.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/board/EgovAdminBoardEdit.jsx @@ -122,7 +122,6 @@ function EgovAdminBoardEdit({props, reloadFunction}) { }, (resp) => { if (Number(resp.resultCode) === Number(CODE.RCV_SUCCESS)) { - alert("삭제되었습니다.") reloadFunction(); } else if (Number(resp.resultCode) === Number(CODE.RCV_ERROR_AUTH)) { console.log("토큰 갱신중.") @@ -179,7 +178,6 @@ function EgovAdminBoardEdit({props, reloadFunction}) {
필수
- {bbsTypeList.map((item) => ( ))} @@ -226,7 +224,7 @@ function EgovAdminBoardEdit({props, reloadFunction}) {
필수
- + {roleList.map((item) => ( ))} @@ -237,7 +235,6 @@ function EgovAdminBoardEdit({props, reloadFunction}) {
필수
- {roleList.map((item) => ( ))} diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/boards/List.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/boards/List.jsx index 27d39a3..f025c4e 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/boards/List.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/boards/List.jsx @@ -58,7 +58,6 @@ function EgovAdminBoardList(props) { mutListTag.push(
-
{item.bbsId}
{item.bbsTitle}
{item.frstCrtId}
@@ -122,7 +121,6 @@ function EgovAdminBoardList(props) { {/* */}
- 아이디 제목 작성자 diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/config/AboutSiteMgt.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/config/AboutSiteMgt.jsx index e641012..bc47159 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/config/AboutSiteMgt.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/config/AboutSiteMgt.jsx @@ -51,7 +51,6 @@ function StandardCodeMgt(props) { mutListTag.push(
-
{item.siteTitle}
{item.siteUrl}
이미지 window.open(e.target.src)}/>
@@ -148,7 +147,6 @@ function StandardCodeMgt(props) { {/* */}
- 사이트명 URL 배너이미지 diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/config/aboutSiteMgt/AboutSiteModal.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/config/aboutSiteMgt/AboutSiteModal.jsx index bc94b97..7e187de 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/config/aboutSiteMgt/AboutSiteModal.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/config/aboutSiteMgt/AboutSiteModal.jsx @@ -243,7 +243,11 @@ function AboutSiteModal({props, reloadFunction}) {
필수
+ defaultValue={props?.siteOrder} onChange={(e) => { + const inputValue = e.target.value; + const numericValue = inputValue.replace(/\D/g, ''); + e.target.value = numericValue; + }}/>
diff --git a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/AdminBoardsController.java b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/AdminBoardsController.java index dcb9a54..66389f3 100644 --- a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/AdminBoardsController.java +++ b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/AdminBoardsController.java @@ -130,7 +130,7 @@ public class AdminBoardsController extends BaseController { if (user == null) { resultVO.setResultCode(ResponseCode.TOKEN_EXPIRED.getCode()); } else { - String result = adminBoardsService.deleteBoard(bbs, user.getId()); + String result = adminBoardsService.deleteBoard(bbs); if (result == null) { resultVO.setResultCode(ResponseCode.SUCCESS.getCode()); } else if (result.equals("notFind")) { @@ -256,7 +256,7 @@ public class AdminBoardsController extends BaseController { resultVO.setResultCode(ResponseCode.TOKEN_EXPIRED.getCode()); } else { contents.setIpAddress(ClientUtils.getRemoteIP(request)); - String result = adminBoardsService.deletePost(contents, user.getId()); + String result = adminBoardsService.deletePost(contents); if (result == null) { resultVO.setResultCode(ResponseCode.SUCCESS.getCode()); } else if (result.equals("notFind")) { diff --git a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/service/AdminBoardsService.java b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/service/AdminBoardsService.java index c65a8c8..1a60c3f 100644 --- a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/service/AdminBoardsService.java +++ b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/boards/service/AdminBoardsService.java @@ -57,23 +57,25 @@ public class AdminBoardsService extends EgovAbstractServiceImpl { } @Transactional - public String deleteBoard(TnBbs bbs, String userId) { + public String deleteBoard(TnBbs bbs) { TnBbs savedBoard = tnBbsRepository.findById(bbs.getBbsSeq()).orElse(null); if (savedBoard == null) { return "notFind"; } else { - savedBoard.setUseYn("N"); - savedBoard.setLastChgDt(LocalDateTime.now()); - savedBoard.setLastChgId(userId); - tnBbsRepository.save(savedBoard); + tnBbsRepository.deleteById(bbs.getBbsSeq()); return null; } } public Map selectPostList(TnBbsContents params) { Map resultMap = new HashMap<>(); - resultMap.put("resultCnt", String.valueOf(adminBoardsMapper.selectPostListCnt(params))); + + params.setFixedYn("N"); resultMap.put("postList", adminBoardsMapper.selectPostList(params)); + resultMap.put("resultCnt", String.valueOf(adminBoardsMapper.selectPostListCnt(params))); + + params.setFixedYn("Y"); + resultMap.put("fixedList", adminBoardsMapper.selectPostList(params)); return resultMap; } @@ -158,16 +160,12 @@ public class AdminBoardsService extends EgovAbstractServiceImpl { } @Transactional - public String deletePost(TnBbsContents contents, String userId) { + public String deletePost(TnBbsContents contents) { TnBbsContents savedPost = tnBbsContentsRepository.findById(contents.getBbsContSeq()).orElse(null); if (savedPost == null) { return "notFind"; } else { - savedPost.setIpAddress(contents.getIpAddress()); - savedPost.setUseYn("N"); - savedPost.setLastChgDt(LocalDateTime.now()); - savedPost.setLastChgId(userId); - tnBbsContentsRepository.save(savedPost); + tnBbsContentsRepository.deleteById(contents.getBbsContSeq()); return null; } } diff --git a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/config/AdminConfigController.java b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/config/AdminConfigController.java index 833b460..57e4cb2 100644 --- a/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/config/AdminConfigController.java +++ b/kcsc-back-end/src/main/java/com/dbnt/kcscbackend/admin/config/AdminConfigController.java @@ -532,7 +532,6 @@ public class AdminConfigController extends BaseController { }) @RequestMapping(method = RequestMethod.GET, value = "/get-site-image") public void getSiteImage(HttpServletResponse response, @RequestParam String fileGrpId) throws Exception { - System.out.println("@@@ in : "); List dbImgList = fileService.findByFileGrpId(fileGrpId); String realFile = dbImgList.get(0).getFilePath(); String fileNm = dbImgList.get(0).getFileNewName(); diff --git a/kcsc-back-end/src/main/resources/mybatisMapper/AdminBoardsMapper.xml b/kcsc-back-end/src/main/resources/mybatisMapper/AdminBoardsMapper.xml index a65e26c..c61ac04 100644 --- a/kcsc-back-end/src/main/resources/mybatisMapper/AdminBoardsMapper.xml +++ b/kcsc-back-end/src/main/resources/mybatisMapper/AdminBoardsMapper.xml @@ -30,7 +30,9 @@ from tn_bbs_contents order by bbs_cont_seq desc + limit #{rowCnt} offset #{firstIndex} +