1. 부과제외 수정.

2. 기타 수정.
main
jjh 3 months ago
parent 9e56edbde4
commit 42276a096b

@ -183,13 +183,13 @@
<!-- DataTables(그리드) --> <!-- DataTables(그리드) -->
<div class="card-datatable text-nowrap"> <div class="card-datatable text-nowrap">
<div class="dataTables_wrapper dt-bootstrap5 no-footer"> <div class="dataTables_wrapper dt-bootstrap5 no-footer">
<div class="table-responsive ox-scroll oy-scroll h-px-500" name="table-responsive"> <div class="table-responsive ox-scroll oy-scroll h-px-500" name="tableRspns">
<table class="table-layout-fixed dataTable datatables-ajax table table-bordered no-footer" aria-describedby="DataTables_Table_0_info"> <table class="table-layout-fixed dataTable datatables-ajax table table-bordered no-footer" aria-describedby="DataTables_Table_0_info">
<thead class="sticky-thead"> <thead class="sticky-thead">
<tr name="theadTr" data-search-target="[data-doctx='${pageName}']"> <tr name="theadTr" data-search-target="[data-doctx='${pageName}']">
</tr> </tr>
</thead> </thead>
<template name="titleCols"> <template name="tmpltCols">
<th class="cmn" style="width: 72px;">No.</th> <th class="cmn" style="width: 72px;">No.</th>
<th class="cmn" style="width: 56px;"><input type="checkbox" class="form-check-input" name="gridAllCheckbox" onchange="pageObject['${pageName}'].dataTableCheckbox(this, this.checked);" /></th> <th class="cmn" style="width: 56px;"><input type="checkbox" class="form-check-input" name="gridAllCheckbox" onchange="pageObject['${pageName}'].dataTableCheckbox(this, this.checked);" /></th>
<th class="cmn" style="width: 160px;">업무구분</th> <th class="cmn" style="width: 160px;">업무구분</th>
@ -225,10 +225,10 @@
</template> </template>
<tbody name="tbodyList"> <tbody name="tbodyList">
</tbody> </tbody>
<template is="curly-brackets" name="dataRows"> <template is="curly-brackets" name="tmpltRows">
<tr data-key="LEVY_EXCL_ID"> <tr data-key="LEVY_EXCL_ID">
<td class="cmn text-center" onclick ondblclick>{ROW_NUM}</td> <td class="cmn text-center" onclick ondblclick>{ROW_NUM}</td>
<td class="cmn text-center"><input type="checkbox" class="form-check-input" name="gridCheckbox" value="MPNG_ID" onchange="pageObject['${pageName}'].dataTableCheckbox(this, this.checked);" /></td> <td class="cmn text-center"><input type="checkbox" class="form-check-input" name="gridCheckbox" value="LEVY_EXCL_ID" onchange="pageObject['${pageName}'].dataTableCheckbox(this, this.checked);" /></td>
<td class="cmn text-center" onclick ondblclick>{TASK_SE_NM}</td> <td class="cmn text-center" onclick ondblclick>{TASK_SE_NM}</td>
<td class="cmn text-center" onclick ondblclick>{LEVY_EXCL_YMD}</td> <td class="cmn text-center" onclick ondblclick>{LEVY_EXCL_YMD}</td>
<td class="cmn text-center" onclick ondblclick>{LEVY_EXCL_SE_NM}</td> <td class="cmn text-center" onclick ondblclick>{LEVY_EXCL_SE_NM}</td>
@ -264,7 +264,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="dataNotFound"> <template name="tmpltNotFound">
<tr class="bpv"> <tr class="bpv">
<td valign="top" colspan="29" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td> <td valign="top" colspan="29" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -350,7 +350,7 @@
$P.ctrl.onCurrentChange = (item) => { $P.ctrl.onCurrentChange = (item) => {
if (!item) return; if (!item) return;
let key = item.data.MPNG_ID; let key = item.data.LEVY_EXCL_ID;
$P.$find("tbodyList").setCurrentRow(key); $P.$find("tbodyList").setCurrentRow(key);
}; };
@ -374,7 +374,7 @@
dialog.open({ dialog.open({
id: dialogId id: dialogId
, title: $P.control.prefixName + " 정보" , title: params.btnTitle
, size: $P.ctrl.infoSize , size: $P.ctrl.infoSize
, content: resp , content: resp
, init: () => { , init: () => {
@ -391,7 +391,7 @@
// 삭제 callback // 삭제 callback
$P.ctrl.onRemove = (params, resp) => { $P.ctrl.onRemove = (params, resp) => {
let showMessage = resp.rtnMsg.replace(/[S]|[F]/g, $P.ctrl.prefixName); let showMessage = resp.rtnMsg.replace(/[S]|[F]/g, params.btnTitle);
// 메시지 출력 // 메시지 출력
dialog.alert({ dialog.alert({
@ -427,7 +427,7 @@
let clsForTask = $P.$find("taskSeCd").val().toLowerCase(); // 소문자 let clsForTask = $P.$find("taskSeCd").val().toLowerCase(); // 소문자
// 업무별 DataTables(그리드) tr, td // 업무별 DataTables(그리드) tr, td
let foundContent = $P.find("dataRows").content; let foundContent = $P.find("tmpltRows").content;
let foundTr = $(foundContent).find("tr")[0].cloneNode(false); let foundTr = $(foundContent).find("tr")[0].cloneNode(false);
let foundTds = $(foundContent).find("." + clsForTask + ",.cmn"); let foundTds = $(foundContent).find("." + clsForTask + ",.cmn");
@ -439,7 +439,7 @@
.replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('" + dataItem.getValue("LEVY_EXCL_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('" + dataItem.getValue("LEVY_EXCL_ID") + "');")
.replace(/{ondblclick}/gi, "pageObject['${pageName}'].dataTableDblClick('" + dataItem.getValue("LEVY_EXCL_ID") + "');"); .replace(/{ondblclick}/gi, "pageObject['${pageName}'].dataTableDblClick('" + dataItem.getValue("LEVY_EXCL_ID") + "');");
let trs = empty ? [$P.find("dataNotFound").content.querySelector("." + clsForTask + ",.cmn").outerHTML] : let trs = empty ? [$P.find("tmpltNotFound").content.querySelector("." + clsForTask + ",.cmn").outerHTML] :
dataList.inStrings(foundTr.outerHTML, replacer); dataList.inStrings(foundTr.outerHTML, replacer);
let noMore = (dataList.length >= totalSize); let noMore = (dataList.length >= totalSize);
@ -449,7 +449,7 @@
initScroll = false; initScroll = false;
} }
$P.find("table-responsive").changeContent(trs.join(), initScroll, noMore); $P.find("tableRspns").changeContent(trs.join(), initScroll, noMore);
// checkbox 체크 해제 // checkbox 체크 해제
$P.$find("gridAllCheckbox").prop("checked", false); $P.$find("gridAllCheckbox").prop("checked", false);
@ -538,6 +538,7 @@
sggCd: $P.$find("sggCd").val() // 시군구 코드 sggCd: $P.$find("sggCd").val() // 시군구 코드
, taskSeCd: $P.$find("taskSeCd").val() // 업무 구분 코드 , taskSeCd: $P.$find("taskSeCd").val() // 업무 구분 코드
, levyExclIds: selected.join(",") // 부과 제외 IDs , levyExclIds: selected.join(",") // 부과 제외 IDs
, btnTitle: obj.btnTitle // 버튼 title
, delRsn: obj.reason // 삭제 사유 , delRsn: obj.reason // 삭제 사유
}; };
@ -591,14 +592,14 @@
renderForTask($P.find("gridbuttonArea"), taskSeCd.toLowerCase()); renderForTask($P.find("gridbuttonArea"), taskSeCd.toLowerCase());
// 업무별 그리드 th // 업무별 그리드 th
let colContent = $P.find("titleCols").content; let colContent = $P.find("tmpltCols").content;
let cols = $(colContent).find("." + taskSeCd.toLowerCase() + ",.cmn"); let cols = $(colContent).find("." + taskSeCd.toLowerCase() + ",.cmn");
let colsOuterHTML = ""; let colsOuterHTML = "";
cols.each(function() { cols.each(function() {
colsOuterHTML += this.outerHTML; colsOuterHTML += this.outerHTML;
}); });
$P.find("table-responsive").changeColumn(colsOuterHTML); $P.find("tableRspns").changeColumn(colsOuterHTML);
} }
// 사용자검색 버튼 클릭 이벤트 // 사용자검색 버튼 클릭 이벤트
@ -654,13 +655,13 @@
// DataTables(그리드) // DataTables(그리드)
$P.ctrl.query.cellDefs = $P.ctrl.query.cellDefs =
getCellDefs($P.$find("theadTr").find("th").not(".dummy-th").not(":eq(0)") getCellDefs($P.$find("theadTr").find("th").not(".dummy-th").not(":eq(0)")
, $($P.find("dataRows").content).find("td").not(".dummy-td").not(":eq(0)")); , $($P.find("tmpltRows").content).find("td").not(".dummy-td").not(":eq(0)"));
$P.ctrl.download(); $P.ctrl.download();
} }
// 부과제외 수정 버튼 클릭 이벤트 // 부과제외 수정 버튼 클릭 이벤트
$P.fnUpdate = () => { $P.fnUpdate = (btnTitle) => {
// 부과제외 ID // 부과제외 ID
let levyExclId = $P.ctrl.getValue("LEVY_EXCL_ID"); let levyExclId = $P.ctrl.getValue("LEVY_EXCL_ID");
@ -669,6 +670,7 @@
let params = { let params = {
callPurpose: "update" // 호출용도: 수정 callPurpose: "update" // 호출용도: 수정
, btnTitle: btnTitle // 버튼 title
, sggCd: $P.ctrl.getValue("SGG_CD") // 시군구 코드 , sggCd: $P.ctrl.getValue("SGG_CD") // 시군구 코드
, taskSeCd: $P.ctrl.getValue("TASK_SE_CD") // 업무 구분 코드 , taskSeCd: $P.ctrl.getValue("TASK_SE_CD") // 업무 구분 코드
, levyExclId: $P.ctrl.getValue("LEVY_EXCL_ID") // 부과제외 ID , levyExclId: $P.ctrl.getValue("LEVY_EXCL_ID") // 부과제외 ID
@ -679,7 +681,7 @@
} }
// 부과제외 삭제 버튼 클릭 이벤트 // 부과제외 삭제 버튼 클릭 이벤트
$P.fnRemove = () => { $P.fnRemove = (btnTitle) => {
let selected = $P.ctrl.dataset.getKeys("selected"); // 선택 자료 let selected = $P.ctrl.dataset.getKeys("selected"); // 선택 자료
if (selected.length < 1) { if (selected.length < 1) {
@ -706,7 +708,10 @@
, content: template , content: template
, init: () => { setDialogZindex(); } , init: () => { setDialogZindex(); }
, onOK: () => { , onOK: () => {
$P.callbackRsn({ reason: $("#reason").val() }); $P.callbackRsn({
btnTitle: btnTitle // 버튼 title
, reason: $("#reason").val() // 삭제 사유
});
} }
}); });
}); });
@ -728,15 +733,32 @@
// 동적검색에서 엔터(Enter) 키를 누르면 검색한다. // 동적검색에서 엔터(Enter) 키를 누르면 검색한다.
$P.$find("term").onEnterPress($P.fnSearchList); $P.$find("term").onEnterPress($P.fnSearchList);
// form-date 항목에서 키보드로 입력시 날짜 포맷팅 적용
$P.$find("frmSearch").find(".form-date").each(function() {
$(this).on("input", function() {
let value = this.value.replaceAll("-", "");
if (value.length > 7) {
this.value = value.substring(0, 4) + "-" + value.substring(4, 6) + "-" + value.substring(6);
} else if(value.length > 5) {
this.value = value.substring(0, 4) + "-" + value.substring(4);
}
});
});
// 업무 버튼 이벤트 // 업무 버튼 이벤트
$P.$find("btnUpdate").on("click", () => { $P.fnUpdate(); }); // 수정 $P.$find("btnUpdate").on("click", function() {
$P.$find("btnRemove").on("click", () => { $P.fnRemove(); }); // 삭제 $P.fnUpdate($P.$find("btnUpdate").attr("title")); // 수정
});
$P.$find("btnRemove").on("click", function() {
$P.fnRemove($P.$find("btnRemove").attr("title")); // 삭제
});
// DataTables width 변경 조정 // DataTables width 변경 조정
fnMakeResizableTable($P.find("table-responsive")); fnMakeResizableTable($P.find("tableRspns"));
// DataTables 스크롤 이벤트 생성 // DataTables 스크롤 이벤트 생성
fnMakeScrollableTable($P.find("table-responsive"), $P.scrollDataList); fnMakeScrollableTable($P.find("tableRspns"), $P.scrollDataList);
} }
/************************************************************************** /**************************************************************************
@ -745,8 +767,11 @@
// 1. 이벤트 설정 // 1. 이벤트 설정
$P.setEvent(); $P.setEvent();
// 2. 초기 설정 및 업무 구분 변경 // 2. 초기 설정
$P.fnResetAndChangeBiz($("#layout-navbar input[name='taskSeCd']:checked").val()); initDatepicker($P.find("frmSearch")); // 달력 초기화
initDetailSearchButton($P.find("frmSearch"));
$P.fnResetAndChangeBiz($("#layout-navbar input[name='taskSeCd']:checked").val()); // 초기 설정 및 업무 구분 변경
// 3. 보안모드 // 3. 보안모드
fn_securityModeToggle($("#securityMode--top").is(":checked")); fn_securityModeToggle($("#securityMode--top").is(":checked"));

@ -4,46 +4,46 @@
<c:set var="prefixName" scope="request">부과제외 상세 정보</c:set> <c:set var="prefixName" scope="request">부과제외 상세 정보</c:set>
<!-- inner page html --> <!-- inner page html -->
<div class="content-pop"> <div class="content-pop"data-doctx="${pageName}">
<!-- Content --> <!-- Content -->
<div class="container flex-grow-1 px-0"> <div class="container flex-grow-1 px-0">
<div class="card"> <div class="card">
<!-- 입력 영역 --> <!-- 입력 영역 -->
<form id="frmEdit--${pageName}" name="frmEdit"> <form name="frmEdit">
<!-- hidden --> <!-- hidden -->
<input type="hidden" id="sggCd--${pageName}" name="sggCd" data-map="SGG_CD" /> <input type="hidden" name="sggCd" data-map="SGG_CD" />
<input type="hidden" id="taskSeCd--${pageName}" name="taskSeCd" data-map="TASK_SE_CD" /> <input type="hidden" name="taskSeCd" data-map="TASK_SE_CD" />
<input type="hidden" id="crdnId--${pageName}" name="crdnId" data-map="CRDN_ID" /> <input type="hidden" name="crdnId" data-map="CRDN_ID" />
<input type="hidden" id="levyExclId--${pageName}" name="levyExclId" data-map="LEVY_EXCL_ID" /> <input type="hidden" name="levyExclId" data-map="LEVY_EXCL_ID" />
<div class="row g-1"> <div class="row g-1">
<!-- 단속일시 --> <!-- 단속일시 -->
<div class="col-md-12"> <div class="col-md-12">
<label for="crdnYmdTm--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">단속일시</label> <label is="name-label" class="col-form-label bg-lighter pe-2 w-px-120 text-sm-end" for="crdnYmdTm">단속일시</label>
<input type="text" class="form-control w-35" id="crdnYmdTm--${pageName}" name="crdnYmdTm" data-map="CRDN_YMD_TM" data-fmt-type="dt" /> <input is="id-input" type="text" class="form-control w-px-160" name="crdnYmdTm" data-map="CRDN_YMD_TM" data-fmt-type="dt" />
</div> </div>
<!-- 차량번호 --> <!-- 차량번호 -->
<div class="col-md-12"> <div class="col-md-12">
<label for="vhrno--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">차량번호</label> <label is="name-label" class="col-form-label bg-lighter pe-2 w-px-120 text-sm-end" for="vhrno">차량번호</label>
<input type="text" class="form-control w-px-120" id="vhrno--${pageName}" name="vhrno" data-map="VHRNO" autocomplete="off" /> <input is="id-input" type="text" class="form-control w-px-120" name="vhrno" data-map="VHRNO" autocomplete="off" />
</div> </div>
<!-- 부과 제외 구분 --> <!-- 부과 제외 구분 -->
<div class="col-md-12"> <div class="col-md-12">
<label for="levyExclSeNm--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">부과제외구분</label> <label is="name-label" class="col-form-label bg-lighter pe-2 w-px-120 text-sm-end required" for="levyExclSeNm">부과제외구분</label>
<input type="text" class="form-control w-px-120" id="levyExclSeNm--${pageName}" autocomplete="off" /> <input is="id-input" type="text" class="form-control w-px-120" name="levyExclSeNm" autocomplete="off" />
<input type="hidden" id="levyExclSeCd--${pageName}" name="levyExclSeCd" data-map="LEVY_EXCL_SE_CD" /> <input type="hidden" name="levyExclSeCd" data-map="LEVY_EXCL_SE_CD" />
</div> </div>
<!-- 부과 제외 일자 --> <!-- 부과 제외 일자 -->
<div class="col-md-12"> <div class="col-md-12">
<label for="levyExclYmd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">부과제외일자</label> <label is="name-label" class="col-form-label bg-lighter pe-2 w-px-120 text-sm-end required" for="levyExclYmd">부과제외일자</label>
<input type="text" class="form-control form-date" id="levyExclYmd--${pageName}" name="levyExclYmd" data-map="LEVY_EXCL_YMD" <input type="text" class="form-control form-date" name="levyExclYmd" data-map="LEVY_EXCL_YMD"
data-fmt-type="day" autocomplete="off" title="날짜 선택" maxlength="10" required /> data-fmt-type="day" autocomplete="off" title="날짜 선택" maxlength="10" required />
<button type="button" class="bx bx-lg bx-calendar bg-white" id="btnLevyExclYmd--${pageName}"></button> <button type="button" class="bx bx-lg bx-calendar bg-white" name="btnLevyExclYmd"></button>
</div> </div>
<!-- 부과 제외 사유 --> <!-- 부과 제외 사유 -->
<div class="col-md-12"> <div class="col-md-12">
<label for="levyExclRsnCd--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end required">부과제외사유</label> <label is="name-label" class="col-form-label bg-lighter pe-2 w-px-120 text-sm-end required" for="levyExclRsnCd">부과제외사유</label>
<select class="form-select" id="levyExclRsnCd--${pageName}" name="levyExclRsnCd" data-map="LEVY_EXCL_RSN_CD" required> <select is="id-select" class="form-select" name="levyExclRsnCd" data-map="LEVY_EXCL_RSN_CD" required>
<option value="">선택하세요</option> <option value="">선택하세요</option>
<c:forEach items="${FIM022List}" var="item"> <c:forEach items="${FIM022List}" var="item">
<option value="${item.code}">${item.value}</option> <option value="${item.code}">${item.value}</option>
@ -52,8 +52,8 @@
</div> </div>
<!-- 기타 내용 --> <!-- 기타 내용 -->
<div class="col-md-12"> <div class="col-md-12">
<label for="etcCn--${pageName}" class="w-px-120 bg-lighter pe-2 col-form-label text-sm-end">기타 내용</label> <label is="name-label" class="col-form-label bg-lighter pe-2 w-px-120 text-sm-end" for="etcCn">기타 내용</label>
<textarea type="text" class="form-control w-70" id="etcCn--${pageName}" name="etcCn" data-map="ETC_CN" autocomplete="off" rows="3" data-maxlengthb="1000"></textarea> <textarea is="id-textarea" type="text" class="form-control w-70" name="etcCn" data-map="ETC_CN" autocomplete="off" rows="3" data-maxlengthb="1000"></textarea>
</div> </div>
</div> </div>
</form> </form>
@ -64,7 +64,7 @@
<span class="container-page-btn"> <span class="container-page-btn">
<!-- 업무 버튼 --> <!-- 업무 버튼 -->
<span class="container-window-btn-right"> <span class="container-window-btn-right">
<button type="button" class="btn btn-primary w-px-80" id="btnSave--${pageName}" title="저장"> <button type="button" class="btn btn-primary w-px-80" name="btnSave" title="저장">
저장 저장
</button> </button>
</span> </span>
@ -81,7 +81,7 @@
/************************************************************************** /**************************************************************************
* Global Variable * Global Variable
**************************************************************************/ **************************************************************************/
pageObject["${pageName}"] = {}; pageObject["${pageName}"] = newDoctxFinder("${pageName}");
// 공통 코드 // 공통 코드
var FIM021 = new CommonCodes(${FIM021}, true); var FIM021 = new CommonCodes(${FIM021}, true);
@ -97,42 +97,43 @@
// infoDialog 호출 용도(view 조회(편집불가), create 등록, update 수정) // infoDialog 호출 용도(view 조회(편집불가), create 등록, update 수정)
$P.callPurpose = "${callPurpose}"; $P.callPurpose = "${callPurpose}";
// FormFields // FormFields
$P.formFields = new FimsFormFields("#frmEdit--${pageName}"); $P.formFields = new FimsFormFields($P.selector("frmEdit"));
/************************************************************************** /**************************************************************************
* DatasetControl * DatasetControl
**************************************************************************/ **************************************************************************/
$P.control = new DatasetControl({ $P.ctrl = new DatasetControl({
prefix: "levyExcl" prefix: "levyExcl"
, prefixName: "부과제외" , prefixName: "부과제외"
, keymapper: info => info ? info.LEVY_EXCL_ID : "" , keymapper: info => info ? info.LEVY_EXCL_ID : ""
, dataGetter: obj => obj.${infoPrefix}Info , dataGetter: obj => obj.info
}); });
/************************************************************************** /**************************************************************************
* DatasetControl 이벤트 * DatasetControl 이벤트
**************************************************************************/ **************************************************************************/
// 현재 선택 자료 변경 이벤트 // 현재 선택 자료 변경 이벤트
$P.control.onCurrentChange = (item) => { $P.ctrl.onCurrentChange = (item) => {
if (!item) return; if (!item) return;
// Dataset 셋팅 // Dataset 셋팅
$P.formFields.set($P.control, item); $P.formFields.set($P.ctrl, item);
// 업무구분에 따른 URL 변경 // 업무구분에 따른 URL 변경
$P.fnSetURL(item.data.TASK_SE_CD); $P.fnSetURL(item.data.TASK_SE_CD);
// 부과제외구분에 따른 부과제외사유 설정 // 부과제외구분에 따른 부과제외사유 설정
$P.fnSetFim021(item.data.LEVY_EXCL_SE_CD, item.data.LEVY_EXCL_RSN_CD); $P.fnSetFim021(item.data.LEVY_EXCL_SE_CD, item.data.LEVY_EXCL_RSN_CD);
// 호출용도가 등록 이라면.. // 호출용도가 등록 이라면..
if ($P.callPurpose == "create") { if ($P.callPurpose == "create") {
$("#levyExclYmd--${pageName}").datepicker("setDate", new Date()); $P.$P.$find("levyExclYmd").datepicker("setDate", new Date());
} }
} }
// 저장 callback // 저장 callback
$P.control.onSave = (resp) => { $P.ctrl.onSave = (resp) => {
let dialogTitle = $($("#frmEdit--${pageName}").parents(".modal")[0]).find("h5.modal-title").html(); let dialogTitle = $("#" + $P.selfDlgId()).find("h5.modal-title").html();
let showMessage = resp.rtnMsg.replace(/[S]|[F]/g, dialogTitle); let showMessage = resp.rtnMsg.replace(/[S]|[F]/g, dialogTitle);
// 메시지 출력 // 메시지 출력
@ -140,19 +141,18 @@
content: showMessage content: showMessage
, init: () => { setDialogZindex(); } , init: () => { setDialogZindex(); }
, onOK: () => { } , onOK: () => { }
}); , onClose: () => {
if (resp.saved) {
dialog.close($("#frmEdit--${pageName}").parents(".modal")[0].id);
if ("${savedCallbackFuncName}" != "") { if ("${savedCallbackFuncName}" != "") {
${savedCallbackFuncName}(resp.saved); ${savedCallbackFuncName}(resp.saved);
} }
if (resp.saved) { dialog.close($P.selfDlgId()); }
} }
});
} }
// 저장 // 저장
$P.control.save = (info) => { $P.ctrl.save = (info) => {
if (!info) return; if (!info) return;
let create = ($P.callPurpose == "create"); let create = ($P.callPurpose == "create");
@ -162,9 +162,9 @@
${saveCallbackFuncName}(info); ${saveCallbackFuncName}(info);
} else { } else {
ajax.post({ ajax.post({
url: !create ? $P.control.urls.update : $P.control.urls.create url: !create ? $P.ctrl.urls.update : $P.ctrl.urls.create
, data: info || {} , data: info || {}
, success: resp => $P.control.onSave(resp) , success: resp => $P.ctrl.onSave(resp)
}); });
} }
} }
@ -174,22 +174,22 @@
**************************************************************************/ **************************************************************************/
// 업무구분에 따른 URL 설정 // 업무구분에 따른 URL 설정
$P.fnSetURL = (taskSeCd) => { $P.fnSetURL = (taskSeCd) => {
$P.control.urls.create = wctx.url("/" + taskSeCd + "${infoPrefixUrl}" + "/020/create.do"); // 등록 $P.ctrl.urls.create = wctx.url("/" + taskSeCd + "${infoPrefixUrl}" + "/020/create.do"); // 등록
$P.control.urls.update = wctx.url("/" + taskSeCd + "${infoPrefixUrl}" + "/020/update.do"); // 수정 $P.ctrl.urls.update = wctx.url("/" + taskSeCd + "${infoPrefixUrl}" + "/020/update.do"); // 수정
} }
// 부과제외 구분에 따른 부과제외 사유 코드 설정 // 부과제외 구분에 따른 부과제외 사유 코드 설정
$P.fnSetFim021 = (seCode, rsnCode) => { $P.fnSetFim021 = (seCode, rsnCode) => {
let cmnCode = FIM021[seCode]; let cmnCode = FIM021[seCode];
$("#levyExclSeCd--${pageName}").val(cmnCode.code); $P.$find("levyExclSeCd").val(cmnCode.code);
$("#levyExclSeNm--${pageName}").val(cmnCode.value); $P.$find("levyExclSeNm").val(cmnCode.value);
let reasons = FIM022.list().filter(reason => "2" == seCode ? reason.code > "200" : reason.code < "200"); let reasons = FIM022.list().filter(reason => "2" == seCode ? reason.code > "200" : reason.code < "200");
$("#levyExclRsnCd--${pageName}").html(reasons.map(reason => "<option value='" + reason.code + "'>" + reason.value + "</option>").join()); $P.$find("levyExclRsnCd").html(reasons.map(reason => "<option value='" + reason.code + "'>" + reason.value + "</option>").join());
if (typeof rsnCode != "undefined" && rsnCode != "") { if (typeof rsnCode != "undefined" && rsnCode != "") {
$("#levyExclRsnCd--${pageName}").val(rsnCode); $P.$find("levyExclRsnCd").val(rsnCode);
} }
} }
@ -199,14 +199,12 @@
// 저장 버튼 클릭 이벤트 // 저장 버튼 클릭 이벤트
$P.fnSave = () => { $P.fnSave = () => {
// validate 확인 // validate 확인
if (!customValidate($("#frmEdit--${pageName}").find("input, select, textarea"))) return; if (!customValidate($P.$find("frmEdit").find("input,select,textarea"))) return;
dialog.alert({ dialog.alert({
content: "현재 " + $P.control.prefixName + " 정보를 저장하시겠습니까?" content: "현재 " + $P.ctrl.prefixName + " 정보를 저장하시겠습니까?"
, init: () => { setDialogZindex(); } , init: () => { setDialogZindex(); }
, onOK: () => { , onOK: () => { $P.ctrl.save($P.formFields.get()); } // formFields
$P.control.save($P.formFields.get()); // formFields
}
}); });
} }
@ -216,7 +214,7 @@
// 이벤트 설정 // 이벤트 설정
$P.setEvent = () => { $P.setEvent = () => {
// form-date 항목에서 키보드로 입력시 날짜 포맷팅 적용 // form-date 항목에서 키보드로 입력시 날짜 포맷팅 적용
$("#frmEdit--${pageName}").find(".form-date").each(function() { $P.$find("frmEdit").find(".form-date").each(function() {
$(this).on("input", function() { $(this).on("input", function() {
let value = this.value.replaceAll("-", ""); let value = this.value.replaceAll("-", "");
@ -229,27 +227,30 @@
}); });
// 버튼 이벤트 // 버튼 이벤트
$("#btnSave--${pageName}").on("click", () => $P.fnSave()); // 저장 $P.$find("btnSave").on("click", () => { $P.fnSave() }); // 저장
} }
// 초기 화면 설정 // 초기 화면 설정
$P.initForm = () => { $P.initForm = () => {
// 화면 초기화
$P.find("frmEdit").reset();
// 달력 초기화 // 달력 초기화
initDatepicker("frmEdit--${pageName}"); initDatepicker($P.find("frmEdit"));
$("#levyExclYmd--${pageName}").datepicker("setDate", new Date()); $P.$find("levyExclYmd").datepicker("setDate", TODAY());
// 화면 활성화 설정 // 화면 활성화 설정
$("#crdnYmdTm--${pageName}").prop("readonly", true); // 단속 일시 $P.$find("crdnYmdTm").prop("readonly", true); // 단속 일시
$("#vhrno--${pageName}").prop("readonly", true); // 차량번호 $P.$find("vhrno").prop("readonly", true); // 차량번호
$("#levyExclSeNm--${pageName}").prop("readonly", true); // 부과 제외 구분 $P.$find("levyExclSeNm").prop("readonly", true); // 부과 제외 구분
// View로 호출 // View로 호출
if ($P.callPurpose == "view") { if ($P.callPurpose == "view") {
// input 요소들을 disabled // input 요소들을 disabled
$("#frmEdit--${pageName}").find("input,textarea,select").prop("disabled", true); $P.$find("frmEdit").find("input,textarea,select").prop("disabled", true);
// button 요소들을 disabled // button 요소들을 disabled
$("#btnLevyExclYmd--${pageName}").prop("disabled", true); // 부과제외 일자 달력 버튼 $P.$find("btnLevyExclYmd").prop("disabled", true); // 부과제외 일자 달력 버튼
$("#btnSave--${pageName}").prop("disabled", true); // 저장 버튼 $P.$find("btnSave").prop("disabled", true); // 저장 버튼
} }
} }
@ -262,8 +263,8 @@
// 2. 초기 화면 설정 // 2. 초기 화면 설정
$P.initForm(); $P.initForm();
// 3. Dataset 설정 // 3. dataset 설정
$P.control.setData([${levyExclInfo}]); $P.ctrl.setData([${info}]);
}); });
</script> </script>

@ -113,7 +113,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFound"> <template name="tmpltNotFound">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="17" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td> <td valign="top" colspan="17" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -257,7 +257,7 @@
let dataList = $P.ctrl.dataset; let dataList = $P.ctrl.dataset;
let empty = dataList.empty; let empty = dataList.empty;
let trs = empty ? [$P.find("notFound").innerHTML] : let trs = empty ? [$P.find("tmpltNotFound").innerHTML] :
dataList.inStrings($P.find("tmpltRows").innerHTML dataList.inStrings($P.find("tmpltRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('" + dataItem.getValue("MPNG_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('" + dataItem.getValue("MPNG_ID") + "');")

@ -109,7 +109,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFound"> <template name="tmpltNotFound">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="11" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td> <td valign="top" colspan="11" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -277,7 +277,7 @@
let dataList = $P.ctrl.dataset; let dataList = $P.ctrl.dataset;
let empty = dataList.empty; let empty = dataList.empty;
let trs = empty ? [$P.find("notFound").innerHTML] : let trs = empty ? [$P.find("tmpltNotFound").innerHTML] :
dataList.inStrings($P.find("tmpltRows").innerHTML dataList.inStrings($P.find("tmpltRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('" + dataItem.getValue("ENT_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('" + dataItem.getValue("ENT_ID") + "');")
@ -296,7 +296,7 @@
// checkbox 체크 해제 // checkbox 체크 해제
$P.$find("gridAllCheckbox").prop("checked", false); $P.$find("gridAllCheckbox").prop("checked", false);
//보안모드 // 보안모드
fn_securityModeToggle($("#securityMode--top").is(":checked")); fn_securityModeToggle($("#securityMode--top").is(":checked"));
} }

@ -199,6 +199,7 @@
dialog.alert({ dialog.alert({
content: "현재 " + $P.ctrl.prefixName + " 정보를 저장하시겠습니까?" content: "현재 " + $P.ctrl.prefixName + " 정보를 저장하시겠습니까?"
, init: () => { setDialogZindex(); }
, onOK: () => { $P.ctrl.save($P.formFields.get()); } // formFields , onOK: () => { $P.ctrl.save($P.formFields.get()); } // formFields
}); });
} }

@ -29,7 +29,7 @@
<button type="button" class="btn btn-primary w-px-120" name="btnPrintDlbrDecsn" title="심의의결서 출력"> <button type="button" class="btn btn-primary w-px-120" name="btnPrintDlbrDecsn" title="심의의결서 출력">
심의의결서 출력 심의의결서 출력
</button> </button>
</span> </span> <!-- <span class="container-window-btn-right"> -->
</div> <!-- <div class="container-page-btn"> --> </div> <!-- <div class="container-page-btn"> -->
<div class="row g-1"> <div class="row g-1">

@ -93,7 +93,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFoundSndngDtl"> <template name="tmpltNotFoundSndngDtl">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="25" class="dataTables_empty text-center">발송 정보를 찾지 못했습니다.</td> <td valign="top" colspan="25" class="dataTables_empty text-center">발송 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -181,7 +181,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFoundSvbtc"> <template name="tmpltNotFoundSvbtc">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="9" class="dataTables_empty text-center">공시송달 정보를 찾지 못했습니다.</td> <td valign="top" colspan="9" class="dataTables_empty text-center">공시송달 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -364,7 +364,7 @@
let sndngDtlList = $P.ctrlSndngDtl.dataset; let sndngDtlList = $P.ctrlSndngDtl.dataset;
let empty = sndngDtlList.empty; let empty = sndngDtlList.empty;
let trs = empty ? [$P.find("notFoundSndngDtl").innerHTML] : let trs = empty ? [$P.find("tmpltNotFoundSndngDtl").innerHTML] :
sndngDtlList.inStrings($P.find("tmpltSndngDtlRows").innerHTML sndngDtlList.inStrings($P.find("tmpltSndngDtlRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlSndngDtl.setCurrent('" + dataItem.getValue("SNDNG_DTL_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlSndngDtl.setCurrent('" + dataItem.getValue("SNDNG_DTL_ID") + "');")
@ -378,7 +378,7 @@
let svbtcList = $P.ctrlSvbtc.dataset; let svbtcList = $P.ctrlSvbtc.dataset;
let empty = svbtcList.empty; let empty = svbtcList.empty;
let trs = empty ? [$P.find("notFoundSvbtc").innerHTML] : let trs = empty ? [$P.find("tmpltNotFoundSvbtc").innerHTML] :
svbtcList.inStrings($P.find("tmpltSvbtcRows").innerHTML svbtcList.inStrings($P.find("tmpltSvbtcRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlSvbtc.setCurrent('" + dataItem.getValue("SNDNG_DTL_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlSvbtc.setCurrent('" + dataItem.getValue("SNDNG_DTL_ID") + "');")

@ -3,9 +3,7 @@
<!-- Page Body --> <!-- Page Body -->
<div class="content-pop" data-doctx="${pageName}"> <div class="content-pop" data-doctx="${pageName}">
<!-- 화면 분할 -->
<div class="d-flex flex-row justify-content-evenly"> <div class="d-flex flex-row justify-content-evenly">
<!-- 감경 정보 --> <!-- 감경 정보 -->
<div class="col-xl-6 mx-1"> <div class="col-xl-6 mx-1">
<div class="card"> <div class="card">
@ -178,7 +176,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFoundCrdnSttsHstry"> <template name="tmpltNotFoundCrdnSttsHstry">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="6" class="dataTables_empty text-center">처리상태 이력 정보를 찾지 못했습니다.</td> <td valign="top" colspan="6" class="dataTables_empty text-center">처리상태 이력 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -225,7 +223,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFoundPayerHstry"> <template name="tmpltNotFoundPayerHstry">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="5" class="dataTables_empty text-center">주소변동 이력 정보를 찾지 못했습니다.</td> <td valign="top" colspan="5" class="dataTables_empty text-center">주소변동 이력 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -504,7 +502,7 @@
let crdnSttsHstryList = $P.ctrlCrdnSttsHstry.dataset; let crdnSttsHstryList = $P.ctrlCrdnSttsHstry.dataset;
let empty = crdnSttsHstryList.empty; let empty = crdnSttsHstryList.empty;
let trs = empty ? [$P.find("notFoundCrdnSttsHstry").innerHTML] : let trs = empty ? [$P.find("tmpltNotFoundCrdnSttsHstry").innerHTML] :
crdnSttsHstryList.inStrings($P.find("tmpltCrdnSttsHstryRows").innerHTML crdnSttsHstryList.inStrings($P.find("tmpltCrdnSttsHstryRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlCrdnSttsHstry.setCurrent('" + dataItem.getValue("STTS_HSTRY_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlCrdnSttsHstry.setCurrent('" + dataItem.getValue("STTS_HSTRY_ID") + "');")
@ -518,7 +516,7 @@
let payerHstryList = $P.ctrlPayerHstry.dataset; let payerHstryList = $P.ctrlPayerHstry.dataset;
let empty = payerHstryList.empty; let empty = payerHstryList.empty;
let trs = empty ? [$P.find("notFoundPayerHstry").innerHTML] : let trs = empty ? [$P.find("tmpltNotFoundPayerHstry").innerHTML] :
payerHstryList.inStrings($P.find("tmpltPayerHstryRows").innerHTML payerHstryList.inStrings($P.find("tmpltPayerHstryRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlPayerHstry.setCurrent('" + dataItem.getValue("STTS_HSTRY_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlPayerHstry.setCurrent('" + dataItem.getValue("STTS_HSTRY_ID") + "');")

@ -94,7 +94,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFoundRcvmt"> <template name="tmpltNotFoundRcvmt">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="27" class="dataTables_empty text-center">수납정보 이력 정보를 찾지 못했습니다.</td> <td valign="top" colspan="27" class="dataTables_empty text-center">수납정보 이력 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -369,7 +369,7 @@
let rcvmtList = $P.ctrlRcvmt.dataset; let rcvmtList = $P.ctrlRcvmt.dataset;
let empty = rcvmtList.empty; let empty = rcvmtList.empty;
let trs = empty ? [$P.find("notFoundRcvmt").innerHTML] : let trs = empty ? [$P.find("tmpltNotFoundRcvmt").innerHTML] :
rcvmtList.inStrings($P.find("tmpltRcvmtRows").innerHTML rcvmtList.inStrings($P.find("tmpltRcvmtRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].ctrl.setCurrent('" + dataItem.getValue("RCVMT_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrl.setCurrent('" + dataItem.getValue("RCVMT_ID") + "');")

@ -4,7 +4,6 @@
<!-- Page Body --> <!-- Page Body -->
<div class="content-pop" data-doctx="${pageName}"> <div class="content-pop" data-doctx="${pageName}">
<div class="d-flex flex-row justify-content-evenly"> <div class="d-flex flex-row justify-content-evenly">
<!-- 민원 상담 정보 --> <!-- 민원 상담 정보 -->
<div class="col-xl-12 mx-1"> <div class="col-xl-12 mx-1">
<div class="card"> <div class="card">
@ -66,7 +65,7 @@
<td class="cmn dummy-td"></td> <td class="cmn dummy-td"></td>
</tr> </tr>
</template> </template>
<template name="notFoundCvlcptDscsn"> <template name="tmpltNotFoundCvlcptDscsn">
<tr class="odd"> <tr class="odd">
<td valign="top" colspan="10" class="dataTables_empty text-center">민원 상담 정보를 찾지 못했습니다.</td> <td valign="top" colspan="10" class="dataTables_empty text-center">민원 상담 정보를 찾지 못했습니다.</td>
</tr> </tr>
@ -203,7 +202,7 @@
let cvlcptDscsnList = $P.ctrlCvlcptDscsn.dataset; let cvlcptDscsnList = $P.ctrlCvlcptDscsn.dataset;
let empty = cvlcptDscsnList.empty; let empty = cvlcptDscsnList.empty;
let trs = empty ? [$P.find("notFoundCvlcptDscsn").innerHTML] : let trs = empty ? [$P.find("tmpltNotFoundCvlcptDscsn").innerHTML] :
cvlcptDscsnList.inStrings($P.find("tmpltCvlcptDscsnRows").innerHTML cvlcptDscsnList.inStrings($P.find("tmpltCvlcptDscsnRows").innerHTML
, (str, dataItem) => str , (str, dataItem) => str
.replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlCvlcptDscsn.setCurrent('" + dataItem.getValue("CVLCPT_DSCSN_ID") + "');") .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrlCvlcptDscsn.setCurrent('" + dataItem.getValue("CVLCPT_DSCSN_ID") + "');")

Loading…
Cancel
Save