|
|
|
@ -24,6 +24,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
|
|
import org.springframework.web.bind.annotation.RequestParam;
|
|
|
|
|
import org.springframework.web.bind.annotation.ResponseBody;
|
|
|
|
|
import org.springframework.web.servlet.ModelAndView;
|
|
|
|
|
|
|
|
|
|
import egovframework.rte.ptl.mvc.tags.ui.pagination.PaginationInfo;
|
|
|
|
|
import kr.xit.framework.biz.cmm.service.XitFrameCodeService;
|
|
|
|
@ -48,7 +49,7 @@ import kr.xit.framework.support.util.AjaxUtils;
|
|
|
|
|
* @version 1.0 Copyright(c) XIT All rights reserved.
|
|
|
|
|
*/
|
|
|
|
|
@Controller
|
|
|
|
|
@RequestMapping("/_mng_/usr/reg/")
|
|
|
|
|
@RequestMapping("/framework/biz/mng/usr")
|
|
|
|
|
public class XitUserRegMngController {
|
|
|
|
|
|
|
|
|
|
private static final Logger logger = LoggerFactory.getLogger(XitUserRegMngController.class);
|
|
|
|
@ -66,15 +67,26 @@ public class XitUserRegMngController {
|
|
|
|
|
private int PAGE_UNIT;
|
|
|
|
|
@Value("#{prop['Globals.Xit.Pagination.PageSize']}")
|
|
|
|
|
private int PAGE_SIZE;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@RequestMapping(value = "mngUserRegMgtForm", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
public ModelAndView mngUserRegMgtForm() {
|
|
|
|
|
ModelAndView mav = new ModelAndView();
|
|
|
|
|
|
|
|
|
|
//사용자상태코드를 코드정보로부터 조회
|
|
|
|
|
mav.addObject("emplyrSttusCode_result", xitFrameCodeService.findCmmnDetailCodes("XIT013"));//사용자상태코드목록
|
|
|
|
|
|
|
|
|
|
return mav;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* <pre>메소드 설명: 사용자등록관리 목록 페이지</pre>
|
|
|
|
|
* @return String 요청처리 후 응답객체
|
|
|
|
|
* @author: 박민규
|
|
|
|
|
* @date: 2020. 4. 8.
|
|
|
|
|
*/
|
|
|
|
|
@RequestMapping(value = "UserRegMng_list.do", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
public String UserRegMng_list(@ModelAttribute("userSearchVO") XitUserRegMngSearchVO searchVO, ModelMap model) {
|
|
|
|
|
@RequestMapping(value = "mngUserRegMgtForm2", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
public String mngUserRegMgtForm2(@ModelAttribute("userSearchVO") XitUserRegMngSearchVO searchVO, ModelMap model) {
|
|
|
|
|
|
|
|
|
|
// 내역 조회
|
|
|
|
|
|
|
|
|
@ -100,8 +112,9 @@ public class XitUserRegMngController {
|
|
|
|
|
//사용자상태코드를 코드정보로부터 조회
|
|
|
|
|
model.addAttribute("emplyrSttusCode_result", xitFrameCodeService.findCmmnDetailCodes("XIT013"));//사용자상태코드목록
|
|
|
|
|
|
|
|
|
|
return FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/usr/reg/XitUserRegMng_list";
|
|
|
|
|
return FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/usr/mngUserRegMgtForm";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* <pre>메소드 설명: 사용자등록관리 목록 페이지 조회</pre>
|
|
|
|
|
* @return String 요청처리 후 응답객체
|
|
|
|
@ -161,14 +174,14 @@ public class XitUserRegMngController {
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* <pre>메소드 설명: 요청 페이지로 이동 한다.</pre>
|
|
|
|
|
* @param page
|
|
|
|
|
* @param cmd
|
|
|
|
|
* @param tilesDef 타일즈 적용 Type(none: tiles 미적용)
|
|
|
|
|
* @param model
|
|
|
|
|
* @return String 요청처리 후 응답객체
|
|
|
|
|
* @author: 박민규
|
|
|
|
|
* @date: 2020. 4. 8.
|
|
|
|
|
*/
|
|
|
|
|
@RequestMapping(value = "UserRegMng_{cmd}.do", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
@RequestMapping(value = "UserRegMng_{cmd}", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
public String UserRegMng_page(@PathVariable String cmd
|
|
|
|
|
, @RequestParam(value="tilesDef", required=false, defaultValue="") String tilesDef
|
|
|
|
|
, @ModelAttribute("userSearchVO") XitUserRegMngSearchVO searchVO
|
|
|
|
@ -213,20 +226,20 @@ public class XitUserRegMngController {
|
|
|
|
|
|
|
|
|
|
if(!"".equals(tilesDef))
|
|
|
|
|
tilesDef = "."+tilesDef;
|
|
|
|
|
return FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/usr/reg/XitUserRegMng_"+cmd+tilesDef;
|
|
|
|
|
return FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/usr/XitUserRegMng_"+cmd+tilesDef;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* <pre>메소드 설명: 요청 팝업 페이지 이동 한다.</pre>
|
|
|
|
|
* @param page
|
|
|
|
|
* @param cmd
|
|
|
|
|
* @param model
|
|
|
|
|
* @return String 요청처리 후 응답객체
|
|
|
|
|
* @author: 박민규
|
|
|
|
|
* @date: 2020. 4. 8.
|
|
|
|
|
*/
|
|
|
|
|
@RequestMapping(value = "UserRegMng_{cmd}_popup.do", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
@RequestMapping(value = "UserRegMng_{cmd}_popup", method={RequestMethod.GET, RequestMethod.POST})
|
|
|
|
|
public String UserRegMng_page_popup(
|
|
|
|
|
@PathVariable String cmd
|
|
|
|
|
, @ModelAttribute("userSearchVO") XitUserRegMngSearchVO searchVO
|
|
|
|
@ -244,7 +257,7 @@ public class XitUserRegMngController {
|
|
|
|
|
default:
|
|
|
|
|
throw new RuntimeException("유효하지 않은 요청 입니다.");
|
|
|
|
|
}
|
|
|
|
|
return FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/usr/reg/XitUserRegMng_"+cmd+"_popup"+TILES_TYPE.POPUP.getVal();
|
|
|
|
|
return FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"mng/usr/XitUserRegMng_"+cmd+"_popup"+TILES_TYPE.POPUP.getVal();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -257,7 +270,7 @@ public class XitUserRegMngController {
|
|
|
|
|
* @throws ServletException
|
|
|
|
|
* @date: 2020. 4. 8.
|
|
|
|
|
*/
|
|
|
|
|
@RequestMapping(value = "UserRegMng_{cmd}_proc.do", method=RequestMethod.POST)
|
|
|
|
|
@RequestMapping(value = "UserRegMng_{cmd}_proc", method=RequestMethod.POST)
|
|
|
|
|
public void UserRegMng_cmd_proc(@PathVariable String cmd
|
|
|
|
|
,@ModelAttribute("userManageVO") XitUserRegMngVO vo
|
|
|
|
|
,@RequestParam(value="checkedIdForDel", required=false, defaultValue="") String checkedIdForDel
|
|
|
|
@ -272,7 +285,7 @@ public class XitUserRegMngController {
|
|
|
|
|
/**
|
|
|
|
|
* 처리 분기
|
|
|
|
|
*/
|
|
|
|
|
String sLocationUrl = "forward:/_mng_/usr/reg/UserRegMng_list.do";
|
|
|
|
|
String sLocationUrl = "forward:/framework/biz/mng/usr/UserRegMng_list";
|
|
|
|
|
String message = null;
|
|
|
|
|
switch (cmd) {
|
|
|
|
|
case "insert": //등록
|
|
|
|
@ -283,7 +296,7 @@ public class XitUserRegMngController {
|
|
|
|
|
if (bindingResult.hasErrors()) {
|
|
|
|
|
// throw new RuntimeException(xitMessageSource.getMessage("fail.common.insert"));
|
|
|
|
|
message = xitMessageSource.getMessage("fail.common.insert");
|
|
|
|
|
sLocationUrl = "forward:/_mng_/usr/reg/UserRegMng_input.do";
|
|
|
|
|
sLocationUrl = "forward:/framework/biz/mng/usr/UserRegMng_input";
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
//처리
|
|
|
|
@ -292,10 +305,10 @@ public class XitUserRegMngController {
|
|
|
|
|
message = xitMessageSource.getMessage("success.common.insert");
|
|
|
|
|
} catch (RuntimeException e) {
|
|
|
|
|
message = e.getMessage();
|
|
|
|
|
sLocationUrl = "forward:/_mng_/usr/reg/UserRegMng_input.do";
|
|
|
|
|
sLocationUrl = "forward:/framework/biz/mng/usr/UserRegMng_input";
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
message = xitMessageSource.getMessage("fail.common.insert");
|
|
|
|
|
sLocationUrl = "forward:/_mng_/usr/reg/UserRegMng_input.do";
|
|
|
|
|
sLocationUrl = "forward:/framework/biz/mng/usr/UserRegMng_input";
|
|
|
|
|
}
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
@ -309,20 +322,20 @@ public class XitUserRegMngController {
|
|
|
|
|
// beanValidator.validate("userManageVO", vo, bindingResult);
|
|
|
|
|
if (bindingResult.hasErrors()) {
|
|
|
|
|
message = xitMessageSource.getMessage("fail.common.update");
|
|
|
|
|
sLocationUrl = "forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
//처리
|
|
|
|
|
try {
|
|
|
|
|
xitUserRegMngService.modifyProc(vo);
|
|
|
|
|
message = xitMessageSource.getMessage("success.common.update");
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
} catch (RuntimeException e) {
|
|
|
|
|
message = e.getMessage();
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
message = xitMessageSource.getMessage("fail.common.update");
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
}
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
@ -335,13 +348,13 @@ public class XitUserRegMngController {
|
|
|
|
|
try {
|
|
|
|
|
xitUserRegMngService.modifyPwdProc(uniqId, vo.getEmplyrId(), oldPassword, newPassword, newPassword2);
|
|
|
|
|
message = xitMessageSource.getMessage("success.common.update");
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
} catch (RuntimeException e) {
|
|
|
|
|
message = e.getMessage();
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
message = xitMessageSource.getMessage("fail.common.update");
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
}
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
@ -353,10 +366,10 @@ public class XitUserRegMngController {
|
|
|
|
|
break;
|
|
|
|
|
} catch (RuntimeException e) {
|
|
|
|
|
message = e.getMessage();
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
message = xitMessageSource.getMessage("fail.common.delete");
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/_mng_/usr/reg/UserRegMng_view.do":"forward:/_mng_/usr/reg/UserRegMng_edit.do";
|
|
|
|
|
sLocationUrl = "Y".equals(isViewPage)?"forward:/framework/biz/mng/usr/UserRegMng_view":"forward:/framework/biz/mng/usr/UserRegMng_edit";
|
|
|
|
|
}
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|