157 lines
8.3 KiB
HTML
157 lines
8.3 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="ko" xmlns:th="http://www.thymeleaf.org"
|
|
xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity5"
|
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
layout:decorate="~{layout/layout}">
|
|
<th:block layout:fragment="script">
|
|
<script type="text/javascript" th:src="@{/js/publicBoard/publicBoard.js}"></script>
|
|
<script type="text/javascript" th:src="@{/js/publicBoard/reference.js}"></script>
|
|
</th:block>
|
|
<div layout:fragment="content">
|
|
<main>
|
|
<h4 class="boardHeader">■ 자료실</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 bg-light text-center">
|
|
<div class="card-body">
|
|
<ul class="nav nav-tabs" id="boardTab" role="tablist">
|
|
<th:block th:each="tab:${tabStatusList}">
|
|
<li class="nav-item" role="presentation">
|
|
<button class="nav-link referenceTab" th:data-tabcd="${tab.itemCd}" th:classappend="${tab.itemCd eq searchParams.tabStatus?'active':''}" data-bs-toggle="tab" type="button" role="tab" th:text="${tab.itemValue}"></button>
|
|
</li>
|
|
</th:block>
|
|
</ul>
|
|
<div class="tab-content bg-white border border-top-0 p-3" id="userContent">
|
|
<form method="get" th:action="@{/publicBoard/referencePage}">
|
|
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
|
|
<input type="hidden" name="tabStatus" th:value="${searchParams.tabStatus}">
|
|
<div class="row justify-content-between py-1">
|
|
<div class="col-auto">
|
|
<select class="form-select form-select-sm" name="rowCnt" id="rowCnt">
|
|
<th:block th:each="num : ${#numbers.sequence(1,5)}">
|
|
<option th:value="${num*10}" th:text="${num*10}" th:selected="${searchParams.rowCnt eq num*10}"></option>
|
|
</th:block>
|
|
</select>
|
|
</div>
|
|
<div class="col-auto">
|
|
<div class="row justify-content-end">
|
|
<div class="col-auto" sec:authorize="hasRole('ROLE_SUB_ADMIN')">
|
|
<select class="form-select form-select-sm" name="wrtOrgan">
|
|
<option value="">관서 선택</option>
|
|
<th:block th:each="commonCode:${session.commonCode.get('OG')}">
|
|
<th:block th:if="${#lists.contains(mgtOrganList, commonCode.itemCd
|
|
)}">
|
|
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}" th:selected="${commonCode.itemCd eq searchParams.wrtOrgan}"></option>
|
|
</th:block>
|
|
</th:block>
|
|
</select>
|
|
</div>
|
|
<div class="col-auto">
|
|
<input type="text" class="form-control form-control-sm" placeholder="제목" name="title" th:value="${searchParams.title}">
|
|
</div>
|
|
<div class="col-4">
|
|
<div class="input-group w-auto input-daterange" id="dateSelectorDiv">
|
|
<input type="text" class="form-control form-control-sm" id="startDate" name="startDate" placeholder="시작일" autocomplete="off" readonly th:value="${searchParams.startDate}">
|
|
<input type="text" class="form-control form-control-sm" id="endDate" name="endDate" placeholder="종료일" autocomplete="off" readonly th:value="${searchParams.endDate}">
|
|
</div>
|
|
</div>
|
|
<div class="col-auto">
|
|
<input type="submit" class="btn btn-sm btn-primary" id="searchBtn" value="검색">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
<div class="row">
|
|
<div class="col-12">
|
|
<table class="table table-sm table-hover table-bordered">
|
|
<thead>
|
|
<tr class="table-color">
|
|
<th></th>
|
|
<th>제목</th>
|
|
<th>관서</th>
|
|
<th>부서</th>
|
|
<th>계급</th>
|
|
<th>작성자</th>
|
|
<th>작성일시</th>
|
|
<th>첨부파일</th>
|
|
<th>댓글</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody class="table-group-divider">
|
|
<tr class="planTr" th:each="reference:${referenceList}">
|
|
<input type="hidden" class="planKey" th:value="${reference.publicKey}">
|
|
<td><input type="checkbox" class="trChkBox"></td>
|
|
<td align="left" th:text="${reference.title}"></td>
|
|
<th:block th:each="commonCode:${session.commonCode.get('OG')}">
|
|
<td th:if="${reference.wrtOrgan eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
|
|
</th:block>
|
|
<th:block th:each="commonCode:${session.commonCode.get('OFC')}">
|
|
<td th:if="${reference.wrtPart eq commonCode.itemCd}" th:text="${commonCode.itemValue}"></td>
|
|
</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="${#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.commentCnt eq null?'0':reference.commentCnt}"></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="row justify-content-between">
|
|
<div class="col-auto"></div>
|
|
<div class="col-auto">
|
|
<nav aria-label="Page navigation">
|
|
<ul class="pagination mb-0">
|
|
<th:block th:if="${searchParams.pageIndex>3}">
|
|
<li class="page-item" th:data-pageindex="${(searchParams.pageIndex)-3}">
|
|
<a class="page-link" href="#" aria-label="Previous">
|
|
<span aria-hidden="true">«</span>
|
|
</a>
|
|
</li>
|
|
</th:block>
|
|
<th:block th:each="num : ${#numbers.sequence(searchParams.startNum, searchParams.endNum)}">
|
|
<li class="page-item" th:data-pageindex="${num}" th:classappend="${searchParams.pageIndex eq num?'active':''}">
|
|
<a class="page-link" href="#" th:text="${num}"></a>
|
|
</li>
|
|
</th:block>
|
|
<th:block th:if="${searchParams.maxNum>searchParams.endNum+2}">
|
|
<li class="page-item" th:data-pageindex="${(searchParams.pageIndex)+3}">
|
|
<a class="page-link" href="#" aria-label="Next">
|
|
<span aria-hidden="true">»</span>
|
|
</a>
|
|
</li>
|
|
</th:block>
|
|
</ul>
|
|
</nav>
|
|
</div>
|
|
<div class="col-auto">
|
|
<input type="button" class="btn btn-success" value="등록" id="addReferenceBtn">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</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-dialog modal-xl modal-dialog-scrollable">
|
|
<div class="modal-content" id="editContent">
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="modal fade" id="viewModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="viewModalLabel" aria-hidden="true">
|
|
<div class="modal-dialog modal-xl modal-dialog-scrollable">
|
|
<div class="modal-content" id="viewContent">
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</html> |