중간저장

master
강석 최 2022-01-03 12:36:10 +09:00
parent 21a36958ab
commit 422bb5630c
3 changed files with 65 additions and 59 deletions

View File

@ -55,7 +55,7 @@ public class BoardService {
@Transactional @Transactional
public Integer saveContent(Board content){ public Integer saveContent(Board content){
Integer contentSeq = boardRepository.save(content).getContentSeq(); Integer contentSeq = boardRepository.save(content).getContentSeq();
saveBoardLog(content.getContentSeq(), LogStatus.WRITE, null, content.getCreateId()); saveBoardLog(content.getContentSeq(), LogStatus.WRITE, content.getTitle(), content.getCreateId());
saveHashTagLink(contentSeq, content.getHashTagStr()); saveHashTagLink(contentSeq, content.getHashTagStr());
saveUploadFiles(content, content.getCreateId()); saveUploadFiles(content, content.getCreateId());
return contentSeq; return contentSeq;

View File

@ -30,9 +30,9 @@
<div class="card-body"> <div class="card-body">
<div class="row justify-content-start"> <div class="row justify-content-start">
<div class="col-4"> <div class="col-4">
<h5><i class="bi bi-square-fill"></i><span> 저장공간</span></h5> <h5 class="mx-2"><i class="bi bi-square-fill"></i><span> 저장공간</span></h5>
<th:block th:each="diskInfo:${diskInfoList}"> <th:block th:each="diskInfo:${diskInfoList}">
<div class="row justify-content-center py-3 border rounded"> <div class="row justify-content-center py-3 m-2 border rounded">
<div class="col-12"><h5 th:text="${diskInfo.driveName}"></h5></div> <div class="col-12"><h5 th:text="${diskInfo.driveName}"></h5></div>
<div class="col-auto"> <div class="col-auto">
<div class="pie-chart" th:style="|background: conic-gradient(#ACACAC 0% ${diskInfo.useSizePer}%, #26A0DA ${diskInfo.useSizePer}% 100%)|"> <div class="pie-chart" th:style="|background: conic-gradient(#ACACAC 0% ${diskInfo.useSizePer}%, #26A0DA ${diskInfo.useSizePer}% 100%)|">
@ -48,60 +48,66 @@
</th:block> </th:block>
</div> </div>
<div class="col-8"> <div class="col-8">
<h5><i class="bi bi-square-fill"></i><span> 전체 이력</span></h5> <h5 class="mx-2"><i class="bi bi-square-fill"></i><span> 전체 이력</span></h5>
<table class="table table-striped table-hover"> <div class="row p-3 mx-2 border rounded">
<thead> <div class="col-12">
<tr> <table class="table table-striped table-hover">
<th>제목</th> <thead>
<th>행동</th> <tr>
<th>내용</th> <th>제목</th>
<th>사용자</th> <th>행동</th>
<th>발생일시</th> <th>내용</th>
</tr> <th>사용자</th>
</thead> <th>발생일시</th>
<tbody> </tr>
<th:block th:each="log:${boardLogList}"> </thead>
<tr> <tbody>
<td colspan="5" class="p-0"> <th:block th:each="log:${boardLogList}">
<a class="fs-6 text-decoration-none" th:href="|/board/contentList?categorySeq=${log.categorySeq}|" <tr>
th:text="${log.categoryName}"></a> <td colspan="5" class="p-0">
</td> <a class="fs-6 text-decoration-none" th:href="|/board/contentList?categorySeq=${log.categorySeq}|"
</tr> th:text="${log.categoryName}"></a>
<tr> </td>
<td th:text="${log.title}"></td> </tr>
<td th:text="${statusMap.get(log.logStatus)}"></td> <tr>
<td th:text="${log.description}"></td> <td th:text="${log.title}"></td>
<td th:text="${log.createName}"></td> <td th:text="${statusMap.get(log.logStatus)}"></td>
<td th:text="${#temporals.format(log.createDate, 'yyyy-MM-dd HH:mm:ss')}"></td> <td th:text="${log.description}"></td>
</tr> <td th:text="${log.createName}"></td>
</th:block> <td th:text="${#temporals.format(log.createDate, 'yyyy-MM-dd HH:mm:ss')}"></td>
</tbody> </tr>
</table> </th:block>
<div class="row justify-content-center"> </tbody>
<div class="col-auto"> </table>
<nav aria-label="Page navigation"> </div>
<ul class="pagination"> <div class="col-12">
<th:block th:if="${searchParams.pageIndex>3}"> <div class="row justify-content-center">
<li class="page-item"> <div class="col-auto">
<a class="page-link" th:href="|/admin/main?pageIndex=${(searchParams.pageIndex)-3}|" aria-label="Previous"> <nav aria-label="Page navigation">
<span aria-hidden="true">&laquo;</span> <ul class="pagination">
</a> <th:block th:if="${searchParams.pageIndex>3}">
</li> <li class="page-item">
</th:block> <a class="page-link" th:href="|/admin/main?pageIndex=${(searchParams.pageIndex)-3}|" aria-label="Previous">
<th:block th:each="num : ${#numbers.sequence(searchParams.startNum, searchParams.endNum)}"> <span aria-hidden="true">&laquo;</span>
<li class="page-item" th:classappend="${searchParams.pageIndex==num?'active':''}"> </a>
<a class="page-link" th:href="|/admin/main?pageIndex=${(num)}|" th:text="${num}"></a> </li>
</li> </th:block>
</th:block> <th:block th:each="num : ${#numbers.sequence(searchParams.startNum, searchParams.endNum)}">
<th:block th:if="${searchParams.maxNum>searchParams.endNum+2}"> <li class="page-item" th:classappend="${searchParams.pageIndex==num?'active':''}">
<li class="page-item"> <a class="page-link" th:href="|/admin/main?pageIndex=${(num)}|" th:text="${num}"></a>
<a class="page-link" th:href="|/admin/main?pageIndex=${(searchParams.pageIndex)+3}|" aria-label="Next"> </li>
<span aria-hidden="true">&raquo;</span> </th:block>
</a> <th:block th:if="${searchParams.maxNum>searchParams.endNum+2}">
</li> <li class="page-item">
</th:block> <a class="page-link" th:href="|/admin/main?pageIndex=${(searchParams.pageIndex)+3}|" aria-label="Next">
</ul> <span aria-hidden="true">&raquo;</span>
</nav> </a>
</li>
</th:block>
</ul>
</nav>
</div>
</div>
</div> </div>
</div> </div>
</div> </div>

View File

@ -19,10 +19,10 @@
<!-- 컨텐츠페이지의 CSS 영역이 들어감 --> <!-- 컨텐츠페이지의 CSS 영역이 들어감 -->
<th:block layout:fragment="css"></th:block> <th:block layout:fragment="css"></th:block>
<!--bootstrap-->
<script type="text/javascript" th:src="@{/vendor/bootstrap-5.1.3-dist/js/bootstrap.bundle.min.js}"></script>
<!--jquery--> <!--jquery-->
<script type="text/javascript" th:src="@{/vendor/jquery-3.6.0/jquery-3.6.0.min.js}"></script> <script type="text/javascript" th:src="@{/vendor/jquery-3.6.0/jquery-3.6.0.min.js}"></script>
<!--bootstrap-->
<script type="text/javascript" th:src="@{/vendor/bootstrap-5.1.3-dist/js/bootstrap.min.js}"></script>
<!--bootstrap-datepicker--> <!--bootstrap-datepicker-->
<script type="text/javascript" th:src="@{/vendor/bootstrap-datepicker-1.9.0-dist/js/bootstrap-datepicker.min.js}"></script> <script type="text/javascript" th:src="@{/vendor/bootstrap-datepicker-1.9.0-dist/js/bootstrap-datepicker.min.js}"></script>
<script type="text/javascript" th:src="@{/vendor/bootstrap-datepicker-1.9.0-dist/locales/bootstrap-datepicker.ko.min.js}"></script> <script type="text/javascript" th:src="@{/vendor/bootstrap-datepicker-1.9.0-dist/locales/bootstrap-datepicker.ko.min.js}"></script>