|
|
|
@ -286,18 +286,18 @@ $(document).ready(function(){
|
|
|
|
|
Apply.toDataset.current(ctrl.dataset, dataIndex);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$P.fnRemove = (allCompleteDataIds) => {
|
|
|
|
|
$P.fnRemove = (allCompleteDataIndexs) => {
|
|
|
|
|
|
|
|
|
|
if(allCompleteDataIds != null){
|
|
|
|
|
ctrl.dataset.select(allCompleteDataIds,true);
|
|
|
|
|
ctrl.dataset.select(allCompleteDataIndexs,true);
|
|
|
|
|
} else {
|
|
|
|
|
var cur = ctrl.dataset.getCurrent();
|
|
|
|
|
if(cur == null){
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var curKey = cur["INDIV_ID"];
|
|
|
|
|
ctrl.dataset.select(curKey,true);
|
|
|
|
|
let dataIndex = ctrl.dataset.getCurrent("item").index;
|
|
|
|
|
ctrl.dataset.select(dataIndex, true);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var selected = ctrl.dataset.getDataset("selected");
|
|
|
|
@ -333,15 +333,17 @@ $(document).ready(function(){
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var ds = ctrl.dataset.getDataset();
|
|
|
|
|
var ds = ctrl.dataset.getDataset("item");
|
|
|
|
|
|
|
|
|
|
var indivIds = ds.filter(function(item){
|
|
|
|
|
if(item['STTS_CD'] == '9' || item['STTS_CD'] == 'B'){
|
|
|
|
|
return item["INDIV_ID"];
|
|
|
|
|
let filtered = ds.filter(function(item){
|
|
|
|
|
if(item.data['STTS_CD'] == '9' || item.data['STTS_CD'] == 'B'){
|
|
|
|
|
return true;
|
|
|
|
|
} else {
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
if(indivIds.length == 0){
|
|
|
|
|
|
|
|
|
|
if(filtered.length == 0){
|
|
|
|
|
dialog.alert({
|
|
|
|
|
content : "요청 완료자료가 없습니다.",
|
|
|
|
|
init : function() {
|
|
|
|
@ -350,14 +352,15 @@ $(document).ready(function(){
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var dataIndexs = filtered.map(item=>item.index);
|
|
|
|
|
|
|
|
|
|
dialog.alert({
|
|
|
|
|
content : "완료된 자료를 모두 삭제하시겠습니까?",
|
|
|
|
|
init : function() {
|
|
|
|
|
AppSupport.focusOK();
|
|
|
|
|
},
|
|
|
|
|
onOK : () => {
|
|
|
|
|
$P.fnRemove(indivIds);
|
|
|
|
|
$P.fnRemove(dataIndexs);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|