FAISP/src/main/resources/templates/faRpt/faRptViewModal.html

129 lines
6.6 KiB
HTML

<!DOCTYPE html>
<html lang="ko" xmlns:th="http://www.thymeleaf.org">
<div class="modal-header bg-dark">
<h5 class="modal-title text-white" id="faRptViewModalLabel">외사정보보고 열람</h5>
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body" id="faRptViewBody">
<input type="hidden" id="faRptKey" th:value="${faRpt.faRptKey}">
<ul class="nav nav-tabs" id="userTab" role="tablist">
<li class="nav-item" role="presentation">
<button class="nav-link active" id="boardTab" data-bs-toggle="tab" data-bs-target="#boardTabPanel" type="button" role="tab" aria-controls="boardTabPanel" aria-selected="true">본문</button>
</li>
<li class="nav-item" role="presentation">
<button class="nav-link" id="readUserTab" data-bs-toggle="tab" data-bs-target="#readUserTabPanel" type="button" role="tab" aria-controls="readUserTabPanel" aria-selected="false">수신자</button>
</li>
<li class="nav-item" role="presentation" th:if="${#lists.size(faRpt.fileList)>0}">
<button class="nav-link" id="fileTab" data-bs-toggle="tab" data-bs-target="#fileTabPanel" type="button" role="tab" aria-controls="fileTabPanel" aria-selected="false" th:text="${#strings.concat('첨부파일(', #lists.size(faRpt.fileList), ')')}"></button>
</li>
</ul>
<div class="tab-content bg-white border border-top-0 p-2">
<div class="tab-pane fade p-2 show active" id="boardTabPanel" role="tabpanel" tabindex="0">
<div class="row mb-1">
<label class="col-sm-1 col-form-label col-form-label-sm text-center">분류</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start">
<th:block th:each="code:${session.commonCode.get('FRC')}">
<th:block th:if="${code.itemCd eq faRpt.faRptType}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
<div class="col-6"></div>
<label class="col-sm-1 col-form-label col-form-label-sm text-center">작성일시</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${#temporals.format(faRpt.wrtDt, 'yyyy-MM-dd HH:mm')}"></label>
<label class="col-sm-1 col-form-label col-form-label-sm text-center">제목</label>
<label class="col-sm-8 col-form-label col-form-label-sm text-start" th:text="${faRpt.title}"></label>
<label class="col-sm-1 col-form-label col-form-label-sm text-center">작성자</label>
<label class="col-sm-2 col-form-label col-form-label-sm text-start" th:text="${faRpt.wrtUserNm}"></label>
</div>
<hr class="my-1">
<div class="row mb-1 justify-content-center">
<label class="col-sm-1 col-form-label col-form-label-sm text-center">내용</label>
<div class="col-sm-11 form-control-sm view-modal-content" th:utext="${faRpt.content}"></div>
</div>
<hr class="my-1">
<div class="row mb-1">
<label class="col-sm-1 col-form-label col-form-label-sm text-center">해시태그</label>
<label class="col-sm-11 col-form-label col-form-label-sm text-start" th:text="${faRpt.hashTags}"></label>
</div>
</div>
<div class="tab-pane fade p-2" id="readUserTabPanel" role="tabpanel" tabindex="0">
<div class="row table-secondary">
<div class="col-1">no</div>
<div class="col-9">수신자</div>
<div class="col-2">열람</div>
</div>
<hr class="my-1">
<div class="row">
<div class="col-12">
<th:block th:each="readUser, idx:${faRpt.readUserList}">
<div class="row my-1">
<div class="col-1" th:text="${idx.index+1}"></div>
<div class="col-9">
<th:block th:each="code:${session.commonCode.get('OG')}">
<th:block th:if="${code.itemCd eq readUser.ogCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:each="code:${session.commonCode.get(readUser.ogCd)}">
<th:block th:if="${code.itemCd eq readUser.ofcCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:each="code:${session.commonCode.get('JT')}">
<th:block th:if="${code.itemCd eq readUser.titleCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:text="${readUser.userNm}"></th:block>
</div>
<div class="col-2">
<th:block th:text="${readUser.readYn eq 'T'?'O':'X'}"></th:block>
</div>
</div>
</th:block>
</div>
</div>
</div>
<div class="tab-pane fade p-2" id="fileTabPanel" role="tabpanel" tabindex="0">
<div class="row mb-3">
<div class="col-sm-12">
<table class="table table-sm" id="fileTable">
<thead>
<tr class="table-secondary">
<th>파일명</th>
<th>사이즈</th>
</tr>
</thead>
<tbody>
<th:block th:if="${#lists.isEmpty(faRpt.fileList)}">
<tr>
<td colspan="2">파일이 없습니다.</td>
</tr>
</th:block>
<th:block th:unless="${#lists.isEmpty(faRpt.fileList)}">
<th:block th:each="file:${faRpt.fileList}">
<tr class="fileInfoTr">
<td>
<a href="#" class="fileDownLink" data-board="faRpt"
th:data-parentkey="${file.faRptKey}" th:data-fileseq="${file.fileSeq}"
th:text="|${file.origNm}.${file.fileExtn}|"></a>
</td>
<td th:text="${file.fileSize}"></td>
</tr>
</th:block>
</th:block>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
<div class="modal-footer bg-light">
<th:block th:if="${userSeq eq faRpt.wrtUserSeq or accessAuth eq 'ACC003'}">
<button type="button" class="btn btn-danger" id="deleteBtn" th:data-farptkey="${faRpt.faRptKey}">삭제</button>
<button type="button" class="btn btn-warning" id="editFaRptBtn" th:data-farptkey="${faRpt.faRptKey}">수정</button>
</th:block>
<th:block th:each="readUser:${faRpt.readUserList}">
<th:block th:if="${readUser.userSeq eq userSeq}">
<button type="button" class="btn btn-warning" id="addReceiveUserBtn" th:data-farptkey="${faRpt.faRptKey}">수신자 추가</button>
<button type="button" class="btn btn-success" id="reSendBtn" th:data-farptkey="${faRpt.faRptKey}">회신</button>
</th:block>
</th:block>
<!--
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>
-->
</div>