민원답변대상자료 화면 수정

main
이범준 1 year ago
parent 5ce3b2b90a
commit a64d891dcf

@ -174,6 +174,12 @@ public class CrdnServiceBean extends AbstractServiceBean implements CrdnService
//if(!ifEmpty(crdn.getTeamId(), () -> "").equals("")) {
//}
//TODO : 입력파라미터에 납부자ID가 없고, 납부자명이 있을때 납부자 신규등록
//TODO : 납부자정보의 납부자ID와 입력파라미터의 납부자ID가 동일하고, 납부자명이 다를때 납부자 신규등록
//TODO : 납부자정보ID,납부자명이 동일하고, 주소가 다를 때 주소업데이트
if(ifEmpty(crdn.getCrdnSttsCd(), () -> "").equals("")){
if(!ifEmpty(crdn.getRtpyrId(), () -> "").equals("")) {
crdn.setCrdnSttsCd("21");

@ -62,4 +62,10 @@ public interface CrdnCvlcptService {
*/
boolean updateAnswerContent(CrdnCvlcpt crdnCvlcpt);
/** .
* @param processType , crdnIDs ID
* @return
*/
boolean updateAnswerTargetProcessStatus(String processType, String[] crdnIDs);
}

@ -555,4 +555,18 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
}
@Override
public boolean updateAnswerTargetProcessStatus(String processType, String[] crdnIDs) {
if(processType.equals("answerExecute")) {
// TODO : 답변완료실행
} else if(processType.equals("answerComplete")) {
// TODO : 답변완료
} else {
return false;
}
return true;
}
}

@ -361,4 +361,23 @@ public class Cvlc01Controller extends ApplicationController {
.addObject("saved", saved);
}
/** .
* @param crdnCvlcpt
* @return jsonView
* <pre><code> {
* "affected":
* "saved": true, false
* }</code></pre>
*/
@RequestMapping(name="답변 내용 저장", value="/030/update.do")
public ModelAndView updateAnswerTargetProcessStatus(String processType, String... crdnIDs) {
boolean saved = false;
saved = crdnCvlcptService.updateAnswerTargetProcessStatus(processType, crdnIDs);
return new ModelAndView("jsonView")
.addObject("saved", saved);
}
}

@ -197,6 +197,25 @@ $(document).ready(function(){
$P.crdnControl.beforeCurrent = null;
$P.crdnControl.tableRenderComplete = false;
$P.crdnControl.save = (processType) => {
var keyArr = $P.crdnControl.dataset.getKeys("selected");
ajax.post({
url : $P.crdnControl.urls.update,
data : {
"processType" : processType,
"crdnIDs" : $P.crdnControl.dataset.getKeys("selected")
},
success : resp => {
if(resp.saved){
dialog.alert({ content : "저장됐습니다." });
$P.refreshCrdnList();
}
}
});
}
/**************************************************************************
* DatasetControl.on
**************************************************************************/
@ -281,7 +300,7 @@ $(document).ready(function(){
$P.fnReset();
$P.crdnControl.urls.load = wctx.url("/"+taskSeCd+"/cvlc/cvlc01/030/list.do");
$P.crdnControl.urls.getInfo = wctx.url("/"+taskSeCd+"/sprt/sprt01/020/info.do");
$P.crdnControl.urls.update = wctx.url("/"+taskSeCd+"/sprt/cvlc01/030/update.do");
$P.crdnControl.urls.update = wctx.url("/"+taskSeCd+"/cvlc/cvlc01/030/update.do");
}
$P.refreshCrdnList = () => {
@ -458,6 +477,30 @@ $(document).ready(function(){
});
}
$P.fnAnswerExcute = () => {
var count = $P.crdnControl.dataset.getKeys("selected").length;
dialog.alert({
content : "선택된 "+count+"건의 자료를 답변등록을 실행하시겠습니까?"
, onOK : () => {
$P.crdnControl.save('answerExcute');
}
});
}
$P.fnAnswerComplete = () => {
var count = $P.crdnControl.dataset.getKeys("selected").length;
dialog.alert({
content : "선택된 "+count+"건의 자료를 답변완료 상태로 변경하시겠습니까?"
, onOK : () => {
$P.crdnControl.save('answerComplete');
}
});
}
$P.provide = {
"getCountStatus" : function(currentKey){
var ds = $P.crdnControl.dataset.getDataset();
@ -497,8 +540,8 @@ $(document).ready(function(){
$('#btnSearch--${pageName}').on('click', () => $P.searchCrdnList());
$("#btnOpenCvlcptOrgnl--${pageName}").on("click", () => $P.fnOpenCvlcptOrgnl());
$("#btnOpenAnswerPreview--${pageName}").on("click", () => $P.fnOpenAnswerPreview());
$("#btnAnswerExecute--${pageName}").on("click", () => {});
$("#btnAnswerComplete--${pageName}").on("click", () => {});
$("#btnAnswerExecute--${pageName}").on("click", () => $P.fnAnswerExcute());
$("#btnAnswerComplete--${pageName}").on("click", () => $P.fnAnswerComplete());
$("#table-responsive--${pageName}").scroll(function(){ $P.scrollEnd(this); });
/**************************************************************************

Loading…
Cancel
Save