공용게시판 테이블 수정, 직급 표현.

강석 최 2022-11-01 14:47:16 +09:00
parent de0d83439a
commit d62012e8ae
12 changed files with 246 additions and 201 deletions

View File

@ -49,10 +49,8 @@ public class PublicBoardController {
ModelAndView mav = new ModelAndView("publicBoard/board/boardPage"); ModelAndView mav = new ModelAndView("publicBoard/board/boardPage");
publicBoard.setQueryInfo(); publicBoard.setQueryInfo();
publicBoard.setPublicType("PLB002"); publicBoard.setPublicType("PLB002");
if (loginUser.getUserRole().contains(Role.SUB_ADMIN.getValue())) {
publicBoard.setDownOrganCdList(loginUser.getDownOrganCdList()); publicBoard.setDownOrganCdList(loginUser.getDownOrganCdList());
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList()); mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
}
publicBoard.setUpOrganCdList(loginUser.getUpOrganCdList()); publicBoard.setUpOrganCdList(loginUser.getUpOrganCdList());
mav.addObject("boardList", publicBoardService.selectContentList(publicBoard)); mav.addObject("boardList", publicBoardService.selectContentList(publicBoard));
publicBoard.setContentCnt(publicBoardService.selectContentListCnt(publicBoard)); publicBoard.setContentCnt(publicBoardService.selectContentListCnt(publicBoard));
@ -67,10 +65,8 @@ public class PublicBoardController {
ModelAndView mav = new ModelAndView("publicBoard/reference/referencePage"); ModelAndView mav = new ModelAndView("publicBoard/reference/referencePage");
publicBoard.setQueryInfo(); publicBoard.setQueryInfo();
publicBoard.setPublicType("PLB003"); publicBoard.setPublicType("PLB003");
if (loginUser.getUserRole().contains(Role.SUB_ADMIN.getValue())) {
publicBoard.setDownOrganCdList(loginUser.getDownOrganCdList()); publicBoard.setDownOrganCdList(loginUser.getDownOrganCdList());
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList()); mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
}
publicBoard.setUpOrganCdList(loginUser.getUpOrganCdList()); publicBoard.setUpOrganCdList(loginUser.getUpOrganCdList());
mav.addObject("referenceList", publicBoardService.selectContentList(publicBoard)); mav.addObject("referenceList", publicBoardService.selectContentList(publicBoard));
publicBoard.setContentCnt(publicBoardService.selectContentListCnt(publicBoard)); publicBoard.setContentCnt(publicBoardService.selectContentListCnt(publicBoard));
@ -86,10 +82,8 @@ public class PublicBoardController {
ModelAndView mav = new ModelAndView("publicBoard/qna/qnaPage"); ModelAndView mav = new ModelAndView("publicBoard/qna/qnaPage");
publicBoard.setQueryInfo(); publicBoard.setQueryInfo();
publicBoard.setPublicType("PLB004"); publicBoard.setPublicType("PLB004");
if (loginUser.getUserRole().contains(Role.SUB_ADMIN.getValue())) {
publicBoard.setDownOrganCdList(loginUser.getDownOrganCdList()); publicBoard.setDownOrganCdList(loginUser.getDownOrganCdList());
mav.addObject("mgtOrganList", loginUser.getDownOrganCdList()); mav.addObject("mgtOrganList", loginUser.getDownOrganCdList());
}
mav.addObject("qnaList", publicBoardService.selectContentList(publicBoard)); mav.addObject("qnaList", publicBoardService.selectContentList(publicBoard));
publicBoard.setContentCnt(publicBoardService.selectContentListCnt(publicBoard)); publicBoard.setContentCnt(publicBoardService.selectContentListCnt(publicBoard));
publicBoard.setPaginationInfo(); publicBoard.setPaginationInfo();
@ -104,31 +98,19 @@ public class PublicBoardController {
switch (publicBoard.getPublicType()) { switch (publicBoard.getPublicType()) {
case "PLB001": // 공지사항 case "PLB001": // 공지사항
mav = new ModelAndView("publicBoard/notice/noticeEditModal"); mav = new ModelAndView("publicBoard/notice/noticeEditModal");
if (publicBoard.getPublicKey() != null) {
publicBoard = publicBoardService.selectPublicBoard(publicBoard.getPublicKey());
}
break; break;
case "PLB002": // 공용게시판 case "PLB002": // 공용게시판
mav = new ModelAndView("publicBoard/board/boardEditModal"); mav = new ModelAndView("publicBoard/board/boardEditModal");
if (publicBoard.getPublicKey() != null) {
publicBoard = publicBoardService.selectPublicBoard(publicBoard.getPublicKey());
}
break; break;
case "PLB003": // 자료실 case "PLB003": // 자료실
mav = new ModelAndView("publicBoard/reference/referenceEditModal"); mav = new ModelAndView("publicBoard/reference/referenceEditModal");
if (publicBoard.getPublicKey() != null) {
publicBoard = publicBoardService.selectPublicBoard(publicBoard.getPublicKey());
}
break; break;
case "PLB004": // Q&A case "PLB004": // Q&A
mav = new ModelAndView("publicBoard/qna/qnaEditModal"); mav = new ModelAndView("publicBoard/qna/qnaEditModal");
}
if (publicBoard.getPublicKey() != null) { if (publicBoard.getPublicKey() != null) {
publicBoard = publicBoardService.selectPublicBoard(publicBoard.getPublicKey()); publicBoard = publicBoardService.selectPublicBoard(publicBoard.getPublicKey());
break; }else{
}
}
if (publicBoard.getPublicKey() == null) {
publicBoard.setWrtOrgan(loginUser.getOgCd()); publicBoard.setWrtOrgan(loginUser.getOgCd());
publicBoard.setWrtPart(loginUser.getOfcCd()); publicBoard.setWrtPart(loginUser.getOfcCd());
publicBoard.setWrtUserSeq(loginUser.getUserSeq()); publicBoard.setWrtUserSeq(loginUser.getUserSeq());

View File

@ -2,7 +2,7 @@
<html lang="ko" <html lang="ko"
xmlns:th="http://www.thymeleaf.org" xmlns:th="http://www.thymeleaf.org"
xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity5"> xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity5">
<header th:fragment="headerFragment" class="border-bottom row justify-content-between py-1 px-3"> <header th:fragment="headerFragment" class="border-bottom w-100 row justify-content-between py-1 px-3">
<div class="col-auto row justify-content-start"> <div class="col-auto row justify-content-start">
<div class="col-auto"> <div class="col-auto">
<div class="navbar-header"> <div class="navbar-header">

View File

@ -13,10 +13,16 @@
<input type="hidden" name="wrtOrgan" th:value="${info.wrtOrgan}"> <input type="hidden" name="wrtOrgan" th:value="${info.wrtOrgan}">
<input type="hidden" name="wrtPart" th:value="${info.wrtPart}"> <input type="hidden" name="wrtPart" th:value="${info.wrtPart}">
<input type="hidden" name="wrtUserSeq" th:value="${info.wrtUserSeq}"> <input type="hidden" name="wrtUserSeq" th:value="${info.wrtUserSeq}">
<input type="hidden" name="wrtUserGrd" th:value="${info.wrtUserGrd}">
<input type="hidden" name="wrtUserNm" th:value="${info.wrtUserNm}">
<div class="mb-3 row"> <div class="mb-3 row">
<label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control" id="wrtUserNm" name="wrtUserNm" th:value="${info.wrtUserNm}" readonly> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq info.wrtUserGrd}">
<input type="text" class="form-control" id="wrtUserNm" th:value="|${commonCode.itemValue} ${info.wrtUserNm}|" readonly>
</th:block>
</th:block>
</div> </div>
<label for="wrtDt" class="col-sm-2 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-2 col-form-label text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">

View File

@ -56,20 +56,21 @@
<div class="card"> <div class="card">
<div class="card-body"> <div class="card-body">
<div class="row"> <div class="row">
<table class="table table-hover"> <table class="table table-hover table-bordered">
<thead> <thead>
<tr> <tr>
<th></th> <th></th>
<th>제목</th> <th>제목</th>
<th>관서</th> <th>관서</th>
<th>부서</th> <th>부서</th>
<th>계급</th>
<th>작성자</th> <th>작성자</th>
<th>작성일시</th> <th>작성일시</th>
<th>첨부파일</th> <th>첨부파일</th>
<th>댓글</th> <th>댓글</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody class="table-group-divider">
<tr class="planTr" th:each="board:${boardList}"> <tr class="planTr" th:each="board:${boardList}">
<input type="hidden" class="planKey" th:value="${board.publicKey}"> <input type="hidden" class="planKey" th:value="${board.publicKey}">
<td><input type="checkbox" class="trChkBox"></td> <td><input type="checkbox" class="trChkBox"></td>
@ -80,6 +81,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<td th:if="${board.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td> <td th:if="${board.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<td th:if="${board.wrtUserGrd eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block>
<td th:text="${board.wrtUserNm}"></td> <td th:text="${board.wrtUserNm}"></td>
<td th:text="${#temporals.format(board.wrtDt, 'yyyy-MM-dd HH:mm')}"></td> <td th:text="${#temporals.format(board.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
<td th:text="${board.fileCnt eq null?'파일 없음':#strings.concat(board.fileCnt,' 건')}"></td> <td th:text="${board.fileCnt eq null?'파일 없음':#strings.concat(board.fileCnt,' 건')}"></td>

View File

@ -11,7 +11,11 @@
<div class="mb-3 row"> <div class="mb-3 row">
<label for="wrtUserNm" class="col-sm-1 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-1 col-form-label text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control border-0" id="wrtUserNm" name="wrtUserNm" th:value="${info.wrtUserNm}" readonly> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq info.wrtUserGrd}">
<input type="text" class="form-control border-0" id="wrtUserNm" name="wrtUserNm" th:value="|${commonCode.itemValue} ${info.wrtUserNm}|" readonly>
</th:block>
</th:block>
</div> </div>
<label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">
@ -94,6 +98,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${comment.wrtUserNm}"></div> <div class="col-auto" th:text="${comment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto"> <div class="col-auto">
@ -121,6 +128,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${childComment.wrtUserNm}"></div> <div class="col-auto" th:text="${childComment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(childComment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(childComment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto" th:if="${userSeq eq childComment.wrtUserSeq}"> <div class="col-auto" th:if="${userSeq eq childComment.wrtUserSeq}">

View File

@ -41,6 +41,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${comment.wrtUserNm}"></div> <div class="col-auto" th:text="${comment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto" th:if="${userSeq eq comment.wrtUserSeq}"> <div class="col-auto" th:if="${userSeq eq comment.wrtUserSeq}">

View File

@ -13,10 +13,16 @@
<input type="hidden" name="wrtOrgan" th:value="${info.wrtOrgan}"> <input type="hidden" name="wrtOrgan" th:value="${info.wrtOrgan}">
<input type="hidden" name="wrtPart" th:value="${info.wrtPart}"> <input type="hidden" name="wrtPart" th:value="${info.wrtPart}">
<input type="hidden" name="wrtUserSeq" th:value="${info.wrtUserSeq}"> <input type="hidden" name="wrtUserSeq" th:value="${info.wrtUserSeq}">
<input type="hidden" name="wrtUserGrd" th:value="${info.wrtUserGrd}">
<input type="hidden" name="wrtUserNm" th:value="${info.wrtUserNm}">
<div class="mb-3 row"> <div class="mb-3 row">
<label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control" id="wrtUserNm" name="wrtUserNm" th:value="${info.wrtUserNm}" readonly> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq info.wrtUserGrd}">
<input type="text" class="form-control" id="wrtUserNm" th:value="|${commonCode.itemValue} ${info.wrtUserNm}|" readonly>
</th:block>
</th:block>
</div> </div>
<label for="wrtDt" class="col-sm-2 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-2 col-form-label text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">

View File

@ -57,20 +57,21 @@
<div class="card"> <div class="card">
<div class="card-body"> <div class="card-body">
<div class="row"> <div class="row">
<table class="table table-hover"> <table class="table table-hover table-bordered">
<thead> <thead>
<tr> <tr>
<th></th> <th></th>
<th>제목</th> <th>제목</th>
<th>관서</th> <th>관서</th>
<th>부서</th> <th>부서</th>
<th>계급</th>
<th>작성자</th> <th>작성자</th>
<th>작성일시</th> <th>작성일시</th>
<th>첨부파일</th> <th>첨부파일</th>
<th>댓글</th> <th>댓글</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody class="table-group-divider">
<tr class="planTr" th:each="qna:${qnaList}"> <tr class="planTr" th:each="qna:${qnaList}">
<input type="hidden" class="planKey" th:value="${qna.publicKey}"> <input type="hidden" class="planKey" th:value="${qna.publicKey}">
<td><input type="checkbox" class="trChkBox"></td> <td><input type="checkbox" class="trChkBox"></td>
@ -81,6 +82,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<td th:if="${qna.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td> <td th:if="${qna.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<td th:if="${qna.wrtUserGrd eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block>
<td th:text="${qna.wrtUserNm}"></td> <td th:text="${qna.wrtUserNm}"></td>
<td th:text="${#temporals.format(qna.wrtDt, 'yyyy-MM-dd HH:mm')}"></td> <td th:text="${#temporals.format(qna.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
<td th:text="${qna.fileCnt eq null?'파일 없음':#strings.concat(qna.fileCnt,' 건')}"></td> <td th:text="${qna.fileCnt eq null?'파일 없음':#strings.concat(qna.fileCnt,' 건')}"></td>

View File

@ -11,7 +11,11 @@
<div class="mb-3 row"> <div class="mb-3 row">
<label for="wrtUserNm" class="col-sm-1 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-1 col-form-label text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control border-0" id="wrtUserNm" name="wrtUserNm" th:value="${info.wrtUserNm}" readonly> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq info.wrtUserGrd}">
<input type="text" class="form-control border-0" id="wrtUserNm" name="wrtUserNm" th:value="|${commonCode.itemValue} ${info.wrtUserNm}|" readonly>
</th:block>
</th:block>
</div> </div>
<label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">
@ -94,6 +98,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${comment.wrtUserNm}"></div> <div class="col-auto" th:text="${comment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto"> <div class="col-auto">
@ -121,6 +128,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${childComment.wrtUserNm}"></div> <div class="col-auto" th:text="${childComment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(childComment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(childComment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto" th:if="${userSeq eq childComment.wrtUserSeq}"> <div class="col-auto" th:if="${userSeq eq childComment.wrtUserSeq}">

View File

@ -13,10 +13,16 @@
<input type="hidden" name="wrtOrgan" th:value="${info.wrtOrgan}"> <input type="hidden" name="wrtOrgan" th:value="${info.wrtOrgan}">
<input type="hidden" name="wrtPart" th:value="${info.wrtPart}"> <input type="hidden" name="wrtPart" th:value="${info.wrtPart}">
<input type="hidden" name="wrtUserSeq" th:value="${info.wrtUserSeq}"> <input type="hidden" name="wrtUserSeq" th:value="${info.wrtUserSeq}">
<input type="hidden" name="wrtUserGrd" th:value="${info.wrtUserGrd}">
<input type="hidden" name="wrtUserNm" th:value="${info.wrtUserNm}">
<div class="mb-3 row"> <div class="mb-3 row">
<label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-2 col-form-label text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control" id="wrtUserNm" name="wrtUserNm" th:value="${info.wrtUserNm}" readonly> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq info.wrtUserGrd}">
<input type="text" class="form-control" id="wrtUserNm" th:value="|${commonCode.itemValue} ${info.wrtUserNm}|" readonly>
</th:block>
</th:block>
</div> </div>
<label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">

View File

@ -10,6 +10,11 @@
<div layout:fragment="content"> <div layout:fragment="content">
<main class="pt-3"> <main class="pt-3">
<h4>자료실</h4> <h4>자료실</h4>
<input type="hidden" name="_csrf_header" th:value="${_csrf.headerName}"/>
<input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/>
<div class="row mx-0">
<div class="col-12 card text-center">
<div class="card-body">
<ul class="nav nav-tabs" id="boardTab" role="tablist"> <ul class="nav nav-tabs" id="boardTab" role="tablist">
<th:block th:each="tab:${tabStatusList}"> <th:block th:each="tab:${tabStatusList}">
<li class="nav-item" role="presentation"> <li class="nav-item" role="presentation">
@ -17,12 +22,7 @@
</li> </li>
</th:block> </th:block>
</ul> </ul>
<div class="tab-content border border-top-0 p-3" id="userContent">
<input type="hidden" name="_csrf_header" th:value="${_csrf.headerName}"/>
<input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/>
<div class="row mx-0">
<div class="col-12 card text-center">
<div class="card-body">
<form method="get" th:action="@{/publicBoard/referencePage}"> <form method="get" th:action="@{/publicBoard/referencePage}">
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}"> <input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
<input type="hidden" name="tabStatus" th:value="${searchParams.tabStatus}"> <input type="hidden" name="tabStatus" th:value="${searchParams.tabStatus}">
@ -66,20 +66,21 @@
<div class="card"> <div class="card">
<div class="card-body"> <div class="card-body">
<div class="row"> <div class="row">
<table class="table table-hover"> <table class="table table-hover table-bordered">
<thead> <thead>
<tr> <tr>
<th></th> <th></th>
<th>제목</th> <th>제목</th>
<th>관서</th> <th>관서</th>
<th>부서</th> <th>부서</th>
<th>계급</th>
<th>작성자</th> <th>작성자</th>
<th>작성일시</th> <th>작성일시</th>
<th>첨부파일</th> <th>첨부파일</th>
<th>댓글</th> <th>댓글</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody class="table-group-divider">
<tr class="planTr" th:each="reference:${referenceList}"> <tr class="planTr" th:each="reference:${referenceList}">
<input type="hidden" class="planKey" th:value="${reference.publicKey}"> <input type="hidden" class="planKey" th:value="${reference.publicKey}">
<td><input type="checkbox" class="trChkBox"></td> <td><input type="checkbox" class="trChkBox"></td>
@ -90,6 +91,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<td th:if="${reference.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td> <td th:if="${reference.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<td th:if="${reference.wrtUserGrd eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
</th:block>
<td th:text="${reference.wrtUserNm}"></td> <td th:text="${reference.wrtUserNm}"></td>
<td th:text="${#temporals.format(reference.wrtDt, 'yyyy-MM-dd HH:mm')}"></td> <td th:text="${#temporals.format(reference.wrtDt, 'yyyy-MM-dd HH:mm')}"></td>
<td th:text="${reference.fileCnt eq null?'파일 없음':#strings.concat(reference.fileCnt,' 건')}"></td> <td th:text="${reference.fileCnt eq null?'파일 없음':#strings.concat(reference.fileCnt,' 건')}"></td>
@ -136,6 +140,7 @@
</div> </div>
</div> </div>
</div> </div>
</div>
</main> </main>
<div class="modal fade" id="editModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="editModalLabel" aria-hidden="true"> <div class="modal fade" id="editModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="editModalLabel" aria-hidden="true">

View File

@ -8,11 +8,14 @@
<div class="row"> <div class="row">
<div class="col-12"> <div class="col-12">
<input type="hidden" name="publicKeyKey" id="viewModalPublicKey" th:value="${info.publicKey}"> <input type="hidden" name="publicKeyKey" id="viewModalPublicKey" th:value="${info.publicKey}">
<div class="mb-3 row"> <div class="mb-3 row">
<label for="wrtUserNm" class="col-sm-1 col-form-label text-center">작성자</label> <label for="wrtUserNm" class="col-sm-1 col-form-label text-center">작성자</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input type="text" class="form-control border-0" id="wrtUserNm" name="wrtUserNm" th:value="${info.wrtUserNm}" readonly> <th:block th:each="commonCode:${session.commonCode.get('JT')}">
<th:block th:if="${commonCode.itemCd eq info.wrtUserGrd}">
<input type="text" class="form-control border-0" id="wrtUserNm" name="wrtUserNm" th:value="|${commonCode.itemValue} ${info.wrtUserNm}|" readonly>
</th:block>
</th:block>
</div> </div>
<label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label> <label for="wrtDt" class="col-sm-1 col-form-label text-center">작성일시</label>
<div class="col-sm-2"> <div class="col-sm-2">
@ -102,6 +105,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq comment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${comment.wrtUserNm}"></div> <div class="col-auto" th:text="${comment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(comment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto"> <div class="col-auto">
@ -129,6 +135,9 @@
<th:block th:each="commonCode:${session.commonCode.get('OFC')}"> <th:block th:each="commonCode:${session.commonCode.get('OFC')}">
<div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtPart}" th:text="${commonCode.itemValue}"></div> <div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtPart}" th:text="${commonCode.itemValue}"></div>
</th:block> </th:block>
<th:block th:each="commonCode:${session.commonCode.get('JT')}">
<div class="col-auto" th:if="${commonCode.itemCd eq childComment.wrtUserGrd}" th:text="${commonCode.itemValue}"></div>
</th:block>
<div class="col-auto" th:text="${childComment.wrtUserNm}"></div> <div class="col-auto" th:text="${childComment.wrtUserNm}"></div>
<div class="col-auto" th:text="|작성일시: ${#temporals.format(childComment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div> <div class="col-auto" th:text="|작성일시: ${#temporals.format(childComment.wrtDt, 'yyyy-MM-dd HH:mm')}|"></div>
<div class="col-auto" th:if="${userSeq eq childComment.wrtUserSeq}"> <div class="col-auto" th:if="${userSeq eq childComment.wrtUserSeq}">