선원세부현황 작업완료.

master
강석 최 2023-07-14 18:01:57 +09:00
parent 95d82e128d
commit eb17d055fa
11 changed files with 372 additions and 209 deletions

View File

@ -9,6 +9,7 @@ import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.fishingBoat.Illega
import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.processResult.ShipProcessInfo; import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.processResult.ShipProcessInfo;
import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.processResult.ShipProcessInfoHistory; import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.processResult.ShipProcessInfoHistory;
import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.sailor.IllegalShipSailor; import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.sailor.IllegalShipSailor;
import com.dbnt.faisp.main.faStatistics.unlawfulFishing.model.sailor.IllegalShipSailorHistory;
import com.dbnt.faisp.main.faStatistics.unlawfulFishing.service.UnlawfulFishingService; import com.dbnt.faisp.main.faStatistics.unlawfulFishing.service.UnlawfulFishingService;
import com.dbnt.faisp.main.userInfo.model.UserInfo; import com.dbnt.faisp.main.userInfo.model.UserInfo;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
@ -161,7 +162,7 @@ public class UnlawfulFishingController {
} }
@PostMapping("/deleteIllegalShipInfo") @PostMapping("/deleteIllegalShipInfo")
public void deleteIllegalShipInfo(IllegalShipInfo illegalShipInfo){ public void deleteIllegalShipInfo(@RequestBody IllegalShipInfo illegalShipInfo){
unlawfulFishingService.deleteIllegalShipInfo(illegalShipInfo.getFbKey()); unlawfulFishingService.deleteIllegalShipInfo(illegalShipInfo.getFbKey());
} }
@ -240,7 +241,7 @@ public class UnlawfulFishingController {
} }
@PostMapping("/deleteShipProcessInfo") @PostMapping("/deleteShipProcessInfo")
public void deleteShipProcessInfo(ShipProcessInfo shipProcessInfo){ public void deleteShipProcessInfo(@RequestBody ShipProcessInfo shipProcessInfo){
unlawfulFishingService.deleteShipProcessInfo(shipProcessInfo.getPrKey()); unlawfulFishingService.deleteShipProcessInfo(shipProcessInfo.getPrKey());
} }
@ -284,11 +285,23 @@ public class UnlawfulFishingController {
unlawfulFishingService.saveIllegalShipSailorList(sailorList); unlawfulFishingService.saveIllegalShipSailorList(sailorList);
} }
@PostMapping("/saveIllegalShipSailor")
public void saveIllegalShipSailor(@AuthenticationPrincipal UserInfo loginUser, IllegalShipSailor sailorInfo){
sailorInfo.setWrtOrgan(loginUser.getOgCd());
sailorInfo.setWrtPart(loginUser.getOfcCd());
sailorInfo.setWrtUserSeq(loginUser.getUserSeq());
sailorInfo.setWrtUserGrd(loginUser.getTitleCd());
sailorInfo.setWrtUserNm(loginUser.getUserNm());
sailorInfo.setWrtDt(LocalDateTime.now());
unlawfulFishingService.saveIllegalShipSailor(sailorInfo);
}
@GetMapping("/issEditModal") @GetMapping("/issEditModal")
public ModelAndView illegalShipSailorEditModal(@AuthenticationPrincipal UserInfo loginUser, IllegalShipSailor illegalShipSailor){ public ModelAndView illegalShipSailorEditModal(@AuthenticationPrincipal UserInfo loginUser, IllegalShipSailor illegalShipSailor){
ModelAndView mav = new ModelAndView("faStatistics/unlawfulFishing/illegalShipSailor/issEditModal"); ModelAndView mav = new ModelAndView("faStatistics/unlawfulFishing/illegalShipSailor/issEditModal");
illegalShipSailor = unlawfulFishingService.selectIllegalShipSailor(illegalShipSailor.getSailorKey()); illegalShipSailor = unlawfulFishingService.selectIllegalShipSailor(illegalShipSailor.getSailorKey());
mav.addObject("illegalShipSailor", illegalShipSailor); mav.addObject("illegalShipSailor", illegalShipSailor);
mav.addObject("illegalShipInfo", unlawfulFishingService.selectIllegalShipInfo(illegalShipSailor.getFbKey()));
return mav; return mav;
} }
@GetMapping("/issViewModal") @GetMapping("/issViewModal")
@ -307,6 +320,17 @@ public class UnlawfulFishingController {
mav.addObject("userSeq", loginUser.getUserSeq()); mav.addObject("userSeq", loginUser.getUserSeq());
return mav; return mav;
} }
@GetMapping("/issHistoryDiv")
public ModelAndView illegalShipSailorHistoryDiv(IllegalShipSailorHistory history){
ModelAndView mav = new ModelAndView("faStatistics/unlawfulFishing/illegalShipSailor/issHistoryDiv");
mav.addObject("illegalShipSailor", unlawfulFishingService.selectIllegalShipSailorHistory(history.getSailorKey(), history.getVersionNo()));
return mav;
}
@PostMapping("/deleteIllegalShipSailor")
public void deleteIllegalShipSailor(@RequestBody IllegalShipSailor sailor){
unlawfulFishingService.deleteIllegalShipSailor(sailor.getSailorKey());
}
@GetMapping("/crackdownStatusVersionInfo") @GetMapping("/crackdownStatusVersionInfo")
public ModelAndView selectUnlawfulFishingVersionInfo(Integer cdsKey, Integer versionNo){ public ModelAndView selectUnlawfulFishingVersionInfo(Integer cdsKey, Integer versionNo){

View File

@ -33,8 +33,8 @@ public class IllegalShipSailorHistory extends SailorBaseEntity {
@NoArgsConstructor @NoArgsConstructor
@AllArgsConstructor @AllArgsConstructor
public static class IllegalShipSailorHistoryId implements Serializable { public static class IllegalShipSailorHistoryId implements Serializable {
private Integer versionNo;
private Integer sailorKey; private Integer sailorKey;
private Integer versionNo;
} }
/*@Transient /*@Transient

View File

@ -19,4 +19,8 @@ public interface IllegalShipSailorRepository extends JpaRepository<IllegalShipSa
void deleteAllByIdInQuery(@Param("idList") List<Integer> sailorDeleteKeyList); void deleteAllByIdInQuery(@Param("idList") List<Integer> sailorDeleteKeyList);
Optional<IllegalShipSailor> findBySailorKey(Integer sailorKey); Optional<IllegalShipSailor> findBySailorKey(Integer sailorKey);
@Modifying(clearAutomatically = true)
@Query("update IllegalShipSailor set status = :status where sailorKey = :sailorKey")
void bulkModifyingBySailorKeyToStatus(Integer sailorKey, String status);
} }

View File

@ -256,6 +256,24 @@ public class UnlawfulFishingService {
isshRepository.saveAll(historyList); isshRepository.saveAll(historyList);
} }
public void saveIllegalShipSailor(IllegalShipSailor sailorInfo) {
if(sailorInfo.getStatus().equals("DST007")){
IllegalShipSailorHistory lastHistory = isshRepository.findTopBySailorKeyOrderByVersionNoDesc(sailorInfo.getSailorKey()).orElse(null);
IllegalShipSailorHistory history = new IllegalShipSailorHistory();
BeanUtils.copyProperties(sailorInfo, history);
history.setVersionNo(lastHistory==null?1:(lastHistory.getVersionNo()+1));
isshRepository.save(history);
if(lastHistory!=null){
sailorInfo.setWrtOrgan(lastHistory.getWrtOrgan());
sailorInfo.setWrtPart(lastHistory.getWrtPart());
sailorInfo.setWrtUserSeq(lastHistory.getWrtUserSeq());
sailorInfo.setWrtUserGrd(lastHistory.getWrtUserGrd());
sailorInfo.setWrtUserNm(lastHistory.getWrtUserNm());
}
}
issRepository.save(sailorInfo);
}
public List<IllegalShipSailor> selectIllegalShipSailorList(UnlawfulFishingParam params) { public List<IllegalShipSailor> selectIllegalShipSailorList(UnlawfulFishingParam params) {
return unlawfulFishingMapper.selectIllegalShipSailorList(params); return unlawfulFishingMapper.selectIllegalShipSailorList(params);
} }
@ -267,4 +285,13 @@ public class UnlawfulFishingService {
public List<IllegalShipSailorHistory> selectIllegalShipSailorHistoryList(Integer sailorKey) { public List<IllegalShipSailorHistory> selectIllegalShipSailorHistoryList(Integer sailorKey) {
return isshRepository.findBySailorKeyOrderByVersionNoDesc(sailorKey); return isshRepository.findBySailorKeyOrderByVersionNoDesc(sailorKey);
} }
public IllegalShipSailorHistory selectIllegalShipSailorHistory(Integer sailorKey, Integer versionNo) {
return isshRepository.findById(new IllegalShipSailorHistory.IllegalShipSailorHistoryId(sailorKey, versionNo)).orElse(null);
}
@Transactional
public void deleteIllegalShipSailor(Integer sailorKey) {
issRepository.bulkModifyingBySailorKeyToStatus(sailorKey, "DST008");
}
} }

View File

@ -188,6 +188,8 @@
inner join illegal_ship_info b on a.fb_key = b.fb_key inner join illegal_ship_info b on a.fb_key = b.fb_key
inner join crackdown_info c on b.cds_key = c.cds_key inner join crackdown_info c on b.cds_key = c.cds_key
<include refid="selectShipProcessInfoListWhere"></include> <include refid="selectShipProcessInfoListWhere"></include>
order by a.wrt_dt desc
limit #{rowCnt} offset #{firstIndex}
</select> </select>
<select id="selectShipProcessInfoListCnt" resultType="int" parameterType="UnlawfulFishingParam"> <select id="selectShipProcessInfoListCnt" resultType="int" parameterType="UnlawfulFishingParam">
select count(*) select count(*)
@ -221,6 +223,8 @@
inner join illegal_ship_info isi on iss.fb_key = isi.fb_key inner join illegal_ship_info isi on iss.fb_key = isi.fb_key
inner join crackdown_info ci on isi.cds_key = ci.cds_key inner join crackdown_info ci on isi.cds_key = ci.cds_key
<include refid="selectIllegalShipSailorListWhere"></include> <include refid="selectIllegalShipSailorListWhere"></include>
order by a.wrt_dt desc
limit #{rowCnt} offset #{firstIndex}
</select> </select>
<select id="selectIllegalShipSailorListCnt" resultType="int" parameterType="UnlawfulFishingParam"> <select id="selectIllegalShipSailorListCnt" resultType="int" parameterType="UnlawfulFishingParam">

View File

@ -43,8 +43,33 @@ $(document).on('click', '.deleteTab', function (){
targetLi.parents("li").remove() targetLi.parents("li").remove()
targetContent.remove() targetContent.remove()
}) })
$(document).on('click', '.saveEditInfoBtn', function (){ $(document).on('click', '.saveEditInfoBtn', function (){
if(confirm("저장하시겠습니까?")){
const form = $("#issEditForm");
form.find("#infoStatus").val($(this).attr('data-status'))
const formData = new FormData(form[0]);
$.ajax({
type : 'POST',
data : formData,
url : "/unlawfulFishing/saveIllegalShipSailor",
processData: false,
contentType: false,
beforeSend: function (xhr){
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
},
success : function(result) {
alert("저장되었습니다.");
contentFade("out");
location.reload();
},
error : function(xhr, status) {
alert("저장에 실패하였습니다.")
contentFade("out");
}
})
}
})
$(document).on('click', '.saveAllInfoBtn', function (){
if(confirm("저장하시겠습니까?")){ if(confirm("저장하시겠습니까?")){
const sailorList = []; const sailorList = [];
const fbKey = $("#fbKey").val() const fbKey = $("#fbKey").val()
@ -93,6 +118,66 @@ $(document).on('click', '.sailorTr', function (){
getIssViewModal($(this).attr('data-sailorkey')) getIssViewModal($(this).attr('data-sailorkey'))
}) })
$(document).on('click', '#deleteSailorInfoBtn', function (){
deleteIllegalShipSailor($(".sailorKey").val());
})
$(document).on('click', '#editSailorInfoBtn', function (){
$("#issViewModal").modal('hide');
getIssEditModal($(".sailorKey").val());
})
$(document).on('click', '.versionInfoTr', function (){
const versionInfoTr = $(this)
$(".versionInfoChkbox").prop("checked", false);
versionInfoTr.find(".versionInfoChkbox").prop("checked", true);
getIssHistory(versionInfoTr.find(".sailorKey").val(), versionInfoTr.find(".versionNo").val());
})
$(document).on('click', '#sailorInfoViewTab', function (){
$("#issViewModal").find(".modal-dialog")[0].className="modal-dialog modal-xl modal-dialog-scrollable";
})
$(document).on('click', '#sailorInfoVersionTab', function (){
$("#issViewModal").find(".modal-dialog")[0].className="modal-dialog modal-xxl modal-dialog-scrollable";
})
function getIssHistory(sailorKey, versionNo){
$.ajax({
url: '/unlawfulFishing/issHistoryDiv',
data: {sailorKey: sailorKey, versionNo: versionNo},
type: 'GET',
dataType:"html",
success: function(html){
$("#versionInfoDiv").empty().append(html)
},
error:function(e){
ajaxErrorAction(e);
}
});
}
function deleteIllegalShipSailor(sailorKey){
if(confirm("삭제하시겠습니까?\n되돌릴 수 없습니다.")){
contentFade("in");
$.ajax({
type : 'POST',
data : JSON.stringify({sailorKey: Number(sailorKey)}),
url : "/unlawfulFishing/deleteIllegalShipSailor",
contentType: 'application/json',
beforeSend: function (xhr){
xhr.setRequestHeader($("[name='_csrf_header']").val(), $("[name='_csrf']").val());
},
success : function(result) {
alert("삭제되었습니다.");
location.reload();
},
error : function(xhr, status) {
alert("삭제를 실패하였습니다.")
contentFade("out");
}
})
}
}
function getIssAddModal(){ function getIssAddModal(){
$.ajax({ $.ajax({
url: '/unlawfulFishing/issAddModal', url: '/unlawfulFishing/issAddModal',

View File

@ -11,9 +11,9 @@ $(document).on('click', '.isiTr', function (){
$(document).on('click', '#isiSelectBtn', function (){ $(document).on('click', '#isiSelectBtn', function (){
const selectedCheckbox = $(".isiCheckbox:checked") const selectedCheckbox = $(".isiCheckbox:checked")
if(selectedCheckbox.length>0){ if(selectedCheckbox.length>0){
const editModalBody = $("#editModalBody") const activeModal = $(".modal.fade.show")
editModalBody.find("#fbKey").val(selectedCheckbox.attr('data-fbkey')) activeModal.find("#fbKey").val(selectedCheckbox.attr('data-fbkey'))
editModalBody.find("#boatNameKr").val(selectedCheckbox.attr('data-boatnamekr')) activeModal.find("#boatNameKr").val(selectedCheckbox.attr('data-boatnamekr'))
$("#isiSelectModal").modal('hide'); $("#isiSelectModal").modal('hide');
}else{ }else{
alert("대상을 선택해주세요.") alert("대상을 선택해주세요.")

View File

@ -4,7 +4,7 @@
<h5 class="modal-title text-white" id="issEditModalLabel">선원 세부 현황 작성</h5> <h5 class="modal-title text-white" id="issEditModalLabel">선원 세부 현황 작성</h5>
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button> <button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div> </div>
<div class="modal-body" id="editModalBody"> <div class="modal-body">
<form action="#" method="post" id="issAddForm"> <form action="#" method="post" id="issAddForm">
<div class="row px-2 mb-1"> <div class="row px-2 mb-1">
<label for="boatNameKr" class="col-sm-2 col-form-label col-form-label-sm text-center">선명</label> <label for="boatNameKr" class="col-sm-2 col-form-label col-form-label-sm text-center">선명</label>
@ -141,7 +141,7 @@
</div> </div>
<div class="modal-footer bg-light"> <div class="modal-footer bg-light">
<!--<button type="button" class="btn btn-warning saveEditInfoBtn" data-status="DST001">임시저장</button>--> <!--<button type="button" class="btn btn-warning saveEditInfoBtn" data-status="DST001">임시저장</button>-->
<button type="button" class="btn btn-primary saveEditInfoBtn" data-status="DST007">저장</button> <button type="button" class="btn btn-primary saveAllInfoBtn" data-status="DST007">저장</button>
</div> </div>
<div class="d-none" id="sailorTabEmptyLi"> <div class="d-none" id="sailorTabEmptyLi">

View File

@ -5,40 +5,42 @@
<button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button> <button type="button" class="btn-close f-invert" data-bs-dismiss="modal" aria-label="Close"></button>
</div> </div>
<div class="modal-body"> <div class="modal-body">
<form action="#" method="post" id="csEditForm"> <form action="#" method="post" id="issEditForm">
<input type="hidden" name="cdsKey" id="cdsKey" th:value="${illegalShipSailor.sailorKey}"> <input type="hidden" name="sailorKey" id="sailorKey" th:value="${illegalShipSailor.sailorKey}">
<input type="hidden" class="status" name="status" id="infoStatus" th:value="${illegalShipSailor.status}"> <input type="hidden" class="status" name="status" id="infoStatus" th:value="${illegalShipSailor.status}">
<input type="hidden" name="wrtOrgan" th:value="${illegalShipSailor.wrtOrgan}"> <input type="hidden" name="wrtOrgan" th:value="${illegalShipSailor.wrtOrgan}">
<input type="hidden" name="wrtPart" th:value="${illegalShipSailor.wrtPart}"> <input type="hidden" name="wrtPart" th:value="${illegalShipSailor.wrtPart}">
<input type="hidden" name="wrtUserSeq" th:value="${illegalShipSailor.wrtUserSeq}"> <input type="hidden" name="wrtUserSeq" th:value="${illegalShipSailor.wrtUserSeq}">
<input type="hidden" name="wrtUserGrd" th:value="${illegalShipSailor.wrtUserGrd}"> <input type="hidden" name="wrtUserGrd" th:value="${illegalShipSailor.wrtUserGrd}">
<input type="hidden" name="wrtUserNm" th:value="${illegalShipSailor.wrtUserNm}"> <input type="hidden" name="wrtUserNm" th:value="${illegalShipSailor.wrtUserNm}">
<input type="hidden" name="wrtDt" th:value="${#temporals.format(illegalShipSailor.wrtDt, 'yyyy-MM-dd HH:mm:ss')}"> <input type="hidden" name="wrtDt" th:value="${#temporals.format(illegalShipSailor.wrtDt, 'yyyy-MM-dd HH:mm')}">
<div class="row mb-1"> <div class="row mb-1">
<label for="caseNum" class="col-sm-1 col-form-label col-form-label-sm text-center">선명</label> <label for="boatNameKr" class="col-sm-1 col-form-label col-form-label-sm text-center">선명</label>
<div class="col-sm-2"> <div class="col-sm-2">
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control form-control-sm " id="caseNum" name="caseNum"> <input type="hidden" class="fbKey" name="fbKey" id="fbKey" th:value="${illegalShipInfo.fbKey}">
<input type="text" class="form-control form-control-sm " id="boatNameKr" th:value="${illegalShipInfo.boatNameKr}">
<input type="button" class="btn btn-sm btn-outline-primary w-auto" id="selectIllegalShipInfoBtn" value="불러오기"> <input type="button" class="btn btn-sm btn-outline-primary w-auto" id="selectIllegalShipInfoBtn" value="불러오기">
</div> </div>
</div> </div>
</div> </div>
<div class="row mb-1"> <div class="row mb-1">
<label class="col-sm-1 col-form-label col-form-label-sm text-center">선원명(한글)</label> <div class="row mb-1">
<label class="col-sm-2 col-form-label col-form-label-sm text-center">선원명(한글)</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input class="form-control form-control-sm" name="sailorNameKr" id="sailorNameKr" th:value="${illegalShipSailor.sailorNameKr}"> <input class="form-control form-control-sm" name="sailorNameKr" id="sailorNameKr" th:value="${illegalShipSailor.sailorNameKr}">
</div> </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-center">선원명(중문)</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input class="form-control form-control-sm" name="sailorNameCn" id="sailorNameCn" th:value="${illegalShipSailor.sailorNameCn}"> <input class="form-control form-control-sm" name="sailorNameCn" id="sailorNameCn" th:value="${illegalShipSailor.sailorNameCn}">
</div> </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-center">생년월일</label>
<div class="col-sm-2"> <div class="col-sm-2">
<input class="form-control form-control-sm" name="birthdate" id="birthdate" th:value="${#temporals.format(illegalShipSailor.birthdate, 'yyyy-MM-dd')}"> <input class="form-control form-control-sm" name="birthdate" id="birthdate" th:value="${#temporals.format(illegalShipSailor.birthdate, 'yyyy-MM-dd')}">
</div> </div>
</div> </div>
<div class="row mb-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-2 col-form-label col-form-label-sm text-center">거주지</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="residence"> <select class="form-select form-select-sm" name="residence">
<option value="">선택</option> <option value="">선택</option>
@ -48,7 +50,7 @@
</th:block> </th:block>
</select> </select>
</div> </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-center">학력</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="education"> <select class="form-select form-select-sm" name="education">
<option value="">선택</option> <option value="">선택</option>
@ -58,7 +60,7 @@
</th:block> </th:block>
</select> </select>
</div> </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-center">선박 내 직책</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="position"> <select class="form-select form-select-sm" name="position">
<option value="">선택</option> <option value="">선택</option>
@ -70,7 +72,7 @@
</div> </div>
</div> </div>
<div class="row mb-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-2 col-form-label col-form-label-sm text-center">승선경력</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="career"> <select class="form-select form-select-sm" name="career">
<option value="">선택</option> <option value="">선택</option>
@ -80,7 +82,7 @@
</th:block> </th:block>
</select> </select>
</div> </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-center">동종 범죄경력</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="similarCriminalHistory"> <select class="form-select form-select-sm" name="similarCriminalHistory">
<option value="">선택</option> <option value="">선택</option>
@ -91,7 +93,7 @@
<option value="0" th:selected="${illegalShipSailor.similarCriminalHistory == 0}">없음</option> <option value="0" th:selected="${illegalShipSailor.similarCriminalHistory == 0}">없음</option>
</select> </select>
</div> </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-center">이종 범죄경력</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="heterogeneousCriminalHistory"> <select class="form-select form-select-sm" name="heterogeneousCriminalHistory">
<option value="">선택</option> <option value="">선택</option>
@ -104,6 +106,10 @@
</div> </div>
</div> </div>
<div class="row mb-1"> <div class="row mb-1">
<label class="col-sm-2 col-form-label col-form-label-sm text-center">임금</label>
<div class="col-sm-2">
<input class="form-control form-control-sm" name="monthlyWages" placeholder="(0.000위안/월)" th:value="${illegalShipSailor.monthlyWages}">
</div>
<label class="col-sm-2 col-form-label col-form-label-sm text-center">검거이력(나포이력, 선원 포함)</label> <label class="col-sm-2 col-form-label col-form-label-sm text-center">검거이력(나포이력, 선원 포함)</label>
<div class="col-sm-2"> <div class="col-sm-2">
<select class="form-select form-select-sm" name="arrestHistory"> <select class="form-select form-select-sm" name="arrestHistory">
@ -115,21 +121,20 @@
<option value="0" th:selected="${illegalShipSailor.arrestHistory == 0}">없음</option> <option value="0" th:selected="${illegalShipSailor.arrestHistory == 0}">없음</option>
</select> </select>
</div> </div>
</div>
<div class="row mb-1">
<label class="col-sm-2 col-form-label col-form-label-sm text-center">범죄경력 세부내용</label> <label class="col-sm-2 col-form-label col-form-label-sm text-center">범죄경력 세부내용</label>
<div class="col-sm-3"> <div class="col-sm-10">
<input class="form-control form-control-sm" name="criminalHistoryDetail" th:value="${illegalShipSailor.criminalHistoryDetail}"> <input class="form-control form-control-sm" name="criminalHistoryDetail" th:value="${illegalShipSailor.criminalHistoryDetail}">
</div> </div>
</div> </div>
<div class="row mb-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-2 col-form-label col-form-label-sm text-center">비고</label>
<div class="col-sm-3"> <div class="col-sm-10">
<input class="form-control form-control-sm" name="monthlyWages" placeholder="(0.000위안/월)" th:value="${illegalShipSailor.monthlyWages}">
</div>
<label class="col-sm-1 col-form-label col-form-label-sm text-center">비고</label>
<div class="col-sm-5">
<input class="form-control form-control-sm" name="note" th:value="${illegalShipSailor.note}"> <input class="form-control form-control-sm" name="note" th:value="${illegalShipSailor.note}">
</div> </div>
</div> </div>
</div>
</form> </form>
</div> </div>
<div class="modal-footer bg-light"> <div class="modal-footer bg-light">

View File

@ -0,0 +1,57 @@
<!DOCTYPE html>
<html lang="ko" xmlns:th="http://www.thymeleaf.org">
<div class="row justify-content-start">
<div class="col-auto">■ 선원정보</div>
</div>
<div class="row border border-secondary">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">선원명(한글)</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.sailorNameKr}"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">선원명(중문)</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.sailorNameCn}"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">생년월일</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.birthdate}"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">거주지</label>
<label class="col-sm-2 col-form-label col-form-label py-2 text-start">
<th:block th:each="code:${session.commonCode.get('RSC')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.residence}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">학력</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<th:block th:each="code:${session.commonCode.get('SED')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.education}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">선박 내 직책</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<th:block th:each="code:${session.commonCode.get('POS')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.position}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">승선경력</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<th:block th:each="code:${session.commonCode.get('BE')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.career}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">동종 범죄경력</label>
<label class="col-sm-2 col-form-label col-form-label py-2 text-start" th:text="|${illegalShipSailor.similarCriminalHistory}건|"></label>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">이종 범죄경력</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="|${illegalShipSailor.heterogeneousCriminalHistory}건|"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">임금</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="|${illegalShipSailor.monthlyWages}건|"></label>
<label class="col-sm-2 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">검거이력<br/>(나포이력, 선원 포함)</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-secondary text-start" th:text="|${illegalShipSailor.arrestHistory}건|"></label>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">범죄경력<br/>세부내용</label>
<div class="col-sm-11 border-secondary" th:text="${illegalShipSailor.criminalHistoryDetail}"></div>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">비고</label>
<div class="col-sm-11 border-secondary" th:text="${illegalShipSailor.note}"></div>
</div>

View File

@ -7,14 +7,14 @@
<div class="modal-body"> <div class="modal-body">
<ul class="nav nav-tabs" id="fishingBoatTab" role="tablist"> <ul class="nav nav-tabs" id="fishingBoatTab" role="tablist">
<li class="nav-item" role="presentation"> <li class="nav-item" role="presentation">
<button class="nav-link active" id="processInfoViewTab" data-bs-toggle="tab" data-bs-target="#processInfoViewTabPanel" type="button" role="tab" aria-controls="processInfoViewTabPanel" aria-selected="true">최신버전</button> <button class="nav-link active" id="sailorInfoViewTab" data-bs-toggle="tab" data-bs-target="#sailorInfoViewTabPanel" type="button" role="tab" aria-controls="sailorInfoViewTabPanel" aria-selected="true">최신버전</button>
</li> </li>
<li class="nav-item" role="presentation" th:unless="${#lists.size(illegalShipSailor.historyList) <= 1}"> <li class="nav-item" role="presentation" th:unless="${#lists.size(illegalShipSailor.historyList) <= 1}">
<button class="nav-link" id="processInfoVersionTab" data-bs-toggle="tab" data-bs-target="#processInfoVersionTabPanel" type="button" role="tab" aria-controls="processInfoHistoryTabPanel" aria-selected="false">수정이력</button> <button class="nav-link" id="sailorInfoVersionTab" data-bs-toggle="tab" data-bs-target="#sailorInfoVersionTabPanel" type="button" role="tab" aria-controls="sailorInfoHistoryTabPanel" aria-selected="false">수정이력</button>
</li> </li>
</ul> </ul>
<div class="tab-content bg-white border border-top-0"> <div class="tab-content bg-white border border-top-0">
<div class="tab-pane fade p-2 mx-2 show active" id="processInfoViewTabPanel" role="tabpanel" aria-labelledby="processInfoViewTab" tabindex="0"> <div class="tab-pane fade p-2 mx-2 show active" id="sailorInfoViewTabPanel" role="tabpanel" aria-labelledby="sailorInfoViewTab" tabindex="0">
<input type="hidden" class="sailorKey" th:value="${illegalShipSailor.sailorKey}"> <input type="hidden" class="sailorKey" th:value="${illegalShipSailor.sailorKey}">
<div class="row py-2 justify-content-end"> <div class="row py-2 justify-content-end">
<div class="col-auto"> <div class="col-auto">
@ -35,101 +35,58 @@
</th:block> </th:block>
</div> </div>
</div> </div>
<!--<div class="row border border-secondary"> <div class="row border border-secondary">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">처리현황</label> <label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">선원명(한글)</label>
<div class="col-sm-2 border-end border-secondary"> <label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.sailorNameKr}"></label>
<th:block th:each="code:${session.commonCode.get('PR')}"> <label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">선원명(중문)</label>
<div class="pt-2" th:if="${code.itemCd eq illegalShipSailor.processStatus}" th:text="${code.itemValue}"></div> <label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.sailorNameCn}"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">생년월일</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.birthdate}"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">거주지</label>
<label class="col-sm-2 col-form-label col-form-label py-2 text-start">
<th:block th:each="code:${session.commonCode.get('RSC')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.residence}" th:text="${code.itemValue}"></th:block>
</th:block> </th:block>
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">수사중지 여부</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.isIvsgtStop eq 'Y'?'중지':(illegalShipSailor.isIvsgtStop eq 'N'?'수사중':illegalShipSailor.isIvsgtStop)}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">선고법원</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="${illegalShipSailor.sentencingCourt}"></label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">선고내용</label>
<label class="col-sm-2 col-form-label col-form-label py-2 text-start" th:text="${illegalShipSailor.sentencingDetail}"></label>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">압송소요시간</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.pressurizedTimeTaken}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">압송거리</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<th:block th:if="${!#strings.isEmpty(illegalShipSailor.distance)}" th:text="|${illegalShipSailor.distance}해리|"></th:block>
</label> </label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-10">영장청구 소요시간</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.warrantReqTakeTime}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">석방일시</label>
<div class="col-sm-2 border-secondary">
<input type="text" class="form-control form-control border-0" id="releaseDt" readonly th:value="${#temporals.format(illegalShipSailor.releaseDt, 'yyyy-MM-dd HH:mm')}">
</div>
</div> </div>
<div class="row border border-secondary border-top-0"> <div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">위탁시작일</label> <label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">학력</label>
<div class="col-sm-2 border-end border-secondary"> <label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.consignmentStartDt}"> <th:block th:each="code:${session.commonCode.get('SED')}">
</div> <th:block th:if="${code.itemCd eq illegalShipSailor.education}" th:text="${code.itemValue}"></th:block>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">위탁종료일</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.consignmentEndDt}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">퇴거일</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.evictionDt}">
</div>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">직접인계일</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.directHandoverDt}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">인계 해점</label>
<div class="col-sm-2 border-end border-secondary">
<div class="input-group w-auto">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.handoverSeaPointLon}">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.handoverSeaPointLat}">
</div>
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">인계 함정</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.handoverBoat}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">중측 인수함정</label>
<div class="col-sm-2">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.middleTakeoverBoat}">
</div>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">몰수확정일</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.confiscationDt}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">폐선일</label>
<div class="col-sm-2 border-end border-secondary">
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.boatDisposalDt}">
</div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">폐선종류</label>
<div class="col-sm-2 border-end border-secondary">
<th:block th:each="code:${session.commonCode.get('BDT')}">
<input type="text" class="form-control form-control border-0" readonly th:if="${code.itemCd eq illegalShipSailor.boatDisposalType}" th:value="${code.itemValue}">
</th:block> </th:block>
</div> </label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">선박 내 직책</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<th:block th:each="code:${session.commonCode.get('POS')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.position}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">승선경력</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start">
<th:block th:each="code:${session.commonCode.get('BE')}">
<th:block th:if="${code.itemCd eq illegalShipSailor.career}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">동종 범죄경력</label>
<label class="col-sm-2 col-form-label col-form-label py-2 text-start" th:text="|${illegalShipSailor.similarCriminalHistory}건|"></label>
</div> </div>
<div class="row border border-secondary border-top-0"> <div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">침몰일</label> <label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center fs-12">이종 범죄경력</label>
<div class="col-sm-2 border-end border-secondary"> <label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="|${illegalShipSailor.heterogeneousCriminalHistory}건|"></label>
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.exileDt}"> <label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">임금</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-end border-secondary text-start" th:text="|${illegalShipSailor.monthlyWages}건|"></label>
<label class="col-sm-2 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">검거이력<br/>(나포이력, 선원 포함)</label>
<label class="col-sm-2 col-form-label col-form-label py-2 border-secondary text-start" th:text="|${illegalShipSailor.arrestHistory}건|"></label>
</div> </div>
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">환부일</label> <div class="row border border-secondary border-top-0">
<div class="col-sm-2 border-end border-secondary"> <label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">범죄경력<br/>세부내용</label>
<input type="text" class="form-control form-control border-0" readonly th:value="${illegalShipSailor.returnDt}"> <div class="col-sm-11 border-secondary" th:text="${illegalShipSailor.criminalHistoryDetail}"></div>
</div>
<div class="row border border-secondary border-top-0">
<label class="col-sm-1 col-form-label col-form-label fw-bold bg-label py-2 border-end border-secondary text-center">비고</label>
<div class="col-sm-11 border-secondary" th:text="${illegalShipSailor.note}"></div>
</div> </div>
</div>-->
<div class="row justify-content-start pt-3"> <div class="row justify-content-start pt-3">
<div class="col-auto">■ 어선정보</div> <div class="col-auto">■ 어선정보</div>
</div> </div>
@ -378,7 +335,7 @@
</th:block> </th:block>
</th:block> </th:block>
</div> </div>
<div class="tab-pane fade p-2 mx-2" id="processInfoVersionTabPanel" role="tabpanel" aria-labelledby="processInfoVersionTab" tabindex="0"> <div class="tab-pane fade p-2 mx-2" id="sailorInfoVersionTabPanel" role="tabpanel" aria-labelledby="sailorInfoVersionTab" tabindex="0">
<div class="row"> <div class="row">
<div class="col-4"> <div class="col-4">
<table class="table table-hover"> <table class="table table-hover">
@ -391,7 +348,7 @@
</thead> </thead>
<tbody> <tbody>
<tr class="versionInfoTr" th:each="versionInfo:${illegalShipSailor.historyList}"> <tr class="versionInfoTr" th:each="versionInfo:${illegalShipSailor.historyList}">
<input type="hidden" class="prKey" th:value="${versionInfo.prKey}"> <input type="hidden" class="sailorKey" th:value="${versionInfo.sailorKey}">
<input type="hidden" class="versionNo" th:value="${versionInfo.versionNo}"> <input type="hidden" class="versionNo" th:value="${versionInfo.versionNo}">
<td><input type="checkbox" class="versionInfoChkbox"></td> <td><input type="checkbox" class="versionInfoChkbox"></td>
<td> <td>
@ -420,10 +377,10 @@
<!--작성자, 관리자일 경우 수정, 삭제 허용--> <!--작성자, 관리자일 경우 수정, 삭제 허용-->
<div class="modal-footer justify-content-between bg-light"> <div class="modal-footer justify-content-between bg-light">
<div class="col-auto"> <div class="col-auto">
<button type="button" class="btn btn-danger" id="deleteProcessInfoBtn">삭제</button> <button type="button" class="btn btn-danger" id="deleteSailorInfoBtn">삭제</button>
</div> </div>
<div class="col-auto"> <div class="col-auto">
<button type="button" class="btn btn-warning" id="editProcessInfoBtn">수정</button> <button type="button" class="btn btn-warning" id="editSailorInfoBtn">수정</button>
</div> </div>
</div> </div>
</th:block> </th:block>