diff --git a/src/main/java/cokr/xit/fims/framework/biz/cmm/web/XitLoginController.java b/src/main/java/cokr/xit/fims/framework/biz/cmm/web/XitLoginController.java index 98c8ea93..055c0149 100644 --- a/src/main/java/cokr/xit/fims/framework/biz/cmm/web/XitLoginController.java +++ b/src/main/java/cokr/xit/fims/framework/biz/cmm/web/XitLoginController.java @@ -49,23 +49,19 @@ public class XitLoginController extends AbstractController { private XitFrameCrudService xitFrameCrudService; - - private String LOGIN_PAGE ="framework/biz/login/XitLoginUsr"; + private String LOGIN_PAGE = "fimslogin"; private String ACCESS_DENIED_PAGE = "login/XitAccessDenied"; private String MAIN_PAGE = "/framework/biz/cmm/mainPage.do"; - - private String MAIN_PAGE_USR =""; - /** * 로그인 후 메인화면으로 들어간다 - * + * * @param * @return 로그인 페이지 - * @exception Exception + * @throws Exception */ @RequestMapping(name = "", value = "/actionMain") public String actionMain() @@ -78,15 +74,14 @@ public class XitLoginController extends AbstractController { return LOGIN_PAGE; } - String url = this.getMainPageUrlByUserSe(); - return "forward:"+url; + return "forward:" + "/framework/biz/cmm/mainPage.do"; } /** *
* 메소드 설명: 일반(스프링 시큐리티) 로그인을 처리 한다. *- * + * * @param loginVO 아이디, 비밀번호가 담긴 LoginVO * @param response 로그인결과(세션정보) * @param request 세션처리를 위한 HttpServletRequest @@ -98,7 +93,7 @@ public class XitLoginController extends AbstractController { */ @RequestMapping(name = "", value = "/actionSecurityLogin") public String actionSecurityLogin(@ModelAttribute("loginVO") XitLoginVO loginVO, HttpServletResponse response, - HttpServletRequest request, ModelMap model, @RequestParam Map
메소드 설명: 아이디 찾기 페이지 요청별 팝업+ * * @param page * @param vo * @return + * @throws Exception * @author: 김동규 - * @throws Exception * @date: 2020. 10. 21. */ @RequestMapping(name = "", value = "/findIdPopup/{page}") - public ModelAndView findIdPopup(@PathVariable String page, @ModelAttribute("xitLoginVO") XitLoginVO vo) throws Exception{ + public ModelAndView findIdPopup(@PathVariable String page, @ModelAttribute("xitLoginVO") XitLoginVO vo) throws Exception { ModelAndView mav = new ModelAndView(); - if(page.endsWith(".do") || page.endsWith(".ajax")){ - page = page.substring(0,page.lastIndexOf(".")); + if (page.endsWith(".do") || page.endsWith(".ajax")) { + page = page.substring(0, page.lastIndexOf(".")); } switch (page) { - case "input": //아이디 찾기 -정보입력 페이지 - mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"login/findIdFormPopup.popup"); + case "input": //아이디 찾기 -정보입력 페이지 + mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH + "login/findIdFormPopup.popup"); break; - case "inputEvr": //(모든사용자)아이디 찾기 -정보입력 페이지 - mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"login/findIdEvrFormPopup.popup"); + case "inputEvr": //(모든사용자)아이디 찾기 -정보입력 페이지 + mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH + "login/findIdEvrFormPopup.popup"); break; - - case "result": //아이디 찾기 -결과 - XitLoginVO loginVO = xitLoginService.findId(vo); - mav.addObject("userAcnt",loginVO.getId()); - mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"login/findIdResultFormPopup.popup"); + + case "result": //아이디 찾기 -결과 + XitLoginVO loginVO = xitLoginService.findId(vo); + mav.addObject("userAcnt", loginVO.getId()); + mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH + "login/findIdResultFormPopup.popup"); break; - + default: throw new RuntimeException("유효하지 않은 요청 입니다."); } return mav; } - - + + /** *
메소드 설명: 비밀번호 찾기 페이지 요청별 팝업+ * * @param xitUserInfoVO * @param page * @throws IOException @@ -298,20 +292,20 @@ public class XitLoginController extends AbstractController { public ModelAndView findPwdPopup(@ModelAttribute("xitUserInfoVO") XitUserInfoVO xitUserInfoVO, @PathVariable String page) throws RuntimeException { ModelAndView mav = new ModelAndView(); - if(page.endsWith(".do") || page.endsWith(".ajax")){ - page = page.substring(0,page.lastIndexOf(".")); + if (page.endsWith(".do") || page.endsWith(".ajax")) { + page = page.substring(0, page.lastIndexOf(".")); } switch (page) { - case "input": //비밀번호 찾기 -정보입력 페이지 - mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"login/findPwdFormPopup.popup"); + case "input": //비밀번호 찾기 -정보입력 페이지 + mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH + "login/findPwdFormPopup.popup"); break; - case "inputEvr": //(모든사용자)비밀번호 찾기 -정보입력 페이지 - mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"login/findPwdEvrFormPopup.popup"); + case "inputEvr": //(모든사용자)비밀번호 찾기 -정보입력 페이지 + mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH + "login/findPwdEvrFormPopup.popup"); break; - case "result": //비밀번호 찾기 -결과 - mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH +"login/findPwdResultFormPopup.popup"); + case "result": //비밀번호 찾기 -결과 + mav.setViewName(FrameworkConstants.FRAMEWORK_JSP_BASE_PATH + "login/findPwdResultFormPopup.popup"); break; default: @@ -319,45 +313,46 @@ public class XitLoginController extends AbstractController { } return mav; } - + /** *
메소드 설명: 비밀번호 찾기 CRUD 처리+ * * @param res * @param model * @param session - * @param vo xitUserInfoVO + * @param vo xitUserInfoVO * @return + * @throws Exception * @author: 김동규 - * @throws Exception * @date: 2020. 10. 21. */ - @RequestMapping(name = "", value = "FindPwd_{cmd}_proc", method=RequestMethod.POST) + @RequestMapping(name = "", value = "FindPwd_{cmd}_proc", method = RequestMethod.POST) public void FindPwd_cmd_proc(HttpServletResponse res, Model model - , HttpSession session - , @ModelAttribute("xitLoginVO") XitLoginVO vo - , @PathVariable String cmd - , HttpServletRequest request - , HttpServletResponse response - ) throws Exception { - + , HttpSession session + , @ModelAttribute("xitLoginVO") XitLoginVO vo + , @PathVariable String cmd + , HttpServletRequest request + , HttpServletResponse response + ) throws Exception { + String sLocationUrl = null; Map
메소드 설명: (일반/기업/업무)사용자 유형별 메인페이지 경로를 반환 한다. - * -사용자 유형별 지정한 메인페이지 설정값이 없을 경우 default경로(Globals.Xit.MainPage)를 반환 한다. - * [사용자 유형별 메인페이지 설정] - * Globals.Xit.MainPage.Gnr //일반회원 - * Globals.Xit.MainPage.Ent //기업회원 - * Globals.Xit.MainPage.Usr //업무사용자 - *- * @return String 요청처리 후 응답객체 - * @author: 박민규 - * @date: 2020. 11. 20. - */ - private String getMainPageUrlByUserSe() { - String url = MAIN_PAGE; - XitLoginVO loginVO = XitCmmnUtil.getUserInfo(); - USER_SE userSe = USER_SE.valueOf(loginVO.getUserSe()); - if(!XitCmmnUtil.isEmpty(userSe)) { - switch (userSe) { - case USR: //업무사용자 - if(XitCmmnUtil.notEmpty(MAIN_PAGE_USR)) - url = MAIN_PAGE_USR; - break; - default: - break; - } - } - - return url; - } - - -} - -class RequestWrapperForSecurity extends HttpServletRequestWrapper { - private String username = null; - private String password = null; - - public RequestWrapperForSecurity(HttpServletRequest request, String id, String passwd) { - super(request); - this.username = id; - this.password = passwd; - } - - @Override - public String getServletPath() { - return ((HttpServletRequest) super.getRequest()).getContextPath() + "/xit_security_login"; - } - - @Override - public String getRequestURI() { - return ((HttpServletRequest) super.getRequest()).getContextPath() + "/xit_security_login"; + return resultMap; } - @Override - public String getParameter(String name) { - if (name.equals("xit_security_username")) { - return username; - } - - if (name.equals("xit_security_password")) { - return password; - } - return super.getParameter(name); - } } diff --git a/src/main/webapp/WEB-INF/jsp/fims/framework/biz/login/XitLoginEvrUsr.jsp b/src/main/webapp/WEB-INF/jsp/fims/framework/biz/login/XitLoginEvrUsr.jsp deleted file mode 100644 index 1b4fa014..00000000 --- a/src/main/webapp/WEB-INF/jsp/fims/framework/biz/login/XitLoginEvrUsr.jsp +++ /dev/null @@ -1,322 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%> -<%@ include file="/WEB-INF/jsp/include/taglib.jsp" %> -<%@ include file="/WEB-INF/jsp/include/fims/taglib.jsp" %> - - - - - - - -