사건보고서

- 모달 오류 수정.
 - 범죄테마 공통코드 오류 수정.
master
강석 최 2023-01-31 15:54:05 +09:00
parent 6c756e1326
commit bf4539695f
5 changed files with 31 additions and 24 deletions

View File

@ -64,7 +64,7 @@ public class IvsgtController {
mav.addObject("boardInvestigation", boardInvestigation);
mav.addObject("userSeq",loginUser.getUserSeq());
//메뉴권한 확인
mav.addObject("accessAuth", authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/ivsgt/"+boardInvestigation.getIvsgtType()).get(0).getAccessAuth());
mav.addObject("accessAuth", authMgtService.selectAccessConfigList(loginUser.getUserSeq(), "/ivsgt/arrest").get(0).getAccessAuth());
return mav;
}

View File

@ -65,8 +65,7 @@
count(file_seq) AS fileCnt
FROM ivsgt_file
GROUP BY ivsgt_key
) b
ON a.ivsgt_key = b.ivsgt_key
) b ON a.ivsgt_key = b.ivsgt_key
INNER JOIN arrest_type t
ON a.ivsgt_key = t.ivsgt_key
INNER JOIN code_mgt cm

View File

@ -10,7 +10,10 @@ $(document).on('click', '#ivsgtEditBtn', function () {
$(document).on('click', '#saveIvsgtBtn', function (){
saveBoardInvestigation('N')
});
$(document).on('change', '#arrestCd', function (){
$(".arrestCd2").hide();
$("."+this.value).show();
})
$(document).on('click', '#saveTempBtn', function (){
saveBoardInvestigation('Y')
});
@ -101,6 +104,10 @@ function getIvsgtEditModal(ivsgtKey, ivsgtType){
$("#ivsgtViewBody").empty();
$("#ivsgtEditModalContent").empty().append(html)
$("#ivsgtEditModal").modal('show');
const selectedArrestCd = $("#ivsgtEditForm").find("#arrestCd").val()
if(selectedArrestCd){
$("."+selectedArrestCd).show();
}
setEditor('editor', '400')
setUploadDiv();
},

View File

@ -57,9 +57,9 @@
<div class="col-sm-2">
<select class="form-select form-select-sm" name="arrestCd" id="arrestCd">
<option value="">범죄테마 선택-</option>
<th:block th:each="commonCode:${session.commonCode.get('CTH')}">
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}"
th:selected="${boardInvestigation.arrestType != null and commonCode.itemCd eq boardInvestigation.arrestType.arrestCd}"></option>
<th:block th:each="code:${session.commonCode.get('CTH')}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}"
th:selected="${boardInvestigation.arrestType != null and code.itemCd eq boardInvestigation.arrestType.arrestCd}"></option>
</th:block>
</select>
</div>
@ -67,9 +67,10 @@
<div class="col-sm-2">
<select class="form-select form-select-sm" name="arrestCd2" id="arrestCd2">
<option value="">위반유형 선택-</option>
<th:block th:each="num : ${#numbers.sequence(1,#lists.size(session.commonCode.get('AT')))}">
<th:block th:if="${boardInvestigation.arrestType ne null && 'AT'+num == boardInvestigation.arrestType.arrestCd}" th:each="commonCode:${session.commonCode.get('AT'+num)}">
<option th:value="${commonCode.itemCd}" th:text="${commonCode.itemValue}" th:selected="${boardInvestigation.arrestType.arrestCd2 eq commonCode.itemCd}"></option>
<th:block th:each="cthCode:${session.commonCode.get('CTH')}">
<th:block th:each="code:${session.commonCode.get(cthCode.itemCd)}">
<option th:value="${code.itemCd}" th:text="${code.itemValue}" class="arrestCd2" th:classappend="${cthCode.itemCd}" style="display: none"
th:selected="${boardInvestigation.arrestType != null and code.itemCd eq boardInvestigation.arrestType.arrestCd2}"></option>
</th:block>
</th:block>
</select>

View File

@ -29,7 +29,7 @@
<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('AT')}">
<th:block th:each="code:${session.commonCode.get('CTH')}">
<th:block th:if="${code.itemCd eq boardInvestigation.arrestType.arrestCd}" th:text="${code.itemValue}"></th:block>
</th:block>
</label>