parent
4e96b0dbc6
commit
5abdc3ad31
@ -0,0 +1,532 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" session="false"%>
|
||||
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
|
||||
|
||||
<!-- inner page html -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content -->
|
||||
<div class="container-xxl flex-grow-1 px-0">
|
||||
<c:set var="prefixName" scope="request">부과 관리</c:set>
|
||||
|
||||
<!-- Page Body -->
|
||||
<div class="card">
|
||||
<div class="wrapper-list">
|
||||
<div>
|
||||
<!-- 상단 버튼 -->
|
||||
<div class="container-page-btn">
|
||||
<button type="button" class="btn btn-outline-dark w-px-120" id="btnReset--${pageName}" title="초기화" onclick="fnReset${pageName}();">
|
||||
초기화
|
||||
</button>
|
||||
<span class="container-window-btn-right">
|
||||
<button type="button" class="btn btn-search w-px-120" id="btnSearch--${pageName}" title="검색" onclick="fnSearchList${pageName}();">
|
||||
검색
|
||||
</button>
|
||||
<button type="button" class="btn btn-excel w-px-120" id="btnExcel--${pageName}" title="엑셀" onclick="fnExcel${pageName}();">
|
||||
엑셀
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<!-- / 상단 버튼 -->
|
||||
|
||||
<!-- 검색 조건 영역 -->
|
||||
<form id="frmSearch--${pageName}" name="frmSearch">
|
||||
<!-- hidden -->
|
||||
<input type="hidden" id="sggCd--${pageName}" name="sggCd" data-map="SGG_CD" />
|
||||
|
||||
<!-- 메인 조건 -->
|
||||
<div class="container-search">
|
||||
<div class="row g-1">
|
||||
<!-- 업무구분 -->
|
||||
<div class="col-12">
|
||||
<label class="form-label fw-bold form-search-title text-end">업무구분</label>
|
||||
<span class="form-search-linebox">
|
||||
<c:forEach items="${FIM054List}" var="item">
|
||||
<label>
|
||||
<input type="radio" class="form-check-input" name="taskSeCd" alt="업무구분"
|
||||
value="${item.code}" onchange="fnResetAndChangeBiz${pageName}(this.value);">
|
||||
${item.value}
|
||||
</label>
|
||||
</c:forEach>
|
||||
</span>
|
||||
</div>
|
||||
<!-- 회계연도 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">회계연도</label>
|
||||
<input type="text" class="form-control w-px-60" id="schFyr--${pageName}" name="schFyr" maxlength="4" autocomplete="off" />
|
||||
</div>
|
||||
<!-- 부과 번호 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">부과번호</label>
|
||||
<input type="text" class="form-control w-px-80" id="schLevyNoFrom--${pageName}" name="schLevyNoFrom" maxlength="6" autocomplete="off" />
|
||||
~
|
||||
<input type="text" class="form-control w-px-80" id="schLevyNoTo--${pageName}" name="schLevyNoTo" maxlength="6" autocomplete="off" />
|
||||
</div>
|
||||
<!-- 부과 일자 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">부과일자</label>
|
||||
<span class="form-search-linebox">
|
||||
<input type="text" class="form-control form-date" id="schLevyYmdFrom--${pageName}" name="schLevyYmdFrom"
|
||||
data-fmt-type="day" title="시작 날짜 선택" />
|
||||
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
|
||||
~
|
||||
<input type="text" class="form-control form-date" id="schLevyYmdTo--${pageName}" name="schLevyYmdTo"
|
||||
data-fmt-type="day" title="종료 날짜 선택" />
|
||||
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
|
||||
</span>
|
||||
</div>
|
||||
<!-- 단속 일자 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">단속일자</label>
|
||||
<span class="form-search-linebox">
|
||||
<input type="text" class="form-control form-date" id="schCrdnYmdFrom--${pageName}" name="schCrdnYmdFrom"
|
||||
data-fmt-type="day" title="시작 날짜 선택" />
|
||||
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
|
||||
~
|
||||
<input type="text" class="form-control form-date" id="schCrdnYmdTo--${pageName}" name="schCrdnYmdTo"
|
||||
data-fmt-type="day" title="종료 날짜 선택" />
|
||||
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
|
||||
</span>
|
||||
</div>
|
||||
<!-- 차량번호 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">차량번호</label>
|
||||
<input type="text" class="form-control w-px-160" id="schVhrno--${pageName}" name="schVhrno" autocomplete="off" />
|
||||
</div>
|
||||
<!-- 동적검색 -->
|
||||
<div class="col-6">
|
||||
<input type="hidden" id="by--${pageName}" name="by" />
|
||||
<input type="text" class="form-control" id="byOutput--${pageName}" value="동적 검색" readonly />
|
||||
<input type="hidden" id="mainOption--${pageName}" name="mainOption" />
|
||||
<input type="hidden" id="subOption--${pageName}" name="subOption" />
|
||||
<input type="text" class="form-control w-px-300" id="term--${pageName}" name="term" autocomplete="off" />
|
||||
<!-- 상세 검색조건 버튼 -->
|
||||
<span class="flr">
|
||||
<button type="button" class="btn btn-open-detail" data-bs-toggle="collapse" data-bs-target="#searchDetail--${pageName}">
|
||||
<i class="bx bx-chevron-down"></i>
|
||||
상세검색
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- / 메인 조건 -->
|
||||
|
||||
<!-- 상세 조건 -->
|
||||
<div id="searchDetail--${pageName}" class="container-search container-search-detail collapse">
|
||||
<div class="row g-1">
|
||||
<!-- 진술자명 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">진술자명</label>
|
||||
<input type="text" class="form-control w-px-150" id="schSttrNm--${pageName}" name="schSttrNm" />
|
||||
</div>
|
||||
<!-- 납부자명 -->
|
||||
<div class="col-6">
|
||||
<label class="form-label fw-bold form-search-title text-end">납부자명</label>
|
||||
<input type="text" class="form-control w-px-150" id="schRtpyrNm--${pageName}" name="schRtpyrNm" />
|
||||
</div>
|
||||
<!-- 등록일자, 수정일자 -->
|
||||
<div class="col-6">
|
||||
<select class="form-select text-center" id="schDetailRegDtOpt--${pageName}" name="schDetailRegDtOpt">
|
||||
<option value="regDt">등록일자</option>
|
||||
<option value="mdfcnDt">수정일자</option>
|
||||
</select>
|
||||
<span class="form-search-linebox">
|
||||
<input type="text" class="form-control form-date" id="schDetailRegDtFrom--${pageName}" name="schDetailRegDtFrom"
|
||||
data-fmt-type="day" title="시작 날짜 선택" />
|
||||
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
|
||||
~
|
||||
<input type="text" class="form-control form-date" id="schDetailRegDtTo--${pageName}" name="schDetailRegDtTo"
|
||||
data-fmt-type="day" title="종료 날짜 선택">
|
||||
<button type="button" class="bx bx-sm bx-calendar bg-white"></button>
|
||||
</span>
|
||||
</div>
|
||||
<!-- 등록자명, 수정자명 -->
|
||||
<div class="col-6">
|
||||
<select class="form-select text-center" id="schDetailRgtrOpt--${pageName}" name="schDetailRgtrOpt">
|
||||
<option value="rgtr">등록자</option>
|
||||
<option value="mdfr">수정자</option>
|
||||
</select>
|
||||
<input type="text" class="form-control" id="schDetailRgtrNm--${pageName}" name="schDetailRgtrNm" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- / 상세 조건 -->
|
||||
</form>
|
||||
<!-- / 검색 조건 영역 -->
|
||||
|
||||
<!-- 업무 버튼 및 건수 표시 -->
|
||||
<div>
|
||||
<span class="container-page-btn">
|
||||
<!-- 건수, 페이지 표시 -->
|
||||
<div class="d-flex flex-row justify-content-between">
|
||||
<label class="dataTables_info" id="paging--${pageName}PagingInfo" role="status" aria-live="polite"></label>
|
||||
<ul class="pagination pagination-primary" id="paging--${pageName}">
|
||||
</ul>
|
||||
</div>
|
||||
<span class="container-window-btn-right">
|
||||
<!-- 업무 버튼 -->
|
||||
|
||||
</span>
|
||||
</span>
|
||||
</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" style="width: 72px;">NO.</th>
|
||||
<th class="cmn" style="width: 56px;">
|
||||
<input type="checkbox" class="form-check-input" onchange="${pageName}Control.select(this.checked);">
|
||||
</th>
|
||||
<th class="cmn" style="width: 160px;">업무구분</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('RCPT_YMD', this.innerText, 'ymd', '');">접수일자</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('RCPT_NO', this.innerText, 'match', 'part');">접수번호</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('RCPT_SE_CD', this.innerText, 'codeValue', 'FIM029');">접수구분</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('NTFCTN_SE_CD', this.innerText, 'codeValue', 'FIM030');">통보구분</th>
|
||||
<th class="cmn" style="width: 160px;" onclick="searchFromGridTitle('STTR_NM', this.innerText, 'match', 'part');">진술자명</th>
|
||||
<th class="cmn" style="width: 140px;" onclick="searchFromGridTitle('OPNN_SBMSN_STTS_CD', this.innerText, 'codeValue', 'FIM031');">의견제출상태</th>
|
||||
<th class="cmn" style="width: 160px;" onclick="searchFromGridTitle('OPNN_SBMSN_SE_CD', this.innerText, 'codeValue', 'FIM033');">의견제출분류</th>
|
||||
<th class="cmn" style="width: 280px;" onclick="searchFromGridTitle('OPNN_SBMSN_GIST', this.innerText, 'match', 'part');">의견제출요지</th>
|
||||
<th class="cmn" style="width: 180px;" onclick="searchFromGridTitle('CRDN_YMD', this.innerText, 'ymd', '');">단속일시</th>
|
||||
<th class="cmn" style="width: 140px;" onclick="searchFromGridTitle('VHRNO', this.innerText, 'match', 'part');">차량번호</th>
|
||||
<th class="cmn" style="width: 280px;" onclick="searchFromGridTitle('CRDN_PLC', this.innerText, 'match', 'part');">단속장소</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('FFNLG_AMT', this.innerText, 'match', 'part');">과태료금액</th>
|
||||
<th class="cmn" style="width: 160px;" onclick="searchFromGridTitle('CRDN_STTS_CD', this.innerText, 'codeValue', 'FIM010');">처리상태</th>
|
||||
<th class="cmn" style="width: 140px;" onclick="searchFromGridTitle('DOC_NO', this.innerText, 'ymd', '');">문서번호</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('ANS_YMD', this.innerText, 'ymd', '');">답변일자</th>
|
||||
<th class="cmn" style="width: 240px;" onclick="searchFromGridTitle('ANS_CN', this.innerText, 'match', 'part');">답변내용</th>
|
||||
<th class="cmn" style="width: 200px;" onclick="searchFromGridTitle('RTPYR_NM', this.innerText, 'match', 'part');">납부자명</th>
|
||||
<th class="cmn" style="width: 120px;" onclick="searchFromGridTitle('RTPYR_BRDT', this.innerText, 'match', 'part');">납부자생일</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="{LEVY_ID}">
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{ROW_NUM}</td>
|
||||
<td class="cmn text-center">
|
||||
<input type="checkbox" class="form-check-input" value="{LEVY_ID}" onchange="${pageName}Control.select('{LEVY_ID}', this.checked);">
|
||||
</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{TASK_SE_NM}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RCPT_YMD}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RCPT_NO}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RCPT_SE_NM}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{NTFCTN_SE_NM}</td>
|
||||
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{STTR_NM}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{OPNN_SBMSN_STTS_NM}</td>
|
||||
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{OPNN_SBMSN_SE_NM}</td>
|
||||
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{OPNN_SBMSN_GIST}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{CRDN_YMD_TM}</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-start" onclick="{onclick}" ondblclick="{ondblclick}">{CRDN_STTS_NM}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{DOC_NO}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{ANS_YMD}</td>
|
||||
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{ANS_CN}</td>
|
||||
<td class="cmn text-start" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_NM}</td>
|
||||
<td class="cmn text-center" onclick="{onclick}" ondblclick="{ondblclick}">{RTPYR_BRDT}</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="26" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
|
||||
</tr>
|
||||
</template>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- / DataTables(그리드) -->
|
||||
</div>
|
||||
</div> <!-- / Wrapper-list -->
|
||||
</div> <!-- / Card -->
|
||||
</div>
|
||||
<!-- / Content -->
|
||||
|
||||
<jsp:include page="/WEB-INF/jsp/include/bottom.jsp" />
|
||||
|
||||
<div class="content-backdrop fade"></div>
|
||||
</div>
|
||||
<!-- / inner page html <div class="content-wrapper"> -->
|
||||
|
||||
<script>
|
||||
/**************************************************************************
|
||||
* Global Variable
|
||||
**************************************************************************/
|
||||
// URL
|
||||
var ${pageName}PrefixUrl = "/levy/levy01";
|
||||
// FormFields
|
||||
var ${pageName}Fields = new FimsFormFields("#frmSearch--${pageName}");
|
||||
|
||||
/**************************************************************************
|
||||
* DatasetControl
|
||||
**************************************************************************/
|
||||
var ${pageName}Control = new DatasetControl({
|
||||
prefix : "levy"
|
||||
, prefixName : "부과"
|
||||
, infoSize : "xl"
|
||||
, keymapper : info => info ? info.LEVY_ID : ""
|
||||
, dataGetter : obj => obj.levyList
|
||||
, appendData : true
|
||||
, tableRenderComplete : false // dataTables 에 자료 추가 완료 여부
|
||||
, urls : {
|
||||
getInfo : wctx.url("/sprt/sprt02/010/main.do") // 개별총정보
|
||||
}
|
||||
, formats : {
|
||||
RCPT_YMD : dateFormat
|
||||
, ANS_YMD : dateFormat
|
||||
, ANS_YMD_TM : datetimeFormat
|
||||
, CRDN_YMD_TM : datetimeFormat
|
||||
, FFNLG_CRDN_AMT : numberFormat
|
||||
, FFNLG_AMT : numberFormat
|
||||
, REG_DT : datetimeFormat
|
||||
, MDFCN_DT : datetimeFormat
|
||||
}
|
||||
});
|
||||
|
||||
/**************************************************************************
|
||||
* DatasetControl 이벤트
|
||||
**************************************************************************/
|
||||
// Dataset 변경
|
||||
${pageName}Control.onDatasetChange = obj => {
|
||||
renderList${pageName}();
|
||||
|
||||
$("#paging--${pageName}").setPagingInfo({
|
||||
list : ${pageName}Control.dataset
|
||||
, prefix : "paging--${pageName}"
|
||||
, start : obj.${infoPrefix}Start
|
||||
, totalSize : obj.${infoPrefix}Total
|
||||
, fetchSize : obj.${infoPrefix}Fetch
|
||||
, func : "${pageName}Control.load({index})"
|
||||
});
|
||||
|
||||
${pageName}Control.tableRenderComplete = true; // dataTables 에 자료 추가 완료
|
||||
};
|
||||
|
||||
// 현재 선택 자료 변경 이벤트
|
||||
${pageName}Control.onCurrentChange = item => {
|
||||
if (!item) return;
|
||||
|
||||
let key = item.data.LEVY_ID;
|
||||
|
||||
$("#tbody--${pageName}").setCurrentRow(key);
|
||||
};
|
||||
|
||||
// 선택(체크) 변경 이벤트
|
||||
${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() {
|
||||
let checkbox = $(this);
|
||||
|
||||
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"
|
||||
, 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("LEVY_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"));
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* 초기 셋팅
|
||||
**************************************************************************/
|
||||
// 초기화
|
||||
initForm${pageName} = () => {
|
||||
// 화면 초기화
|
||||
$("#frmSearch--${pageName}")[0].reset();
|
||||
|
||||
// dataset 초기화
|
||||
${pageName}Control.dataset.clear();
|
||||
}
|
||||
|
||||
// 이벤트
|
||||
setEvent${pageName} = () => {
|
||||
// form-date 항목에서 키보드로 입력시 날짜 포맷팅 적용
|
||||
$("#frmSearch--${pageName}").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);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
// DataTables width 변경 조정
|
||||
$("#DataTables_Table_0--${pageName}").find("th").resizable( {handles : "e"} );
|
||||
|
||||
// DataTables 스크롤 이벤트
|
||||
$("#table-responsive--${pageName}").scroll(function() {
|
||||
let el = $(this);
|
||||
|
||||
if (el.scrollTop() == 0) {
|
||||
return;
|
||||
}
|
||||
if (!${pageName}Control.tableRenderComplete) {
|
||||
return;
|
||||
}
|
||||
|
||||
let itemsCnt = ${pageName}Control.dataset._items.length;
|
||||
let totCnt = ${pageName}Control.dataset.getValue("TOT_CNT");
|
||||
|
||||
if (itemsCnt >= totCnt) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ((el[0].scrollHeight - el.scrollTop() + VERTICAL_SCROLL_HEIGHT) <= el.outerHeight()) {
|
||||
${pageName}Control.tableRenderComplete = false; // dataTables 에 자료 추가 완료
|
||||
|
||||
${pageName}Control.load(${pageName}Control.query.pageNum + 1);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// 화면 초기값 셋팅
|
||||
setForm${pageName} = (taskSeCd) => {
|
||||
// 업무 구분 코드
|
||||
$("#frmSearch--${pageName} input[name='taskSeCd'][value='" + taskSeCd + "']").prop("checked", true);
|
||||
|
||||
// 최고 관리자 경우 업무구분을 선택할 수 있도록 하자.
|
||||
$("#frmSearch--${pageName} input[name='taskSeCd']").each(function(i) {
|
||||
$(this).prop("disabled", "true");
|
||||
});
|
||||
|
||||
$("#schFyr--${pageName}").val(new Date().getFullYear());
|
||||
$("#schLevyNoFrom--${pageName}").val("000000");
|
||||
$("#schLevyNoTo--${pageName}").val("999999");
|
||||
|
||||
// 달력 초기화
|
||||
initDatepicker("frmSearch--${pageName}");
|
||||
// $("#schLevyYmdFrom--${pageName}").datepicker("setDate", DateUtil.getDateDay(-365).date);
|
||||
// $("#schLevyYmdTo--${pageName}").datepicker("setDate", new Date());
|
||||
}
|
||||
|
||||
// URL 설정
|
||||
setURL${pageName} = (taskSeCd) => {
|
||||
${pageName}Control.urls.load = wctx.url("/" + taskSeCd + ${pageName}PrefixUrl + "/030/list.do"); // 조회
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* 버튼 clickEvent
|
||||
**************************************************************************/
|
||||
// 업무 구분 변경
|
||||
fnResetAndChangeBiz${pageName} = (taskSeCd) => {
|
||||
// 초기화
|
||||
initForm${pageName}();
|
||||
|
||||
// 업무 구분 코드
|
||||
if (typeof taskSeCd == "undefined" || taskSeCd == null || taskSeCd == "") {
|
||||
taskSeCd = $("#layout-navbar input[name='taskSeCd']:checked").val();
|
||||
}
|
||||
|
||||
// 화면 초기값 설정
|
||||
setForm${pageName}(taskSeCd);
|
||||
|
||||
// URL 설정
|
||||
setURL${pageName}(taskSeCd);
|
||||
}
|
||||
|
||||
// 초기화 버튼 이벤트
|
||||
fnReset${pageName} = () => {
|
||||
fnResetAndChangeBiz${pageName}();
|
||||
}
|
||||
|
||||
// 검색 버튼 이벤트
|
||||
fnSearchList${pageName} = () => {
|
||||
// 검색조건
|
||||
${pageName}Control.query = ${pageName}Fields.get();
|
||||
|
||||
${pageName}Control.query.fetchSize = FETCH_XS; // 한번에 조회되는 자료 건수 FETCH_XS = 30
|
||||
${pageName}Control.query.delYn = "N"; // 삭제 여부
|
||||
|
||||
${pageName}Control.load();
|
||||
}
|
||||
|
||||
// 엑셀 버튼 이벤트
|
||||
fnExcel${pageName} = () => {
|
||||
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* script 진입
|
||||
**************************************************************************/
|
||||
$(document).ready(function() {
|
||||
// 기본 데이터 설정
|
||||
$("#sggCd--${pageName}").val("${sggCd}"); // 시군구 코드
|
||||
|
||||
// 이벤트 설정
|
||||
setEvent${pageName}();
|
||||
|
||||
// 보안모드
|
||||
fn_securityModeToggle($("#securityMode--top").is(":checked"));
|
||||
|
||||
// 업무 구분 설정
|
||||
let defaultBizValue = $("#layout-navbar input[name='taskSeCd']:checked").val();
|
||||
$("#frmSearch--${pageName} input[name='taskSeCd'][value='" + defaultBizValue + "']").prop("checked", true);
|
||||
|
||||
// 화면 초기 설정 및 업무 구분 변경
|
||||
fnResetAndChangeBiz${pageName}(defaultBizValue);
|
||||
});
|
||||
|
||||
</script>
|
Loading…
Reference in New Issue