FAISP/src/main/resources/templates/faStatistics/fishingBoat/fishingBoatMgt.html

324 lines
19 KiB
HTML

<!DOCTYPE html>
<html lang="ko" xmlns:th="http://www.thymeleaf.org"
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/faStatistics/fishingBoatMgt.js}"></script>
</th:block>
<th:block layout:fragment="css">
<style>
#violationSelectDiv{
position: absolute;
top: 100px;
left: 710px;
display: none;
z-index: 10;
}
</style>
</th:block>
<div layout:fragment="content">
<main>
<input type="hidden" id="menuKey" value="51">
<div class="row justify-content-between">
<div class="col-auto">
<div class="d-inline align-middle"><i class="bi bi-square-fill"></i></div>
<h5 class="d-inline align-middle"> 불법조업 외국어선 정보</h5>
</div>
<div class="col-auto"><p class="mb-0 mt-2">외사통계 > 불법조업외국어선 > 불법조업 외국어선 정보</p></div>
</div>
<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">
<form method="get" th:action="@{/faStatistics/fishingBoat}" id="searchForm">
<input type="hidden" name="pageIndex" id="pageIndex" th:value="${searchParams.pageIndex}">
<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>
<select class="form-select form-select-sm" name="year" id="year">
<option value="">나포 연도</option>
<th:block th:each="year:${yearList}">
<option th:value="${year}" th:text="${year}" th:selected="${searchParams.year eq year}"></option>
</th:block>
</select>
</div>
<div class="col-8">
<div class="row">
<div class="col-11">
<div class="row justify-content-end pb-1">
<div class="col-2">
<select class="form-select form-select-sm" name="caseAgency">
<option value="">사건담당경찰서</option>
<th:block th:each="code:${session.commonCode.get('OG')}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.caseAgency}"></option>
</th:block>
</select>
</div>
<div class="col-2">
<select class="form-select form-select-sm" name="crackdownPolice" id="searchFormPolice">
<option value="">단속경찰서</option>
<th:block th:each="code:${session.commonCode.get('CPO')}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.crackdownPolice}"></option>
</th:block>
</select>
</div>
<div class="col-2">
<select class="form-select form-select-sm" name="crackdownBoat" id="searchFormBoat" disabled>
<option value="">단속함정</option>
<th:block th:each="cpoCode:${session.commonCode.get('CPO')}">
<th:block th:each="code:${session.commonCode.get(cpoCode)}">
<option th:if="${code.useChk eq 'T'}" th:class="${code.categoryCd}" th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.crackdownBoat}" style="display: none;"></option>
</th:block>
</th:block>
</select>
</div>
<div class="col-2">
<input type="text" class="form-control form-control-sm" placeholder="선명(한글)" name="boatNameKr" th:value="${searchParams.boatNameKr}">
</div>
</div>
<div class="row justify-content-end">
<div class="col-2">
<div class="input-group">
<input type="text" class="form-control form-control-sm" placeholder="선적지(성)" name="boatNnySung" th:value="${searchParams.boatNnySung}">
<input type="text" class="form-control form-control-sm" placeholder="선적지(시)" name="boatNnySi" th:value="${searchParams.boatNnySi}">
</div>
</div>
<div class="col-2">
<div class="input-group">
<input type="text" class="form-control form-control-sm" placeholder="톤수~" name="tonMin" th:value="${searchParams.tonMin>0?searchParams.tonMin:''}">
<input type="text" class="form-control form-control-sm" placeholder="톤수" name="tonMax" th:value="${searchParams.tonMax>0?searchParams.tonMax:''}">
</div>
</div>
<div class="col-2">
<select class="form-select form-select-sm" name="boatMaterial">
<option value="">선질</option>
<th:block th:each="code:${session.commonCode.get('BM')}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.boatMaterial}"></option>
</th:block>
</select>
</div>
<div class="col-2">
<select class="form-select form-select-sm" name="fisheryType">
<option value="">어업종류</option>
<th:block th:each="code:${session.commonCode.get('FT')}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.fisheryType}"></option>
</th:block>
</select>
</div>
</div>
<div class="row justify-content-end">
<div class="col-4">
<input type="text" class="form-control form-control-sm" id="violationInput" placeholder="위반형태" readonly>
<div class="bg-white border p-2 text-start" id="violationSelectDiv">
<th:block th:each="code:${session.commonCode.get('VT')}">
<div>
<input type="checkbox" name="violationList" class="violationParams" th:id="|violation${code.itemCd}|" th:value="${code.itemCd}" th:checked="${searchParams.violationList ne null?#lists.contains(searchParams.violationList, code.itemCd):false}">
<label th:for="|violation${code.itemCd}|" class="form-label col-form-label-sm mb-0" th:text="${code.itemValue}"></label>
</div>
</th:block>
</div>
</div>
<div class="col-2">
<select class="form-select form-select-sm" name="processStatus">
<option value="">처리현황</option>
<th:block th:each="code:${session.commonCode.get('PR')}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}" th:selected="${code.itemCd eq searchParams.processStatus}"></option>
</th:block>
</select>
</div>
<div class="col-4">
<div class="input-group w-auto input-daterange" id="dateSelectorDiv">
<select class="form-select form-select-sm w-30" name="dateSelector">
<option value="">조건선택</option>
<option value="napoDt" th:selected="${searchParams.dateSelector eq 'napoDt'}">나포일시</option>
<option value="evictionDt" th:selected="${searchParams.dateSelector eq 'evictionDt'}">퇴거일</option>
<option value="directHandoverDt" th:selected="${searchParams.dateSelector eq 'directHandoverDt'}">직접인계일</option>
<option value="consignmentDt" th:selected="${searchParams.dateSelector eq 'consignmentDt'}">위탁일</option>
<option value="confiscationDt" th:selected="${searchParams.dateSelector eq 'confiscationDt'}">몰수확정일</option>
<option value="boatDisposalDt" th:selected="${searchParams.dateSelector eq 'boatDisposalDt'}">폐선일</option>
<option value="returnDt" th:selected="${searchParams.dateSelector eq 'returnDt'}">환부일</option>
<option value="wrtDt" th:selected="${searchParams.dateSelector eq 'wrtDt'}">최종수정일</option>
</select>
<input type="text" class="form-control form-control-sm w-35" id="startDate" name="startDate" placeholder="시작일" autocomplete="off" readonly th:value="${searchParams.startDate}">
<input type="text" class="form-control form-control-sm w-35" id="endDate" name="endDate" placeholder="종료일" autocomplete="off" readonly th:value="${searchParams.endDate}">
</div>
</div>
</div>
</div>
<div class="col-1 d-grid gap-2">
<input type="submit" class="btn btn-lg btn-primary col-auto" id="searchBtn" value="검색">
</div>
</div>
</div>
</div>
</form>
<div class="card">
<div class="card-body">
<div class="row">
<div class="col-12 overflow-auto">
<table class="table table-sm table-hover table-bordered text-nowrap">
<thead class="align-middle">
<tr class="table-secondary">
<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>
</thead>
<tbody class="table-group-divider align-middle">
<tr class="crackdownStatusTr" th:each="crackdownStatus,cnt:${crackdownStatusList}">
<input type="hidden" class="cdsKey" th:value="${crackdownStatus.cdsKey}">
<td th:text="${cnt.count}"></td>
<td th:text="${#temporals.format(crackdownStatus.napoDt, 'yyyy-MM-dd HH:mm')}"></td>
<td>
<th:block th:text="${crackdownStatus.napoSeaPointLon}"></th:block>
<br>
<th:block th:text="${crackdownStatus.napoSeaPointLat}"></th:block>
</td>
<td>
<th:block th:each="code:${session.commonCode.get('OG')}">
<th:block th:if="${crackdownStatus.caseAgency eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td>
<th:block th:each="code:${session.commonCode.get('CPO')}">
<th:block th:if="${crackdownStatus.crackdownPolice eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td>
<th:block th:each="code:${session.commonCode.get(crackdownStatus.crackdownPolice)}">
<th:block th:if="${crackdownStatus.crackdownBoat eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td th:text="${crackdownStatus.boatNameKr}"></td>
<td th:text="${crackdownStatus.sailorNameKr}"></td>
<td>
<th:block th:each="code:${session.commonCode.get('FT')}">
<th:block th:if="${crackdownStatus.fisheryType eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td th:text="|${crackdownStatus.boatNnySung} ${crackdownStatus.boatNnySi}|"></td>
<td th:text="|${crackdownStatus.tonCnt ne null?crackdownStatus.tonCnt:'-'}t|"></td>
<td>
<th:block th:each="code:${session.commonCode.get('BM')}">
<th:block th:if="${crackdownStatus.boatMaterial eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td class="text-wrap min-width-300" th:text="${crackdownStatus.violationStr}"></td>
<td>
<th:block th:each="code:${session.commonCode.get('PR')}">
<th:block th:if="${crackdownStatus.processStatus eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</td>
<td>
<th:block th:each="code:${session.commonCode.get('OG')}">
<th:block th:if="${crackdownStatus.wrtOrgan eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:each="code:${session.commonCode.get('JT')}">
<th:block th:if="${crackdownStatus.wrtUserGrd eq code.itemCd}" th:text="${code.itemValue}"></th:block>
</th:block>
<th:block th:text="${crackdownStatus.wrtUserNm}"></th:block>
</td>
<td th:text="${#temporals.format(crackdownStatus.wrtDt, 'yyyy-MM-dd HH:mm')}"></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">&laquo;</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">&raquo;</span>
</a>
</li>
</th:block>
</ul>
</nav>
</div>
<div class="col-auto">
<input type="button" class="btn btn-success" value="등록" id="getFishingBoatEditModalBtn">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</main>
<div class="modal fade" id="fishingBoatEditModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="fishingBoatEditModalLabel" aria-hidden="true">
<div class="modal-dialog modal-xxl modal-dialog-scrollable">
<div class="modal-content" id="fishingBoatEditModalContent">
</div>
</div>
</div>
<div class="modal fade" id="fishingBoatViewModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="fishingBoatViewModalLabel" aria-hidden="true">
<div class="modal-dialog modal-xxl modal-dialog-scrollable">
<div class="modal-content" id="fishingBoatViewModalContent">
</div>
</div>
</div>
<div class="modal fade" id="crackdownSubModal" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="crackdownSubModalLabel" aria-hidden="true">
<div class="modal-dialog modal-xl modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header bg-dark">
<h5 class="modal-title text-white" id="crackdownSubModalLabel">단속현황 불러오기</h5>
<input type="hidden" id="modalUrl" value="/modal/crackdownStatusModal">
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body text-nowrap" id="subModalBody">
<div class="row">
<div class="col-12">
<form method="get" action="#" id="modalSearchForm">
<input type="hidden" name="pageIndex" id="modalPageIndex" value="1">
<input type="hidden" name="rowCnt" value="10">
</form>
</div>
</div>
</div>
<div class="modal-footer bg-light">
<button type="button" class="btn btn-primary" id="getCrackdownBtn">불러오기</button>
<!-- <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">닫기</button>-->
</div>
</div>
</div>
</div>
</div>
</html>