diff --git a/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01010-main.jsp b/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01010-main.jsp index dc43cbd0..2cbef4df 100644 --- a/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01010-main.jsp +++ b/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01010-main.jsp @@ -63,16 +63,18 @@ $(document).ready(function() { }; // 현재 선택 자료 변경 이벤트 - ctrl.upDataset.onCurrentChange = (DI) => { - if (!DI) return; - var key = DI.data.CRDN_ID; - $P.$findn("upTbody").setCurrentRow(key); + ctrl.upDataset.onCurrentChange = (dataItem) => { + if (!dataItem) { + return; + } + $P.$findn("upTbody").setCurrentRow(dataItem.index); }; - ctrl.downDataset.onCurrentChange = (DI) => { - if (!DI) return; - var key = DI.data.CRDN_ID; - $P.$findn("downTbody").setCurrentRow(key); + ctrl.downDataset.onCurrentChange = (dataItem) => { + if (!dataItem) { + return; + } + $P.$findn("downTbody").setCurrentRow(dataItem.index); }; // 선택(체크) 변경 이벤트 @@ -290,11 +292,11 @@ $(document).ready(function() { var replacer; if(updown == "up"){ replacer = (str, dataItem) => str - .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrl.upDataset.setCurrent('" + dataItem.getValue("CRDN_ID") + "');") + .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrl.upDataset.setCurrent('{DATA-INDEX}');") .replace(/{ondblclick}/gi, "pageObject['${pageName}'].getInfo('"+ dataItem.getValue("TASK_SE_CD") +"','" + dataItem.getValue("CRDN_ID") + "');") } else { replacer = (str, dataItem) => str - .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrl.downDataset.setCurrent('" + dataItem.getValue("CRDN_ID") + "');") + .replace(/{onclick}/gi, "pageObject['${pageName}'].ctrl.downDataset.setCurrent('{DATA-INDEX}');") .replace(/{ondblclick}/gi, "pageObject['${pageName}'].getInfo('"+ dataItem.getValue("TASK_SE_CD") +"','" + dataItem.getValue("CRDN_ID") + "');") } @@ -758,17 +760,20 @@ $(document).ready(function() { var downDataset = ctrl.downDataset; if(upDataset.length > 0){ - var info = upDataset.getData(crdnId); - if(info != null){ + let filtered = upDataset.getDataset("item").filter(item=>item.data.CRDN_ID == crdnId); + if(filtered != null && filtered.length > 0){ + let info = upDataset.getData(filtered[0].index); return info; } } if(downDataset.length > 0){ - var info = downDataset.getData(crdnId); - if(info != null){ + let filtered = downDataset.getDataset("item").filter(item=>item.data.CRDN_ID == crdnId); + if(filtered != null && filtered.length > 0){ + let info = downDataset.getData(filtered[0].index); return info; } + } return null; diff --git a/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01015-info.jsp b/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01015-info.jsp index a207e27a..ca6aa382 100644 --- a/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01015-info.jsp +++ b/src/main/webapp/WEB-INF/jsp/fims/sprt/sprt01015-info.jsp @@ -4,10 +4,10 @@ 통합조회 그리드 템플릿(내용)