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

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
*/
public ModelAndView noticeSheetSendingTargetInfo() {
public ModelAndView noticeSheetSendingTargetInfo(SndbQuery req) {
ModelAndView mav = new ModelAndView("fims/sndb/sndb01110-info");
// 사용자 정보
ManagedUser managedUser = (ManagedUser)currentUser().getUser();
// 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");
return mav.addObject("pageName", "sndb01110") // View(jsp)에서 사용할 id 뒤에 붙일 suffix
.addObject("infoPrefix", "nhtSndngTrgt") // prefix
.addObject("sggCd", managedUser.getOrgID()) // 시군구 코드(SGG_CD)
.addObject("infoPrefix", "levyTrgt") // prefix
.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("FIM004List", commonCodes.get("FIM004")) // 주정차위반 내역 코드(VLTN_ID)
.addObject("FIM005List", commonCodes.get("FIM005")) // 전용차로위반 내역 코드(VLTN_ID)

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

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

@ -64,12 +64,12 @@
<!-- 위반항목 -->
<div class="col-6">
<label class="form-label fw-bold form-search-title">위반항목</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>
<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-6">

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

@ -60,7 +60,7 @@
<th class="cmn" style="width: 280px;">주소</th>
<th class="cmn" style="width: 320px;">상세주소</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: 280px;">단속장소</th>
<th class="cmn" style="width: 100px;">회계연도</th>

@ -9,122 +9,136 @@
<!-- Page Body -->
<div class="card">
<div class="wrapper-pop">
<!-- 입력 영역 -->
<form id="frmEdit--${pageName}" name="frmEdit">
<input type="hidden" id="sggCd--${pageName}" name="sggCd" />
<input type="hidden" id="taskSeCd--${pageName}" name="taskSeCd" />
</form> <!-- /입력 영역 -->
<!-- 업무 버튼 및 건수 표시 -->
<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>
<!-- 업무 버튼 표시 -->
<div>
<span class="container-page-btn">
<span class="container-window-btn-right">
<!-- 업무 버튼 -->
<button type="button" class="btn btn-search w-px-120" id="btnSearch--${pageName}" title="검색" onclick="fnSearchList${pageName}();">
검색
</button>
</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>
<!-- / 업무 버튼 및 건수 표시 -->
<!-- DataTables(그리드) -->
<div class="card-datatable text-nowrap">
<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;" >
<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">
<tr id="theadTr--${pageName}"
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;">
<input type="checkbox" class="form-check-input" onchange="${pageName}Control.select(this.checked);">
</th>
<th class="cmn" style="width: 120px;">발송상태</th>
<th class="cmn" style="width: 200px;">등기번호</th>
<th class="cmn" style="width: 120px;">발송일자</th>
<th class="cmn" style="width: 120px;">납기일자</th>
<th class="cmn" style="width: 200px;">납부자명</th>
<th class="cmn" style="width: 160px;">납부자번호</th>
<th class="cmn" style="width: 100px;">우편번호</th>
<th class="cmn" style="width: 280px;">주소</th>
<th class="cmn" style="width: 320px;">상세주소</th>
<th class="cmn" style="width: 160px;">위반내용</th>
<th class="cmn" style="width: 180px;">단속일시</th>
<th class="cmn" style="width: 140px;">차량번호</th>
<th class="cmn" style="width: 280px;">단속장소</th>
<th class="cmn" style="width: 120px;">단속금액</th>
<th class="cmn" style="width: 180px;">등록일시</th>
<th class="cmn" style="width: 140px;">등록사용자</th>
<th class="cmn" style="width: 180px;">수정일시</th>
<th class="cmn" style="width: 140px;">수정사용자</th>
<th class="cmn dummy-th"></th>
</tr>
</thead>
<tbody id="tbody--${pageName}">
</tbody>
<template id="${infoPrefix}Row--${pageName}">
<tr data-key="{SNDNG_DTL_ID}">
<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);">
</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{SNDNG_DTL_STTS_NM}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RG_NO}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{SNDNG_YMD}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{DUDT_YMD}</td>
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_NM}</td>
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_NO}</td>
<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>
</form> <!-- /입력 영역 -->
</div> <!-- <div class="card"> -->
<p></p>
<div class="card">
<!-- 입력 영역 -->
<form id="frmEdit--${pageName}" name="frmEdit">
<div class="row g-1">
<!-- 발송 구분 -->
<div class="col-12">
<label for="sndngSeCd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">발송구분</label>
<select class="form-select" id="sndngSeCd--${pageName}" name="sndngSeCd">
<option value="">전체</option>
<c:forEach items="${FIM047List}" var="item">
<option value="${item.code}">${item.value}</option>
</c:forEach>
</select>
</div>
<!-- 문서 번호 -->
<div class="col-md-4">
<label for="docNo--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">문서번호</label>
<input type="text" class="form-control w-55" id="docNo--${pageName}" name="docNo" />
</div>
<!-- 발송 일자 -->
<div class="col-md-4">
<label for="sndngYmd--${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="sndngYmd--${pageName}" name="sndngYmd"
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">
<label for="sndngEndYmd--${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="sndngEndYmd--${pageName}" name="sndngEndYmd"
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="ttlNm--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">제목</label>
<input type="text" class="form-control w-87" id="ttlNm--${pageName}" name="ttlNm" />
</div>
<!-- 기타 내용 -->
<div class="col-md-12">
<label for="etcCn--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">기타내용</label>
<textarea type="text" class="form-control w-87" id="etcCn--${pageName}" name="etcCn" rows="2" data-maxlengthb="1000"></textarea>
</div>
</div>
<!-- / DataTables(그리드) -->
</div> <!-- <div class="wrapper-list"> -->
</form> <!-- /입력 영역 -->
<!-- 업무 버튼 표시 -->
<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> <!-- / Content <div class="container flex-grow-1 px-0"> -->
</div>
<!-- / inner page html <div class="content-wrapper"> -->
</div> <!-- / inner page html <div class="content-wrapper"> -->
<script>
/**************************************************************************
@ -133,209 +147,54 @@
// URL
var ${pageName}PrefixUrl = "/sndb/sndb01";
// FormFields
var ${pageName}SearchFields = new FimsFormFields("#frmSearch--${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
**************************************************************************/
var ${pageName}Control = new DatasetControl({
prefix : "nhtSndngDtl"
, prefixName : "발송 상세"
, keymapper : info => info ? info.SNDNG_DTL_ID : ""
, dataGetter : obj => obj.nhtSndngDtlList
, appendData : true
, tableRenderComplete : false // dataTables 에 자료 추가 완료 여부
, formats : {
SNDNG_YMD : dateFormat
, DUDT_YMD : dateFormat
, FFNLG_AMT : numberFormat
, REG_DT : datetimeFormat
, MDFCN_DT : datetimeFormat
}
prefix : "nhtTrgt"
, prefixName : "고지서 발송 대상"
, keymapper : info => info ? info.CRDN_ID : ""
, dataGetter : obj => obj.nhtTrgtList
});
/**************************************************************************
* DatasetControl 이벤트
**************************************************************************/
// Dataset 변경 이벤트
${pageName}Control.onDatasetChange = obj => {
renderList${pageName}();
${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"); // 개별총정보
};
// 저장 callback
${pageName}Control.onSave = (resp) => {
let dialogTitle = $("#" + ${pageName}Control.prefix + "Dialog").find("h5.modal-title").html();
let showMessage = resp.retMessage.replace(/[S]|[F]/g, dialogTitle);
// 선택(체크) 변경 이벤트
${pageName}Control.onSelectionChange = selected => {
let ${infoPrefix}List = ${pageName}Control.dataset;
let keys = selected.map(e => ${infoPrefix}List.getKey(e));
dialog.alert(showMessage);
$("#tbody--${pageName} input[type='checkbox']").each(function() {
let checkbox = $(this);
if (resp.saved) {
dialog.close(${pageName}Control.prefix + "Dialog");
checkbox.prop("checked", keys.includes(checkbox.val()));
});
};
// 개별총정보 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"
});
if ("${savedCallbackFuncName}" != "") {
${savedCallbackFuncName}(resp.saved);
}
});
}
/**************************************************************************
*
**************************************************************************/
// 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) => {
// 선택된 자료의 발송 상세 ID 추가
let selected = ${pageName}Control.dataset.getKeys("selected");
if (selected.length < 1) return;
// 저장
${pageName}Control.save = (info) => {
if (!info) return;
params.sndngDtlIDs = selected.join(","); // 발송 상세 IDs
params.delYn = "N"; // 삭제 여부
let create = isEmpty(info.levyExclId);
ajax.post({
url : wctx.url("/" + params.taskSeCd + ${pageName}PrefixUrl + "/levyIdnty.do")
, data : params || {}
, success : resp => { }
url : !create ? ${pageName}Control.urls.update : ${pageName}Control.urls.create
, data : info
, success : resp => ${pageName}Control.onSave(resp)
});
}
@ -361,94 +220,73 @@
$("#DataTables_Table_0--${pageName}").find("th").resizable( {handles : "e"} );
}
/**************************************************************************
* 버튼 clickEvent
**************************************************************************/
// 엑셀 저장
fnExcel${pageName} = () => {
}
// 화면 초기값 셋팅
setForm${pageName} = (taskSeCd) => {
// 업무에 따른 위반 내용
let vltnIdCode = [];
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} = () => {
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
// 위반 항목
$("#schVltnId--${pageName}").empty();
dialog.alert({
content : "세외수입 과태료 대장에 등록하시겠습니까?"
, onOK : () => {
createNxrp${pageName}(${pageName}Fields.get());
}
$("#schVltnId--${pageName}").append("<option value=''>" + "전체" + "</option>");
$(vltnIdCode).each(function(index, item) {
$("#schVltnId--${pageName}").append("<option value='" + vltnIdCode[index].code +"'>" + vltnIdCode[index].value + "</option>");
});
}
// 매치정보 등록
fnUpdateNxrpMtchg${pageName} = () => {
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
// 달력 초기화
initDatepicker("frmSearch--${pageName}");
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());
}
// 우편통합 발송
fnCreateSndngLink${pageName} = () => {
// 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);
// URL 설정
setURL${pageName} = (taskSeCd) => {
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();
// 등기번호 등록
fnCreateRgNo${pageName} = () => {
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
${pageName}Control.query.fetchSize = FETCH_XS; // 한번에 조회되는 자료 건수 FETCH_XS = 30
${pageName}Control.query.delYn = "N"; // 삭제 여부
${pageName}Control.query.crdnDelYn = "N"; // 단속 대장 삭제 여부
createRgNo${pageName}(${pageName}Fields.get());
${pageName}Control.load();
}
// 반송(종적결과) 확인
fnCreateSndbk${pageName} = () => {
// 저장
fnSave${pageName} = () => {
// validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return;
dialog.alert({
content : "종적결과를 확인하시겠습니까?"
content : "현재 " + ${pageName}Control.prefixName + " 정보를 저장하시겠습니까?"
, 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 진입
**************************************************************************/
@ -463,8 +301,11 @@
// 이벤트 설정
setEvent${pageName}();
// Dataset 셋팅 - 화면이 열리면서 조회하는 경우 addData 하여 자료를 추가
${pageName}Control.addData(${nhtSndngDtl});
// 화면 초기값 설정
setForm${pageName}("${taskSeCd}");
// URL 설정
setURL${pageName}("${taskSeCd}");
});
</script>

Loading…
Cancel
Save