|
|
|
@ -236,7 +236,7 @@
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_STTS_CD}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-end">{FFNLG_CRDN_AMT}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-end">{ADVNTCE_AMT}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_INPT_SE_CD}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_INPT_SE_NM}</td>
|
|
|
|
|
<td class="dummy-td"></td>
|
|
|
|
|
</tr>
|
|
|
|
|
</template>
|
|
|
|
@ -343,13 +343,13 @@
|
|
|
|
|
<template id="sameVehicleInspectionSubRow--${pageName}">
|
|
|
|
|
<tr data-key="{CRDN_ID}">
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_YMD_TM}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_INPT_SE_CD}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_INPT_SE_NM}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{TEAM_NM}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{VHRNO}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_STDG_NM}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-start text-truncate"
|
|
|
|
|
style="max-width:500px;min-width: 300px;">{CRDN_PLC}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_STTS_CD}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center">{CRDN_STTS_NM}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-end">{FFNLG_CRDN_AMT}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-start">{RTPYR_NM}</td>
|
|
|
|
|
<td onclick="{onclick}" ondblclick="{ondblclick}" class="text-center privacy-cell">
|
|
|
|
@ -377,7 +377,7 @@
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
LoadScript("inspectionScript","/resources/js/fims/crdn/inspection.js");
|
|
|
|
|
LoadScript("crdn02010Script","/resources/js/fims/crdn/crdn02010.js?ver=${ver}");
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
|
* Global Variable
|
|
|
|
@ -396,58 +396,13 @@ $(document).ready(function(){
|
|
|
|
|
* DatasetControl
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
//단속사진검사 datasetControl 인스턴스
|
|
|
|
|
$P.photoInspectionControl = new DatasetControl({
|
|
|
|
|
dataGetter : obj => obj["List"], appendData:true,
|
|
|
|
|
keymapper : info => info ? info.CRDN_ID : "",
|
|
|
|
|
urls : {
|
|
|
|
|
load : ""
|
|
|
|
|
},
|
|
|
|
|
formats: {
|
|
|
|
|
CRDN_YMD_TM : datetimeFormat,
|
|
|
|
|
CRDN_INPT_SE_CD : FIM003,
|
|
|
|
|
CRDN_STTS_CD : FIM010,
|
|
|
|
|
FFNLG_CRDN_AMT : numberFormat,
|
|
|
|
|
ADVNTCE_AMT : numberFormat
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
$P.photoInspectionControl.defaultFetchSize = FETCH_XS;
|
|
|
|
|
$P.photoInspectionControl.query = { pageNum : 1, fetchSize : $P.photoInspectionControl.defaultFetchSize };
|
|
|
|
|
$P.photoInspectionControl.beforeCurrent = null;
|
|
|
|
|
$P.ctrl = newCrdn02010Control();
|
|
|
|
|
$P.ctrl.defaultFetchSize = FETCH_XS;
|
|
|
|
|
$P.ctrl.query = { pageNum : 1, fetchSize : $P.ctrl.defaultFetchSize };
|
|
|
|
|
$P.ctrl.beforeCurrent = null;
|
|
|
|
|
$P.ctrl.getNext = (key) => {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//동일차량검사 datasetControl 인스턴스
|
|
|
|
|
$P.sameVehicleMainControl = new DatasetControl({
|
|
|
|
|
dataGetter : obj => obj["List"], appendData:true,
|
|
|
|
|
keymapper : info => info ? info.CRDN_ID_LIST : "",
|
|
|
|
|
urls : {
|
|
|
|
|
load : ""
|
|
|
|
|
},
|
|
|
|
|
formats: {
|
|
|
|
|
CRDN_CNT : numberFormat,
|
|
|
|
|
FFNLG_CRDN_AMT : numberFormat
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
$P.sameVehicleMainControl.defaultFetchSize = FETCH_XS;
|
|
|
|
|
$P.sameVehicleMainControl.query = { pageNum : 1, fetchSize : $P.sameVehicleMainControl.defaultFetchSize };
|
|
|
|
|
$P.sameVehicleMainControl.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl = new DatasetControl({
|
|
|
|
|
dataGetter : obj => obj["List"],
|
|
|
|
|
keymapper : info => info ? info.CRDN_ID : "",
|
|
|
|
|
urls : {
|
|
|
|
|
load : ""
|
|
|
|
|
},
|
|
|
|
|
formats: {
|
|
|
|
|
CRDN_YMD_TM : datetimeFormat,
|
|
|
|
|
CRDN_INPT_SE_CD : FIM003,
|
|
|
|
|
CRDN_STTS_CD : FIM010,
|
|
|
|
|
FFNLG_CRDN_AMT : numberFormat
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.getNext = (key) => {
|
|
|
|
|
|
|
|
|
|
var ds = $P.photoInspectionControl.dataset.getDataset();
|
|
|
|
|
var ds = $P.ctrl.dataset.getDataset();
|
|
|
|
|
|
|
|
|
|
var index = ds.findIndex(item => item.CRDN_ID == key);
|
|
|
|
|
if(ds.length > index+1){
|
|
|
|
@ -456,29 +411,38 @@ $(document).ready(function(){
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//동일차량검사 datasetControl 인스턴스
|
|
|
|
|
$P.alt = newCrdn02010Alt();
|
|
|
|
|
$P.alt.defaultFetchSize = FETCH_XS;
|
|
|
|
|
$P.alt.query = { pageNum : 1, fetchSize : $P.alt.defaultFetchSize };
|
|
|
|
|
$P.alt.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
$P.shift = new newCrdn02010Shift();
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
|
* Dataset.on
|
|
|
|
|
**************************************************************************/
|
|
|
|
|
$P.photoInspectionControl.dataset.onDatasetChange = (obj, option) => {
|
|
|
|
|
$P.ctrl.dataset.onDatasetChange = (obj, option) => {
|
|
|
|
|
|
|
|
|
|
var t = $P.getGridTemplate("photoInspection");
|
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.photoInspectionControl.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.photoInspectionControl.dataset.length, trs, "photoInspection", option);
|
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.ctrl.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.ctrl.dataset.length, trs, "photoInspection", option);
|
|
|
|
|
|
|
|
|
|
Apply.fromDataset.paging($P.photoInspectionControl.dataset, obj, "photoInspectionPaging--${pageName}");
|
|
|
|
|
Apply.fromDataset.paging($P.ctrl.dataset, obj, "photoInspectionPaging--${pageName}");
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
Apply.fromDataset.currentRow($P.photoInspectionControl.dataset, dataItem, $("#photoInspectionTbody--${pageName}")[0]);
|
|
|
|
|
$P.ctrl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
Apply.fromDataset.currentRow($P.ctrl.dataset, dataItem, $("#photoInspectionTbody--${pageName}")[0]);
|
|
|
|
|
|
|
|
|
|
var dataKey = "";
|
|
|
|
|
var curDataVhrno = "";
|
|
|
|
|
var nextDataKey = "";
|
|
|
|
|
var nextDataVhrno = "";
|
|
|
|
|
if(!$P.photoInspectionControl.dataset.empty){
|
|
|
|
|
dataKey = $P.photoInspectionControl.dataset.getKey(dataItem);
|
|
|
|
|
curDataVhrno = $P.photoInspectionControl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
|
var nextData = $P.photoInspectionControl.getNext(dataKey);
|
|
|
|
|
if(!$P.ctrl.dataset.empty){
|
|
|
|
|
dataKey = $P.ctrl.dataset.getKey(dataItem);
|
|
|
|
|
curDataVhrno = $P.ctrl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
|
var nextData = $P.ctrl.getNext(dataKey);
|
|
|
|
|
nextDataKey = nextData != null ? nextData.CRDN_ID : "";
|
|
|
|
|
nextDataVhrno = nextData != null ? nextData.VHRNO : "";
|
|
|
|
|
}
|
|
|
|
@ -486,17 +450,17 @@ $(document).ready(function(){
|
|
|
|
|
$P.showPhoto(dataKey,nextDataKey,curDataVhrno,nextDataVhrno);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.dataset.onDatasetChange = (obj, option) => {
|
|
|
|
|
$P.alt.dataset.onDatasetChange = (obj, option) => {
|
|
|
|
|
|
|
|
|
|
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", option);
|
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.alt.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.alt.dataset.length, trs, "sameVehicleInspectionMain", option);
|
|
|
|
|
|
|
|
|
|
Apply.fromDataset.paging($P.sameVehicleMainControl.dataset, obj, "sameVehicleInspectionMainPaging--${pageName}");
|
|
|
|
|
Apply.fromDataset.paging($P.alt.dataset, obj, "sameVehicleInspectionMainPaging--${pageName}");
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
Apply.fromDataset.currentRow($P.sameVehicleMainControl.dataset, dataItem, $("#sameVehicleInspectionMainTbody--${pageName}")[0]);
|
|
|
|
|
$P.alt.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
Apply.fromDataset.currentRow($P.alt.dataset, dataItem, $("#sameVehicleInspectionMainTbody--${pageName}")[0]);
|
|
|
|
|
if(dataItem){
|
|
|
|
|
$P.searchDetailInspectionDataList(dataItem.data["CRDN_ID_LIST"]);
|
|
|
|
|
} else {
|
|
|
|
@ -504,14 +468,14 @@ $(document).ready(function(){
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl.dataset.onDatasetChange = (obj, option) => {
|
|
|
|
|
$P.shift.dataset.onDatasetChange = (obj, option) => {
|
|
|
|
|
var t = $P.getGridTemplate("sameVehicleInspectionSub");
|
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.sameVehicleSubControl.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.sameVehicleSubControl.dataset.length, trs, "sameVehicleInspectionSub", option);
|
|
|
|
|
var trs = Apply.fromDataset.getTbody($P.shift.dataset, t.found, t.notFound, t.replacer);
|
|
|
|
|
$P.renderInspectionDataList(obj["Total"], $P.shift.dataset.length, trs, "sameVehicleInspectionSub", option);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
Apply.fromDataset.currentRow($P.sameVehicleSubControl.dataset, dataItem, $("#sameVehicleInspectionSubTbody--${pageName}")[0]);
|
|
|
|
|
$P.shift.dataset.onCurrentChange = (dataItem) => {
|
|
|
|
|
Apply.fromDataset.currentRow($P.shift.dataset, dataItem, $("#sameVehicleInspectionSubTbody--${pageName}")[0]);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
/**************************************************************************
|
|
|
|
@ -529,15 +493,15 @@ $(document).ready(function(){
|
|
|
|
|
$("#schRgtrNm--${pageName}").prop("readonly", true); // 사용자 이름
|
|
|
|
|
$('#schCrdnYmdFrom--${pageName}').datepicker('setDate', DateUtil.getDateDay(-7).date);
|
|
|
|
|
$('#schCrdnYmdTo--${pageName}').datepicker('setDate', TODAY());
|
|
|
|
|
$P.photoInspectionControl.dataset.setData([]);
|
|
|
|
|
$P.sameVehicleMainControl.dataset.setData([]);
|
|
|
|
|
$P.ctrl.dataset.setData([]);
|
|
|
|
|
$P.alt.dataset.setData([]);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
$P.fnResetAndChangeBiz = (taskSeCd) => {
|
|
|
|
|
$P.fnReset();
|
|
|
|
|
$P.photoInspectionControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
|
$P.sameVehicleMainControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
|
$P.sameVehicleSubControl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
|
$P.ctrl.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
|
$P.alt.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
|
$P.shift.urls.load = wctx.url("/"+taskSeCd+"/crdn/crdn02/020/list.do");
|
|
|
|
|
|
|
|
|
|
var clsForTask = taskSeCd.toLowerCase();
|
|
|
|
|
//업무별 조회조건
|
|
|
|
@ -556,9 +520,9 @@ $(document).ready(function(){
|
|
|
|
|
var data = formFields.get();
|
|
|
|
|
|
|
|
|
|
if($P.currentDisplay == "photoInspection"){
|
|
|
|
|
data.fetchSize = $P.photoInspectionControl.defaultFetchSize;
|
|
|
|
|
data.fetchSize = $P.ctrl.defaultFetchSize;
|
|
|
|
|
} else if($P.currentDisplay == "sameVehicleInspection"){
|
|
|
|
|
data.fetchSize = $P.sameVehicleMainControl.defaultFetchSize;
|
|
|
|
|
data.fetchSize = $P.alt.defaultFetchSize;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return data;
|
|
|
|
@ -567,34 +531,34 @@ $(document).ready(function(){
|
|
|
|
|
$P.searchInspectionList = () => {
|
|
|
|
|
switch ($P.currentDisplay) {
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
$P.photoInspectionControl.query = $P.getParams();
|
|
|
|
|
$P.photoInspectionControl.query.inspectionDataType = "photo";
|
|
|
|
|
$P.photoInspectionControl.load(1);
|
|
|
|
|
$P.ctrl.query = $P.getParams();
|
|
|
|
|
$P.ctrl.query.inspectionDataType = "photo";
|
|
|
|
|
$P.ctrl.load(1);
|
|
|
|
|
break;
|
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
|
$P.sameVehicleMainControl.query = $P.getParams();
|
|
|
|
|
$P.sameVehicleMainControl.query.inspectionDataType = "sameVehicleMain";
|
|
|
|
|
$P.sameVehicleMainControl.load(1);
|
|
|
|
|
$P.alt.query = $P.getParams();
|
|
|
|
|
$P.alt.query.inspectionDataType = "sameVehicleMain";
|
|
|
|
|
$P.alt.load(1);
|
|
|
|
|
break;
|
|
|
|
|
default: break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.searchDetailInspectionDataList = (dataKey) => {
|
|
|
|
|
$P.sameVehicleSubControl.query = {};
|
|
|
|
|
$P.sameVehicleSubControl.query.inspectionDataType = "sameVehicleSub";
|
|
|
|
|
$P.sameVehicleSubControl.query.crdnIds = dataKey;
|
|
|
|
|
$P.sameVehicleSubControl.query.taskSeCd = $P.sameVehicleMainControl.query.taskSeCd;
|
|
|
|
|
$P.sameVehicleSubControl.load(0);
|
|
|
|
|
$P.shift.query = {};
|
|
|
|
|
$P.shift.query.inspectionDataType = "sameVehicleSub";
|
|
|
|
|
$P.shift.query.crdnIds = dataKey;
|
|
|
|
|
$P.shift.query.taskSeCd = $P.alt.query.taskSeCd;
|
|
|
|
|
$P.shift.load(0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.scrollInspectionDataList = () => {
|
|
|
|
|
switch ($P.currentDisplay) {
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
$P.photoInspectionControl.load($P.photoInspectionControl.query.pageNum + 1);
|
|
|
|
|
$P.ctrl.load($P.ctrl.query.pageNum + 1);
|
|
|
|
|
break;
|
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
|
$P.sameVehicleMainControl.load($P.sameVehicleMainControl.query.pageNum + 1);
|
|
|
|
|
$P.alt.load($P.alt.query.pageNum + 1);
|
|
|
|
|
break;
|
|
|
|
|
default: break;
|
|
|
|
|
}
|
|
|
|
@ -603,35 +567,35 @@ $(document).ready(function(){
|
|
|
|
|
$P.refreshInspectionList = () => {
|
|
|
|
|
switch ($P.currentDisplay) {
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
$P.photoInspectionControl.beforeCurrent = {
|
|
|
|
|
key : $P.photoInspectionControl.dataset.getCurrent()["CRDN_ID"],
|
|
|
|
|
index : $P.photoInspectionControl.dataset.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
$P.ctrl.beforeCurrent = {
|
|
|
|
|
key : $P.ctrl.dataset.getCurrent()["CRDN_ID"],
|
|
|
|
|
index : $P.ctrl.dataset.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
Apply.fromDatasetControl.reload($P.photoInspectionControl).then((resp)=>{
|
|
|
|
|
Apply.toDataset.set($P.photoInspectionControl.dataset, resp);
|
|
|
|
|
$P.photoInspectionControl.dataset.onDatasetChange(resp, {reloaded : true});
|
|
|
|
|
Apply.fromDatasetControl.reload($P.ctrl).then((resp)=>{
|
|
|
|
|
Apply.toDataset.set($P.ctrl.dataset, resp);
|
|
|
|
|
$P.ctrl.dataset.onDatasetChange(resp, {reloaded : true});
|
|
|
|
|
|
|
|
|
|
if($P.photoInspectionControl.beforeCurrent != null){
|
|
|
|
|
let beforeCurrentKey = $P.photoInspectionControl.beforeCurrent.key;
|
|
|
|
|
let beforeCurrentIndex = $P.photoInspectionControl.beforeCurrent.index;
|
|
|
|
|
$P.photoInspectionControl.beforeCurrent = null;
|
|
|
|
|
if($P.ctrl.beforeCurrent != null){
|
|
|
|
|
let beforeCurrentKey = $P.ctrl.beforeCurrent.key;
|
|
|
|
|
let beforeCurrentIndex = $P.ctrl.beforeCurrent.index;
|
|
|
|
|
$P.ctrl.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
if(!$P.photoInspectionControl.dataset.empty){
|
|
|
|
|
var info = $P.photoInspectionControl.dataset.getData(beforeCurrentKey);
|
|
|
|
|
if(!$P.ctrl.dataset.empty){
|
|
|
|
|
var info = $P.ctrl.dataset.getData(beforeCurrentKey);
|
|
|
|
|
|
|
|
|
|
if(info != null){
|
|
|
|
|
$P.photoInspectionControl.dataset.setCurrent(beforeCurrentKey, true);
|
|
|
|
|
$P.ctrl.dataset.setCurrent(beforeCurrentKey, true);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
if(beforeCurrentIndex > ($P.photoInspectionControl.dataset.length - 1)){
|
|
|
|
|
info = $P.photoInspectionControl.dataset.getDataset()[$P.photoInspectionControl.dataset.length - 1];
|
|
|
|
|
if(beforeCurrentIndex > ($P.ctrl.dataset.length - 1)){
|
|
|
|
|
info = $P.ctrl.dataset.getDataset()[$P.ctrl.dataset.length - 1];
|
|
|
|
|
} else {
|
|
|
|
|
info = $P.photoInspectionControl.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
info = $P.ctrl.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.dataset.setCurrent(info["CRDN_ID"], true);
|
|
|
|
|
$P.ctrl.dataset.setCurrent(info["CRDN_ID"], true);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -639,34 +603,34 @@ $(document).ready(function(){
|
|
|
|
|
});
|
|
|
|
|
break;
|
|
|
|
|
case "sameVehicleInspection":
|
|
|
|
|
$P.sameVehicleMainControl.beforeCurrent = {
|
|
|
|
|
key : $P.sameVehicleMainControl.dataset.getCurrent()["CRDN_ID_LIST"],
|
|
|
|
|
index : $P.sameVehicleMainControl.dataset.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
$P.alt.beforeCurrent = {
|
|
|
|
|
key : $P.alt.dataset.getCurrent()["CRDN_ID_LIST"],
|
|
|
|
|
index : $P.alt.dataset.getCurrent()["ROW_NUM"] - 1
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
Apply.fromDatasetControl.reload($P.sameVehicleMainControl).then((resp)=>{
|
|
|
|
|
Apply.toDataset.set($P.sameVehicleMainControl.dataset, resp);
|
|
|
|
|
$P.sameVehicleMainControl.dataset.onDatasetChange(resp, {reloaded : true});
|
|
|
|
|
Apply.fromDatasetControl.reload($P.alt).then((resp)=>{
|
|
|
|
|
Apply.toDataset.set($P.alt.dataset, resp);
|
|
|
|
|
$P.alt.dataset.onDatasetChange(resp, {reloaded : true});
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleMainControl.beforeCurrent != null){
|
|
|
|
|
var beforeCurrentKey = $P.sameVehicleMainControl.beforeCurrent.key;
|
|
|
|
|
var beforeCurrentIndex = $P.sameVehicleMainControl.beforeCurrent.index;
|
|
|
|
|
$P.sameVehicleMainControl.beforeCurrent = null;
|
|
|
|
|
if($P.alt.beforeCurrent != null){
|
|
|
|
|
var beforeCurrentKey = $P.alt.beforeCurrent.key;
|
|
|
|
|
var beforeCurrentIndex = $P.alt.beforeCurrent.index;
|
|
|
|
|
$P.alt.beforeCurrent = null;
|
|
|
|
|
|
|
|
|
|
if(!$P.sameVehicleMainControl.dataset.empty){
|
|
|
|
|
var info = $P.sameVehicleMainControl.dataset.getData(beforeCurrentKey);
|
|
|
|
|
if(!$P.alt.dataset.empty){
|
|
|
|
|
var info = $P.alt.dataset.getData(beforeCurrentKey);
|
|
|
|
|
|
|
|
|
|
if(info != null){
|
|
|
|
|
$P.sameVehicleMainControl.dataset.setCurrent(beforeCurrentKey,true);
|
|
|
|
|
$P.alt.dataset.setCurrent(beforeCurrentKey,true);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
if(beforeCurrentIndex > ($P.sameVehicleMainControl.dataset.length - 1)){
|
|
|
|
|
info = $P.sameVehicleMainControl.dataset.getDataset()[$P.sameVehicleMainControl.dataset.length - 1];
|
|
|
|
|
if(beforeCurrentIndex > ($P.alt.dataset.length - 1)){
|
|
|
|
|
info = $P.alt.dataset.getDataset()[$P.alt.dataset.length - 1];
|
|
|
|
|
} else {
|
|
|
|
|
info = $P.sameVehicleMainControl.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
info = $P.alt.dataset.getDataset()[beforeCurrentIndex];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.dataset.setCurrent(info["CRDN_ID_LIST"],true);
|
|
|
|
|
$P.alt.dataset.setCurrent(info["CRDN_ID_LIST"],true);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
@ -681,7 +645,7 @@ $(document).ready(function(){
|
|
|
|
|
|
|
|
|
|
$P.fnExcelDown = async() => {
|
|
|
|
|
if($P.currentDisplay == "photoInspection"){
|
|
|
|
|
if($P.photoInspectionControl.dataset.empty){
|
|
|
|
|
if($P.ctrl.dataset.empty){
|
|
|
|
|
alert("조회된 자료가 없습니다.");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
@ -690,13 +654,13 @@ $(document).ready(function(){
|
|
|
|
|
$("#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.ctrl.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
$P.photoInspectionControl.download();
|
|
|
|
|
$P.ctrl.download();
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
if($P.sameVehicleMainControl.dataset.empty){
|
|
|
|
|
if($P.alt.dataset.empty){
|
|
|
|
|
alert("조회된 자료가 없습니다.");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
@ -710,9 +674,9 @@ $(document).ready(function(){
|
|
|
|
|
$("#sameVehicleInspectionMain_Table_0--${pageName} thead th").not(".dummy-th"),
|
|
|
|
|
$($("#sameVehicleInspectionMainRow--${pageName}")[0].content).find("td").not(".dummy-td")
|
|
|
|
|
);
|
|
|
|
|
$P.sameVehicleMainControl.query.cellDefs = cellDefs;
|
|
|
|
|
$P.alt.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleMainControl.download();
|
|
|
|
|
$P.alt.download();
|
|
|
|
|
} else if(excelTarget == "sub"){
|
|
|
|
|
|
|
|
|
|
var cellDefs = getCellDefs(
|
|
|
|
@ -720,9 +684,9 @@ $(document).ready(function(){
|
|
|
|
|
$($("#sameVehicleInspectionSubRow--${pageName}")[0].content).find("td").not(".dummy-td"),
|
|
|
|
|
getCellDefsForPrivacyCell
|
|
|
|
|
);
|
|
|
|
|
$P.sameVehicleSubControl.query.cellDefs = cellDefs;
|
|
|
|
|
$P.shift.query.cellDefs = cellDefs;
|
|
|
|
|
|
|
|
|
|
$P.sameVehicleSubControl.download();
|
|
|
|
|
$P.shift.download();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
@ -772,7 +736,7 @@ $(document).ready(function(){
|
|
|
|
|
|
|
|
|
|
switch (renderDataType) {
|
|
|
|
|
case "photoInspection":
|
|
|
|
|
var initScroll = ($P.photoInspectionControl.query.pageNum < 2);
|
|
|
|
|
var initScroll = ($P.ctrl.query.pageNum < 2);
|
|
|
|
|
if(option != null && option.reloaded){
|
|
|
|
|
initScroll = false;
|
|
|
|
|
}
|
|
|
|
@ -781,7 +745,7 @@ $(document).ready(function(){
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
case "sameVehicleInspectionMain":
|
|
|
|
|
var initScroll = ($P.sameVehicleMainControl.query.pageNum < 2);
|
|
|
|
|
var initScroll = ($P.alt.query.pageNum < 2);
|
|
|
|
|
if(option != null && option.reloaded){
|
|
|
|
|
initScroll = false;
|
|
|
|
|
}
|
|
|
|
@ -807,11 +771,11 @@ $(document).ready(function(){
|
|
|
|
|
|
|
|
|
|
if(dataKey != ""){
|
|
|
|
|
$("#photoInspectionTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
|
Apply.toDataset.current($P.photoInspectionControl.dataset, dataKey);
|
|
|
|
|
Apply.toDataset.current($P.ctrl.dataset, dataKey);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var curDataVhrno = $P.photoInspectionControl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
|
var nextData = $P.photoInspectionControl.getNext(dataKey);
|
|
|
|
|
var curDataVhrno = $P.ctrl.dataset.getData(dataKey)["VHRNO"];
|
|
|
|
|
var nextData = $P.ctrl.getNext(dataKey);
|
|
|
|
|
var nextDataKey = nextData != null ? nextData.CRDN_ID : "";
|
|
|
|
|
var nextDataVhrno = nextData != null ? nextData.VHRNO : "";
|
|
|
|
|
$P.showPhoto(dataKey,nextDataKey,curDataVhrno,nextDataVhrno);
|
|
|
|
@ -822,7 +786,7 @@ $(document).ready(function(){
|
|
|
|
|
}
|
|
|
|
|
$("#sameVehicleInspectionMainTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
|
|
|
|
|
|
Apply.toDataset.current($P.sameVehicleMainControl.dataset, dataKey);
|
|
|
|
|
Apply.toDataset.current($P.alt.dataset, dataKey);
|
|
|
|
|
|
|
|
|
|
$P.searchDetailInspectionDataList(dataKey);
|
|
|
|
|
|
|
|
|
@ -833,7 +797,7 @@ $(document).ready(function(){
|
|
|
|
|
}
|
|
|
|
|
$("#sameVehicleInspectionSubTbody--${pageName}").setCurrentRow(dataKey);
|
|
|
|
|
|
|
|
|
|
Apply.toDataset.current($P.sameVehicleSubControl.dataset, dataKey);
|
|
|
|
|
Apply.toDataset.current($P.shift.dataset, dataKey);
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -845,7 +809,7 @@ $(document).ready(function(){
|
|
|
|
|
var dialogUrl = wctx.url("/sprt/sprt02/010/main.do");
|
|
|
|
|
|
|
|
|
|
let params = {
|
|
|
|
|
callControlName : "pageObject['${pageName}'].photoInspectionControl"
|
|
|
|
|
callControlName : "pageObject['${pageName}'].ctrl"
|
|
|
|
|
, crdnId : dataKey
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -911,9 +875,9 @@ $(document).ready(function(){
|
|
|
|
|
var info = "";
|
|
|
|
|
|
|
|
|
|
if ($P.currentDisplay == "photoInspection") {
|
|
|
|
|
info = $P.photoInspectionControl.dataset.getCurrent("item");
|
|
|
|
|
info = $P.ctrl.dataset.getCurrent("item");
|
|
|
|
|
} else if ($P.currentDisplay == "sameVehicleInspection") {
|
|
|
|
|
info = $P.sameVehicleSubControl.dataset.getCurrent("item");
|
|
|
|
|
info = $P.shift.dataset.getCurrent("item");
|
|
|
|
|
} else {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
@ -966,7 +930,7 @@ $(document).ready(function(){
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var info = $P.photoInspectionControl.dataset.getCurrent("item");
|
|
|
|
|
var info = $P.ctrl.dataset.getCurrent("item");
|
|
|
|
|
|
|
|
|
|
if (info == undefined || info == "") {
|
|
|
|
|
return;
|
|
|
|
|