serviceBean메소드 반환형 변경(boolean -> 결과메시지(String))

main
이범준 9 months ago
parent 060a31815a
commit 1dd0b9c99a

@ -1,5 +1,5 @@
package cokr.xit.fims.cmmn.service; package cokr.xit.fims.cmmn.service;
public interface LinkService { public interface LinkService {
boolean insertElectronicNoticeSndng(String filePath, String sggCd, String taskSeCd, String tmplatId); String insertElectronicNoticeSndng(String filePath, String sggCd, String taskSeCd, String tmplatId);
} }

@ -13,7 +13,7 @@ public interface StngService {
* <li> false</li> * <li> false</li>
* </ul> * </ul>
*/ */
boolean updateTaskStng(Task task, List<Vltn> vltnList); String updateTaskStng(Task task, List<Vltn> vltnList);
/** , . /** , .
* @param sggCd , taskSeCd * @param sggCd , taskSeCd
@ -22,5 +22,5 @@ public interface StngService {
* <li> false</li> * <li> false</li>
* </ul> * </ul>
*/ */
boolean createTaskStng(String sggCd, String taskSeCd); String createTaskStng(String sggCd, String taskSeCd);
} }

@ -25,7 +25,7 @@ public class LinkServiceBean extends AbstractServiceBean implements LinkService
private ExtrStngMapper extrStngMapper; private ExtrStngMapper extrStngMapper;
@Override @Override
public boolean insertElectronicNoticeSndng(String filePath, String sggCd, String taskSeCd, String tmplatId) { public String insertElectronicNoticeSndng(String filePath, String sggCd, String taskSeCd, String tmplatId) {
ExtrStngQuery extrStngQuery = new ExtrStngQuery(); ExtrStngQuery extrStngQuery = new ExtrStngQuery();
extrStngQuery.setSggCd(sggCd).setTaskSeCd(taskSeCd); extrStngQuery.setSggCd(sggCd).setTaskSeCd(taskSeCd);
@ -77,6 +77,6 @@ public class LinkServiceBean extends AbstractServiceBean implements LinkService
linkBean.insertElectronicNoticeSndng(masterInfo, List.of(detailInfo)); linkBean.insertElectronicNoticeSndng(masterInfo, List.of(detailInfo));
} }
return true; return "[S]";
} }
} }

@ -31,7 +31,7 @@ public class StngServiceBean extends AbstractServiceBean implements StngService
private CodeBean codeBean; private CodeBean codeBean;
@Override @Override
public boolean updateTaskStng(Task task, List<Vltn> vltnList) { public String updateTaskStng(Task task, List<Vltn> vltnList) {
boolean result = taskBean.update(task); boolean result = taskBean.update(task);
if(!result) { if(!result) {
@ -45,11 +45,11 @@ public class StngServiceBean extends AbstractServiceBean implements StngService
} }
} }
return result; return result ? "[S]" : "[F]";
} }
@Override @Override
public boolean createTaskStng(String sggCd, String taskSeCd) { public String createTaskStng(String sggCd, String taskSeCd) {
Task task = new Task(); Task task = new Task();
task.setSggCd(sggCd); task.setSggCd(sggCd);
task.setTaskSeCd(taskSeCd); task.setTaskSeCd(taskSeCd);
@ -95,7 +95,7 @@ public class StngServiceBean extends AbstractServiceBean implements StngService
} }
} }
return result; return result ? "[S]" : "[F]";
} }

@ -23,31 +23,31 @@ public interface CrdnService {
* @param crdnIds ID * @param crdnIds ID
* @return * @return
*/ */
boolean remove(String... crdnIds); String remove(String... crdnIds);
/** . /** .
* @param nonQueryRequest , crdn , newFileList * @param nonQueryRequest , crdn , newFileList
* @return * @return
*/ */
boolean create(Map<String, Object> nonQueryRequest, Crdn crdn, List<FileInfo> newFileInfoList); String create(Map<String, Object> nonQueryRequest, Crdn crdn, List<FileInfo> newFileInfoList);
/** . /** .
* @param nonQueryRequest , crdn , newFileInfoList * @param nonQueryRequest , crdn , newFileInfoList
* @return * @return
*/ */
boolean update(Map<String,Object> nonQueryRequest, Crdn crdn, List<FileInfo> newFileInfoList); String update(Map<String,Object> nonQueryRequest, Crdn crdn, List<FileInfo> newFileInfoList);
/** , . /** , .
* @param chgAmtSe , crdnId ID * @param chgAmtSe , crdnId ID
* @return * @return
*/ */
boolean updateOverTimeInfo(String chgAmtSe, String crdnId); String updateOverTimeInfo(String chgAmtSe, String crdnId);
/** . /** .
* @param crdn * @param crdn
* @return * @return
*/ */
boolean updateTagInfo(Crdn crdn); String updateTagInfo(Crdn crdn);
/** . /** .
* @param query * @param query
@ -83,7 +83,7 @@ public interface CrdnService {
* @param entType , fileName * @param entType , fileName
* @return * @return
*/ */
boolean removeEquipmentLinkFile(String workPath, String fileName); String removeEquipmentLinkFile(String workPath, String fileName);
/** . /** .
* @param crdn , processList * @param crdn , processList

@ -32,13 +32,13 @@ public interface CrdnStngService {
* @param teamId ID * @param teamId ID
* @return * @return
*/ */
boolean removeTeamInfo(String teamId); String removeTeamInfo(String teamId);
/** . /** .
* @param team * @param team
* @return * @return
*/ */
boolean saveTeamInfo(Team team); String saveTeamInfo(Team team);
/** . /** .
* @param teamId ID * @param teamId ID
@ -62,19 +62,19 @@ public interface CrdnStngService {
* @param exmptnVhcl * @param exmptnVhcl
* @return * @return
*/ */
boolean createExemptionVehicleInfo(ExmptnVhcl exmptnVhcl); String createExemptionVehicleInfo(ExmptnVhcl exmptnVhcl);
/** . /** .
* @param exmptnVhcl * @param exmptnVhcl
* @return * @return
*/ */
boolean updateExemptionVehicleInfo(ExmptnVhcl exmptnVhcl); String updateExemptionVehicleInfo(ExmptnVhcl exmptnVhcl);
/** . /** .
* @param exmptnVhcl * @param exmptnVhcl
* @return * @return
*/ */
boolean removeExemptionVehicleInfo(ExmptnVhcl exmptnVhcl); String removeExemptionVehicleInfo(ExmptnVhcl exmptnVhcl);
/** . /** .
* @param exemptionVehicleId ID * @param exemptionVehicleId ID

@ -198,29 +198,37 @@ public class CrdnServiceBean extends AbstractServiceBean implements CrdnService
} }
@Override @Override
public boolean remove(String... crdnIds) { public String remove(String... crdnIds) {
return crdnBean.remove(crdnIds); boolean result = crdnBean.remove(crdnIds);
if(result) {
return "[S]";
} else {
return "[F]단속 자료 삭제 중 오류가 발생하였습니다.";
}
} }
@Override @Override
public boolean create(Map<String, Object> nonQueryRequest, Crdn crdn, List<FileInfo> fileInfoList) { public String create(Map<String, Object> nonQueryRequest, Crdn crdn, List<FileInfo> fileInfoList) {
return crdnBean.create(nonQueryRequest, crdn, fileInfoList); boolean result = crdnBean.create(nonQueryRequest, crdn, fileInfoList);
if(result) {
return "[S]";
} else {
return "[F]단속 자료 등록 중 오류가 발생하였습니다.";
}
} }
@Override @Override
public boolean update(Map<String, Object> nonQueryRequest, Crdn crdn, List<FileInfo> newFileInfoList) { public String update(Map<String, Object> nonQueryRequest, Crdn crdn, List<FileInfo> newFileInfoList) {
boolean result = crdnBean.updateLedger(nonQueryRequest, crdn); boolean result = crdnBean.updateLedger(nonQueryRequest, crdn);
if(!result) { if(!result) {
throw new RuntimeException("단속 정보 수정 중 오류가 발생하였습니다."); throw new RuntimeException("단속 정보 수정 중 오류가 발생하였습니다.");
} }
return true; return "[S]";
} }
@Override @Override
public boolean updateOverTimeInfo(String chgAmtSe, String crdnId) { public String updateOverTimeInfo(String chgAmtSe, String crdnId) {
DataObject crdnInfo = crdnInfoMapper.selectCrdnInfo(crdnId); DataObject crdnInfo = crdnInfoMapper.selectCrdnInfo(crdnId);
Crdn crdn = new Crdn(); Crdn crdn = new Crdn();
@ -245,7 +253,7 @@ public class CrdnServiceBean extends AbstractServiceBean implements CrdnService
} }
if(crdnUpdtMapper.updateOverTimeInfo(crdn) != 1) { if(crdnUpdtMapper.updateOverTimeInfo(crdn) != 1) {
return false; return "[F]2시간초과여부 변경 중 오류가 발생하였습니다.";
} }
if(chgAmtSe.equals("0") || chgAmtSe.equals("1")) { if(chgAmtSe.equals("0") || chgAmtSe.equals("1")) {
@ -261,18 +269,20 @@ public class CrdnServiceBean extends AbstractServiceBean implements CrdnService
int effected = crdnUpdtMapper.updateCrdnAmt(crdn); int effected = crdnUpdtMapper.updateCrdnAmt(crdn);
if(effected != 1) { if(effected != 1) {
return false; return "[F]단속자료 금액 변경 중 오류가 발생하였습니다.";
} }
return true; return "[S]";
} }
@Override @Override
public boolean updateTagInfo(Crdn crdn) { public String updateTagInfo(Crdn crdn) {
return crdnUpdtMapper.updateTagInfo(crdn) == 1 ? true : false; if(crdnUpdtMapper.updateTagInfo(crdn) == 1) {
return "[S]";
} else {
return "[F]";
}
} }
@Override @Override
public DataObject getCrackdownInfo(CrdnQuery query) { public DataObject getCrackdownInfo(CrdnQuery query) {
return crdnInfoMapper.selectCrdnInfo(query.getCrdnId()); return crdnInfoMapper.selectCrdnInfo(query.getCrdnId());
@ -299,8 +309,13 @@ public class CrdnServiceBean extends AbstractServiceBean implements CrdnService
} }
@Override @Override
public boolean removeEquipmentLinkFile(String workPath, String fileName) { public String removeEquipmentLinkFile(String workPath, String fileName) {
return crdnBean.removeEquipmentLinkFile(workPath, fileName); boolean result = crdnBean.removeEquipmentLinkFile(workPath, fileName);
if(result) {
return "[S]";
} else {
return "[F]장비연계파일 삭제 중 오류가 발생하였습니다.";
}
} }
@Override @Override

@ -41,14 +41,14 @@ public class CrdnStngServiceBean extends AbstractServiceBean implements CrdnStng
} }
@Override @Override
public boolean removeTeamInfo(String teamId) { public String removeTeamInfo(String teamId) {
return crdnStngBean.removeTeamInfo(teamId); return crdnStngBean.removeTeamInfo(teamId) ? "[S]" : "[F]";
} }
@Override @Override
public boolean saveTeamInfo(Team team) { public String saveTeamInfo(Team team) {
return crdnStngBean.saveTeamInfo(false, team); return crdnStngBean.saveTeamInfo(false, team) ? "[S]" : "[F]";
} }
@Override @Override
@ -67,18 +67,33 @@ public class CrdnStngServiceBean extends AbstractServiceBean implements CrdnStng
} }
@Override @Override
public boolean createExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) { public String createExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) {
return crdnStngBean.createExemptionVehicleInfo(exmptnVhcl); boolean result = crdnStngBean.createExemptionVehicleInfo(exmptnVhcl);
if(result) {
return "[S]";
} else {
return "[F]";
}
} }
@Override @Override
public boolean updateExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) { public String updateExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) {
return crdnStngBean.updateExemptionVehicleInfo(exmptnVhcl); boolean result = crdnStngBean.updateExemptionVehicleInfo(exmptnVhcl);
if(result) {
return "[S]";
} else {
return "[F]";
}
} }
@Override @Override
public boolean removeExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) { public String removeExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) {
return crdnStngBean.removeExemptionVehicleInfo(exmptnVhcl); boolean result = crdnStngBean.removeExemptionVehicleInfo(exmptnVhcl);
if(result) {
return "[S]";
} else {
return "[F]";
}
} }
@Override @Override

@ -175,7 +175,11 @@ public class Crdn02Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView updateOverTimeInfo(String chgAmtSe, String crdnId) { public ModelAndView updateOverTimeInfo(String chgAmtSe, String crdnId) {
boolean saved = crdnService.updateOverTimeInfo(chgAmtSe, crdnId); boolean saved = false;
String rtnMsg = crdnService.updateOverTimeInfo(chgAmtSe, crdnId);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }

@ -129,8 +129,11 @@ public class Crdn03Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView updateTagInfo(Crdn crdn) { public ModelAndView updateTagInfo(Crdn crdn) {
boolean saved = false;
boolean saved = crdnService.updateTagInfo(crdn); String rtnMsg = crdnService.updateTagInfo(crdn);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }

@ -327,9 +327,11 @@ public class Crdn05Controller extends ApplicationController {
LayoutDescriptor info = crdnStngBean.getLinkFileLayoutMetadata(fileLayoutId); LayoutDescriptor info = crdnStngBean.getLinkFileLayoutMetadata(fileLayoutId);
String workPath = info.getLinkFileLocation(); String workPath = info.getLinkFileLocation();
boolean saved = false;
boolean saved = crdnService.removeEquipmentLinkFile(workPath, fileName); String rtnMsg = crdnService.removeEquipmentLinkFile(workPath, fileName);
if(rtnMsg.contains("[S]")) {
saved = true;
}
mav.addObject("saved", saved); mav.addObject("saved", saved);
return mav; return mav;
} }
@ -480,8 +482,11 @@ public class Crdn05Controller extends ApplicationController {
} }
Map<String, Object> nonQueryRequest = new HashMap<String, Object>(); Map<String, Object> nonQueryRequest = new HashMap<String, Object>();
crdn.setCvlcptLinkYn("N"); crdn.setCvlcptLinkYn("N");
saved = crdnService.create(nonQueryRequest, crdn, fileInfoList);
String rtnMsg = crdnService.create(nonQueryRequest, crdn, fileInfoList);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);

@ -110,8 +110,10 @@ public class Crdn07Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
saved = crdnStngService.removeTeamInfo(teamId); String rtnMsg = crdnStngService.removeTeamInfo(teamId);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
@ -134,8 +136,10 @@ public class Crdn07Controller extends ApplicationController {
String sggCd = globalStngMapper.selectSggCd(curDeptCode); String sggCd = globalStngMapper.selectSggCd(curDeptCode);
team.setSggCd(sggCd); team.setSggCd(sggCd);
saved = crdnStngService.saveTeamInfo(team); String rtnMsg = crdnStngService.saveTeamInfo(team);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);

@ -152,6 +152,7 @@ public class Crdn08Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView createExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) { public ModelAndView createExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) {
ModelAndView mav = new ModelAndView("jsonView");
ManagedUser currentUser = userMapper.getUser(currentUser().getAccount(), currentUser().getInstitute()); ManagedUser currentUser = userMapper.getUser(currentUser().getAccount(), currentUser().getInstitute());
String deptCd = currentUser.getDeptCode(); String deptCd = currentUser.getDeptCode();
@ -159,10 +160,12 @@ public class Crdn08Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
saved = crdnStngService.createExemptionVehicleInfo(exmptnVhcl); String rtnMsg = crdnStngService.createExemptionVehicleInfo(exmptnVhcl);
if(rtnMsg.contains("[S]")) {
return new ModelAndView("jsonView") saved = true;
.addObject("saved", saved); }
mav.addObject("saved", saved);
return mav;
} }
@ -175,6 +178,7 @@ public class Crdn08Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView updateExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) { public ModelAndView updateExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) {
ModelAndView mav = new ModelAndView("jsonView");
ManagedUser currentUser = userMapper.getUser(currentUser().getAccount(), currentUser().getInstitute()); ManagedUser currentUser = userMapper.getUser(currentUser().getAccount(), currentUser().getInstitute());
String deptCd = currentUser.getDeptCode(); String deptCd = currentUser.getDeptCode();
@ -182,10 +186,12 @@ public class Crdn08Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
saved = crdnStngService.updateExemptionVehicleInfo(exmptnVhcl); String rtnMsg = crdnStngService.updateExemptionVehicleInfo(exmptnVhcl);
if(rtnMsg.contains("[S]")) {
return new ModelAndView("jsonView") saved = true;
.addObject("saved", saved); }
mav.addObject("saved", saved);
return mav;
} }
@ -198,13 +204,16 @@ public class Crdn08Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView removeExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) { public ModelAndView removeExemptionVehicleInfo(ExmptnVhcl exmptnVhcl) {
ModelAndView mav = new ModelAndView("jsonView");
boolean saved = false; boolean saved = false;
saved = crdnStngService.removeExemptionVehicleInfo(exmptnVhcl); String rtnMsg = crdnStngService.removeExemptionVehicleInfo(exmptnVhcl);
if(rtnMsg.contains("[S]")) {
return new ModelAndView("jsonView") saved = true;
.addObject("saved", saved); }
mav.addObject("saved", saved);
return mav;
} }

@ -47,31 +47,31 @@ public interface CrdnCvlcptService {
* @param crdnID ID * @param crdnID ID
* @return * @return
*/ */
boolean sendBackCivilComplaintInfo(String crdnId); String sendBackCivilComplaintInfo(String crdnId);
/** . /** .
* @param nonQueryRequest , crdnCvlcpt , crdn * @param nonQueryRequest , crdnCvlcpt , crdn
* @return * @return
*/ */
boolean updateCvlcptProcessSection(Map<String, Object> nonQueryRequest, CrdnCvlcpt crdnCvlcpt, Crdn crdn); String updateCvlcptProcessSection(Map<String, Object> nonQueryRequest, CrdnCvlcpt crdnCvlcpt, Crdn crdn);
/** . /** .
* @param crdnId ID * @param crdnId ID
* @return * @return
*/ */
boolean copyCvlcptCrdnInfo(String crdnId); String copyCvlcptCrdnInfo(String crdnId);
/** . /** .
* @param crdnCvlcpt * @param crdnCvlcpt
* @return * @return
*/ */
boolean updateAnswerContent(CrdnCvlcpt crdnCvlcpt); String updateAnswerContent(CrdnCvlcpt crdnCvlcpt);
/** . /** .
* @param processType , crdnIds ID * @param processType , crdnIds ID
* @return * @return
*/ */
boolean updateAnswerTargetProcessStatus(String processType, String currentUserInstitute, String currentUserAcnt, String[] crdnIds); String updateAnswerTargetProcessStatus(String processType, String currentUserInstitute, String currentUserAcnt, String[] crdnIds);
/** . /** .
* @param crdnQuery * @param crdnQuery
@ -88,13 +88,13 @@ public interface CrdnCvlcptService {
* @param saveData , crdnCvlcpt * @param saveData , crdnCvlcpt
* @return * @return
*/ */
boolean saveAnswerWordsInfo(String saveData, CrdnCvlcpt crdnCvlcpt); String saveAnswerWordsInfo(String saveData, CrdnCvlcpt crdnCvlcpt);
/** . /** .
* @param ansWordsId ID * @param ansWordsId ID
* @return * @return
*/ */
boolean removeCvlcptAnswerWordsInfo(String ansWordsId); String removeCvlcptAnswerWordsInfo(String ansWordsId);
/** . /** .
* @param crdnQuery * @param crdnQuery
@ -106,7 +106,7 @@ public interface CrdnCvlcptService {
* @param crdnCvlcpt * @param crdnCvlcpt
* @return * @return
*/ */
boolean saveWarningWordsInfo(CrdnCvlcpt crdnCvlcpt); String saveWarningWordsInfo(CrdnCvlcpt crdnCvlcpt);
/** . /** .
* @param query * @param query
@ -118,17 +118,17 @@ public interface CrdnCvlcptService {
* @param crdnCvlcpt * @param crdnCvlcpt
* @return * @return
*/ */
boolean createDmndDataInfo(CrdnCvlcpt crdnCvlcpt); String createDmndDataInfo(CrdnCvlcpt crdnCvlcpt);
/** . /** .
* @param indivIds ID * @param indivIds ID
* @return * @return
*/ */
boolean removeDmndDataInfo(String... indivIds); String removeDmndDataInfo(String... indivIds);
/** . /** .
* @param crdnIds ID * @param crdnIds ID
* @return * @return
*/ */
boolean executeDisabledTagInfoInquire(String... crdnIds); String executeDisabledTagInfoInquire(String... crdnIds);
} }

@ -333,7 +333,7 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
@Override @Override
public boolean sendBackCivilComplaintInfo(String crdnId) { public String sendBackCivilComplaintInfo(String crdnId) {
boolean saved = false; boolean saved = false;
DataObject crdnInfo = crdnInfoMapper.selectCrdnInfo(crdnId); DataObject crdnInfo = crdnInfoMapper.selectCrdnInfo(crdnId);
@ -365,11 +365,11 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
} }
return saved; return saved ? "[S]" : "[F]";
} }
@Override @Override
public boolean updateCvlcptProcessSection(Map<String, Object> nonQueryRequest, CrdnCvlcpt crdnCvlcpt, Crdn crdn) { public String updateCvlcptProcessSection(Map<String, Object> nonQueryRequest, CrdnCvlcpt crdnCvlcpt, Crdn crdn) {
boolean saved = false; boolean saved = false;
DataObject crdnInfo = crdnInfoMapper.selectCrdnInfo(crdn.getCrdnId()); DataObject crdnInfo = crdnInfoMapper.selectCrdnInfo(crdn.getCrdnId());
@ -449,28 +449,28 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
} }
return saved; return saved ? "[S]" : "[F]";
} }
@Override @Override
public boolean copyCvlcptCrdnInfo(String crdnId) { public String copyCvlcptCrdnInfo(String crdnId) {
return crdnCvlcptSubBean.copyCvlcptCrdnInfo(crdnId); return crdnCvlcptSubBean.copyCvlcptCrdnInfo(crdnId) ? "[S]" : "[F]";
} }
@Override @Override
public boolean updateAnswerContent(CrdnCvlcpt crdnCvlcpt) { public String updateAnswerContent(CrdnCvlcpt crdnCvlcpt) {
int effected = crdnCvlcptMapper.updateAnswerContent(crdnCvlcpt); int effected = crdnCvlcptMapper.updateAnswerContent(crdnCvlcpt);
if(effected != 1) { if(effected != 1) {
throw new RuntimeException("답변 내용 저장에 실패하였습니다."); throw new RuntimeException("답변 내용 저장에 실패하였습니다.");
} }
return true; return "[S]";
} }
@Override @Override
public boolean updateAnswerTargetProcessStatus(String processType, String currentUserInstitute, String currentUserAcnt, String[] crdnIds) { public String updateAnswerTargetProcessStatus(String processType, String currentUserInstitute, String currentUserAcnt, String[] crdnIds) {
List<DataObject> targetDataList = crdnCvlcptMapper.selectAnswerTargetList(crdnIds); List<DataObject> targetDataList = crdnCvlcptMapper.selectAnswerTargetList(crdnIds);
@ -518,7 +518,7 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
} }
return true; return "[S]";
} }
@Override @Override
@ -539,7 +539,7 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
@Override @Override
public boolean saveAnswerWordsInfo(String saveData, CrdnCvlcpt crdnCvlcpt) { public String saveAnswerWordsInfo(String saveData, CrdnCvlcpt crdnCvlcpt) {
boolean saved = false; boolean saved = false;
if(saveData.equals("basic")) { if(saveData.equals("basic")) {
saved = crdnCvlcptMainBean.saveAnswerBasicWordsInfo(crdnCvlcpt); saved = crdnCvlcptMainBean.saveAnswerBasicWordsInfo(crdnCvlcpt);
@ -547,14 +547,14 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
if(saveData.equals("body")) { if(saveData.equals("body")) {
saved = crdnCvlcptMainBean.saveAnswerBodyWordsInfo(crdnCvlcpt); saved = crdnCvlcptMainBean.saveAnswerBodyWordsInfo(crdnCvlcpt);
} }
return saved; return saved ? "[S]" : "[F]";
} }
@Override @Override
public boolean removeCvlcptAnswerWordsInfo(String ansWordsId) { public String removeCvlcptAnswerWordsInfo(String ansWordsId) {
CrdnCvlcpt crdnCvlcpt = new CrdnCvlcpt(); CrdnCvlcpt crdnCvlcpt = new CrdnCvlcpt();
crdnCvlcpt.setAnsWordsId(ansWordsId); crdnCvlcpt.setAnsWordsId(ansWordsId);
return answerWordsMapper.deleteCvlcptAnswerWordsInfo(crdnCvlcpt) == 1 ? true : false; return answerWordsMapper.deleteCvlcptAnswerWordsInfo(crdnCvlcpt) == 1 ? "[S]" : "[F]";
} }
@Override @Override
@ -563,8 +563,8 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
@Override @Override
public boolean saveWarningWordsInfo(CrdnCvlcpt crdnCvlcpt) { public String saveWarningWordsInfo(CrdnCvlcpt crdnCvlcpt) {
return crdnCvlcptSubBean.saveWarningWordsInfo(crdnCvlcpt); return crdnCvlcptSubBean.saveWarningWordsInfo(crdnCvlcpt) ? "[S]" : "[F]";
} }
@Override @Override
@ -573,17 +573,17 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
@Override @Override
public boolean createDmndDataInfo(CrdnCvlcpt crdnCvlcpt) { public String createDmndDataInfo(CrdnCvlcpt crdnCvlcpt) {
return crdnCvlcptMainBean.createDmndDataInfo(crdnCvlcpt); return crdnCvlcptMainBean.createDmndDataInfo(crdnCvlcpt) ? "[S]" : "[F]";
} }
@Override @Override
public boolean removeDmndDataInfo(String... indivIds) { public String removeDmndDataInfo(String... indivIds) {
return crdnCvlcptMainBean.removeDmndDataInfo(indivIds); return crdnCvlcptMainBean.removeDmndDataInfo(indivIds) ? "[S]" : "[F]";
} }
@Override @Override
public boolean executeDisabledTagInfoInquire(String... crdnIds) { public String executeDisabledTagInfoInquire(String... crdnIds) {
int i=0; int i=0;
HashMap<String, Boolean> vehicleResultMap = new HashMap<String, Boolean>(); HashMap<String, Boolean> vehicleResultMap = new HashMap<String, Boolean>();
@ -662,7 +662,7 @@ public class CrdnCvlcptServiceBean extends AbstractServiceBean implements CrdnCv
} }
} }
return i > 0 ? true : false; return i > 0 ? "[S]" : "[F]";
} }
} }

@ -157,11 +157,14 @@ public class Cvlc01Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView removeCivilComplaint(String[] crdnIds) { public ModelAndView removeCivilComplaint(String[] crdnIds) {
ModelAndView mav = new ModelAndView("jsonView");
boolean saved = crdnService.remove(crdnIds); boolean saved = false;
String rtnMsg = crdnService.remove(crdnIds);
return new ModelAndView("jsonView") if(rtnMsg.contains("S")) {
.addObject("saved", saved); saved = true;
}
mav.addObject("saved", saved);
return mav;
} }
/** . /** .
@ -265,6 +268,7 @@ public class Cvlc01Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView saveCivilComplaintProcessSection(HttpServletRequest hReq, CrdnCvlcpt crdnCvlcpt, Crdn crdn) { public ModelAndView saveCivilComplaintProcessSection(HttpServletRequest hReq, CrdnCvlcpt crdnCvlcpt, Crdn crdn) {
ModelAndView mav = new ModelAndView("jsonView");
ManagedUser currentUser = userMapper.getUser(currentUser().getAccount(), currentUser().getInstitute()); ManagedUser currentUser = userMapper.getUser(currentUser().getAccount(), currentUser().getInstitute());
String deptCd = currentUser.getDeptCode(); String deptCd = currentUser.getDeptCode();
@ -286,11 +290,12 @@ public class Cvlc01Controller extends ApplicationController {
} }
} }
saved = crdnCvlcptService.updateCvlcptProcessSection(nonQueryRequest, crdnCvlcpt, crdn); String rtnMsg = crdnCvlcptService.updateCvlcptProcessSection(nonQueryRequest, crdnCvlcpt, crdn);
if(rtnMsg.contains("[S]")) {
saved = true;
return new ModelAndView("jsonView") }
.addObject("saved", saved); mav.addObject("saved", saved);
return mav;
} }
/** . /** .
@ -301,13 +306,16 @@ public class Cvlc01Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView copyCivilComplaintInfo(String crdnId) { public ModelAndView copyCivilComplaintInfo(String crdnId) {
ModelAndView mav = new ModelAndView("jsonView");
boolean saved = false; boolean saved = false;
saved = crdnCvlcptService.copyCvlcptCrdnInfo(crdnId); String rtnMsg = crdnCvlcptService.copyCvlcptCrdnInfo(crdnId);
if(rtnMsg.contains("[S]")) {
return new ModelAndView("jsonView") saved = true;
.addObject("saved", saved); }
mav.addObject("saved", saved);
return mav;
} }
/** () . /** () .
@ -318,12 +326,15 @@ public class Cvlc01Controller extends ApplicationController {
* }</code></pre> * }</code></pre>
*/ */
public ModelAndView sendBackCivilComplaintInfo(String crdnId) { public ModelAndView sendBackCivilComplaintInfo(String crdnId) {
ModelAndView mav = new ModelAndView("jsonView");
boolean saved = false; boolean saved = false;
saved = crdnCvlcptService.sendBackCivilComplaintInfo(crdnId); String rtnMsg = crdnCvlcptService.sendBackCivilComplaintInfo(crdnId);
if(rtnMsg.contains("[S]")) {
return new ModelAndView("jsonView") saved = true;
.addObject("saved", saved); }
mav.addObject("saved", saved);
return mav;
} }
} }

@ -212,8 +212,10 @@ public class Cvlc02Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
saved = crdnCvlcptService.updateAnswerContent(crdnCvlcpt); String rtnMsg = crdnCvlcptService.updateAnswerContent(crdnCvlcpt);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }
@ -231,8 +233,10 @@ public class Cvlc02Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
String currentInstitute = currentUser().getInstitute(); String currentInstitute = currentUser().getInstitute();
String currentUserAcnt = currentUser().getAccount(); String currentUserAcnt = currentUser().getAccount();
saved = crdnCvlcptService.updateAnswerTargetProcessStatus(processType, currentInstitute, currentUserAcnt, crdnIds); String rtnMsg = crdnCvlcptService.updateAnswerTargetProcessStatus(processType, currentInstitute, currentUserAcnt, crdnIds);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }
@ -248,8 +252,10 @@ public class Cvlc02Controller extends ApplicationController {
public ModelAndView executeDisabledTagInfoInquire(String... crdnIds) { public ModelAndView executeDisabledTagInfoInquire(String... crdnIds) {
boolean saved = false; boolean saved = false;
saved = crdnCvlcptService.executeDisabledTagInfoInquire(crdnIds); String rtnMsg = crdnCvlcptService.executeDisabledTagInfoInquire(crdnIds);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }

@ -96,8 +96,10 @@ public class Cvlc04Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
saved = crdnCvlcptService.createDmndDataInfo(crdnCvlcpt); String rtnMsg = crdnCvlcptService.createDmndDataInfo(crdnCvlcpt);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
@ -113,8 +115,11 @@ public class Cvlc04Controller extends ApplicationController {
*/ */
public ModelAndView removeDmndDataInfo(String[] indivIds) { public ModelAndView removeDmndDataInfo(String[] indivIds) {
boolean saved = crdnCvlcptService.removeDmndDataInfo(indivIds); boolean saved = false;
String rtnMsg = crdnCvlcptService.removeDmndDataInfo(indivIds);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }

@ -119,7 +119,10 @@ public class Cvlc05Controller extends ApplicationController {
String saveData = hReq.getParameter("saveData"); String saveData = hReq.getParameter("saveData");
if(saveData.equals("basic") || saveData.equals("body")) { if(saveData.equals("basic") || saveData.equals("body")) {
saved = crdnCvlcptService.saveAnswerWordsInfo(saveData, crdnCvlcpt); String rtnMsg = crdnCvlcptService.saveAnswerWordsInfo(saveData, crdnCvlcpt);
if(rtnMsg.contains("[S]")) {
saved = true;
}
} }
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
@ -137,8 +140,10 @@ public class Cvlc05Controller extends ApplicationController {
public ModelAndView removeCvlcptAnswerWordsInfo(String ansWordsId) { public ModelAndView removeCvlcptAnswerWordsInfo(String ansWordsId) {
boolean saved = false; boolean saved = false;
saved = crdnCvlcptService.removeCvlcptAnswerWordsInfo(ansWordsId); String rtnMsg = crdnCvlcptService.removeCvlcptAnswerWordsInfo(ansWordsId);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }

@ -87,8 +87,10 @@ public class Cvlc06Controller extends ApplicationController {
String currentSggCd = globalStngMapper.selectSggCd(deptCd); String currentSggCd = globalStngMapper.selectSggCd(deptCd);
crdnCvlcpt.setSggCd(currentSggCd); crdnCvlcpt.setSggCd(currentSggCd);
saved = crdnCvlcptService.saveWarningWordsInfo(crdnCvlcpt); String rtnMsg = crdnCvlcptService.saveWarningWordsInfo(crdnCvlcpt);
if(rtnMsg.contains("[S]")) {
saved = true;
}
return new ModelAndView("jsonView") return new ModelAndView("jsonView")
.addObject("saved", saved); .addObject("saved", saved);
} }

@ -9,7 +9,7 @@ import cokr.xit.foundation.data.DataObject;
public interface FactionService { public interface FactionService {
boolean updateSgg(FineIntegrationSigungu sgg); String updateSgg(FineIntegrationSigungu sgg);
DataObject getSggInfo(CmmnQuery req); DataObject getSggInfo(CmmnQuery req);
@ -39,7 +39,7 @@ public interface FactionService {
* <li> false</li> * <li> false</li>
* </ul> * </ul>
*/ */
boolean create(FineIntegrationDepartment dept); String create(FineIntegrationDepartment dept);
/** . /** .
* @param dept * @param dept
@ -48,7 +48,7 @@ public interface FactionService {
* <li> false</li> * <li> false</li>
* </ul> * </ul>
*/ */
boolean update(FineIntegrationDepartment dept); String update(FineIntegrationDepartment dept);
/** . /** .
* @param deptCds * @param deptCds
@ -57,5 +57,5 @@ public interface FactionService {
* <li> false</li> * <li> false</li>
* </ul> * </ul>
*/ */
boolean remove(String... deptCds); String remove(String... deptCds);
} }

@ -20,8 +20,8 @@ public class FactionServiceBean extends AbstractServiceBean implements FactionSe
private FactionBean factionBean; private FactionBean factionBean;
@Override @Override
public boolean updateSgg(FineIntegrationSigungu sgg) { public String updateSgg(FineIntegrationSigungu sgg) {
return factionBean.updateSgg(sgg); return factionBean.updateSgg(sgg) ? "[S]" : "[F]";
} }
@Override @Override
@ -46,17 +46,23 @@ public class FactionServiceBean extends AbstractServiceBean implements FactionSe
} }
@Override @Override
public boolean create(FineIntegrationDepartment dept) { public String create(FineIntegrationDepartment dept) {
return factionBean.create(dept); return factionBean.create(dept) ? "[S]" : "[F]";
} }
@Override @Override
public boolean update(FineIntegrationDepartment dept) { public String update(FineIntegrationDepartment dept) {
return factionBean.update(dept); return factionBean.update(dept) ? "[S]" : "[F]";
} }
@Override @Override
public boolean remove(String... deptCds) { public String remove(String... deptCds) {
return factionBean.remove(deptCds); boolean result = factionBean.remove(deptCds);
if(result) {
return "[S]";
} else {
return "[F]";
}
} }
} }

@ -158,9 +158,11 @@ public class Mngt03Controller extends ApplicationController {
sgg.setOfficialSealFilepath(newOffcs.get("filePath")); sgg.setOfficialSealFilepath(newOffcs.get("filePath"));
sgg.setOfficialSealFilename(newOffcs.get("fileName")); sgg.setOfficialSealFilename(newOffcs.get("fileName"));
} }
boolean saved = false;
boolean saved = factionService.updateSgg(sgg); String rtnMsg = factionService.updateSgg(sgg);
if(rtnMsg.contains("[S]")) {
saved = true;
}
mav.addObject("saved", saved); mav.addObject("saved", saved);
return mav; return mav;
} }
@ -203,8 +205,11 @@ public class Mngt03Controller extends ApplicationController {
public ModelAndView updateTaskStng(Task task) { public ModelAndView updateTaskStng(Task task) {
ModelAndView mav = new ModelAndView("jsonView"); ModelAndView mav = new ModelAndView("jsonView");
boolean saved = stngService.updateTaskStng(task, task.getVltnStngList()); boolean saved = false;
String rtnMsg = stngService.updateTaskStng(task, task.getVltnStngList());
if(rtnMsg.contains("[S]")) {
saved = true;
}
mav.addObject("saved", saved); mav.addObject("saved", saved);
return mav; return mav;
} }
@ -219,8 +224,11 @@ public class Mngt03Controller extends ApplicationController {
public ModelAndView createTaskStng(String sggCd, String taskSeCd) { public ModelAndView createTaskStng(String sggCd, String taskSeCd) {
ModelAndView mav = new ModelAndView("jsonView"); ModelAndView mav = new ModelAndView("jsonView");
boolean saved = stngService.createTaskStng(sggCd, taskSeCd); boolean saved = false;
String rtnMsg = stngService.createTaskStng(sggCd, taskSeCd);
if(rtnMsg.contains("[S]")) {
saved = true;
}
mav.addObject("saved", saved); mav.addObject("saved", saved);
return mav; return mav;
} }

@ -98,8 +98,11 @@ public class Mngt04Controller extends ApplicationController {
*/ */
public ModelAndView removeDept(String... deptCds) { public ModelAndView removeDept(String... deptCds) {
ModelAndView mav = new ModelAndView("jsonView"); ModelAndView mav = new ModelAndView("jsonView");
boolean saved = false;
boolean saved = factionService.remove(deptCds); String rtnMsg = factionService.remove(deptCds);
if(rtnMsg.contains("[S]")) {
saved = true;
}
mav.addObject("saved", saved); mav.addObject("saved", saved);
return mav; return mav;

@ -29,7 +29,7 @@ public interface IntegrationSearchService {
* @param etcCn , crdnIds ID * @param etcCn , crdnIds ID
* @return * @return
*/ */
boolean updateEtcCn(String etcCn, String... crdnIds); String updateEtcCn(String etcCn, String... crdnIds);
/** . /** .
* @param formatType ,formatName , printOption , crdnIds * @param formatType ,formatName , printOption , crdnIds

@ -110,10 +110,14 @@ public class IntegrationSearchServiceBean extends AbstractServiceBean implements
} }
@Override @Override
public boolean updateEtcCn(String etcCn, String... crdnIds) { public String updateEtcCn(String etcCn, String... crdnIds) {
return integrationSearchBean.updateEtcCn(etcCn, crdnIds);
boolean result = integrationSearchBean.updateEtcCn(etcCn, crdnIds);
if(result) {
return "[S]";
} else {
return "[F]";
}
} }
@Override @Override

@ -392,8 +392,10 @@ public class Sprt01Controller extends ApplicationController {
boolean saved = false; boolean saved = false;
saved = integrationSearchService.updateEtcCn(crdn.getEtcCn(), crdnIds); String rtnMsg = integrationSearchService.updateEtcCn(crdn.getEtcCn(), crdnIds);
if(rtnMsg.contains("[S]")) {
saved = true;
}
mav.addObject("saved", saved); mav.addObject("saved", saved);
return mav; return mav;

Loading…
Cancel
Save