feat : 답변 대상 자료, 답변처리 대기 자료 메뉴 추가

main
이범준 1 year ago
parent 7e2ffe007d
commit 2386af33c5

@ -0,0 +1,758 @@
<%--
* <pre>
* description :
*
* packageName :
* fileName : rtAnswerTargetDataForm.jsp
* author : 이범준
* date : 2023-05-30
* ======================================================================
* 변경일 변경자 변경 내용
* ----------------------------------------------------------------------
* 2023-05-30 이범준 최초 생성
*
* </pre>
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
<%@ include file="/WEB-INF/jsp/include/fims/taglib.jsp"%>
<%@ page import="kr.xit.fims.biz.FimsConst" %>
<c:set var="ctznTmplatId" value="<%= FimsConst.TmplatId.CTZN.getCode() %>"/>
<c:set var="ansSeCodeImpose" value="<%= FimsConst.AnswerSeCode.IMPOSE.getCode() %>"/>
<c:set var="ansSeCodeDisallow" value="<%= FimsConst.AnswerSeCode.DISALLOW.getCode() %>"/>
<c:set var="ansSeCodeEnlight" value="<%= FimsConst.AnswerSeCode.ENLIGHT.getCode() %>"/>
<div>
<div class="container-page-btn">
<button type="button" class="btn btn-outline-dark">초기화</button>
<span class="container-window-btn-right">
</span>
</div>
<!-- tab 공통 -->
<form id="frmSearch" name="frmSearch">
<div class="container-search">
<div class="row">
<div class="col-11">
<div class="row">
<div class="col-12">
<label class="form-label fw-bold form-search-title">시스템구분</label>
<span class="form-search-linebox">
<code:radio grpId="FIM001" id="sysSeCd" name="sysSeCd" defaultSelect='${sessionScope.XitLoginSession.orgnztId}'
onclick="search$$s()" cls="form-check-input" alt="시스템구분"/>
</span>
</div>
<div class="col-12">
<select id="sch_date_opt" name="sch_date_opt" class="form-select">
<option value="crdnYmd">단속일자</option>
<option value="regDt">등록일자</option>
</select>
<span class="form-search-linebox">
<input id="sch_date_from" class="form-control form-date" data-fmt-type="day" name="sch_date_from" type="text" title="시작 날짜 선택">
<button type="button" class="bx bx-calendar bg-white"></button>
~
<input id="sch_date_to" class="form-control form-date" data-fmt-type="day" name="sch_date_to" type="text" title="종료 날짜 선택">
<button type="button" class="bx bx-calendar bg-white"></button>
</span>
</div>
<div class="col-12">
<label class="form-label fw-bold form-search-title">단속구분</label>
<span class="form-search-linebox">
<code:radio type="CMM_ETC2" id="crdnSeCd" name="crdnSeCd" grpId="FIM002"
onclick="search$$s()" cls="form-check-input" alt="단속구분" />
</span>
</div>
<div class="col-12">
<label class="form-label fw-bold form-search-title">자료상태</label>
<code:select id="crdnSttsCd" name="crdnSttsCd"
grpId="FIM010" defaultSelect="01" title="단속처리상태" cls="form-select" alt="단속처리상태" disabled="false"/>
<select id="sch_opt" name="sch_opt" class="form-select">
<option value="vhrno">차량번호</option>
</select>
<input type="text" id="sch_word" name="sch_word" class="form-control" value="" />
<span class="flr">
<button type="button" class="btn btn-open-detail btn-sm" data-bs-toggle="collapse" data-bs-target="#searchDetail">
<i class="bx bx-chevron-down"></i>
상세조회조건
</button>
</span>
</div>
</div>
</div>
<div class="col-1 d-flex align-items-center justify-content-center">
<button type="button" class="btn btn-search btn-square h-px-75" id="btnSearch" title="검색">검색</button>
</div>
</div>
</div>
<div id="searchDetail" class="container-search container-search-detail collapse">
상세조회조건
</div>
</form>
<div>
<span class="container-page-btn">
<div id="totCnt">전체 ㅣ <span></span></div>
<span class="container-window-btn-right">
선택 | n건
<a href="#" class="btn btn-blue" id="btnAnswerPreview" title="답변내용미리보기">답변내용미리보기</a>
<a href="#" class="btn btn-blue" id="btnAnswer" title="답변등록">선택자료 답변등록</a>
</span>
</span>
</div>
<div class="container-search">
<div class="row">
<div class="col-12">
<span class="me-5">결과내재검색</span>
<label class="form-label fw-bold form-search-title">클릭한 항목</label>
<input type="text" id="" name="" class="form-control" value="" />
</div>
</div>
</div>
<div id="tabs" class="nav-align-top mt-3">
<ul class="nav nav-tabs">
<li class="nav-item">
<button id="0" type="button" class="nav-link active" data-bs-toggle="tab" data-bs-target="#tabContent0">전체</button>
</li>
<li class="nav-item">
<button id="1" type="button" class="nav-link" data-bs-toggle="tab" data-bs-target="#tabContent0">부분1</button>
</li>
<li class="nav-item">
<button id="2" type="button" class="nav-link" data-bs-toggle="tab" data-bs-target="#tabContent0">부분2</button>
</li>
<li class="nav-item">
<button id="3" type="button" class="nav-link" data-bs-toggle="tab" data-bs-target="#tabContent0">부분3</button>
</li>
</ul>
</div>
<div class="tab-content">
<div id="tabContent0" style="flex-direction: column" class="tab-pane fade show active">
<div id="tabs_t0"></div>
</div>
<div id="tabContent1" class="tab-pane fade">
<div id="tabs_t1"></div>
</div>
<div id="tabContent2" class="tab-pane fade">
<div id="tabs_t2"></div>
</div>
</div>
<div id="grid"></div>
<div class="d-flex flex-row p-3 justify-content-between">
<label id="grid1PagingInfo" class="dataTables_info" role="status" aria-live="polite"></label>
<ul id="grid1Paging" class="pagination pagination-primary"></ul>
</div>
</div>
<script defer type="text/javascript" src="${pageContext.request.contextPath}/resources/js/fims/biz/common/popupPageNavigation.js"></script>
<script type="text/javaScript">
/**************************************************************************
* Global Variable
**************************************************************************/
/**
* tab index : 0 부터 시작
* @type {number}
*/
var CUR_TAB_IDX = 0;
/**
* tui-grid array
* @type {*[]}
*/
var GRID = {};
/**
* PageNavigation
* @type {*[]}
*/
var pageNav = {};
/**
* 부과대상 데이타 배열
* 단속ID, 접수번호
* @type {Array<{crdnId: string, cvplRceptNo: string}>}
*/
var IMPOSE_DATA;
/**
* 단속진행 상태
* 01 - 초기등록
* 10 - 부과대상
* @type {string[]}
*/
let ARR_PRC_STS_CODE = ['01', '10']
/**
* 팝업 객체
* @type {null}
*/
popup = null;
/**
*
*/
let popupDiv;
/**
*
*/
var callbackSearch = () => search$$s();
let $$Control = new FimsDatasetControl({
prefix:"initData",
prefixName:"초기자료",
infoSize:"xl",
urls : {
load : fimsApiUrl.FIND_CRACKDOWNS
},
keymapper:info => info ? info.CRACKDOWN_KEY : "",
dataGetter:obj => obj.data.contents
});
$$Control._paginationInfo.pagingType = "scroll";
$$Control._paginationInfo.fetchSize = 50;
$$Control._paginationInfo.scrollFuncName = scroll$$s;
$$Control.onDatasetChange = obj => {
let pagination = obj.data.pagination;
if(obj.data.pagination){
$$Control._paginationInfo.totalSize = pagination.totalSize;
$$Control._paginationInfo.pageNum = pagination.pageNum;
} else {
$$Control._paginationInfo.totalSize = obj.count;
}
$$Control.totalCountSetting(obj);
render$$List(obj.data);
if($$Control._paginationInfo.paging && $$Control._paginationInfo.pagingType == "nav"){
let start = 0;
if(pagination.pageNum > 1 && pagination.totalPage > 1 && pagination.totalSize > $$Control._paginationInfo.fetchSize){
start = $$Control._paginationInfo.fetchSize * (pagination.pageNum - 1);
}
$("#grid1Paging").setPaging({
list: $$Control.dataset,
prefix: "grid1",
start: start,
totalSize: pagination.totalSize,
fetchSize: $$Control._paginationInfo.fetchSize,
func: "$$$Control.load({index})",
});
}
};
function search$$s(){
$$Control.query = fnBiz.getParams();
GRID.clear();
$$Control.load(1);
}
function scroll$$s(){
$$Control.load($$Control._paginationInfo.pageNum + 1, "more");
}
function render$$List(data) {
if($$Control._paginationInfo.paging && $$Control._paginationInfo.pagingType == "nav"){
GRID.clear();
}
GRID.appendRows(data.contents);
}
/*******************************
* Biz function
*******************************/
// tab 전체
const fnBiz = {
getParams: () => {
return {
sch_date_opt: $('#sch_date_opt').val()
,sch_date_from: $('#sch_date_from').val()
,sch_date_to: $('#sch_date_to').val()
,[$('#sch_opt').val()]: $('#sch_word').val()
,sysSeCd: $('input:radio[name=sysSeCd]:checked').val()
,crdnSeCd: CUR_TAB_IDX === 2 ? '09' : $('input:radio[name=crdnSeCd]:checked').val()
,crdnSttsCd: CUR_TAB_IDX === 2 ? 'NON-INIT' : $('#crdnSttsCd').val()
,ctznAnsYn: $('input:radio[name=ctznAnsYn]:checked').val()
}
}
,pagePopup: function(flag, params){
let url;
let popTitle;
let popOption;
switch (flag) {
case "total":
url = fimsApiUrl.POPUP_CRACKDOWN_TOTAL;
popOption = {width: 1200, height:900};
popTitle = "개별총정보";
break;
case "edit":
url = fimsApiUrl.POPUP_CRACKDOWN_EDIT;
popOption = {width: 1200, height:900};
popTitle = "정보 변경";
break;
case "file":
url = fimsApiUrl.POPUP_EXTR_CRACKDOWN_FILE_SEL;
popOption = {width: 900, height:750};
popTitle = "외부연계 데이타 선택";
break;
case "impose":
url = fimsApiUrl.POPUP_IMPOSE;
popOption = {width: 500, height: 400};
popTitle = "과태료 시스템 등록";
break;
case "answerPreview":
url = fimsApiUrl.POPUP_CTZN_ANS_PREVIEW;
popOption = {width: 600, height: 620};
popTitle = "답변 내용 미리 보기";
break;
default:
break;
}
popup = CmmPopup.openModal(url, params, popOption, popTitle);
}
,onClickGrid: function(props){
const selColumn = props.columnInfo.name;
switch (selColumn){
case 'cvplRceptNo':
popupDiv = 'edit';
const rowDatas = GRID.store.data.rawData.map(d => {
return {crdnSeCd: d.crdnSeCd, crdnId: d.crdnId, crdnSttsCd: d.crdnSttsCd}
})
pageNav = new PageNavigation(GRID, rowDatas, props.rowKey);
fnBiz.pagePopup(popupDiv, pageNav.gridInfo.curRowData);
$(".tooltip").remove();
break;
default:
break;
}
}
,resetBtn: function() {
switch(CUR_TAB_IDX){
case 0:
$('#btnExtrRegist').show();
$('#divImpose').hide();
$('#divAnswer').hide();
$('#ansDiv').hide();
$('#crdnSttsCd').show();
$('#fldCrdnSeCd').show();
break;
case 1:
$('#btnExtrRegist').hide();
$('#divImpose').show();
$('#divAnswer').hide();
$('#ansDiv').hide();
$('#crdnSttsCd').show();
$('#fldCrdnSeCd').show();
break;
case 2:
$('#btnExtrRegist').hide();
$('#divImpose').hide();
$('#divAnswer').show();
$('#ansDiv').show();
$('#crdnSttsCd').show();
$('#fldCrdnSeCd').hide();
break;
}
}
,onDblClickGrid: function (props) {
popupDiv = 'total';
const rowDatas = GRID.store.data.rawData.map(d => {
return {crdnSeCd: d.crdnSeCd, crdnId: d.crdnId, crdnSttsCd: d.crdnSttsCd}
});
pageNav = new PageNavigation(GRID, rowDatas, props.rowKey);
fnBiz.pagePopup(popupDiv, pageNav.gridInfo.curRowData);
}
,getAnswerSeCode: (stsCode) => {
/*
,{value: '10', text: '부과대상'}
,{value: '11', text: '서손'}
,{value: '12', text: '계도'}
,{value: '20', text: '부과'}
*/
let answerSeCode;
switch(stsCode){
// 부과
case '10':
case '20':
answerSeCode = '${ansSeCodeImpose}';
break;
// 서손
case '11':
answerSeCode = '${ansSeCodeDisallow}';
break;
// 계도
case '12':
answerSeCode = '${ansSeCodeEnlight}';
break;
}
return answerSeCode;
}
};
/**************************************************************************
* event
**************************************************************************/
$(() => {
$("#tabs").on("click", "li", function () {
CUR_TAB_IDX = parseInt($("#tabs .nav-link.active").attr("id"));
});
$('#btnSearch').on('click', () => search$$s());
$('#btnMenualRegist').on('click', () => {
fnBiz.pagePopup('edit', {});
});
$('#btnExtrRegist').on('click', () => {
fnBiz.pagePopup('file');
});
$('#btnImpose').on('click', () => {
const arrChecks = GRID.getCheckedRows();
if(arrChecks.length === 0){
alert('부과 처리 대상을 먼저 선택해 주세요');
return false;
}
IMPOSE_DATA = arrChecks.map((row) => {
const extnlInterfaceId = row.crdnSeCd === '09' ? row.interfaceSeqN + row.ctznSttemntDetailSn : row.fileLinkId
return {
crdnId: row.crdnId
,crdnSeCd: row.crdnSeCd
,extnlInterfaceId
,vhrno: row.vhrno
,cvplRceptNo: row.cvplRceptNo
}
})
fnBiz.pagePopup('impose');
});
$('#btnAnswerPreview').on('click', () => {
if(GRID.store.data.rawData.length == 0){
alert('대상 데이타가 존재하지 않습니다.');
return false;
}
const arrChecks = GRID.getCheckedRows();
let rowKey;
if(arrChecks.length > 0){
rowKey = arrChecks[0].rowKey;
} else {
rowKey = GRID.store.data.rawData[0]?.rowKey;
}
const rowDatas = GRID.store.data.rawData.map(d => {
return {tmplatId: '${ctznTmplatId}', answerSeCode: fnBiz.getAnswerSeCode(d.crdnSttsCd), resnCode: d.erppSeCode, interfaceSeqN: d.interfaceSeqN, vhrno: d.vhrno}
})
popupDiv = 'answerPreview';
NAV = new PageNavigation(GRID, rowDatas, rowKey);
fnBiz.pagePopup(popupDiv, pageNav.gridInfo.curRowData);
});
$('#btnAnswer').on('click', () => {
const arrChecks = GRID.getCheckedRows();
if(arrChecks.length === 0){
alert('답변 처리할 대상을 먼저 선택해 주세요');
return false;
}
const arrData = arrChecks.map((row) => {
return {
interfaceSeqN: row.interfaceSeqN
}
})
// 중복제거
const datas = arrData.reduce(function(acc, current) {
if (acc.findIndex(({ interfaceSeqN }) => interfaceSeqN === current.interfaceSeqN) === -1) {
acc.push(current.interfaceSeqN);
}
return acc;
}, []);
cmmAjax({
url: fimsApiUrl.ADD_CTZN_ANS_LIST
,contentType: 'application/json'
,data: JSON.stringify(datas)
,success: (res) => {
}
});
});
});
/* *******************************
* Grid
******************************* */
const gridColumns = [
{
header: '등록구분',
name: 'crdnRegSeCd',
minWidth: 50,
sortable: false,
align: 'center',
formatter({value}) {
return (new CodeFormat(ComboCodeData.crdnRegSeCd)).format(value);
}
},
{
header: '접수번호',
name: 'cvplRceptNo',
minWidth: 130,
sortable: false,
align: 'center',
renderer: {
type: CustomButtonRenderer,
options: {
formatter: (props)=>{
const rowData = props.grid.getRow(props.rowKey);
return {
formatter: rowData.crdnSeCd === '09' ? rowData.cvplRceptNo : rowData.fileLinkId
,element: "text"
,dataAttrs : {
bsToggle: "tooltip",
bsOffset: "0,4",
bsPlacement: "top",
bsHtml: "true"
}
,attrs : {
title : "<i class='bx bx-window bx-xs'></i> <span>단속현황 정보</span>"
}
}
}
,eventFunction: fnBiz.onClickGrid
,eventType: "click"
}
}
},
{
header: '차량번호',
name: 'vhrno',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '신고자',
name: 'cvplApplcntNm',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '단속구분(신고방법)',
name: 'crdnSeCd',
minWidth: 100,
sortable: false,
align: 'center',
formatter: 'listItemText',
disabled: true,
editor: {
type: "select",
options: {
listItems: [...ComboCodeData.crdnSeCd]
}
}
},
{
header: '위반내용',
name: 'vltnCn',
minWidth: 120,
sortable: false,
align: 'center'
},
{
header: '주민번호(전체)',
name: 'rtpyrNo',
minWidth: 110,
sortable: false,
align: 'center',
className: "privacy"
},
{
header: '주민번호(마스킹)',
name: 'rtpyrNoMask',
minWidth: 110,
sortable: false,
align: 'center',
className: "privacy-mask"
},
{
header: '담당자',
name: 'dutyIdV',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '전화번호',
name: 'pcdTelV',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '접수일자',
name: 'cvplRceptDt',
minWidth: 80,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateFormat.format(value); //
}
},
{
header: '처리기한',
name: 'cvplProcessPd',
minWidth: 80,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateFormat.format(value); //
}
},
{
header: '위반일시',
name: 'crdnYmdTime',
minWidth: 120,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateTimeFormat.format(value); //
}
},
{
header: '사진건수',
name: 'atchFileCnt',
minWidth: 40,
sortable: false,
align: 'center'
},
{
header: '특기사항',
name: 'etcCn',
width: 80,
sortable: false,
align: 'center'
},
{
header: '서손사유',
name: 'erppResnDetail', //erppSeCode
width: 80,
sortable: false,
align: 'center'
},
{
header: '수납금액',
name: 'rcvmtAmt',
minWidth: 100,
sortable: false,
align: 'right'
},
{
header: '위반횟수',
name: 'vltnNmtm',
minWidth: 80,
sortable: false,
align: 'right'
},
{
header: '위반장소',
name: 'crdnPlc',
minWidth: 200,
sortable: false
},
{
header: '처리상태명',
name: 'crdnSttsNm',
hidden: true
},
{
header: '등록일시',
name: 'regDt',
minWidth: 150,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateTimeFormat.format(value); //
}
},
{
header: '최종처리일시',
name: 'mdfcnDt',
minWidth: 150,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateTimeFormat.format(value);
}
},
{
header: '',
name: 'crdnSttsCd',
hidden: true
},
{
header: '서손ID',
name: 'erppId',
hidden: true
},
{
header: '소유자ID',
name: 'rtpyrId',
hidden: true
},
{
header: '서손사유코드',
name: 'erppSeCode',
hidden: true
},
{
header: 'interfaceSeqN',
name: 'interfaceSeqN',
hidden: true
}
];
const gridOptions = {
el: 'grid',
rowHeaders: ['rowNum'],
columns: gridColumns,
columnOptions: {
frozenCount: 6
},
paginationInfoRef : $$Control._paginationInfo
};
const initGrid = () => {
GRID = TuiGrid.of(gridOptions);
GRID.on('dblclick', function (props) { fnBiz.onDblClickGrid(props); });
};
/**************************************************************************
* initialize
**************************************************************************/
$(document).ready(function(){
$('#sch_date_from').datepicker('setDate', DateUtil.getDateDay(-5475).date);
$('#sch_date_to').datepicker('setDate', new Date());
CUR_TAB_IDX = 0;
fnBiz.resetBtn();
initGrid();
});
</script>

@ -0,0 +1,758 @@
<%--
* <pre>
* description :
*
* packageName :
* fileName : rtAnswerWaitDataForm.jsp
* author : 이범준
* date : 2023-05-30
* ======================================================================
* 변경일 변경자 변경 내용
* ----------------------------------------------------------------------
* 2023-05-30 이범준 최초 생성
*
* </pre>
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
<%@ include file="/WEB-INF/jsp/include/fims/taglib.jsp"%>
<%@ page import="kr.xit.fims.biz.FimsConst" %>
<c:set var="ctznTmplatId" value="<%= FimsConst.TmplatId.CTZN.getCode() %>"/>
<c:set var="ansSeCodeImpose" value="<%= FimsConst.AnswerSeCode.IMPOSE.getCode() %>"/>
<c:set var="ansSeCodeDisallow" value="<%= FimsConst.AnswerSeCode.DISALLOW.getCode() %>"/>
<c:set var="ansSeCodeEnlight" value="<%= FimsConst.AnswerSeCode.ENLIGHT.getCode() %>"/>
<div>
<div class="container-page-btn">
<button type="button" class="btn btn-outline-dark">초기화</button>
<span class="container-window-btn-right">
</span>
</div>
<!-- tab 공통 -->
<form id="frmSearch" name="frmSearch">
<div class="container-search">
<div class="row">
<div class="col-11">
<div class="row">
<div class="col-12">
<label class="form-label fw-bold form-search-title">시스템구분</label>
<span class="form-search-linebox">
<code:radio grpId="FIM001" id="sysSeCd" name="sysSeCd" defaultSelect='${sessionScope.XitLoginSession.orgnztId}'
onclick="search$$s()" cls="form-check-input" alt="시스템구분"/>
</span>
</div>
<div class="col-12">
<select id="sch_date_opt" name="sch_date_opt" class="form-select">
<option value="crdnYmd">단속일자</option>
<option value="regDt">등록일자</option>
</select>
<span class="form-search-linebox">
<input id="sch_date_from" class="form-control form-date" data-fmt-type="day" name="sch_date_from" type="text" title="시작 날짜 선택">
<button type="button" class="bx bx-calendar bg-white"></button>
~
<input id="sch_date_to" class="form-control form-date" data-fmt-type="day" name="sch_date_to" type="text" title="종료 날짜 선택">
<button type="button" class="bx bx-calendar bg-white"></button>
</span>
</div>
<div class="col-12">
<label class="form-label fw-bold form-search-title">단속구분</label>
<span class="form-search-linebox">
<code:radio type="CMM_ETC2" id="crdnSeCd" name="crdnSeCd" grpId="FIM002"
onclick="search$$s()" cls="form-check-input" alt="단속구분" />
</span>
</div>
<div class="col-12">
<label class="form-label fw-bold form-search-title">자료상태</label>
<code:select id="crdnSttsCd" name="crdnSttsCd"
grpId="FIM010" defaultSelect="01" title="단속처리상태" cls="form-select" alt="단속처리상태" disabled="false"/>
<select id="sch_opt" name="sch_opt" class="form-select">
<option value="vhrno">차량번호</option>
</select>
<input type="text" id="sch_word" name="sch_word" class="form-control" value="" />
<span class="flr">
<button type="button" class="btn btn-open-detail btn-sm" data-bs-toggle="collapse" data-bs-target="#searchDetail">
<i class="bx bx-chevron-down"></i>
상세조회조건
</button>
</span>
</div>
</div>
</div>
<div class="col-1 d-flex align-items-center justify-content-center">
<button type="button" class="btn btn-search btn-square h-px-75" id="btnSearch" title="검색">검색</button>
</div>
</div>
</div>
<div id="searchDetail" class="container-search container-search-detail collapse">
상세조회조건
</div>
</form>
<div>
<span class="container-page-btn">
<div id="totCnt">전체 ㅣ <span></span></div>
<span class="container-window-btn-right">
선택 | n건
<a href="#" class="btn btn-blue" id="" title="업무처리1">민원내용원본</a>
<a href="#" class="btn btn-blue" id="" title="업무처리2">답변내용 미리보기</a>
</span>
</span>
</div>
<div class="container-search">
<div class="row">
<div class="col-12">
<span class="me-5">결과내재검색</span>
<label class="form-label fw-bold form-search-title">클릭한 항목</label>
<input type="text" id="" name="" class="form-control" value="" />
</div>
</div>
</div>
<div id="tabs" class="nav-align-top mt-3">
<ul class="nav nav-tabs">
<li class="nav-item">
<button id="0" type="button" class="nav-link active" data-bs-toggle="tab" data-bs-target="#tabContent0">전체</button>
</li>
<li class="nav-item">
<button id="1" type="button" class="nav-link" data-bs-toggle="tab" data-bs-target="#tabContent0">부분1</button>
</li>
<li class="nav-item">
<button id="2" type="button" class="nav-link" data-bs-toggle="tab" data-bs-target="#tabContent0">부분2</button>
</li>
<li class="nav-item">
<button id="3" type="button" class="nav-link" data-bs-toggle="tab" data-bs-target="#tabContent0">부분3</button>
</li>
</ul>
</div>
<div class="tab-content">
<div id="tabContent0" style="flex-direction: column" class="tab-pane fade show active">
<div id="tabs_t0"></div>
</div>
<div id="tabContent1" class="tab-pane fade">
<div id="tabs_t1"></div>
</div>
<div id="tabContent2" class="tab-pane fade">
<div id="tabs_t2"></div>
</div>
</div>
<div id="grid"></div>
<div class="d-flex flex-row p-3 justify-content-between">
<label id="grid1PagingInfo" class="dataTables_info" role="status" aria-live="polite"></label>
<ul id="grid1Paging" class="pagination pagination-primary"></ul>
</div>
</div>
<script defer type="text/javascript" src="${pageContext.request.contextPath}/resources/js/fims/biz/common/popupPageNavigation.js"></script>
<script type="text/javaScript">
/**************************************************************************
* Global Variable
**************************************************************************/
/**
* tab index : 0 부터 시작
* @type {number}
*/
var CUR_TAB_IDX = 0;
/**
* tui-grid array
* @type {*[]}
*/
var GRID = {};
/**
* PageNavigation
* @type {*[]}
*/
var pageNav = {};
/**
* 부과대상 데이타 배열
* 단속ID, 접수번호
* @type {Array<{crdnId: string, cvplRceptNo: string}>}
*/
var IMPOSE_DATA;
/**
* 단속진행 상태
* 01 - 초기등록
* 10 - 부과대상
* @type {string[]}
*/
let ARR_PRC_STS_CODE = ['01', '10']
/**
* 팝업 객체
* @type {null}
*/
popup = null;
/**
*
*/
let popupDiv;
/**
*
*/
var callbackSearch = () => search$$s();
let $$Control = new FimsDatasetControl({
prefix:"initData",
prefixName:"초기자료",
infoSize:"xl",
urls : {
load : fimsApiUrl.FIND_CRACKDOWNS
},
keymapper:info => info ? info.CRACKDOWN_KEY : "",
dataGetter:obj => obj.data.contents
});
$$Control._paginationInfo.pagingType = "scroll";
$$Control._paginationInfo.fetchSize = 50;
$$Control._paginationInfo.scrollFuncName = scroll$$s;
$$Control.onDatasetChange = obj => {
let pagination = obj.data.pagination;
if(obj.data.pagination){
$$Control._paginationInfo.totalSize = pagination.totalSize;
$$Control._paginationInfo.pageNum = pagination.pageNum;
} else {
$$Control._paginationInfo.totalSize = obj.count;
}
$$Control.totalCountSetting(obj);
render$$List(obj.data);
if($$Control._paginationInfo.paging && $$Control._paginationInfo.pagingType == "nav"){
let start = 0;
if(pagination.pageNum > 1 && pagination.totalPage > 1 && pagination.totalSize > $$Control._paginationInfo.fetchSize){
start = $$Control._paginationInfo.fetchSize * (pagination.pageNum - 1);
}
$("#grid1Paging").setPaging({
list: $$Control.dataset,
prefix: "grid1",
start: start,
totalSize: pagination.totalSize,
fetchSize: $$Control._paginationInfo.fetchSize,
func: "$$$Control.load({index})",
});
}
};
function search$$s(){
$$Control.query = fnBiz.getParams();
GRID.clear();
$$Control.load(1);
}
function scroll$$s(){
$$Control.load($$Control._paginationInfo.pageNum + 1, "more");
}
function render$$List(data) {
if($$Control._paginationInfo.paging && $$Control._paginationInfo.pagingType == "nav"){
GRID.clear();
}
GRID.appendRows(data.contents);
}
/*******************************
* Biz function
*******************************/
// tab 전체
const fnBiz = {
getParams: () => {
return {
sch_date_opt: $('#sch_date_opt').val()
,sch_date_from: $('#sch_date_from').val()
,sch_date_to: $('#sch_date_to').val()
,[$('#sch_opt').val()]: $('#sch_word').val()
,sysSeCd: $('input:radio[name=sysSeCd]:checked').val()
,crdnSeCd: CUR_TAB_IDX === 2 ? '09' : $('input:radio[name=crdnSeCd]:checked').val()
,crdnSttsCd: CUR_TAB_IDX === 2 ? 'NON-INIT' : $('#crdnSttsCd').val()
,ctznAnsYn: $('input:radio[name=ctznAnsYn]:checked').val()
}
}
,pagePopup: function(flag, params){
let url;
let popTitle;
let popOption;
switch (flag) {
case "total":
url = fimsApiUrl.POPUP_CRACKDOWN_TOTAL;
popOption = {width: 1200, height:900};
popTitle = "개별총정보";
break;
case "edit":
url = fimsApiUrl.POPUP_CRACKDOWN_EDIT;
popOption = {width: 1200, height:900};
popTitle = "정보 변경";
break;
case "file":
url = fimsApiUrl.POPUP_EXTR_CRACKDOWN_FILE_SEL;
popOption = {width: 900, height:750};
popTitle = "외부연계 데이타 선택";
break;
case "impose":
url = fimsApiUrl.POPUP_IMPOSE;
popOption = {width: 500, height: 400};
popTitle = "과태료 시스템 등록";
break;
case "answerPreview":
url = fimsApiUrl.POPUP_CTZN_ANS_PREVIEW;
popOption = {width: 600, height: 620};
popTitle = "답변 내용 미리 보기";
break;
default:
break;
}
popup = CmmPopup.openModal(url, params, popOption, popTitle);
}
,onClickGrid: function(props){
const selColumn = props.columnInfo.name;
switch (selColumn){
case 'cvplRceptNo':
popupDiv = 'edit';
const rowDatas = GRID.store.data.rawData.map(d => {
return {crdnSeCd: d.crdnSeCd, crdnId: d.crdnId, crdnSttsCd: d.crdnSttsCd}
})
pageNav = new PageNavigation(GRID, rowDatas, props.rowKey);
fnBiz.pagePopup(popupDiv, pageNav.gridInfo.curRowData);
$(".tooltip").remove();
break;
default:
break;
}
}
,resetBtn: function() {
switch(CUR_TAB_IDX){
case 0:
$('#btnExtrRegist').show();
$('#divImpose').hide();
$('#divAnswer').hide();
$('#ansDiv').hide();
$('#crdnSttsCd').show();
$('#fldCrdnSeCd').show();
break;
case 1:
$('#btnExtrRegist').hide();
$('#divImpose').show();
$('#divAnswer').hide();
$('#ansDiv').hide();
$('#crdnSttsCd').show();
$('#fldCrdnSeCd').show();
break;
case 2:
$('#btnExtrRegist').hide();
$('#divImpose').hide();
$('#divAnswer').show();
$('#ansDiv').show();
$('#crdnSttsCd').show();
$('#fldCrdnSeCd').hide();
break;
}
}
,onDblClickGrid: function (props) {
popupDiv = 'total';
const rowDatas = GRID.store.data.rawData.map(d => {
return {crdnSeCd: d.crdnSeCd, crdnId: d.crdnId, crdnSttsCd: d.crdnSttsCd}
});
pageNav = new PageNavigation(GRID, rowDatas, props.rowKey);
fnBiz.pagePopup(popupDiv, pageNav.gridInfo.curRowData);
}
,getAnswerSeCode: (stsCode) => {
/*
,{value: '10', text: '부과대상'}
,{value: '11', text: '서손'}
,{value: '12', text: '계도'}
,{value: '20', text: '부과'}
*/
let answerSeCode;
switch(stsCode){
// 부과
case '10':
case '20':
answerSeCode = '${ansSeCodeImpose}';
break;
// 서손
case '11':
answerSeCode = '${ansSeCodeDisallow}';
break;
// 계도
case '12':
answerSeCode = '${ansSeCodeEnlight}';
break;
}
return answerSeCode;
}
};
/**************************************************************************
* event
**************************************************************************/
$(() => {
$("#tabs").on("click", "li", function () {
CUR_TAB_IDX = parseInt($("#tabs .nav-link.active").attr("id"));
});
$('#btnSearch').on('click', () => search$$s());
$('#btnMenualRegist').on('click', () => {
fnBiz.pagePopup('edit', {});
});
$('#btnExtrRegist').on('click', () => {
fnBiz.pagePopup('file');
});
$('#btnImpose').on('click', () => {
const arrChecks = GRID.getCheckedRows();
if(arrChecks.length === 0){
alert('부과 처리 대상을 먼저 선택해 주세요');
return false;
}
IMPOSE_DATA = arrChecks.map((row) => {
const extnlInterfaceId = row.crdnSeCd === '09' ? row.interfaceSeqN + row.ctznSttemntDetailSn : row.fileLinkId
return {
crdnId: row.crdnId
,crdnSeCd: row.crdnSeCd
,extnlInterfaceId
,vhrno: row.vhrno
,cvplRceptNo: row.cvplRceptNo
}
})
fnBiz.pagePopup('impose');
});
$('#btnAnswerPreview').on('click', () => {
if(GRID.store.data.rawData.length == 0){
alert('대상 데이타가 존재하지 않습니다.');
return false;
}
const arrChecks = GRID.getCheckedRows();
let rowKey;
if(arrChecks.length > 0){
rowKey = arrChecks[0].rowKey;
} else {
rowKey = GRID.store.data.rawData[0]?.rowKey;
}
const rowDatas = GRID.store.data.rawData.map(d => {
return {tmplatId: '${ctznTmplatId}', answerSeCode: fnBiz.getAnswerSeCode(d.crdnSttsCd), resnCode: d.erppSeCode, interfaceSeqN: d.interfaceSeqN, vhrno: d.vhrno}
})
popupDiv = 'answerPreview';
NAV = new PageNavigation(GRID, rowDatas, rowKey);
fnBiz.pagePopup(popupDiv, pageNav.gridInfo.curRowData);
});
$('#btnAnswer').on('click', () => {
const arrChecks = GRID.getCheckedRows();
if(arrChecks.length === 0){
alert('답변 처리할 대상을 먼저 선택해 주세요');
return false;
}
const arrData = arrChecks.map((row) => {
return {
interfaceSeqN: row.interfaceSeqN
}
})
// 중복제거
const datas = arrData.reduce(function(acc, current) {
if (acc.findIndex(({ interfaceSeqN }) => interfaceSeqN === current.interfaceSeqN) === -1) {
acc.push(current.interfaceSeqN);
}
return acc;
}, []);
cmmAjax({
url: fimsApiUrl.ADD_CTZN_ANS_LIST
,contentType: 'application/json'
,data: JSON.stringify(datas)
,success: (res) => {
}
});
});
});
/* *******************************
* Grid
******************************* */
const gridColumns = [
{
header: '등록구분',
name: 'crdnRegSeCd',
minWidth: 50,
sortable: false,
align: 'center',
formatter({value}) {
return (new CodeFormat(ComboCodeData.crdnRegSeCd)).format(value);
}
},
{
header: '접수번호',
name: 'cvplRceptNo',
minWidth: 130,
sortable: false,
align: 'center',
renderer: {
type: CustomButtonRenderer,
options: {
formatter: (props)=>{
const rowData = props.grid.getRow(props.rowKey);
return {
formatter: rowData.crdnSeCd === '09' ? rowData.cvplRceptNo : rowData.fileLinkId
,element: "text"
,dataAttrs : {
bsToggle: "tooltip",
bsOffset: "0,4",
bsPlacement: "top",
bsHtml: "true"
}
,attrs : {
title : "<i class='bx bx-window bx-xs'></i> <span>단속현황 정보</span>"
}
}
}
,eventFunction: fnBiz.onClickGrid
,eventType: "click"
}
}
},
{
header: '차량번호',
name: 'vhrno',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '신고자',
name: 'cvplApplcntNm',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '단속구분(신고방법)',
name: 'crdnSeCd',
minWidth: 100,
sortable: false,
align: 'center',
formatter: 'listItemText',
disabled: true,
editor: {
type: "select",
options: {
listItems: [...ComboCodeData.crdnSeCd]
}
}
},
{
header: '위반내용',
name: 'vltnCn',
minWidth: 120,
sortable: false,
align: 'center'
},
{
header: '주민번호(전체)',
name: 'rtpyrNo',
minWidth: 110,
sortable: false,
align: 'center',
className: "privacy"
},
{
header: '주민번호(마스킹)',
name: 'rtpyrNoMask',
minWidth: 110,
sortable: false,
align: 'center',
className: "privacy-mask"
},
{
header: '담당자',
name: 'dutyIdV',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '전화번호',
name: 'pcdTelV',
minWidth: 80,
sortable: false,
align: 'center'
},
{
header: '접수일자',
name: 'cvplRceptDt',
minWidth: 80,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateFormat.format(value); //
}
},
{
header: '처리기한',
name: 'cvplProcessPd',
minWidth: 80,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateFormat.format(value); //
}
},
{
header: '위반일시',
name: 'crdnYmdTime',
minWidth: 120,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateTimeFormat.format(value); //
}
},
{
header: '사진건수',
name: 'atchFileCnt',
minWidth: 40,
sortable: false,
align: 'center'
},
{
header: '특기사항',
name: 'etcCn',
width: 80,
sortable: false,
align: 'center'
},
{
header: '서손사유',
name: 'erppResnDetail', //erppSeCode
width: 80,
sortable: false,
align: 'center'
},
{
header: '수납금액',
name: 'rcvmtAmt',
minWidth: 100,
sortable: false,
align: 'right'
},
{
header: '위반횟수',
name: 'vltnNmtm',
minWidth: 80,
sortable: false,
align: 'right'
},
{
header: '위반장소',
name: 'crdnPlc',
minWidth: 200,
sortable: false
},
{
header: '처리상태명',
name: 'crdnSttsNm',
hidden: true
},
{
header: '등록일시',
name: 'regDt',
minWidth: 150,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateTimeFormat.format(value); //
}
},
{
header: '최종처리일시',
name: 'mdfcnDt',
minWidth: 150,
sortable: false,
align: 'center',
formatter({value}) {
return StrDateTimeFormat.format(value);
}
},
{
header: '',
name: 'crdnSttsCd',
hidden: true
},
{
header: '서손ID',
name: 'erppId',
hidden: true
},
{
header: '소유자ID',
name: 'rtpyrId',
hidden: true
},
{
header: '서손사유코드',
name: 'erppSeCode',
hidden: true
},
{
header: 'interfaceSeqN',
name: 'interfaceSeqN',
hidden: true
}
];
const gridOptions = {
el: 'grid',
rowHeaders: ['rowNum'],
columns: gridColumns,
columnOptions: {
frozenCount: 6
},
paginationInfoRef : $$Control._paginationInfo
};
const initGrid = () => {
GRID = TuiGrid.of(gridOptions);
GRID.on('dblclick', function (props) { fnBiz.onDblClickGrid(props); });
};
/**************************************************************************
* initialize
**************************************************************************/
$(document).ready(function(){
$('#sch_date_from').datepicker('setDate', DateUtil.getDateDay(-5475).date);
$('#sch_date_to').datepicker('setDate', new Date());
CUR_TAB_IDX = 0;
fnBiz.resetBtn();
initGrid();
});
</script>

@ -1,14 +1,17 @@
<%--
================================================================================
File : /fims/biz/rt/rtInitialForm.jsp
Name : 단속 초기자료 - 단속관리 > 단속 초기자료
Auth : 이범준
Date : 2023-04-14
Desc : 단속 초기자료 메인 화면
================================================================================
Date Author Description
================================================================================
================================================================================
* <pre>
* description :
*
* packageName :
* fileName : rtInitialDataForm.jsp
* author : 이범준
* date : 2023-04-14
* ======================================================================
* 변경일 변경자 변경 내용
* ----------------------------------------------------------------------
* 2023-04-14 이범준 최초 생성
*
* </pre>
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>

@ -46,12 +46,10 @@
</tr>
<tr>
<th scope="row">
<label for="pgrmFileNm">프로그램파일명</label>
<label for="action">메뉴화면명</label>
</th>
<td colspan="3" nowrap="nowrap">
<form:input path="pgrmFileNm" cssStyle="width: 64%;" size="60" maxlength="60" title="프로그램파일명" readonly="true"/>
<a id="btnSchPgmPopup" href="#" title="프로그램조회" style="selector-dummy:expression(this.hideFocus=false);">
<img src="<c:url value='/resources/image/fims/framework/etc/img_search.gif' />" alt='프로그램파일명 검색' width="15" height="15"/></a>
</td>
</tr>
<tr>
@ -96,6 +94,16 @@
<form:errors path="dscrp"/>
</td>
</tr>
<tr>
<th scope="row">
<label for="pgrmFileNm">프로그램파일명</label>
</th>
<td colspan="3" nowrap="nowrap">
<form:input path="pgrmFileNm" cssStyle="width: 64%;" size="60" maxlength="60" title="프로그램파일명" readonly="true"/>
<a id="btnSchPgmPopup" href="#" title="프로그램조회" style="selector-dummy:expression(this.hideFocus=false);">
<img src="<c:url value='/resources/image/fims/framework/etc/img_search.gif' />" alt='프로그램파일명 검색' width="15" height="15"/></a>
</td>
</tr>
</tbody>
</table>
<%@include file="/WEB-INF/jsp/include/fims/btns-biz-popup.jsp" %>

Loading…
Cancel
Save