소스코드 정리

main
이범준 1 year ago
parent 90530ef3a4
commit 228052dc86

@ -152,12 +152,14 @@
**************************************************************************/
var FIM002 = new CommonCodes(${FIM002});
var FIM026 = new CommonCodes(${FIM026});
pageObject["${pageName}"] = {};
$(document).ready(function(){
pageObject['${pageName}'] = {};
var thisPO = pageObject["${pageName}"];
pageObject['${pageName}'].crdnControl = new DatasetControl({
thisPO.crdnControl = new DatasetControl({
prefix:"crdn",
prefixName:"종합",
infoSize:"xl",
@ -180,15 +182,15 @@ pageObject['${pageName}'].crdnControl = new DatasetControl({
keymapper:info => info ? info.CRDN_ID : "",
dataGetter:obj => obj.crdnList,
appendData:true
});
});
pageObject['${pageName}'].crdnControl.onDatasetChange = obj => {
thisPO.crdnControl.onDatasetChange = obj => {
var prefix = obj.infoPrefix;
pageObject['${pageName}'].renderCrdnList(obj);
thisPO.renderCrdnList(obj);
$("#crdnPaging--${pageName}").setPagingInfo({
list: pageObject['${pageName}'].crdnControl.dataset,
list: thisPO.crdnControl.dataset,
prefix: "crdn",
start: obj[prefix+"Start"],
totalSize: obj[prefix+"Total"],
@ -196,41 +198,41 @@ pageObject['${pageName}'].crdnControl.onDatasetChange = obj => {
func: "pageObject['${pageName}'].crdnControl.load({index})"
});
};
};
pageObject['${pageName}'].fnResetAndChangeBiz = sysSeCd => {
thisPO.fnResetAndChangeBiz = sysSeCd => {
$("#crdnTbody--${pageName}").html("");
pageObject['${pageName}'].crdnControl.urls.load = wctx.url("/crdn/crdn06/010/"+ sysSeCd +"/list.do");
pageObject['${pageName}'].crdnControl.urls.getInfo = wctx.url("/sprt/sprt01/020/"+ sysSeCd +"/info.do");
}
thisPO.crdnControl.urls.load = wctx.url("/crdn/crdn06/010/"+ sysSeCd +"/list.do");
thisPO.crdnControl.urls.getInfo = wctx.url("/sprt/sprt01/020/"+ sysSeCd +"/info.do");
}
pageObject['${pageName}'].searchCrdnList = () => {
pageObject['${pageName}'].crdnControl.query = pageObject['${pageName}'].getParams();
thisPO.searchCrdnList = () => {
thisPO.crdnControl.query = thisPO.getParams();
$("#crdnTbody--${pageName}").html("");
pageObject['${pageName}'].crdnControl.load(1);
}
thisPO.crdnControl.load(1);
}
pageObject['${pageName}'].scrollCrdnList = () => {
pageObject['${pageName}'].crdnControl.load(pageObject['${pageName}'].crdnControl.query.pageNum + 1);
}
thisPO.scrollCrdnList = () => {
thisPO.crdnControl.load(thisPO.crdnControl.query.pageNum + 1);
}
pageObject['${pageName}'].renderCrdnList = data => {
if(!pageObject['${pageName}'].crdnControl.appendData){
thisPO.renderCrdnList = data => {
if(!thisPO.crdnControl.appendData){
$("#crdnTbody--${pageName}").html("");
}
var crdnList = pageObject['${pageName}'].crdnControl.dataset;
var crdnList = thisPO.crdnControl.dataset;
var empty = crdnList.empty;
var trs = empty ? [ pageObject['${pageName}'].tbodyTemplate.notFound ] : crdnList.inStrings(pageObject['${pageName}'].tbodyTemplate.found);
var trs = empty ? [ thisPO.tbodyTemplate.notFound ] : crdnList.inStrings(thisPO.tbodyTemplate.found);
$("#crdnTbody--${pageName}").html(trs.join());
}
}
pageObject['${pageName}'].getParams = () => {
thisPO.getParams = () => {
var form = $("#frmSearch--${pageName}");
return {
@ -244,14 +246,14 @@ pageObject['${pageName}'].getParams = () => {
,ctznAnsYn: form.find("[name='ctznAnsYn']:checked").val()
,fetchSize: 30
};
}
}
/* *******************************
/* *******************************
* Grid
******************************* */
pageObject['${pageName}'].gridColumns = [
thisPO.gridColumns = [
{ header: '차량번호', name: 'VHRNO', width: 80, align: 'center' },
{ header: '단속구분(신고방법)', name: 'CRDN_SE_CD', width: 100, align: 'center' },
{ header: '위반일시', name: 'CRDN_YMD_TM', width: 120, align: 'center' },
@ -276,8 +278,8 @@ pageObject['${pageName}'].gridColumns = [
{ header: '소유자ID', name: 'RTPYR_ID', hidden: true },
{ header: '서손사유코드', name: 'LEVY_EXCL_RSN_CD', hidden: true },
{ header: 'interfaceSeqN', name: 'INTERFACE_SEQN', hidden: true }
];
pageObject['${pageName}'].gridOptions = {
];
thisPO.gridOptions = {
theadTr: 'crdnTheadTr--${pageName}',
rowHeader: 'No.',
trDataKey: 'CRDN_ID',
@ -285,15 +287,10 @@ pageObject['${pageName}'].gridOptions = {
prefixName : "단속",
clickEvent : "pageObject['${pageName}'].crdnControl.setCurrent('{CRDN_ID}')",
dblClickEvent : "pageObject['${pageName}'].crdnControl.getInfo({})",
columns: pageObject['${pageName}'].gridColumns
};
pageObject['${pageName}'].tbodyTemplate = {};
$(document).ready(function(){
columns: thisPO.gridColumns
};
var thisPO = pageObject['${pageName}'];
thisPO.tbodyTemplate = {};
//페이지로딩 후 초기화
thisPO.tbodyTemplate = initGrid(thisPO.gridOptions);

@ -152,12 +152,14 @@
**************************************************************************/
var FIM002 = new CommonCodes(${FIM002});
var FIM026 = new CommonCodes(${FIM026});
pageObject["${pageName}"] = {};
$(document).ready(function(){
pageObject['${pageName}'] = {};
var thisPO = pageObject["${pageName}"];
pageObject['${pageName}'].crdnControl = new DatasetControl({
thisPO.crdnControl = new DatasetControl({
prefix:"crdn",
prefixName:"종합",
infoSize:"xl",
@ -180,15 +182,15 @@ pageObject['${pageName}'].crdnControl = new DatasetControl({
keymapper:info => info ? info.CRDN_ID : "",
dataGetter:obj => obj.crdnList,
appendData:true
});
});
pageObject['${pageName}'].crdnControl.onDatasetChange = obj => {
thisPO.crdnControl.onDatasetChange = obj => {
var prefix = obj.infoPrefix;
pageObject['${pageName}'].renderCrdnList(obj);
thisPO.renderCrdnList(obj);
$("#crdnPaging--${pageName}").setPagingInfo({
list: pageObject['${pageName}'].crdnControl.dataset,
list: thisPO.crdnControl.dataset,
prefix: "crdn",
start: obj[prefix+"Start"],
totalSize: obj[prefix+"Total"],
@ -196,41 +198,41 @@ pageObject['${pageName}'].crdnControl.onDatasetChange = obj => {
func: "pageObject['${pageName}'].crdnControl.load({index})"
});
};
};
pageObject['${pageName}'].fnResetAndChangeBiz = sysSeCd => {
thisPO.fnResetAndChangeBiz = sysSeCd => {
$("#crdnTbody--${pageName}").html("");
pageObject['${pageName}'].crdnControl.urls.load = wctx.url("/crdn/crdn06/010/"+ sysSeCd +"/list.do");
pageObject['${pageName}'].crdnControl.urls.getInfo = wctx.url("/sprt/sprt01/020/"+ sysSeCd +"/info.do");
}
thisPO.crdnControl.urls.load = wctx.url("/crdn/crdn06/010/"+ sysSeCd +"/list.do");
thisPO.crdnControl.urls.getInfo = wctx.url("/sprt/sprt01/020/"+ sysSeCd +"/info.do");
}
pageObject['${pageName}'].searchCrdnList = () => {
pageObject['${pageName}'].crdnControl.query = pageObject['${pageName}'].getParams();
thisPO.searchCrdnList = () => {
thisPO.crdnControl.query = thisPO.getParams();
$("#crdnTbody--${pageName}").html("");
pageObject['${pageName}'].crdnControl.load(1);
}
thisPO.crdnControl.load(1);
}
pageObject['${pageName}'].scrollCrdnList = () => {
pageObject['${pageName}'].crdnControl.load(pageObject['${pageName}'].crdnControl.query.pageNum + 1);
}
thisPO.scrollCrdnList = () => {
thisPO.crdnControl.load(thisPO.crdnControl.query.pageNum + 1);
}
pageObject['${pageName}'].renderCrdnList = data => {
if(!pageObject['${pageName}'].crdnControl.appendData){
thisPO.renderCrdnList = data => {
if(!thisPO.crdnControl.appendData){
$("#crdnTbody--${pageName}").html("");
}
var crdnList = pageObject['${pageName}'].crdnControl.dataset;
var crdnList = thisPO.crdnControl.dataset;
var empty = crdnList.empty;
var trs = empty ? [ pageObject['${pageName}'].tbodyTemplate.notFound ] : crdnList.inStrings(pageObject['${pageName}'].tbodyTemplate.found);
var trs = empty ? [ thisPO.tbodyTemplate.notFound ] : crdnList.inStrings(thisPO.tbodyTemplate.found);
$("#crdnTbody--${pageName}").html(trs.join());
}
}
pageObject['${pageName}'].getParams = () => {
thisPO.getParams = () => {
var form = $("#frmSearch--${pageName}");
return {
@ -244,14 +246,14 @@ pageObject['${pageName}'].getParams = () => {
,ctznAnsYn: form.find("[name='ctznAnsYn']:checked").val()
,fetchSize: 30
};
}
}
/* *******************************
/* *******************************
* Grid
******************************* */
pageObject['${pageName}'].gridColumns = [
thisPO.gridColumns = [
{ header: '차량번호', name: 'VHRNO', width: 80, align: 'center' },
{ header: '단속구분(신고방법)', name: 'CRDN_SE_CD', width: 100, align: 'center' },
{ header: '위반일시', name: 'CRDN_YMD_TM', width: 120, align: 'center' },
@ -276,8 +278,8 @@ pageObject['${pageName}'].gridColumns = [
{ header: '소유자ID', name: 'RTPYR_ID', hidden: true },
{ header: '서손사유코드', name: 'LEVY_EXCL_RSN_CD', hidden: true },
{ header: 'interfaceSeqN', name: 'INTERFACE_SEQN', hidden: true }
];
pageObject['${pageName}'].gridOptions = {
];
thisPO.gridOptions = {
theadTr: 'crdnTheadTr--${pageName}',
rowHeader: 'No.',
trDataKey: 'CRDN_ID',
@ -285,15 +287,10 @@ pageObject['${pageName}'].gridOptions = {
prefixName : "단속",
clickEvent : "pageObject['${pageName}'].crdnControl.setCurrent('{CRDN_ID}')",
dblClickEvent : "pageObject['${pageName}'].crdnControl.getInfo({})",
columns: pageObject['${pageName}'].gridColumns
};
pageObject['${pageName}'].tbodyTemplate = {};
$(document).ready(function(){
columns: thisPO.gridColumns
};
var thisPO = pageObject['${pageName}'];
thisPO.tbodyTemplate = {};
//페이지로딩 후 초기화
thisPO.tbodyTemplate = initGrid(thisPO.gridOptions);

@ -1,2 +1,3 @@
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" session="false"%>
<%@ include file="/WEB-INF/jsp/include/taglib.jsp"%>
개별총정보 상세화면
Loading…
Cancel
Save