|
|
@ -406,17 +406,23 @@ $(document).ready(function(){
|
|
|
|
$P.photoInspectionControl.defaultFetchSize = FETCH_XS;
|
|
|
|
$P.photoInspectionControl.defaultFetchSize = FETCH_XS;
|
|
|
|
$P.photoInspectionControl.untilPageNum = 0;
|
|
|
|
$P.photoInspectionControl.untilPageNum = 0;
|
|
|
|
$P.photoInspectionControl.beforeCurrent = null;
|
|
|
|
$P.photoInspectionControl.beforeCurrent = null;
|
|
|
|
$P.photoInspectionControl.tableRenderComplete = false;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//동일차량검사 datasetControl 인스턴스
|
|
|
|
//동일차량검사 datasetControl 인스턴스
|
|
|
|
$P.sameVehicleControl = new InspectionControl({
|
|
|
|
$P.sameVehicleMainControl = new DatasetControl({
|
|
|
|
urls : { load : "", getInfo : "" },
|
|
|
|
urls : { load : "", getInfo : "" },
|
|
|
|
dataGetter : obj => obj["List"], appendData:true,
|
|
|
|
dataGetter : obj => obj["List"], appendData:true,
|
|
|
|
keymapper : info => info ? info.CRDN_ID_LIST : "",
|
|
|
|
keymapper : info => info ? info.CRDN_ID_LIST : "",
|
|
|
|
formats: { CRDN_CNT : numberFormat, FFNLG_CRDN_AMT : numberFormat }
|
|
|
|
formats: {
|
|
|
|
},
|
|
|
|
CRDN_CNT : numberFormat,
|
|
|
|
{
|
|
|
|
FFNLG_CRDN_AMT : numberFormat
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.defaultFetchSize = FETCH_XS;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.untilPageNum = 0;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl = new DatasetControl({
|
|
|
|
urls : { load : "", getInfo : "" },
|
|
|
|
urls : { load : "", getInfo : "" },
|
|
|
|
dataGetter : obj => obj["List"],
|
|
|
|
dataGetter : obj => obj["List"],
|
|
|
|
keymapper : info => info ? info.CRDN_ID : "",
|
|
|
|
keymapper : info => info ? info.CRDN_ID : "",
|
|
|
@ -426,13 +432,7 @@ $(document).ready(function(){
|
|
|
|
CRDN_STTS_CD : FIM010,
|
|
|
|
CRDN_STTS_CD : FIM010,
|
|
|
|
FFNLG_CRDN_AMT : numberFormat
|
|
|
|
FFNLG_CRDN_AMT : numberFormat
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
);
|
|
|
|
|
|
|
|
$P.sameVehicleControl.defaultFetchSize = FETCH_XS;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.untilPageNum = 0;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.beforeCurrent = null;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.tableRenderComplete = false;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.tableRenderComplete = false;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.getNext = (key) => {
|
|
|
|
$P.photoInspectionControl.getNext = (key) => {
|
|
|
|
|
|
|
|
|
|
|
@ -446,126 +446,61 @@ $(document).ready(function(){
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
/**************************************************************************
|
|
|
|
/**************************************************************************
|
|
|
|
* DatasetControl.on
|
|
|
|
* Dataset.on
|
|
|
|
**************************************************************************/
|
|
|
|
**************************************************************************/
|
|
|
|
$P.photoInspectionControl.onDatasetChange = (obj) => {
|
|
|
|
$P.photoInspectionControl.dataset.onDatasetChange = (obj) => {
|
|
|
|
|
|
|
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], "photoInspection");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#photoInspectionPaging--${pageName}").setPagingInfo({
|
|
|
|
var t = $P.getGridTemplate("photoInspection");
|
|
|
|
list : $P.photoInspectionControl.dataset,
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.photoInspectionControl.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
prefix : "photoInspectionPaging--${pageName}",
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.photoInspectionControl.dataset.length, trs, "photoInspection");
|
|
|
|
totalSize : obj["Total"]
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.tableRenderComplete = true;
|
|
|
|
Apply.fromDataset.paging($P.photoInspectionControl.dataset, obj, "photoInspectionPaging--${pageName}");
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.onCurrentChange = (DI) => {
|
|
|
|
$P.photoInspectionControl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
|
|
|
Apply.fromDataset.currentRow($P.photoInspectionControl.dataset, dataItem, $("#photoInspectionTbody--${pageName}")[0]);
|
|
|
|
if(!$P.photoInspectionControl.tableRenderComplete){
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.photoInspectionControl.beforeCurrent != null){
|
|
|
|
|
|
|
|
var beforeCurrentKey = $P.photoInspectionControl.beforeCurrent.key;
|
|
|
|
|
|
|
|
var beforeCurrentIndex = $P.photoInspectionControl.beforeCurrent.index;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var dataKey = "";
|
|
|
|
|
|
|
|
var curDataVhrno = "";
|
|
|
|
|
|
|
|
var nextDataKey = "";
|
|
|
|
|
|
|
|
var nextDataVhrno = "";
|
|
|
|
if(!$P.photoInspectionControl.dataset.empty){
|
|
|
|
if(!$P.photoInspectionControl.dataset.empty){
|
|
|
|
var info = $P.photoInspectionControl.dataset.getData(beforeCurrentKey);
|
|
|
|
dataKey = $P.photoInspectionControl.dataset.getKey(dataItem);
|
|
|
|
|
|
|
|
curDataVhrno = $P.photoInspectionControl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
if(info != null){
|
|
|
|
var nextData = $P.photoInspectionControl.getNext(dataKey);
|
|
|
|
$P.photoInspectionControl.dataset.setCurrent(beforeCurrentKey, true);
|
|
|
|
nextDataKey = nextData != null ? nextData.CRDN_ID : "";
|
|
|
|
return;
|
|
|
|
nextDataVhrno = nextData != null ? nextData.VHRNO : "";
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(beforeCurrentIndex > ($P.photoInspectionControl.dataset.length - 1)){
|
|
|
|
|
|
|
|
info = $P.photoInspectionControl.dataset.getDataset()[$P.photoInspectionControl.dataset.length - 1];
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
info = $P.photoInspectionControl.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.dataset.setCurrent(info["CRDN_ID"], true);
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.tableRenderComplete = false;
|
|
|
|
$P.showPhoto(dataKey,nextDataKey,curDataVhrno,nextDataVhrno);
|
|
|
|
if(!DI){
|
|
|
|
|
|
|
|
$P.clickInspectionDataList("","photoInspection", true);
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
$P.clickInspectionDataList($P.photoInspectionControl.getCurrent()["CRDN_ID"],"photoInspection", true);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.onDatasetChange = (obj) => {
|
|
|
|
$P.sameVehicleMainControl.dataset.onDatasetChange = (obj) => {
|
|
|
|
|
|
|
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], "sameVehicleInspectionMain");
|
|
|
|
var t = $P.getGridTemplate("sameVehicleInspectionMain");
|
|
|
|
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.sameVehicleMainControl.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.sameVehicleMainControl.dataset.length, trs, "sameVehicleInspectionMain");
|
|
|
|
|
|
|
|
|
|
|
|
$("#sameVehicleInspectionMainPaging--${pageName}").setPagingInfo({
|
|
|
|
Apply.fromDataset.paging($P.sameVehicleMainControl.dataset, obj, "sameVehicleInspectionMainPaging--${pageName}");
|
|
|
|
list : $P.sameVehicleControl.main.dataset,
|
|
|
|
|
|
|
|
prefix : "sameVehicleInspectionMainPaging--${pageName}",
|
|
|
|
|
|
|
|
totalSize : obj["Total"]
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.tableRenderComplete = true;
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.onCurrentChange = (DI) => {
|
|
|
|
$P.sameVehicleMainControl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
if(!$P.sameVehicleControl.main.tableRenderComplete){
|
|
|
|
Apply.fromDataset.currentRow($P.sameVehicleMainControl.dataset, dataItem, $("#sameVehicleInspectionMainTbody--${pageName}")[0]);
|
|
|
|
return;
|
|
|
|
if(dataItem){
|
|
|
|
}
|
|
|
|
$P.searchDetailInspectionDataList(dataItem.data["CRDN_ID_LIST"]);
|
|
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleControl.main.beforeCurrent != null){
|
|
|
|
|
|
|
|
var beforeCurrentKey = $P.sameVehicleControl.main.beforeCurrent.key;
|
|
|
|
|
|
|
|
var beforeCurrentIndex = $P.sameVehicleControl.main.beforeCurrent.index;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(!$P.sameVehicleControl.main.dataset.empty){
|
|
|
|
|
|
|
|
var info = $P.sameVehicleControl.main.dataset.getData(beforeCurrentKey);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(info != null){
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.dataset.setCurrent(beforeCurrentKey,true);
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(beforeCurrentIndex > ($P.sameVehicleControl.main.dataset.length - 1)){
|
|
|
|
|
|
|
|
info = $P.sameVehicleControl.main.dataset.getDataset()[$P.sameVehicleControl.main.dataset.length - 1];
|
|
|
|
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
info = $P.sameVehicleControl.main.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
$("#sameVehicleInspectionSubTbody--${pageName}").html("");
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.dataset.setCurrent(info["CRDN_ID_LIST"],true);
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.tableRenderComplete = false;
|
|
|
|
|
|
|
|
if(!DI){
|
|
|
|
|
|
|
|
$P.clickInspectionDataList("","sameVehicleInspectionMain", true);
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
$P.clickInspectionDataList($P.sameVehicleControl.main.getCurrent()["CRDN_ID_LIST"],"sameVehicleInspectionMain", true);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.onDatasetChange = (obj) => {
|
|
|
|
$P.sameVehicleSubControl.dataset.onDatasetChange = (obj) => {
|
|
|
|
$P.renderInspectionDataList(obj["Total"], "sameVehicleInspectionSub");
|
|
|
|
var t = $P.getGridTemplate("sameVehicleInspectionSub");
|
|
|
|
$P.sameVehicleControl.sub.tableRenderComplete = true;
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.sameVehicleSubControl.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.sameVehicleSubControl.dataset.length, trs, "sameVehicleInspectionSub");
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.onCurrentChange = (DI) => {
|
|
|
|
$P.sameVehicleSubControl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
if(!$P.sameVehicleControl.sub.tableRenderComplete){
|
|
|
|
Apply.fromDataset.currentRow($P.sameVehicleSubControl.dataset, dataItem, $("#sameVehicleInspectionSubTbody--${pageName}")[0]);
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.tableRenderComplete = false;
|
|
|
|
|
|
|
|
if(!DI){
|
|
|
|
|
|
|
|
$P.clickInspectionDataList("","sameVehicleInspectionSub", true);
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
$P.clickInspectionDataList($P.sameVehicleControl.sub.getCurrent()["CRDN_ID"],"sameVehicleInspectionSub", true);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
/**************************************************************************
|
|
|
@ -583,17 +518,17 @@ $(document).ready(function(){
|
|
|
|
$('#schCrdnYmdFrom--${pageName}').datepicker('setDate', DateUtil.getDateDay(-7).date);
|
|
|
|
$('#schCrdnYmdFrom--${pageName}').datepicker('setDate', DateUtil.getDateDay(-7).date);
|
|
|
|
$('#schCrdnYmdTo--${pageName}').datepicker('setDate', new Date());
|
|
|
|
$('#schCrdnYmdTo--${pageName}').datepicker('setDate', new Date());
|
|
|
|
$P.photoInspectionControl.setData([]);
|
|
|
|
$P.photoInspectionControl.setData([]);
|
|
|
|
$P.sameVehicleControl.main.setData([]);
|
|
|
|
$P.sameVehicleMainControl.setData([]);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
$P.fnResetAndChangeBiz = (taskSeCd) => {
|
|
|
|
$P.fnResetAndChangeBiz = (taskSeCd) => {
|
|
|
|
$P.fnReset();
|
|
|
|
$P.fnReset();
|
|
|
|
$P.photoInspectionControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
$P.photoInspectionControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
$P.photoInspectionControl.urls.getInfo = "";
|
|
|
|
$P.photoInspectionControl.urls.getInfo = "";
|
|
|
|
$P.sameVehicleControl.main.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
$P.sameVehicleMainControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
$P.sameVehicleControl.main.urls.getInfo = "";
|
|
|
|
$P.sameVehicleMainControl.urls.getInfo = "";
|
|
|
|
$P.sameVehicleControl.sub.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
$P.sameVehicleSubControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
$P.sameVehicleControl.sub.urls.getInfo = "";
|
|
|
|
$P.sameVehicleSubControl.urls.getInfo = "";
|
|
|
|
|
|
|
|
|
|
|
|
var clsForTask = taskSeCd.toLowerCase();
|
|
|
|
var clsForTask = taskSeCd.toLowerCase();
|
|
|
|
//업무별 조회조건
|
|
|
|
//업무별 조회조건
|
|
|
@ -607,29 +542,17 @@ $(document).ready(function(){
|
|
|
|
$('#btnPhotoInspection--${pageName}').trigger("click");
|
|
|
|
$('#btnPhotoInspection--${pageName}').trigger("click");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.getParams = () => {
|
|
|
|
|
|
|
|
var formFields = new FimsFormFields("#frmSearch--${pageName}");
|
|
|
|
|
|
|
|
var data = formFields.get();
|
|
|
|
|
|
|
|
|
|
|
|
$P.refreshInspectionList = () => {
|
|
|
|
if($P.currentDisplay == "photoInspection"){
|
|
|
|
switch ($P.currentDisplay) {
|
|
|
|
data.fetchSize = $P.photoInspectionControl.defaultFetchSize;
|
|
|
|
case "photoInspection":
|
|
|
|
} else if($P.currentDisplay == "sameVehicleInspection"){
|
|
|
|
$P.photoInspectionControl.untilPageNum = $P.photoInspectionControl.query.pageNum;
|
|
|
|
data.fetchSize = $P.sameVehicleMainControl.defaultFetchSize;
|
|
|
|
$P.photoInspectionControl.query.fetchSize = $P.photoInspectionControl.defaultFetchSize * $P.photoInspectionControl.query.pageNum;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.beforeCurrent = {
|
|
|
|
|
|
|
|
key : $P.photoInspectionControl.getCurrent()["CRDN_ID"],
|
|
|
|
|
|
|
|
index : $P.photoInspectionControl.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
$P.photoInspectionControl.load(1);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
|
|
|
|
$P.sameVehicleControl.untilPageNum = $P.sameVehicleControl.main.query.pageNum;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.query.fetchSize = $P.sameVehicleControl.defaultFetchSize * $P.sameVehicleControl.main.query.pageNum;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.beforeCurrent = {
|
|
|
|
|
|
|
|
key : $P.sameVehicleControl.main.getCurrent()["CRDN_ID_LIST"],
|
|
|
|
|
|
|
|
index : $P.sameVehicleControl.main.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.load(1);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
default: break;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return data;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.searchInspectionList = () => {
|
|
|
|
$P.searchInspectionList = () => {
|
|
|
@ -640,19 +563,20 @@ $(document).ready(function(){
|
|
|
|
$P.photoInspectionControl.load(1);
|
|
|
|
$P.photoInspectionControl.load(1);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
$P.sameVehicleControl.main.query = $P.getParams();
|
|
|
|
$P.sameVehicleMainControl.query = $P.getParams();
|
|
|
|
$P.sameVehicleControl.main.query.inspectionDataType = "sameVehicleMain";
|
|
|
|
$P.sameVehicleMainControl.query.inspectionDataType = "sameVehicleMain";
|
|
|
|
$P.sameVehicleControl.main.load(1);
|
|
|
|
$P.sameVehicleMainControl.load(1);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
default: break;
|
|
|
|
default: break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.searchDetailInspectionDataList = (dataKey) => {
|
|
|
|
$P.searchDetailInspectionDataList = (dataKey) => {
|
|
|
|
$P.sameVehicleControl.sub.query = {};
|
|
|
|
$P.sameVehicleSubControl.query = {};
|
|
|
|
$P.sameVehicleControl.sub.query.inspectionDataType = "sameVehicleSub";
|
|
|
|
$P.sameVehicleSubControl.query.inspectionDataType = "sameVehicleSub";
|
|
|
|
$P.sameVehicleControl.sub.query.crdnIDs = dataKey;
|
|
|
|
$P.sameVehicleSubControl.query.crdnIDs = dataKey;
|
|
|
|
$P.sameVehicleControl.sub.query.taskSeCd = $P.sameVehicleControl.main.query.taskSeCd;
|
|
|
|
$P.sameVehicleSubControl.query.taskSeCd = $P.sameVehicleMainControl.query.taskSeCd;
|
|
|
|
$P.sameVehicleControl.sub.load(0);
|
|
|
|
$P.sameVehicleSubControl.load(0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.scrollInspectionDataList = () => {
|
|
|
|
$P.scrollInspectionDataList = () => {
|
|
|
@ -661,91 +585,252 @@ $(document).ready(function(){
|
|
|
|
$P.photoInspectionControl.load($P.photoInspectionControl.query.pageNum + 1);
|
|
|
|
$P.photoInspectionControl.load($P.photoInspectionControl.query.pageNum + 1);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
$P.sameVehicleControl.main.load($P.sameVehicleControl.main.query.pageNum + 1);
|
|
|
|
$P.sameVehicleMainControl.load($P.sameVehicleMainControl.query.pageNum + 1);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
default: break;
|
|
|
|
default: break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$P.clickInspectionDataList = (dataKey, gridType, auto) => {
|
|
|
|
|
|
|
|
switch (gridType) {
|
|
|
|
$P.refreshInspectionList = () => {
|
|
|
|
|
|
|
|
switch ($P.currentDisplay) {
|
|
|
|
case "photoInspection":
|
|
|
|
case "photoInspection":
|
|
|
|
|
|
|
|
$P.photoInspectionControl.untilPageNum = $P.photoInspectionControl.query.pageNum;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.fetchSize = $P.photoInspectionControl.defaultFetchSize * $P.photoInspectionControl.query.pageNum;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.beforeCurrent = {
|
|
|
|
|
|
|
|
key : $P.photoInspectionControl.getCurrent()["CRDN_ID"],
|
|
|
|
|
|
|
|
index : $P.photoInspectionControl.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
if(dataKey == ""){
|
|
|
|
Apply.fromDatasetControl.load($P.photoInspectionControl, 1).then((resp)=>{
|
|
|
|
$("#curDataVhrno--${pageName}").html("");
|
|
|
|
Apply.toDataset.set($P.photoInspectionControl.dataset, resp);
|
|
|
|
$("#nextDataVhrno--${pageName}").html("");
|
|
|
|
$P.photoInspectionControl.dataset.onDatasetChange(resp);
|
|
|
|
$("#curDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
$("#nextDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#photoInspectionTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
if($P.photoInspectionControl.untilPageNum != 0){
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.fetchSize = $P.photoInspectionControl.defaultFetchSize;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.pageNum = $P.photoInspectionControl.untilPageNum;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.untilPageNum = 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
var curDataVhrno = $P.photoInspectionControl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
if($P.photoInspectionControl.beforeCurrent != null){
|
|
|
|
var nextData = $P.photoInspectionControl.getNext(dataKey);
|
|
|
|
var beforeCurrentKey = $P.photoInspectionControl.beforeCurrent.key;
|
|
|
|
var nextDataKey = nextData != null ? nextData.CRDN_ID : "";
|
|
|
|
var beforeCurrentIndex = $P.photoInspectionControl.beforeCurrent.index;
|
|
|
|
var nextDataVhrno = nextData != null ? nextData.VHRNO : "";
|
|
|
|
$P.photoInspectionControl.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
|
|
$("#curDataVhrno--${pageName}").html(curDataVhrno);
|
|
|
|
if(!$P.photoInspectionControl.dataset.empty){
|
|
|
|
$("#nextDataVhrno--${pageName}").html(nextDataVhrno);
|
|
|
|
var info = $P.photoInspectionControl.dataset.getData(beforeCurrentKey);
|
|
|
|
|
|
|
|
|
|
|
|
ajax.get({
|
|
|
|
if(info != null){
|
|
|
|
url:"file/list.do",
|
|
|
|
$P.photoInspectionControl.dataset.setCurrent(beforeCurrentKey, true);
|
|
|
|
data: {
|
|
|
|
|
|
|
|
infoType : "100",
|
|
|
|
|
|
|
|
infoKeys : [dataKey, nextDataKey],
|
|
|
|
|
|
|
|
fetchSize : 0
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
success : resp => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var fileList = resp.fileList;
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
|
|
var currentDataFileList = fileList.filter(x => x.INF_KEY == dataKey);
|
|
|
|
if(beforeCurrentIndex > ($P.photoInspectionControl.dataset.length - 1)){
|
|
|
|
var nextDataFileList = fileList.filter(x => x.INF_KEY == nextDataKey);
|
|
|
|
info = $P.photoInspectionControl.dataset.getDataset()[$P.photoInspectionControl.dataset.length - 1];
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
info = $P.photoInspectionControl.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$("#curDataFiles--${pageName}").html("");
|
|
|
|
$P.photoInspectionControl.dataset.setCurrent(info["CRDN_ID"], true);
|
|
|
|
$("#nextDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
currentDataFileList.forEach(function(item, index, array){
|
|
|
|
}
|
|
|
|
var output = fnMakeImgTagForInspection(item.URL, item.FILE_NM,"cur"+item.FILE_ID+'${pageName}',item.MOSAIC);
|
|
|
|
}
|
|
|
|
$("#curDataFiles--${pageName}").append(output);
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
|
|
|
nextDataFileList.forEach(function(item, index, array){
|
|
|
|
|
|
|
|
var output = fnMakeImgTagForInspection(item.URL, item.FILE_NM,"next"+item.FILE_ID+'${pageName}',item.MOSAIC);
|
|
|
|
|
|
|
|
$("#nextDataFiles--${pageName}").append(output);
|
|
|
|
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.untilPageNum = $P.sameVehicleMainControl.query.pageNum;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.query.fetchSize = $P.sameVehicleMainControl.defaultFetchSize * $P.sameVehicleMainControl.query.pageNum;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.beforeCurrent = {
|
|
|
|
|
|
|
|
key : $P.sameVehicleMainControl.getCurrent()["CRDN_ID_LIST"],
|
|
|
|
|
|
|
|
index : $P.sameVehicleMainControl.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Apply.fromDatasetControl.load($P.sameVehicleMainControl, 1).then((resp)=>{
|
|
|
|
|
|
|
|
Apply.toDataset.set($P.sameVehicleMainControl.dataset, resp);
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.dataset.onDatasetChange(resp);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleMainControl.untilPageNum != 0){
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.query.fetchSize = $P.sameVehicleMainControl.defaultFetchSize;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.query.pageNum = $P.sameVehicleMainControl.untilPageNum;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.untilPageNum = 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleMainControl.beforeCurrent != null){
|
|
|
|
|
|
|
|
var beforeCurrentKey = $P.sameVehicleMainControl.beforeCurrent.key;
|
|
|
|
|
|
|
|
var beforeCurrentIndex = $P.sameVehicleMainControl.beforeCurrent.index;
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(!$P.sameVehicleMainControl.dataset.empty){
|
|
|
|
|
|
|
|
var info = $P.sameVehicleMainControl.dataset.getData(beforeCurrentKey);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(info != null){
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.dataset.setCurrent(beforeCurrentKey,true);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
if(beforeCurrentIndex > ($P.sameVehicleMainControl.dataset.length - 1)){
|
|
|
|
|
|
|
|
info = $P.sameVehicleMainControl.dataset.getDataset()[$P.sameVehicleMainControl.dataset.length - 1];
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
info = $P.sameVehicleMainControl.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.dataset.setCurrent(info["CRDN_ID_LIST"],true);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
if(!auto){
|
|
|
|
break;
|
|
|
|
$P.photoInspectionControl.setCurrent(dataKey);
|
|
|
|
default: break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.fnExcelDown = () => {
|
|
|
|
|
|
|
|
if($P.currentDisplay == "photoInspection"){
|
|
|
|
|
|
|
|
if($P.photoInspectionControl.dataset.empty){
|
|
|
|
|
|
|
|
alert("조회된 자료가 없습니다.");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs($("#photoInspection_Table_0--${pageName} thead th").not(".dummy-th").not(":eq(0)"),
|
|
|
|
|
|
|
|
$($("#photoInspectionRow--${pageName}")[0].content).find("td").not(".dummy-td").not(":eq(0)"));
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.download();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleMainControl.dataset.empty){
|
|
|
|
|
|
|
|
alert("조회된 자료가 없습니다.");
|
|
|
|
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(confirm("단속건수 엑셀저장은 확인버튼, 상세내역 엑셀저장시 취소버튼을 누르세요.")){
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs($("#sameVehicleInspectionMain_Table_0--${pageName} thead th").not(".dummy-th"),
|
|
|
|
|
|
|
|
$($("#sameVehicleInspectionMainRow--${pageName}")[0].content).find("td").not(".dummy-td"));
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.download();
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs($("#sameVehicleInspectionSub_Table_0--${pageName} thead th").not(".dummy-th").not(":hidden"),
|
|
|
|
|
|
|
|
$($("#sameVehicleInspectionSubRow--${pageName}")[0].content).find("td").not(".dummy-td").not(".privacy-mask"));
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl.download();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.getGridTemplate = (gridType) => {
|
|
|
|
|
|
|
|
var notFound;
|
|
|
|
|
|
|
|
var found;
|
|
|
|
|
|
|
|
var replacer;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
switch (gridType) {
|
|
|
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
|
|
|
notFound = [document.getElementById("photoInspectionNotFound--${pageName}").innerHTML]
|
|
|
|
|
|
|
|
found = document.getElementById("photoInspectionRow--${pageName}").innerHTML;
|
|
|
|
|
|
|
|
replacer = (str, dataItem) => str
|
|
|
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].clickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','photoInspection');")
|
|
|
|
|
|
|
|
.replace(/{ondblclick}/gi, "pageObject['${pageName}'].dblclickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','photoInspection');");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspectionMain":
|
|
|
|
|
|
|
|
notFound = [document.getElementById("sameVehicleInspectionMainNotFound--${pageName}").innerHTML];
|
|
|
|
|
|
|
|
found = document.getElementById("sameVehicleInspectionMainRow--${pageName}").innerHTML;
|
|
|
|
|
|
|
|
replacer = (str, dataItem) => str
|
|
|
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].clickInspectionDataList('" + dataItem.getValue("CRDN_ID_LIST") + "','sameVehicleInspectionMain');");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspectionSub":
|
|
|
|
|
|
|
|
notFound = [document.getElementById("sameVehicleInspectionSubNotFound--${pageName}").innerHTML]
|
|
|
|
|
|
|
|
found = document.getElementById("sameVehicleInspectionSubRow--${pageName}").innerHTML;
|
|
|
|
|
|
|
|
replacer = (str, dataItem) => str
|
|
|
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].clickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','sameVehicleInspectionSub');")
|
|
|
|
|
|
|
|
.replace(/{ondblclick}/gi, "pageObject['${pageName}'].dblclickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','sameVehicleInspectionSub');");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
found : found,
|
|
|
|
|
|
|
|
notFound : notFound,
|
|
|
|
|
|
|
|
replacer : replacer
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.renderInspectionDataList = (total, listLength, trs, renderDataType) => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
switch (renderDataType) {
|
|
|
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
|
|
|
var noMore = (total == listLength);
|
|
|
|
|
|
|
|
var initScroll = ($P.photoInspectionControl.query.pageNum < 2) && ($P.photoInspectionControl.untilPageNum == 0);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#photoInspection-responsive--${pageName}")[0].changeContent(trs, initScroll, noMore);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspectionMain":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var noMore = (total == listLength);
|
|
|
|
|
|
|
|
var initScroll = ($P.sameVehicleMainControl.query.pageNum < 2) && ($P.sameVehicleMainControl.untilPageNum == 0);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#sameVehicleInspectionMain-responsive--${pageName}")[0].changeContent(trs, initScroll, noMore);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspectionSub":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#sameVehicleInspectionSubTbody--${pageName}").html(trs);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
default: break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//보안모드
|
|
|
|
|
|
|
|
fn_securityModeToggle($("#securityMode--top").is(":checked"));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.clickInspectionDataList = (dataKey, gridType) => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
switch (gridType) {
|
|
|
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(dataKey != ""){
|
|
|
|
|
|
|
|
$("#photoInspectionTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
|
|
|
|
Apply.toDataset.current($P.photoInspectionControl.dataset, dataKey);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var curDataVhrno = $P.photoInspectionControl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
|
|
|
|
var nextData = $P.photoInspectionControl.getNext(dataKey);
|
|
|
|
|
|
|
|
var nextDataKey = nextData != null ? nextData.CRDN_ID : "";
|
|
|
|
|
|
|
|
var nextDataVhrno = nextData != null ? nextData.VHRNO : "";
|
|
|
|
|
|
|
|
$P.showPhoto(dataKey,nextDataKey,curDataVhrno,nextDataVhrno);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case "sameVehicleInspectionMain":
|
|
|
|
case "sameVehicleInspectionMain":
|
|
|
|
if(dataKey == ""){
|
|
|
|
if(dataKey == ""){
|
|
|
|
$P.sameVehicleControl.sub.setData([]);
|
|
|
|
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$("#sameVehicleInspectionMainTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
$("#sameVehicleInspectionMainTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Apply.toDataset.current($P.sameVehicleMainControl.dataset, dataKey);
|
|
|
|
|
|
|
|
|
|
|
|
$P.searchDetailInspectionDataList(dataKey);
|
|
|
|
$P.searchDetailInspectionDataList(dataKey);
|
|
|
|
if(!auto){
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.setCurrent(dataKey);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case "sameVehicleInspectionSub":
|
|
|
|
case "sameVehicleInspectionSub":
|
|
|
|
if(dataKey == ""){
|
|
|
|
if(dataKey == ""){
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$("#sameVehicleInspectionSubTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
$("#sameVehicleInspectionSubTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
if(!auto){
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.setCurrent(dataKey);
|
|
|
|
Apply.toDataset.current($P.sameVehicleSubControl.dataset, dataKey);
|
|
|
|
}
|
|
|
|
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.dblclickInspectionDataList = (dataKey, gridType) => {
|
|
|
|
$P.dblclickInspectionDataList = (dataKey) => {
|
|
|
|
|
|
|
|
|
|
|
|
var taskSeCd = $("#frmSearch--${pageName} input[name='taskSeCd']:checked").val();
|
|
|
|
var taskSeCd = $("#frmSearch--${pageName} input[name='taskSeCd']:checked").val();
|
|
|
|
|
|
|
|
|
|
|
@ -759,7 +844,7 @@ $(document).ready(function(){
|
|
|
|
ajax.get({
|
|
|
|
ajax.get({
|
|
|
|
url : dialogUrl,
|
|
|
|
url : dialogUrl,
|
|
|
|
data : params,
|
|
|
|
data : params,
|
|
|
|
success : resp => {
|
|
|
|
success : (resp) => {
|
|
|
|
|
|
|
|
|
|
|
|
dialog.open({
|
|
|
|
dialog.open({
|
|
|
|
id : "totalInfoMainDialog",
|
|
|
|
id : "totalInfoMainDialog",
|
|
|
@ -771,13 +856,56 @@ $(document).ready(function(){
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.showPhoto = (dataKey, nextDataKey, curDataVhrno, nextDataVhrno) => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(dataKey == ""){
|
|
|
|
|
|
|
|
$("#curDataVhrno--${pageName}").html("");
|
|
|
|
|
|
|
|
$("#nextDataVhrno--${pageName}").html("");
|
|
|
|
|
|
|
|
$("#curDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
$("#nextDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#curDataVhrno--${pageName}").html(curDataVhrno);
|
|
|
|
|
|
|
|
$("#nextDataVhrno--${pageName}").html(nextDataVhrno);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ajax.get({
|
|
|
|
|
|
|
|
url:"file/list.do",
|
|
|
|
|
|
|
|
data: {
|
|
|
|
|
|
|
|
infoType : "100",
|
|
|
|
|
|
|
|
infoKeys : [dataKey, nextDataKey],
|
|
|
|
|
|
|
|
fetchSize : 0
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
success : (resp) => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var fileList = resp.fileList;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var currentDataFileList = fileList.filter(x => x.INF_KEY == dataKey);
|
|
|
|
|
|
|
|
var nextDataFileList = fileList.filter(x => x.INF_KEY == nextDataKey);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#curDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
$("#nextDataFiles--${pageName}").html("");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
currentDataFileList.forEach(function(item, index, array){
|
|
|
|
|
|
|
|
var output = fnMakeImgTagForInspection(item.URL, item.FILE_NM,"cur"+item.FILE_ID+'${pageName}',item.MOSAIC);
|
|
|
|
|
|
|
|
$("#curDataFiles--${pageName}").append(output);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
nextDataFileList.forEach(function(item, index, array){
|
|
|
|
|
|
|
|
var output = fnMakeImgTagForInspection(item.URL, item.FILE_NM,"next"+item.FILE_ID+'${pageName}',item.MOSAIC);
|
|
|
|
|
|
|
|
$("#nextDataFiles--${pageName}").append(output);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.openLevyExclPop = (levyExclSeCd) => {
|
|
|
|
$P.openLevyExclPop = (levyExclSeCd) => {
|
|
|
|
var info = "";
|
|
|
|
var info = "";
|
|
|
|
|
|
|
|
|
|
|
|
if ($P.currentDisplay == "photoInspection") {
|
|
|
|
if ($P.currentDisplay == "photoInspection") {
|
|
|
|
info = $P.photoInspectionControl.dataset.getCurrent("item");
|
|
|
|
info = $P.photoInspectionControl.dataset.getCurrent("item");
|
|
|
|
} else if ($P.currentDisplay == "sameVehicleInspection") {
|
|
|
|
} else if ($P.currentDisplay == "sameVehicleInspection") {
|
|
|
|
info = $P.sameVehicleControl.sub.dataset.getCurrent("item");
|
|
|
|
info = $P.sameVehicleSubControl.dataset.getCurrent("item");
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -798,7 +926,7 @@ $(document).ready(function(){
|
|
|
|
ajax.get({
|
|
|
|
ajax.get({
|
|
|
|
url : wctx.url(taskSeCd + "/excl/excl01/020/info.do"),
|
|
|
|
url : wctx.url(taskSeCd + "/excl/excl01/020/info.do"),
|
|
|
|
data : params,
|
|
|
|
data : params,
|
|
|
|
success : resp => {
|
|
|
|
success : (resp) => {
|
|
|
|
|
|
|
|
|
|
|
|
if((typeof resp) != "string"){
|
|
|
|
if((typeof resp) != "string"){
|
|
|
|
dialog.alert({
|
|
|
|
dialog.alert({
|
|
|
@ -844,7 +972,7 @@ $(document).ready(function(){
|
|
|
|
ajax.get({
|
|
|
|
ajax.get({
|
|
|
|
url : wctx.url("/PVS/crdn/crdn02/050/info.do"),
|
|
|
|
url : wctx.url("/PVS/crdn/crdn02/050/info.do"),
|
|
|
|
data : params,
|
|
|
|
data : params,
|
|
|
|
success : resp => {
|
|
|
|
success : (resp) => {
|
|
|
|
|
|
|
|
|
|
|
|
if((typeof resp) != "string"){
|
|
|
|
if((typeof resp) != "string"){
|
|
|
|
dialog.alert({
|
|
|
|
dialog.alert({
|
|
|
@ -874,81 +1002,6 @@ $(document).ready(function(){
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$P.renderInspectionDataList = (total, renderDataType) => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
switch (renderDataType) {
|
|
|
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
|
|
|
var DS = $P.photoInspectionControl.dataset;
|
|
|
|
|
|
|
|
var empty = DS.empty;
|
|
|
|
|
|
|
|
var notFound = [document.getElementById("photoInspectionNotFound--${pageName}").innerHTML]
|
|
|
|
|
|
|
|
var found = document.getElementById("photoInspectionRow--${pageName}").innerHTML;
|
|
|
|
|
|
|
|
var replacer = (str, dataItem) => str
|
|
|
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].clickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','photoInspection');")
|
|
|
|
|
|
|
|
.replace(/{ondblclick}/gi, "pageObject['${pageName}'].dblclickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','photoInspection');");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var trs = empty ? notFound : DS.inStrings(found, replacer);
|
|
|
|
|
|
|
|
var noMore = (total == DS.length);
|
|
|
|
|
|
|
|
var initScroll = ($P.photoInspectionControl.query.pageNum < 2) && ($P.photoInspectionControl.untilPageNum == 0);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#photoInspection-responsive--${pageName}")[0].changeContent(trs.join(), initScroll, noMore);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.photoInspectionControl.untilPageNum != 0){
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.fetchSize = $P.photoInspectionControl.defaultFetchSize;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.pageNum = $P.photoInspectionControl.untilPageNum;
|
|
|
|
|
|
|
|
$P.photoInspectionControl.untilPageNum = 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspectionMain":
|
|
|
|
|
|
|
|
var DS = $P.sameVehicleControl.main.dataset;
|
|
|
|
|
|
|
|
var empty = DS.empty;
|
|
|
|
|
|
|
|
var notFound = [document.getElementById("sameVehicleInspectionMainNotFound--${pageName}").innerHTML];
|
|
|
|
|
|
|
|
var found = document.getElementById("sameVehicleInspectionMainRow--${pageName}").innerHTML;
|
|
|
|
|
|
|
|
var replacer = (str, dataItem) => str
|
|
|
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].clickInspectionDataList('" + dataItem.getValue("CRDN_ID_LIST") + "','sameVehicleInspectionMain');");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var trs = empty ? notFound : DS.inStrings(found, replacer);
|
|
|
|
|
|
|
|
var noMore = (total == DS.length);
|
|
|
|
|
|
|
|
var initScroll = ($P.sameVehicleControl.main.query.pageNum < 2) && ($P.sameVehicleControl.untilPageNum == 0);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#sameVehicleInspectionMain-responsive--${pageName}")[0].changeContent(trs.join(), initScroll, noMore);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleControl.untilPageNum != 0){
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.query.fetchSize = $P.sameVehicleControl.defaultFetchSize;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.query.pageNum = $P.sameVehicleControl.untilPageNum;
|
|
|
|
|
|
|
|
$P.sameVehicleControl.untilPageNum = 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case "sameVehicleInspectionSub":
|
|
|
|
|
|
|
|
var DS = $P.sameVehicleControl.sub.dataset;
|
|
|
|
|
|
|
|
var empty = DS.empty;
|
|
|
|
|
|
|
|
var notFound = [document.getElementById("sameVehicleInspectionSubNotFound--${pageName}").innerHTML]
|
|
|
|
|
|
|
|
var found = document.getElementById("sameVehicleInspectionSubRow--${pageName}").innerHTML;
|
|
|
|
|
|
|
|
var replacer = (str, dataItem) => str
|
|
|
|
|
|
|
|
.replace(/{onclick}/gi, "pageObject['${pageName}'].clickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','sameVehicleInspectionSub');")
|
|
|
|
|
|
|
|
.replace(/{ondblclick}/gi, "pageObject['${pageName}'].dblclickInspectionDataList('" + dataItem.getValue("CRDN_ID") + "','sameVehicleInspectionSub');");
|
|
|
|
|
|
|
|
var trs = empty ? notFound : DS.inStrings(found, replacer);
|
|
|
|
|
|
|
|
$("#sameVehicleInspectionSubTbody--${pageName}").html(trs.join());
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
default: break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//보안모드
|
|
|
|
|
|
|
|
fn_securityModeToggle($("#securityMode--top").is(":checked"));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.getParams = () => {
|
|
|
|
|
|
|
|
var formFields = new FimsFormFields("#frmSearch--${pageName}");
|
|
|
|
|
|
|
|
var data = formFields.get();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.currentDisplay == "photoInspection"){
|
|
|
|
|
|
|
|
data.fetchSize = $P.photoInspectionControl.defaultFetchSize;
|
|
|
|
|
|
|
|
} else if($P.currentDisplay == "sameVehicleInspection"){
|
|
|
|
|
|
|
|
data.fetchSize = $P.sameVehicleControl.defaultFetchSize;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return data;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
/**************************************************************************
|
|
|
|
* element.on
|
|
|
|
* element.on
|
|
|
@ -974,48 +1027,7 @@ $(document).ready(function(){
|
|
|
|
});
|
|
|
|
});
|
|
|
|
$('#btnSearch--${pageName}').on('click', () => $P.searchInspectionList()); //검색버튼
|
|
|
|
$('#btnSearch--${pageName}').on('click', () => $P.searchInspectionList()); //검색버튼
|
|
|
|
|
|
|
|
|
|
|
|
$('#btnExcel--${pageName}').on('click', function(){
|
|
|
|
$('#btnExcel--${pageName}').on('click', () => $P.fnExcelDown());
|
|
|
|
|
|
|
|
|
|
|
|
if($P.currentDisplay == "photoInspection"){
|
|
|
|
|
|
|
|
if($P.photoInspectionControl.dataset.empty){
|
|
|
|
|
|
|
|
alert("조회된 자료가 없습니다.");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs($("#photoInspection_Table_0--${pageName} thead th").not(".dummy-th").not(":eq(0)"),
|
|
|
|
|
|
|
|
$($("#photoInspectionRow--${pageName}")[0].content).find("td").not(".dummy-td").not(":eq(0)"));
|
|
|
|
|
|
|
|
$P.photoInspectionControl.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.download();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleControl.main.dataset.empty){
|
|
|
|
|
|
|
|
alert("조회된 자료가 없습니다.");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(confirm("단속건수 엑셀저장은 확인버튼, 상세내역 엑셀저장시 취소버튼을 누르세요.")){
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs($("#sameVehicleInspectionMain_Table_0--${pageName} thead th").not(".dummy-th"),
|
|
|
|
|
|
|
|
$($("#sameVehicleInspectionMainRow--${pageName}")[0].content).find("td").not(".dummy-td"));
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.main.download();
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs($("#sameVehicleInspectionSub_Table_0--${pageName} thead th").not(".dummy-th").not(":hidden"),
|
|
|
|
|
|
|
|
$($("#sameVehicleInspectionSubRow--${pageName}")[0].content).find("td").not(".dummy-td").not(".privacy-mask"));
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleControl.sub.download();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#btnInstLevyExcl--${pageName}").on("click", () => $P.openLevyExclPop("1"));
|
|
|
|
$("#btnInstLevyExcl--${pageName}").on("click", () => $P.openLevyExclPop("1"));
|
|
|
|
|
|
|
|
|
|
|
|