고지서 발송 현황 - 신규 발송 등록 수정.

main
jjh 12 months ago
parent 33a7e4058b
commit 991cbdaf7a

@ -460,24 +460,23 @@ public class Sndb01Controller extends ApplicationController {
; ;
} }
/** (sndb/sndb01/110-info) . /** (sndb/sndb01/110-info) .
* *
* @return /sndb/sndb01/110-info * @return /sndb/sndb01/110-info
*/ */
public ModelAndView noticeSheetSendingTargetInfo() { public ModelAndView noticeSheetSendingTargetInfo(SndbQuery req) {
ModelAndView mav = new ModelAndView("fims/sndb/sndb01110-info"); ModelAndView mav = new ModelAndView("fims/sndb/sndb01110-info");
// 사용자 정보
ManagedUser managedUser = (ManagedUser)currentUser().getUser();
// View(jsp)에서 사용할 공통코드를 조회 // View(jsp)에서 사용할 공통코드를 조회
Map<String, List<CommonCode>> commonCodes = getCodesOf("FIM004", "FIM005", "FIM006", "FIM054", "FIM061", "FIM064"); Map<String, List<CommonCode>> commonCodes = getCodesOf("FIM004", "FIM005", "FIM006", "FIM047", "FIM054", "FIM061", "FIM064");
addCodes(commonCodes, mav, "FIM004", "FIM005", "FIM006", "FIM061", "FIM064"); addCodes(commonCodes, mav, "FIM004", "FIM005", "FIM006", "FIM061", "FIM064");
return mav.addObject("pageName", "sndb01110") // View(jsp)에서 사용할 id 뒤에 붙일 suffix return mav.addObject("pageName", "sndb01110") // View(jsp)에서 사용할 id 뒤에 붙일 suffix
.addObject("infoPrefix", "nhtSndngTrgt") // prefix .addObject("infoPrefix", "levyTrgt") // prefix
.addObject("sggCd", managedUser.getOrgID()) // 시군구 코드(SGG_CD) .addObject("sggCd", req.getSggCd()) // 시군구 코드(SGG_CD)
.addObject("taskSeCd", req.getTaskSeCd()) // 업무 구분 코드(TASK_SE_CD)
.addObject("FIM047List", commonCodes.get("FIM047")) // 발송 구분 코드(SNDNG_SE_CD)
.addObject("FIM054List", commonCodes.get("FIM054")) // 업무 구분 코드(TASK_SE_CD) .addObject("FIM054List", commonCodes.get("FIM054")) // 업무 구분 코드(TASK_SE_CD)
.addObject("FIM004List", commonCodes.get("FIM004")) // 주정차위반 내역 코드(VLTN_ID) .addObject("FIM004List", commonCodes.get("FIM004")) // 주정차위반 내역 코드(VLTN_ID)
.addObject("FIM005List", commonCodes.get("FIM005")) // 전용차로위반 내역 코드(VLTN_ID) .addObject("FIM005List", commonCodes.get("FIM005")) // 전용차로위반 내역 코드(VLTN_ID)

@ -602,8 +602,8 @@ public class DpvController {
@Override @Override
@RequestMapping(name = "고지서 발송 대상", value = METHOD_URL.noticeSheetSendingTargetInfo) @RequestMapping(name = "고지서 발송 대상", value = METHOD_URL.noticeSheetSendingTargetInfo)
public ModelAndView noticeSheetSendingTargetInfo() { public ModelAndView noticeSheetSendingTargetInfo(SndbQuery req) {
return super.noticeSheetSendingTargetInfo(); return super.noticeSheetSendingTargetInfo(req);
} }
@Override @Override

@ -560,9 +560,9 @@
// 검색조건 // 검색조건
${pageName}Control.query = ${pageName}Fields.get(); ${pageName}Control.query = ${pageName}Fields.get();
${pageName}Control.query.fetchSize = FETCH_XS; // 한번에 조회되는 자료 건수 FETCH_XS = 30 ${pageName}Control.query.fetchSize = FETCH_XS; // 한번에 조회되는 자료 건수 FETCH_XS = 30
${pageName}Control.query.delYn = "N"; // 삭제 여부 ${pageName}Control.query.delYn = "N"; // 삭제 여부
${pageName}Control.query.crdnDelYn = "N"; // 단속 대장 삭제 여부 ${pageName}Control.query.crdnDelYn = "N"; // 단속 대장 삭제 여부
${pageName}Control.load(); ${pageName}Control.load();
} }

@ -64,12 +64,12 @@
<!-- 위반항목 --> <!-- 위반항목 -->
<div class="col-6"> <div class="col-6">
<label class="form-label fw-bold form-search-title">위반항목</label> <label class="form-label fw-bold form-search-title">위반항목</label>
<select class="form-select" id="schVltnId--${pageName}" name="schVltnId"> <select class="form-select" id="schVltnId--${pageName}" name="schVltnId">
<option value="">전체</option> <option value="">전체</option>
<c:forEach items="${FIM004List}" var="item"> <c:forEach items="${FIM004List}" var="item">
<option value="${item.code}">${item.value}</option> <option value="${item.code}">${item.value}</option>
</c:forEach> </c:forEach>
</select> </select>
</div> </div>
<!-- 단속일자 --> <!-- 단속일자 -->
<div class="col-6"> <div class="col-6">

@ -315,9 +315,9 @@
, success : resp => { , success : resp => {
dialog.open({ dialog.open({
id : ${pageName}Control.prefixed("Dialog") id : ${pageName}Control.prefixed("Dialog")
, title : ${pageName}Control.prefixName + " 정보" , title :"고지서 발송 대상"
, content : resp , content : resp
, size : "xl" , size : "lg"
, onClose : () => { ${pageName}Control.load(${pageName}Control.query.pageNum); } // callback , onClose : () => { ${pageName}Control.load(${pageName}Control.query.pageNum); } // callback
}); });
} }
@ -448,9 +448,11 @@
// 신규 등록 // 신규 등록
fnNhtSndngInfo${pageName} = () => { fnNhtSndngInfo${pageName} = () => {
let params = ${pageName}Fields.get(); let params = {
callPurpose : "create"
params.callPurpose = "create"; , sggCd : $("#sggCd--${pageName}").val() // 시군구 코드
, taskSeCd : $(":input:radio[name='taskSeCd']:checked").val() // 업무 구분 코드
};
getNhtSndngInfo${pageName}(params); getNhtSndngInfo${pageName}(params);
} }

@ -60,7 +60,7 @@
<th class="cmn" style="width: 280px;">주소</th> <th class="cmn" style="width: 280px;">주소</th>
<th class="cmn" style="width: 320px;">상세주소</th> <th class="cmn" style="width: 320px;">상세주소</th>
<th class="cmn" style="width: 180px;">단속일시</th> <th class="cmn" style="width: 180px;">단속일시</th>
<th class="cmn" style="width: 140px;">차량번호</th> <th class="cmn" style="width: 160px;">차량번호</th>
<th class="cmn" style="width: 160px;">법정동</th> <th class="cmn" style="width: 160px;">법정동</th>
<th class="cmn" style="width: 280px;">단속장소</th> <th class="cmn" style="width: 280px;">단속장소</th>
<th class="cmn" style="width: 100px;">회계연도</th> <th class="cmn" style="width: 100px;">회계연도</th>

@ -9,122 +9,136 @@
<!-- Page Body --> <!-- Page Body -->
<div class="card"> <div class="card">
<div class="wrapper-pop"> <!-- 업무 버튼 표시 -->
<!-- 입력 영역 --> <div>
<form id="frmEdit--${pageName}" name="frmEdit"> <span class="container-page-btn">
<input type="hidden" id="sggCd--${pageName}" name="sggCd" /> <span class="container-window-btn-right">
<input type="hidden" id="taskSeCd--${pageName}" name="taskSeCd" /> <!-- 업무 버튼 -->
</form> <!-- /입력 영역 --> <button type="button" class="btn btn-search w-px-120" id="btnSearch--${pageName}" title="검색" onclick="fnSearchList${pageName}();">
검색
<!-- 업무 버튼 및 건수 표시 --> </button>
<div>
<span class="container-page-btn">
<span class="container-window-btn-right">
<!-- 업무 버튼 -->
<button type="button" class="btn btn-excel w-px-120" id="btnExcel--${pageName}" title="엑셀 저장" onclick="fnExcel${pageName}();">
엑셀 저장
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnCreateNxrp--${pageName}" title="세외수입 등록" onclick="fnCreateNxrp${pageName}();">
세외수입 등록
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnUpdateNxrpMtchg--${pageName}" title="매치정보 등록" onclick="fnUpdateNxrpMtchg${pageName}();">
매치정보 작성
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnCreateSndngLink--${pageName}" title="우편통합 발송" onclick="fnCreateSndngLink${pageName}();">
우편통합 발송
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnPrintAdvntce--${pageName}" title="사전통지 출력" onclick="fnPrintAdvntce${pageName}();">
사전통지 출력
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnCreateRgNo--${pageName}" title="등기번호 등록" onclick="fnCreateRgNo${pageName}();">
등기번호 등록
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnCreateSndbk--${pageName}" title="반송 등록" onclick="fnCreateSndbk${pageName}();">
반송 확인
</button>
<button type="button" class="btn btn-primary w-px-120" id="btnLevyIdnty--${pageName}" title="미부과건 확인" onclick="fnLevyIdnty${pageName}();">
미부과건 확인
</button>
</span>
</span> </span>
</span>
</div> <!-- / 업무 버튼 표시 -->
<!-- 조회 영역 -->
<form id="frmSearch--${pageName}" name="frmSearch">
<!-- hidden -->
<input type="hidden" id="sggCd--${pageName}" name="sggCd" data-map="SGG_CD" />
<input type="hidden" id="taskSeCd--${pageName}" name="taskSeCd" data-map="TASK_SE_CD" />
<div class="row g-1">
<!-- 위반항목 -->
<div class="col-8">
<label for="schVltnId--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">위반항목</label>
<select class="form-select" id="schVltnId--${pageName}" name="schVltnId">
<option value="">전체</option>
<c:forEach items="${FIM004List}" var="item">
<option value="${item.code}">${item.value}</option>
</c:forEach>
</select>
</div>
<!-- 총건수 -->
<div class="col-md-4 text-center">
<label for="tnocs--${pageName}" class="w-px-100 bg-lighter pe-2 col-form-label text-sm-end">총건수</label>
<input type="text" class="form-control w-px-160" id="tnocs--${pageName}" name="tnocs" autocomplete="off" readonly />
</div>
<!-- 부과 일자 -->
<div class="col-md-8">
<label for="schLevyYmd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">부과일자</label>
<input type="text" class="form-control form-date" id="schLevyYmd--${pageName}" name="schLevyYmd"
data-fmt-type="day" autocomplete="off" title="날짜 선택" maxlength="10" required />
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
</div>
<!-- 총금액 -->
<div class="col-md-4 text-center">
<label for="gramt--${pageName}" class="w-px-100 bg-lighter pe-2 col-form-label text-sm-end">총금액</label>
<input type="text" class="form-control w-px-160" id="gramt--${pageName}" name="gramt" autocomplete="off" readonly />
</div>
<!-- 최초 납기 일자 -->
<div class="col-md-12">
<label for="schFrstDudtYmd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">최초납기일자</label>
<input type="text" class="form-control form-date" id="schFrstDudtYmd--${pageName}" name="schFrstDudtYmd"
data-fmt-type="day" autocomplete="off" title="날짜 선택" maxlength="10" required />
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
</div>
<!-- 회계연도 -->
<div class="col-md-12">
<label for="schFyr--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">회계연도</label>
<input type="text" class="form-control w-px-80" id="schFyr--${pageName}" name="schFyr" maxlength="4" autocomplete="off" required />
</div>
<!-- 부과번호 -->
<div class="col-md-12">
<label for="schLevyNoFrom--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">부과번호</label>
<input type="text" class="form-control w-px-80" id="schLevyNoFrom--${pageName}" name="schLevyNoFrom" maxlength="6" value="000000" autocomplete="off" required /> ~
<input type="text" class="form-control w-px-80" id="schLevyNoTo--${pageName}" name="schLevyNoTo" maxlength="6" value="999999" autocomplete="off" required />
</div>
</div> </div>
<!-- / 업무 버튼 및 건수 표시 --> </form> <!-- /입력 영역 -->
</div> <!-- <div class="card"> -->
<!-- DataTables(그리드) -->
<div class="card-datatable text-nowrap"> <p></p>
<div class="dataTables_wrapper dt-bootstrap5 no-footer" id="DataTables_Table_0_wrapper--${pageName}">
<div class="table-responsive" id="table-responsive--${pageName}" style="overflow-x:scroll; height:400px; overflow-y:scroll;" > <div class="card">
<table class="table-layout-fixed dataTable datatables-ajax table table-bordered no-footer" id="DataTables_Table_0--${pageName}" aria-describedby="DataTables_Table_0_info"> <!-- 입력 영역 -->
<thead class="sticky-thead"> <form id="frmEdit--${pageName}" name="frmEdit">
<tr id="theadTr--${pageName}" <div class="row g-1">
data-by="by--${pageName}" data-by-output="byOutput--${pageName}" data-main-option="mainOption--${pageName}" data-sub-option="subOption--${pageName}"> <!-- 발송 구분 -->
<th class="cmn hidden" style="width: 56px;"> <div class="col-12">
<input type="checkbox" class="form-check-input" onchange="${pageName}Control.select(this.checked);"> <label for="sndngSeCd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">발송구분</label>
</th> <select class="form-select" id="sndngSeCd--${pageName}" name="sndngSeCd">
<th class="cmn" style="width: 120px;">발송상태</th> <option value="">전체</option>
<th class="cmn" style="width: 200px;">등기번호</th> <c:forEach items="${FIM047List}" var="item">
<th class="cmn" style="width: 120px;">발송일자</th> <option value="${item.code}">${item.value}</option>
<th class="cmn" style="width: 120px;">납기일자</th> </c:forEach>
<th class="cmn" style="width: 200px;">납부자명</th> </select>
<th class="cmn" style="width: 160px;">납부자번호</th> </div>
<th class="cmn" style="width: 100px;">우편번호</th> <!-- 문서 번호 -->
<th class="cmn" style="width: 280px;">주소</th> <div class="col-md-4">
<th class="cmn" style="width: 320px;">상세주소</th> <label for="docNo--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">문서번호</label>
<th class="cmn" style="width: 160px;">위반내용</th> <input type="text" class="form-control w-55" id="docNo--${pageName}" name="docNo" />
<th class="cmn" style="width: 180px;">단속일시</th> </div>
<th class="cmn" style="width: 140px;">차량번호</th> <!-- 발송 일자 -->
<th class="cmn" style="width: 280px;">단속장소</th> <div class="col-md-4">
<th class="cmn" style="width: 120px;">단속금액</th> <label for="sndngYmd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">발송일자</label>
<th class="cmn" style="width: 180px;">등록일시</th> <input type="text" class="form-control form-date" id="sndngYmd--${pageName}" name="sndngYmd"
<th class="cmn" style="width: 140px;">등록사용자</th> data-fmt-type="day" autocomplete="off" title="날짜 선택" maxlength="10" required />
<th class="cmn" style="width: 180px;">수정일시</th> <button type="button" class="bx bx-sm bx-calendar bg-white"></button>
<th class="cmn" style="width: 140px;">수정사용자</th> </div>
<th class="cmn dummy-th"></th> <!-- 발송 종료 일자 -->
</tr> <div class="col-md-4">
</thead> <label for="sndngEndYmd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">납기일자</label>
<tbody id="tbody--${pageName}"> <input type="text" class="form-control form-date" id="sndngEndYmd--${pageName}" name="sndngEndYmd"
</tbody> data-fmt-type="day" autocomplete="off" title="날짜 선택" maxlength="10" required />
<template id="${infoPrefix}Row--${pageName}"> <button type="button" class="bx bx-sm bx-calendar bg-white"></button>
<tr data-key="{SNDNG_DTL_ID}"> </div>
<td class="cmn text-center hidden"> <!-- 제목 명 -->
<input type="checkbox" class="form-check-input" value="{SNDNG_DTL_ID}" onchange="${pageName}Control.select('{SNDNG_DTL_ID}', this.checked);"> <div class="col-md-12">
</td> <label for="ttlNm--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">제목</label>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{SNDNG_DTL_STTS_NM}</td> <input type="text" class="form-control w-87" id="ttlNm--${pageName}" name="ttlNm" />
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RG_NO}</td> </div>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{SNDNG_YMD}</td> <!-- 기타 내용 -->
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{DUDT_YMD}</td> <div class="col-md-12">
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_NM}</td> <label for="etcCn--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">기타내용</label>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_NO}</td> <textarea type="text" class="form-control w-87" id="etcCn--${pageName}" name="etcCn" rows="2" data-maxlengthb="1000"></textarea>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_ZIP}</td>
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_ADDR}</td>
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_DTL_ADDR}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{VLTN_NM}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{CRDN_DT}</td>
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{VHRNO}</td>
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{CRDN_PLC}</td>
<td class="cmn text-end" onclick="{onclick}" ondblclick="{ondblclick}">{FFNLG_AMT}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{REG_DT}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RGTR_NM}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{MDFCN_DT}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{MDFR_NM}</td>
<td class="cmn dummy-td"></td>
</tr>
</template>
<template id="${infoPrefix}NotFound--${pageName}">
<tr class="odd">
<td valign="top" colspan="19" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
</tr>
</template>
</table>
</div>
</div> </div>
</div> </div>
<!-- / DataTables(그리드) --> </form> <!-- /입력 영역 -->
</div> <!-- <div class="wrapper-list"> --> <!-- 업무 버튼 표시 -->
<div>
<span class="container-page-btn">
<span class="container-window-btn-right">
<!-- 업무 버튼 -->
<button type="button" class="btn btn-primary w-px-80" id="btnSave--${pageName}" title="저장" onclick="fnSave${pageName}()">
저장
</button>
</span>
</span>
</div> <!-- / 업무 버튼 표시 -->
</div> <!-- <div class="card"> --> </div> <!-- <div class="card"> -->
</div> <!-- / Content <div class="container flex-grow-1 px-0"> --> </div> <!-- / Content <div class="container flex-grow-1 px-0"> -->
</div> </div> <!-- / inner page html <div class="content-wrapper"> -->
<!-- / inner page html <div class="content-wrapper"> -->
<script> <script>
/************************************************************************** /**************************************************************************
@ -133,209 +147,54 @@
// URL // URL
var ${pageName}PrefixUrl = "/sndb/sndb01"; var ${pageName}PrefixUrl = "/sndb/sndb01";
// FormFields // FormFields
var ${pageName}SearchFields = new FimsFormFields("#frmSearch--${pageName}");
var ${pageName}Fields = new FimsFormFields("#frmEdit--${pageName}"); var ${pageName}Fields = new FimsFormFields("#frmEdit--${pageName}");
// 공통 코드
var FIM004 = new CommonCodes(${FIM004}, true); // 주정차위반 내역 코드
var FIM005 = new CommonCodes(${FIM005}, true); // 전용차로위반 내역 코드
var FIM006 = new CommonCodes(${FIM006}, true); // 장애인주차위반 내역 코드
var FIM061 = new CommonCodes(${FIM061}, true); // 전기차 충전구역 및 충전방해 위반 코드
var FIM064 = new CommonCodes(${FIM064}, true); // 화물자동차 밤샘주차 위반 코드
/************************************************************************** /**************************************************************************
* DatasetControl * DatasetControl
**************************************************************************/ **************************************************************************/
var ${pageName}Control = new DatasetControl({ var ${pageName}Control = new DatasetControl({
prefix : "nhtSndngDtl" prefix : "nhtTrgt"
, prefixName : "발송 상세" , prefixName : "고지서 발송 대상"
, keymapper : info => info ? info.SNDNG_DTL_ID : "" , keymapper : info => info ? info.CRDN_ID : ""
, dataGetter : obj => obj.nhtSndngDtlList , dataGetter : obj => obj.nhtTrgtList
, appendData : true
, tableRenderComplete : false // dataTables 에 자료 추가 완료 여부
, formats : {
SNDNG_YMD : dateFormat
, DUDT_YMD : dateFormat
, FFNLG_AMT : numberFormat
, REG_DT : datetimeFormat
, MDFCN_DT : datetimeFormat
}
}); });
/************************************************************************** /**************************************************************************
* DatasetControl 이벤트 * DatasetControl 이벤트
**************************************************************************/ **************************************************************************/
// Dataset 변경 이벤트 // 저장 callback
${pageName}Control.onDatasetChange = obj => { ${pageName}Control.onSave = (resp) => {
renderList${pageName}(); let dialogTitle = $("#" + ${pageName}Control.prefix + "Dialog").find("h5.modal-title").html();
let showMessage = resp.retMessage.replace(/[S]|[F]/g, dialogTitle);
${pageName}Control.select(true); // 전체 선택 되도록..
if (obj.length > 0) {
}
${pageName}Control.tableRenderComplete = true; // dataTables 에 자료 추가 완료
};
// 현재 선택 자료 변경 이벤트
${pageName}Control.onCurrentChange = item => {
if (!item) return;
let key = item.data.SNDNG_DTL_ID;
$("#tbody--${pageName}").setCurrentRow(key);
${pageName}Control.urls.getInfo = wctx.url("/" + ${pageName}Control.dataset.getValue("TASK_SE_CD") + "/sprt/sprt02/010/main.do"); // 개별총정보
};
// 선택(체크) 변경 이벤트 dialog.alert(showMessage);
${pageName}Control.onSelectionChange = selected => {
let ${infoPrefix}List = ${pageName}Control.dataset;
let keys = selected.map(e => ${infoPrefix}List.getKey(e));
$("#tbody--${pageName} input[type='checkbox']").each(function() { if (resp.saved) {
let checkbox = $(this); dialog.close(${pageName}Control.prefix + "Dialog");
checkbox.prop("checked", keys.includes(checkbox.val())); if ("${savedCallbackFuncName}" != "") {
}); ${savedCallbackFuncName}(resp.saved);
};
// 개별총정보 dialog
${pageName}Control.getInfo = (crdnId) => {
if (typeof crdnId == "undefined" || crdnId == null || crdnId == "") {
return;
}
let params = {
callControlName : "${pageName}Control"
, viewPurpose : "readonly"
, crdnId : crdnId
}
ajax.get({
url : ${pageName}Control.urls.getInfo
, data : params
, success : resp => {
dialog.open({
id : "totalInfoMainDialog"
, title : "개별총정보"
, content : resp
, size : "xxl"
});
} }
}); }
}
/**************************************************************************
*
**************************************************************************/
// DataTables에 click, dbclick 이벤트
renderList${pageName} = () => {
let ${infoPrefix}List = ${pageName}Control.dataset;
let empty = ${infoPrefix}List.empty;
let trs = empty ?
[document.getElementById("${infoPrefix}NotFound--${pageName}").innerHTML] : <%-- from template#${infoPrefix}NotFound --%>
${infoPrefix}List.inStrings(
document.getElementById("${infoPrefix}Row--${pageName}").innerHTML, <%-- from template#${infoPrefix}Row --%>
(str, dataItem) => str
.replace(/{onclick}/gi, "${pageName}Control.setCurrent('" + dataItem.getValue("SNDNG_DTL_ID") + "');")
.replace(/{ondblclick}/gi, "${pageName}Control.getInfo('" + dataItem.getValue("CRDN_ID") + "');")
);
$("#tbody--${pageName}").html(trs.join());
$("th input[type='checkbox']").prop("checked", false);
//보안모드
fn_securityModeToggle($("#securityMode--top").is(":checked"));
}
// 세외수입 등록
createNxrp${pageName} = (params) => {
// 선택된 자료의 발송 상세 ID 추가
let selected = ${pageName}Control.dataset.getKeys("selected");
if (selected.length < 1) return;
params.sndngDtlIDs = selected.join(","); // 발송 상세 IDs
params.delYn = "N"; // 삭제 여부
ajax.post({
url : wctx.url("/" + params.taskSeCd + ${pageName}PrefixUrl + "/createNxrp.do")
, data : params || {}
, success : resp => { }
});
}
// 매칭정보 확인
updateNxrpMtchg${pageName} = (params) => {
// 선택된 자료의 발송 상세 ID 추가
let selected = ${pageName}Control.dataset.getKeys("selected");
if (selected.length < 1) return;
params.sndngDtlIDs = selected.join(","); // 발송 상세 IDs
params.delYn = "N"; // 삭제 여부
ajax.post({
url : wctx.url("/" + params.taskSeCd + ${pageName}PrefixUrl + "/updateNxrpMtchg.do")
, data : params || {}
, success : resp => {}
});
}
// 우편통합 발송
createSndngLink${pageName} = (obj) => {
let btnTitle = $("#btnCreateSndngLink--${pageName}").attr("title");
// 선택된 자료의 발송 상세 ID 추가
let selected = ${pageName}Control.dataset.getKeys("selected");
if (selected.length < 1) return;
let info = {};
info.sndngDtlIDs = selected.join(","); // 발송 상세 IDs
info.sndngId = ${pageName}Control.dataset.getValue("SNDNG_ID"); // 발송 ID
info.sggCd = $("#sggCd--${pageName}").val(); // 시군구 코드
info.taskSeCd = $("#taskSeCd--${pageName}").val(); // 업무 구분 코드
info.sndngSeCd = "02"; // 발송 구분 코드
info.sndngYmd = obj.sndngYmd; // 발송 일자
info.dudtYmd = obj.dudtYmd; // 납기 일자
info.postSndngSeCd = obj.postSndngSeCd; // 우편 발송 구분 코드 0 일반, 1 등기
ajax.post({
url : wctx.url("/" + info.taskSeCd + ${pageName}PrefixUrl + "/080/createSndngLink.do")
, data : info || {}
, success : resp => {
let showMessage = resp.retMessage.replace(/[S]|[F]/g, btnTitle);
dialog.alert(showMessage);
}
});
}
// 종적결과 등록
createSndbk${pageName} = (params) => {
// 선택된 자료의 발송 상세 ID 추가
let selected = ${pageName}Control.dataset.getKeys("selected");
if (selected.length < 1) return;
params.sndngDtlIDs = selected.join(","); // 발송 상세 IDs
params.delYn = "N"; // 삭제 여부
ajax.post({
url : wctx.url("/" + params.taskSeCd + ${pageName}PrefixUrl + "/createSndbk.do")
, data : params || {}
, success : resp => { }
});
} }
// 미부과건 확인 // 저장
levyIdnty${pageName} = (params) => { ${pageName}Control.save = (info) => {
// 선택된 자료의 발송 상세 ID 추가 if (!info) return;
let selected = ${pageName}Control.dataset.getKeys("selected");
if (selected.length < 1) return;
params.sndngDtlIDs = selected.join(","); // 발송 상세 IDs let create = isEmpty(info.levyExclId);
params.delYn = "N"; // 삭제 여부
ajax.post({ ajax.post({
url : wctx.url("/" + params.taskSeCd + ${pageName}PrefixUrl + "/levyIdnty.do") url : !create ? ${pageName}Control.urls.update : ${pageName}Control.urls.create
, data : params || {} , data : info
, success : resp => { } , success : resp => ${pageName}Control.onSave(resp)
}); });
} }
@ -361,94 +220,73 @@
$("#DataTables_Table_0--${pageName}").find("th").resizable( {handles : "e"} ); $("#DataTables_Table_0--${pageName}").find("th").resizable( {handles : "e"} );
} }
/************************************************************************** // 화면 초기값 셋팅
* 버튼 clickEvent setForm${pageName} = (taskSeCd) => {
**************************************************************************/ // 업무에 따른 위반 내용
// 엑셀 저장 let vltnIdCode = [];
fnExcel${pageName} = () => { if (taskSeCd == "PVS") { // 주정차 위반
vltnIdCode = FIM004.list();
} } else if (taskSeCd == "BPV") { // 전용차로 위반
vltnIdCode = FIM005.list();
} else if (taskSeCd == "DPV") { // 장애인 전용
vltnIdCode = FIM006.list();
} else if (taskSeCd == "ECA") { // 전기차 주차 위반
vltnIdCode = FIM061.list();
} else if (taskSeCd == "TPV") { // 밤샘 주차 위반
vltnIdCode = FIM064.list();
} else {
return;
}
// 세외수입 등록 // 위반 항목
fnCreateNxrp${pageName} = () => { $("#schVltnId--${pageName}").empty();
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
dialog.alert({ $("#schVltnId--${pageName}").append("<option value=''>" + "전체" + "</option>");
content : "세외수입 과태료 대장에 등록하시겠습니까?" $(vltnIdCode).each(function(index, item) {
, onOK : () => { $("#schVltnId--${pageName}").append("<option value='" + vltnIdCode[index].code +"'>" + vltnIdCode[index].value + "</option>");
createNxrp${pageName}(${pageName}Fields.get());
}
}); });
}
// 매치정보 등록 // 달력 초기화
fnUpdateNxrpMtchg${pageName} = () => { initDatepicker("frmSearch--${pageName}");
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
updateNxrpMtchg${pageName}(${pageName}Fields.get()); $("#schLevyYmd--${pageName}").datepicker("setDate", DateUtil.getDateDay(-365).date);
$("#schFrstDudtYmd--${pageName}").datepicker("setDate", new Date());
$("#schFyr--${pageName}").val(new Date().getFullYear());
} }
// 우편통합 발송 // URL 설정
fnCreateSndngLink${pageName} = () => { setURL${pageName} = (taskSeCd) => {
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
let callbackFuncName = "createSndngLink${pageName}";
let popupWidth = 480;
let popupHeight = 480;
let popupX = (window.screen.width / 2) - (popupWidth / 2);
let popupY= (window.screen.height / 2) - (popupHeight / 2);
window.open(
wctx.url("/resources/html/inputDateDialog.html"
+ "?callbackFuncName=" + callbackFuncName
+ "&CALL_PURPOSE=" + "post"
+ "&SNDNG_YMD=" + ${pageName}Control.dataset.getValue("SNDNG_YMD")
+ "&DUDT_YMD=" + ${pageName}Control.dataset.getValue("DUDT_YMD")
)
, "inputEPostDateDialog"
, 'status=no, height=' + popupHeight + ', width=' + popupWidth + ', left='+ popupX + ', top='+ popupY
);
} }
// 사전통지 출력 /**************************************************************************
fnPrintAdvntce${pageName} = () => { * 버튼 clickEvent
**************************************************************************/
} // 검색 버튼 이벤트
fnSearchList${pageName} = () => {
// 검색조건
${pageName}Control.query = ${pageName}SearchFields.get();
// 등기번호 등록 ${pageName}Control.query.fetchSize = FETCH_XS; // 한번에 조회되는 자료 건수 FETCH_XS = 30
fnCreateRgNo${pageName} = () => { ${pageName}Control.query.delYn = "N"; // 삭제 여부
// validate 확인 ${pageName}Control.query.crdnDelYn = "N"; // 단속 대장 삭제 여부
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
createRgNo${pageName}(${pageName}Fields.get()); ${pageName}Control.load();
} }
// 반송(종적결과) 확인 // 저장
fnCreateSndbk${pageName} = () => { fnSave${pageName} = () => {
// validate 확인 // validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return; if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
dialog.alert({ dialog.alert({
content : "종적결과를 확인하시겠습니까?" content : "현재 " + ${pageName}Control.prefixName + " 정보를 저장하시겠습니까?"
, onOK : () => { , onOK : () => {
createSndbk${pageName}(${pageName}Fields.get()); ${pageName}Control.save(${pageName}Fields.get());
} }
}); });
} }
// 미부과건 확인
fnLevyIdnty${pageName} = () => {
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
levyIdnty${pageName}(${pageName}Fields.get());
}
/************************************************************************** /**************************************************************************
* script 진입 * script 진입
**************************************************************************/ **************************************************************************/
@ -463,8 +301,11 @@
// 이벤트 설정 // 이벤트 설정
setEvent${pageName}(); setEvent${pageName}();
// Dataset 셋팅 - 화면이 열리면서 조회하는 경우 addData 하여 자료를 추가 // 화면 초기값 설정
${pageName}Control.addData(${nhtSndngDtl}); setForm${pageName}("${taskSeCd}");
// URL 설정
setURL${pageName}("${taskSeCd}");
}); });
</script> </script>

Loading…
Cancel
Save