|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" session="false"%>
|
|
|
|
|
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
|
|
|
|
|
|
|
|
|
|
<c:set var="prefixName" scope="request">임대계약서 관리</c:set>
|
|
|
|
|
<c:set var="prefixName" scope="request">임대차계약서 관리</c:set>
|
|
|
|
|
|
|
|
|
|
<!-- inner page html -->
|
|
|
|
|
<div class="content-wrapper" data-doctx="${pageName}">
|
|
|
|
@ -26,42 +26,60 @@
|
|
|
|
|
|
|
|
|
|
<!-- 검색 조건 영역 -->
|
|
|
|
|
<form name="frmSearch">
|
|
|
|
|
<!-- hidden -->
|
|
|
|
|
<input type="hidden" name="userId" />
|
|
|
|
|
|
|
|
|
|
<!-- 메인 조건 -->
|
|
|
|
|
<div class="container-search">
|
|
|
|
|
<div class="row g-1">
|
|
|
|
|
<!-- 단속 일자 -->
|
|
|
|
|
<div class="col-6">
|
|
|
|
|
<label class="form-label form-search-title w-px-120 text-end fw-bold">단속일자</label>
|
|
|
|
|
<label class="form-label form-search-title w-px-120 text-end fw-bold required">단속일자</label>
|
|
|
|
|
<span class="form-search-linebox">
|
|
|
|
|
<input type="text" class="form-control form-date" name="schCrdnYmdFrom"
|
|
|
|
|
data-fmt-type="day" autocomplete="off" title="시작 날짜 선택" />
|
|
|
|
|
data-fmt-type="day" autocomplete="off" title="시작 날짜 선택" required />
|
|
|
|
|
<button type="button" class="bx bx-lg bx-calendar bg-white"></button>
|
|
|
|
|
~
|
|
|
|
|
<input type="text" class="form-control form-date" name="schCrdnYmdTo"
|
|
|
|
|
data-fmt-type="day" autocomplete="off" title="종료 날짜 선택" />
|
|
|
|
|
data-fmt-type="day" autocomplete="off" title="종료 날짜 선택" required />
|
|
|
|
|
<button type="button" class="bx bx-lg bx-calendar bg-white"></button>
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
<!-- 기업 번호 -->
|
|
|
|
|
<div class="col-6">
|
|
|
|
|
<label is="name-label" class="form-label form-search-title w-px-120 text-end fw-bold" for="schEntNo">임대기업번호</label>
|
|
|
|
|
<select is="id-select" class="form-select w-px-160" name="schEntNo">
|
|
|
|
|
<label is="name-label" class="form-label form-search-title w-px-120 text-end fw-bold" for="entId">임대기업번호</label>
|
|
|
|
|
<select is="id-select" class="form-select w-px-160" name="entId">
|
|
|
|
|
<option value="">전체</option>
|
|
|
|
|
<c:forEach items="${entNoList}" var="item">
|
|
|
|
|
<option value="${item.ENT_NO}">${item.ENT_NO}</option>
|
|
|
|
|
<c:forEach items="${entRegNoList}" var="item">
|
|
|
|
|
<option value="${item.ENT_ID}">${item.ENT_REG_NO}</option>
|
|
|
|
|
</c:forEach>
|
|
|
|
|
</select>
|
|
|
|
|
</div>
|
|
|
|
|
<!-- 차량번호 -->
|
|
|
|
|
<!-- 자동차등록번호 -->
|
|
|
|
|
<div class="col-6">
|
|
|
|
|
<label is="name-label" class="form-label form-search-title w-px-120 text-end fw-bold" for="schVhrno">차량번호</label>
|
|
|
|
|
<label is="name-label" class="form-label form-search-title w-px-120 text-end fw-bold" for="schVhrno">자동차등록번호</label>
|
|
|
|
|
<input is="id-input" type="text" class="form-control w-px-160" name="schVhrno" autocomplete="off" />
|
|
|
|
|
</div>
|
|
|
|
|
<!-- 동적검색 -->
|
|
|
|
|
<div class="col-6">
|
|
|
|
|
<input type="hidden" name="by" />
|
|
|
|
|
<input type="text" class="form-control w-px-120 text-end fw-bold" name="byOutput" value="동적 검색" readonly />
|
|
|
|
|
<input type="hidden" name="mainOption" />
|
|
|
|
|
<input type="hidden" name="subOption" />
|
|
|
|
|
<input type="text" class="form-control w-px-400" name="term" autocomplete="off" />
|
|
|
|
|
<!-- 상세 검색조건 버튼 -->
|
|
|
|
|
<span class="flr">
|
|
|
|
|
<button type="button" class="btn btn-open-detail" data-bs-toggle="collapse" data-bs-target="[data-doctx='${pageName}'] [name='searchDetail']">
|
|
|
|
|
<i class="bx bx-chevron-down"></i>
|
|
|
|
|
상세검색
|
|
|
|
|
</button>
|
|
|
|
|
</span>
|
|
|
|
|
</div> <!-- 동적검색 -->
|
|
|
|
|
</div>
|
|
|
|
|
</div> <!-- 메인 조건 -->
|
|
|
|
|
|
|
|
|
|
<!-- 상세 조건 -->
|
|
|
|
|
<div name="searchDetail" class="container-search container-search-detail collapse">
|
|
|
|
|
<div class="row g-1">
|
|
|
|
|
</div>
|
|
|
|
|
</div> <!-- 상세 조건 -->
|
|
|
|
|
</form>
|
|
|
|
|
<!-- 검색 조건 영역 -->
|
|
|
|
|
|
|
|
|
@ -76,11 +94,11 @@
|
|
|
|
|
</div>
|
|
|
|
|
<!-- 업무 버튼 -->
|
|
|
|
|
<span class="container-window-btn-right">
|
|
|
|
|
<button type="button" class="btn btn-primary w-px-120" name="btnCreate" title="임대계약서 등록">
|
|
|
|
|
임대계약서 등록
|
|
|
|
|
<button type="button" class="btn btn-primary w-px-120" name="btnCreate" title="임대차계약서 승인 요청">
|
|
|
|
|
승인 요청
|
|
|
|
|
</button>
|
|
|
|
|
<button type="button" class="btn btn-primary w-px-120" name="btnRemove" title="임대계약서 삭제">
|
|
|
|
|
임대계약서 삭제
|
|
|
|
|
<button type="button" class="btn btn-primary w-px-120" name="btnRemove" title="임대차계약서 승인 요청 취소">
|
|
|
|
|
승인 요청 취소
|
|
|
|
|
</button>
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
@ -88,24 +106,36 @@
|
|
|
|
|
<!-- 업무 버튼 및 건수 표시 -->
|
|
|
|
|
|
|
|
|
|
<!-- tab -->
|
|
|
|
|
<div class="nav-align-top" name="tabMain" >
|
|
|
|
|
<div class="nav-align-top" name="tabMain">
|
|
|
|
|
<ul class="nav nav-tabs" role="tablist">
|
|
|
|
|
<li class="nav-item">
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100 active" role="tab" data-bs-toggle="tab"
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100 active" role="tab" data-bs-toggle="tab" name="tabItem0"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('전체');">
|
|
|
|
|
전체
|
|
|
|
|
</button>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="nav-item">
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100" role="tab" data-bs-toggle="tab"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('단속');">
|
|
|
|
|
단속
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100" role="tab" data-bs-toggle="tab" name="tabItem1"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('대상');">
|
|
|
|
|
대상
|
|
|
|
|
</button>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="nav-item">
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100" role="tab" data-bs-toggle="tab" name="tabItem2"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('미대상');">
|
|
|
|
|
미대상
|
|
|
|
|
</button>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="nav-item">
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100" role="tab" data-bs-toggle="tab"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('세외수입');">
|
|
|
|
|
세외수입
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100" role="tab" data-bs-toggle="tab" name="tabItem3"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('승인요청');">
|
|
|
|
|
승인요청
|
|
|
|
|
</button>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="nav-item">
|
|
|
|
|
<button type="button" class="nav-link w-px-160 h-100" role="tab" data-bs-toggle="tab" name="tabItem4"
|
|
|
|
|
onClick="pageObject['${pageName}'].fnSearchList('승인완료');">
|
|
|
|
|
승인완료
|
|
|
|
|
</button>
|
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
|
|
|
@ -123,15 +153,25 @@
|
|
|
|
|
</thead>
|
|
|
|
|
<template name="tmpltCols">
|
|
|
|
|
<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: 160px;">업무구분</th>
|
|
|
|
|
<th class="cmn" style="width: 120px;">대상여부</th>
|
|
|
|
|
<th class="cmn" style="width: 180px;" onclick="FimsSupport.searchFromGridTitle('CHG_DMND_DT', this.innerText, 'ymd', '');">요청일시</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('CHG_APRV_YN', this.innerText, 'codeValue', 'CMN006');">승인여부</th>
|
|
|
|
|
<th class="cmn" style="width: 180px;" onclick="FimsSupport.searchFromGridTitle('CHG_APRV_DT', this.innerText, 'ymd', '');">승인일시</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('CHG_AUTZR', this.innerText, 'match', 'part');">승인자</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('CHG_APRV_RSN', this.innerText, 'match', 'part');">승인사유</th>
|
|
|
|
|
<th class="cmn" style="width: 200px;" onclick="FimsSupport.searchFromGridTitle('ENT_NM', this.innerText, 'match', 'part');">기업명</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('ENT_REG_NO', this.innerText, 'match', 'part');">법인(사업자)번호</th>
|
|
|
|
|
<th class="cmn" style="width: 180px;" onclick="FimsSupport.searchFromGridTitle('CRDN_YMD', this.innerText, 'ymd', '');">단속일시</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('VHRNO', this.innerText, 'match', 'part');">차량번호</th>
|
|
|
|
|
<th class="cmn" style="width: 120px;" onclick="FimsSupport.searchFromGridTitle('RTPYR_SE_CD', this.innerText, 'codeValue', 'FIM011');">납부자구분</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('RTPYR_NO', this.innerText, 'ymd', '');">납부자번호</th>
|
|
|
|
|
<th class="cmn" style="width: 200px;" onclick="FimsSupport.searchFromGridTitle('RTPYR_NM', this.innerText, 'match', 'part');">납부자명</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('VLTN_ARTCL', this.innerText, 'match', 'part');">위반항목</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('VHRNO', this.innerText, 'match', 'part');">자동차등록번호</th>
|
|
|
|
|
<th class="cmn" style="width: 180px;" onclick="FimsSupport.searchFromGridTitle('CTRT_BGNG_DT', this.innerText, 'ymd', '');">계약시작일시</th>
|
|
|
|
|
<th class="cmn" style="width: 180px;" onclick="FimsSupport.searchFromGridTitle('CTRT_END_DT', this.innerText, 'ymd', '');">계약종료일시</th>
|
|
|
|
|
<th class="cmn" style="width: 100px;" onclick="FimsSupport.searchFromGridTitle('HIRER_SE_CD', this.innerText, 'codeValue', 'FIM089');">임차인구분</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('HIRER_REG_NO', this.innerText, 'match', 'part');">임차인번호</th>
|
|
|
|
|
<th class="cmn" style="width: 200px;" onclick="FimsSupport.searchFromGridTitle('HIRER_NM', this.innerText, 'match', 'part');">임차인명</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('HIRER_TELNO', this.innerText, 'match', 'part');">전화번호</th>
|
|
|
|
|
<th class="cmn" style="width: 160px;" onclick="FimsSupport.searchFromGridTitle('HIRER_MBL_TELNO', this.innerText, 'match', 'part');">휴대전화번호</th>
|
|
|
|
|
<th class="cmn" style="width: 120px;" onclick="FimsSupport.searchFromGridTitle('CRDN_STDG_NM', this.innerText, 'match', 'part');">단속법정동</th>
|
|
|
|
|
<th class="cmn" style="width: 280px;" onclick="FimsSupport.searchFromGridTitle('CRDN_PLC', this.innerText, 'match', 'part');">단속장소</th>
|
|
|
|
|
<th class="cmn" style="width: 120px;" onclick="FimsSupport.searchFromGridTitle('FFNLG_CRDN_AMT', this.innerText, 'match', 'part');">단속원금</th>
|
|
|
|
@ -146,19 +186,27 @@
|
|
|
|
|
<tbody name="tbodyList">
|
|
|
|
|
</tbody>
|
|
|
|
|
<template is="curly-brackets" name="tmpltRows">
|
|
|
|
|
<tr data-index="DATA-INDEX">
|
|
|
|
|
<tr data-index="{data-index}">
|
|
|
|
|
<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="DATA-INDEX" onchange="pageObject['${pageName}'].dataTableCheckbox(this, this.checked);" /></td>
|
|
|
|
|
<td class="cmn text-center"><input type="checkbox" class="form-check-input" name="gridCheckbox" value="{data-index}" 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>{CRDN_YMD_TM}</td>
|
|
|
|
|
<td class="cmn text-center fw-bold text-blue" onclick ondblclick>{TRGT_STTS_NM}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CHG_DMND_DT}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CHG_APRV_NM}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CHG_APRV_DT}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CHG_AUTZR}</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{CHG_APRV_RSN}</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{ENT_NM}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{ENT_REG_NO}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CRDN_DT}</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{VHRNO}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{RTPYR_SE_NM}</td>
|
|
|
|
|
<td class="cmn text-center privacy-cell" onclick ondblclick>
|
|
|
|
|
<span>{RTPYR_NO}</span>
|
|
|
|
|
<span>*************</span>
|
|
|
|
|
</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{RTPYR_NM}</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{VLTN_ARTCL}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CTRT_BGNG_DT}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CTRT_END_DT}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{HIRER_SE_NM}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{HIRER_REG_NO}</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{HIRER_NM}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{HIRER_TELNO}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{HIRER_MBL_TELNO}</td>
|
|
|
|
|
<td class="cmn text-center" onclick ondblclick>{CRDN_STDG_NM}</td>
|
|
|
|
|
<td class="cmn text-start" onclick ondblclick>{CRDN_PLC}</td>
|
|
|
|
|
<td class="cmn text-end" onclick ondblclick>{FFNLG_CRDN_AMT}</td>
|
|
|
|
@ -172,7 +220,7 @@
|
|
|
|
|
</template>
|
|
|
|
|
<template name="tmpltNotFound">
|
|
|
|
|
<tr class="cmn">
|
|
|
|
|
<td valign="top" colspan="17" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
|
|
|
|
|
<td valign="top" colspan="29" class="dataTables_empty text-center">${prefixName} 정보를 찾지 못했습니다.</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</template>
|
|
|
|
|
</table>
|
|
|
|
@ -189,7 +237,7 @@
|
|
|
|
|
<!-- / inner page html <div class="content-wrapper"> -->
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
LoadScript("rent02010Script",wctx.url("/webjars/js/fims/rent/rent02010.js?ver=${ver}"));
|
|
|
|
|
LoadScript("rent02050Script", wctx.url("/webjars/js/fims/rent/rent02050.js?ver=${ver}"));
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
|
* Global Variable
|
|
|
|
@ -200,70 +248,33 @@
|
|
|
|
|
* script 진입
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
$(document).ready(function() {
|
|
|
|
|
/**************************************************************************
|
|
|
|
|
* pageObject
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
// pageObject
|
|
|
|
|
let $P = pageObject["${pageName}"];
|
|
|
|
|
|
|
|
|
|
// formFields
|
|
|
|
|
$P.formFields = new FimsFormFields($P.selectorn("frmSearch"));
|
|
|
|
|
|
|
|
|
|
// datasetControl
|
|
|
|
|
$P.ctrl = newRent02010Control("${pageName}", "[data-doctx=${pageName}]");
|
|
|
|
|
$P.ctrl = newRent02050Control("${pageName}", "[data-doctx=${pageName}]");
|
|
|
|
|
// paging
|
|
|
|
|
$P.pagingSupport = new FimsPagingSupport({
|
|
|
|
|
ctrl: $P.ctrl // DatasetControl
|
|
|
|
|
, ignoreCtrlPrefix: true // ctrl.prefix 가 있더라도 무시
|
|
|
|
|
, linkContainer: "[name='dataPaging']" // <ul class="pagination pagination-primary" name="dataPaging">
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
|
* DataTable 이벤트
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
// DataTable에 click, dbclick 이벤트
|
|
|
|
|
$P.renderList = (obj, option) => {
|
|
|
|
|
// 데이터 셋
|
|
|
|
|
let dataList = $P.ctrl.dataset;
|
|
|
|
|
let empty = dataList.empty;
|
|
|
|
|
|
|
|
|
|
// 업무별 DataTables(그리드) tr, td
|
|
|
|
|
let foundContent = $P.findn("tmpltRows").content;
|
|
|
|
|
let foundTr = $(foundContent).find("tr")[0].cloneNode(false);
|
|
|
|
|
let foundTds = $(foundContent).find(".cmn");
|
|
|
|
|
|
|
|
|
|
foundTds.each(function() {
|
|
|
|
|
foundTr.appendChild(this.cloneNode(true));
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
let replacer = (str, dataItem) => str
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].dataTableClick('{DATA-INDEX}');")
|
|
|
|
|
.replace(/{ondblclick}/gi, "pageObject['${pageName}'].dataTableDblClick('{CRDN_ID}');");
|
|
|
|
|
|
|
|
|
|
let trs = empty ?
|
|
|
|
|
[$P.findn("tmpltNotFound").content.querySelector(".cmn").outerHTML]
|
|
|
|
|
: dataList.inStrings(foundTr.outerHTML, replacer);
|
|
|
|
|
|
|
|
|
|
let noMore = (dataList.length >= obj["Total"]);
|
|
|
|
|
let initScroll = ($P.ctrl.query.pageNum < 2);
|
|
|
|
|
|
|
|
|
|
if (option != null && option.reloaded) {
|
|
|
|
|
initScroll = false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// pagingInfo
|
|
|
|
|
$P.pagingSupport.setPagingInfo(obj);
|
|
|
|
|
|
|
|
|
|
$P.findn("tableRspns").changeContent(trs.join(), initScroll, noMore);
|
|
|
|
|
|
|
|
|
|
// checkbox 체크 해제
|
|
|
|
|
$P.$findn("gridAllCheckbox").prop("checked", false);
|
|
|
|
|
|
|
|
|
|
// 보안모드
|
|
|
|
|
fn_securityModeToggle($("#securityMode--top").is(":checked"));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// dataTable 체크박스 클릭 이벤트
|
|
|
|
|
$P.dataTableCheckbox = (element, bool) => {
|
|
|
|
|
GRID.checkbox.sync(element, bool);
|
|
|
|
|
|
|
|
|
|
let atLeastOne = GRID.checkbox.countChecked(element) > 0;
|
|
|
|
|
let tabName = $P.$findn("tabMain").find("button.active").text().trim();
|
|
|
|
|
|
|
|
|
|
// 버튼
|
|
|
|
|
if (tabName == "대상") {
|
|
|
|
|
$P.$findn("btnCreate").prop("disabled", !atLeastOne);
|
|
|
|
|
} else if (tabName == "승인요청") {
|
|
|
|
|
$P.$findn("btnRemove").prop("disabled", !atLeastOne);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Apply.toDataset.selection($P.ctrl.dataset, element, bool);
|
|
|
|
|
}
|
|
|
|
@ -278,10 +289,9 @@
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// dataTable 더블 클릭 이벤트
|
|
|
|
|
$P.dataTableDblClick = (dataKey) => {
|
|
|
|
|
$P.dataTableDblClick = (dataIndex) => {
|
|
|
|
|
let params = {
|
|
|
|
|
callPurpose: "update"
|
|
|
|
|
, crdnId: dataKey
|
|
|
|
|
callPurpose: "view"
|
|
|
|
|
, lsctId: $P.ctrl.getValue("LSCT_ID")
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
@ -298,21 +308,42 @@
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
// URL 설정
|
|
|
|
|
$P.setUrl = (prefixUrl) => {
|
|
|
|
|
$P.ctrl.urls.load = wctx.url(prefixUrl + "/010/list.do"); // 검색 url
|
|
|
|
|
$P.ctrl.urls.getInfo = wctx.url(prefixUrl + "/020/info.do"); // 상세 정보 url
|
|
|
|
|
$P.ctrl.urls.load = wctx.url(prefixUrl + "/050/list.do"); // 검색
|
|
|
|
|
$P.ctrl.urls.getInfo = wctx.url(prefixUrl + "/020/info.do"); // 상세 정보
|
|
|
|
|
$P.ctrl.urls.create = wctx.url(prefixUrl + "/050/createAprv.do") // 승인 요청
|
|
|
|
|
$P.ctrl.urls.remove = wctx.url(prefixUrl + "/050/removeAprv.do") // 승인 요청 취소
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 버튼 설정
|
|
|
|
|
$P.setButton = (tabName) => {
|
|
|
|
|
// tab
|
|
|
|
|
if (tabName == "대상") {
|
|
|
|
|
$P.$findn("btnCreate").prop("disabled", false);
|
|
|
|
|
$P.$findn("btnRemove").prop("disabled", true);
|
|
|
|
|
} else if (tabName == "승인요청") {
|
|
|
|
|
$P.$findn("btnCreate").prop("disabled", true);
|
|
|
|
|
$P.$findn("btnRemove").prop("disabled", false);
|
|
|
|
|
} else {
|
|
|
|
|
$P.$findn("btnCreate").prop("disabled", true);
|
|
|
|
|
$P.$findn("btnRemove").prop("disabled", true);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
|
* 버튼 clickEvent
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
// 초기화 버튼 이벤트
|
|
|
|
|
// 초기화
|
|
|
|
|
$P.fnReset = () => {
|
|
|
|
|
// 화면 초기화
|
|
|
|
|
$P.findn("frmSearch").reset();
|
|
|
|
|
// dataset 초기화
|
|
|
|
|
$P.ctrl.dataset.clear();
|
|
|
|
|
|
|
|
|
|
// URL 설정
|
|
|
|
|
$P.setUrl("${prefixUrl}");
|
|
|
|
|
|
|
|
|
|
// input, select 초기화
|
|
|
|
|
let searchForm = $P.$findn("frmSearch");
|
|
|
|
|
searchForm.find("input[type='radio']").not("[name='taskSeCd']").prop("checked", false);
|
|
|
|
|
searchForm.find("input[type='checkbox']").prop("checked", false);
|
|
|
|
|
searchForm.find("input[type='text']").val("");
|
|
|
|
|
searchForm.find("input[type='hidden']").val("");
|
|
|
|
@ -322,16 +353,10 @@
|
|
|
|
|
AppSupport.initDetailSearchButton($P.findn("frmSearch")); // 상세검색 버튼 화살표
|
|
|
|
|
|
|
|
|
|
// 기본 데이터 설정
|
|
|
|
|
$P.$findn("userId").val("${userId}"); // 사용자 ID
|
|
|
|
|
$P.$findn("schCrdnYmdFrom").datepicker("setDate", DateSupport.getAddDay(-365)); // 단속 일자 시작
|
|
|
|
|
$P.$findn("schCrdnYmdTo").datepicker("setDate", TODAY()); // 단속 일자 종료
|
|
|
|
|
$P.$findn("schVhrno").val("167하9750"); // 차량번호
|
|
|
|
|
|
|
|
|
|
// URL 설정
|
|
|
|
|
$P.setUrl("${prefixUrl}");
|
|
|
|
|
|
|
|
|
|
// dataset 초기화
|
|
|
|
|
$P.ctrl.dataset.clear();
|
|
|
|
|
$P.$findn("schVhrno").val("167하9750"); // 자동차등록번호
|
|
|
|
|
$P.$findn("byOutput").val("동적 검색"); // 동적 검색
|
|
|
|
|
|
|
|
|
|
// 그리드 th
|
|
|
|
|
let colContent = $P.findn("tmpltCols").content;
|
|
|
|
@ -342,30 +367,47 @@
|
|
|
|
|
colsOuterHTML += this.outerHTML;
|
|
|
|
|
});
|
|
|
|
|
$P.findn("tableRspns").changeColumn(colsOuterHTML);
|
|
|
|
|
|
|
|
|
|
// 버튼 설정
|
|
|
|
|
$(".nav-link.active").removeClass("active"); // 기존의 활성화된 탭에서 active 클래스 제거
|
|
|
|
|
$P.$findn("tabItem0").addClass("active"); // 새로운 탭에 active 클래스 추가
|
|
|
|
|
|
|
|
|
|
let tabName = $P.$findn("tabMain").find("button.active").text().trim();
|
|
|
|
|
$P.setButton(tabName);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 검색 버튼 이벤트
|
|
|
|
|
// 검색
|
|
|
|
|
$P.fnSearchList = (tabName) => {
|
|
|
|
|
// validate 확인
|
|
|
|
|
if (!AppSupport.customValidate($P.$findn("frmSearch").find("input,select,textarea"))) return;
|
|
|
|
|
|
|
|
|
|
// 버튼 설정
|
|
|
|
|
if (!tabName) {
|
|
|
|
|
tabName = $P.$findn("tabMain").find("button.active").text().trim();
|
|
|
|
|
}
|
|
|
|
|
$P.setButton(tabName);
|
|
|
|
|
|
|
|
|
|
// 검색 조건
|
|
|
|
|
$P.ctrl.query = $P.formFields.get(); // 검색 조건
|
|
|
|
|
$P.ctrl.query = new FimsFormFields($P.selectorn("frmSearch")).get(); // 검색 조건
|
|
|
|
|
$P.ctrl.query.fetchSize = DEFAULT_FETCH_SIZE; // 한번에 조회되는 자료 건수
|
|
|
|
|
$P.ctrl.query.delYn = "N"; // 삭제 여부
|
|
|
|
|
|
|
|
|
|
// tab
|
|
|
|
|
if (tabName == "단속") {
|
|
|
|
|
$P.ctrl.query.nxrpCrdnLinkYn = "N";
|
|
|
|
|
} else if (tabName == "세외수입") {
|
|
|
|
|
$P.ctrl.query.nxrpCrdnLinkYn = "Y";
|
|
|
|
|
} else {
|
|
|
|
|
$P.ctrl.query.nxrpCrdnLinkYn = "N";
|
|
|
|
|
if (tabName == "승인요청") {
|
|
|
|
|
$P.ctrl.query.chgDmndYn = "Y"; // 변경 요청 여부 Y
|
|
|
|
|
$P.ctrl.query.chgAprvYn = "N"; // 변경 승인 여부 N
|
|
|
|
|
} else if (tabName == "승인완료") {
|
|
|
|
|
$P.ctrl.query.chgDmndYn = "Y"; // 변경 요청 여부 Y
|
|
|
|
|
$P.ctrl.query.chgAprvYn = "Y"; // 변경 승인 여부 Y
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.ctrl.query.trgtSttsNm = tabName;
|
|
|
|
|
|
|
|
|
|
// 임대기업번호가 전체라면..
|
|
|
|
|
if ($P.ctrl.query.schEntNo == "" ) {
|
|
|
|
|
if ($P.ctrl.query.entId == "" ) {
|
|
|
|
|
// schEntNo 의 option을 전체를 배열로 담는다.
|
|
|
|
|
let arrEntNo = $.map($P.$findn("schEntNo").find("option"), function(e) { return e.value; });
|
|
|
|
|
let arrEntId = $.map($P.$findn("entId").find("option"), function(e) { return e.value; });
|
|
|
|
|
|
|
|
|
|
if (arrEntNo.length == 1) {
|
|
|
|
|
if (arrEntId.length == 1) {
|
|
|
|
|
dialog.alert({
|
|
|
|
|
content: "등록되어 있는 임대기업 정보가 없습니다."
|
|
|
|
|
+ "<br>" + "'임대기업관리' 메뉴에서 임대기업 정보를 먼저 등록하시기 바랍니다."
|
|
|
|
@ -375,14 +417,14 @@
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 빈 값(전체)을 제외하고 "," 로 구분하여 schEntNos 에 담는다.
|
|
|
|
|
$P.ctrl.query.schEntNos = arrEntNo.filter((element) => element !== "").join(',');
|
|
|
|
|
// 빈 값(전체)을 제외하고 "," 로 구분하여 entIds 에 담는다.
|
|
|
|
|
$P.ctrl.query.entIds = arrEntId.filter((element) => element !== "").join(',');
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.ctrl.load(1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 엑셀 버튼 이벤트
|
|
|
|
|
// 엑셀
|
|
|
|
|
$P.fnExcel = () => {
|
|
|
|
|
if ($P.ctrl.dataset.empty) {
|
|
|
|
|
dialog.alert({
|
|
|
|
@ -401,20 +443,35 @@
|
|
|
|
|
$P.ctrl.download();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 임대기업 매핑 등록 버튼 이벤트
|
|
|
|
|
// 임대계약서 승인 요청
|
|
|
|
|
$P.fnCreate = () => {
|
|
|
|
|
let selected = $P.ctrl.getDataset("selected"); // 선택 자료
|
|
|
|
|
|
|
|
|
|
if (selected.length < 1) {
|
|
|
|
|
dialog.alert({
|
|
|
|
|
content: "선택하신 " + $P.ctrl.prefixName + " 정보가 없습니다."
|
|
|
|
|
, init: () => { AppSupport.setDialogZindex(); }
|
|
|
|
|
, onOK: () => { }
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
dialog.alert({
|
|
|
|
|
content: "선택한 " + selected.length + "건의 " + $P.ctrl.prefixName + " 정보를 승인 요청하시겠습니까?"
|
|
|
|
|
, onOK: () => {
|
|
|
|
|
let params = {
|
|
|
|
|
callPurpose: "create"
|
|
|
|
|
, userId: $P.$findn("userId").val()
|
|
|
|
|
, schEntNo: ""
|
|
|
|
|
};
|
|
|
|
|
, lsctIds: selected.map(info => info.LSCT_ID).join(",")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.ctrl.getInfo(params);
|
|
|
|
|
$P.ctrl.create(params);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 임대기업 매핑 삭제 버튼 이벤트
|
|
|
|
|
// 임대계약서 승인 요청 취소
|
|
|
|
|
$P.fnRemove = () => {
|
|
|
|
|
let selected = $P.ctrl.dataset.getKeys("selected"); // 선택 자료
|
|
|
|
|
let selected = $P.ctrl.getDataset("selected"); // 선택 자료
|
|
|
|
|
|
|
|
|
|
if (selected.length < 1) {
|
|
|
|
|
dialog.alert({
|
|
|
|
@ -426,11 +483,11 @@
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
dialog.alert({
|
|
|
|
|
content: "선택한 " + selected.length + "건의 " + $P.ctrl.prefixName + " 정보를 삭제하시겠습니까?"
|
|
|
|
|
content: "선택한 " + selected.length + "건의 " + $P.ctrl.prefixName + " 정보를 승인 요청을 취소하시겠습니까?"
|
|
|
|
|
, onOK: () => {
|
|
|
|
|
let params = {
|
|
|
|
|
callPurpose: "create"
|
|
|
|
|
, mpngIds: selected.join(",")
|
|
|
|
|
callPurpose: "remove"
|
|
|
|
|
, lsctIds: selected.map(info => info.LSCT_ID).join(",")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.ctrl.remove(params);
|
|
|
|
@ -449,8 +506,8 @@
|
|
|
|
|
$P.$findn("btnExcel").on("click", () => { $P.fnExcel() }); // 엑셀
|
|
|
|
|
|
|
|
|
|
// 업무 버튼 이벤트
|
|
|
|
|
$P.$findn("btnCreate").on("click", () => { $P.fnCreate(); }); // 등록
|
|
|
|
|
$P.$findn("btnRemove").on("click", () => { $P.fnRemove(); }); // 삭제
|
|
|
|
|
$P.$findn("btnCreate").on("click", () => { $P.fnCreate(); }); // 승인 요청
|
|
|
|
|
$P.$findn("btnRemove").on("click", () => { $P.fnRemove(); }); // 승인 요청 취소
|
|
|
|
|
|
|
|
|
|
// DataTables width 변경 조정
|
|
|
|
|
Componentization.fnMakeResizableTable($P.findn("tableRspns"));
|
|
|
|
|