Commit cceb2a44 by fudahua

登陆接口

parent 6b95acc5
...@@ -193,8 +193,8 @@ public class LoginController extends WebBaseController{ ...@@ -193,8 +193,8 @@ public class LoginController extends WebBaseController{
//判断是否存在random //判断是否存在random
AES aes = SecureUtil.aes(LOGIN_KEY.getBytes()); AES aes = SecureUtil.aes(LOGIN_KEY.getBytes());
String o = aes.decryptStr(random); String o = aes.decryptStr(random);
if(o == null){ if (o == null || StringUtils.isBlank(wxEnterpriseId)) {
logger.info("解密异常"); logger.info("解密异常");
ModelAndView model = new ModelAndView(new RedirectView("/haoban-3/#/gic-error", false,false)); ModelAndView model = new ModelAndView(new RedirectView("/haoban-3/#/gic-error", false,false));
return model; return model;
} }
...@@ -207,16 +207,8 @@ public class LoginController extends WebBaseController{ ...@@ -207,16 +207,8 @@ public class LoginController extends WebBaseController{
ModelAndView model = new ModelAndView(new RedirectView("/haoban-3/#/gic-error", false,false)); ModelAndView model = new ModelAndView(new RedirectView("/haoban-3/#/gic-error", false,false));
return model; return model;
} }
WxEnterpriseDTO detailDTO = null;
if (StringUtils.isNotBlank(wxEnterpriseId)) { WxEnterpriseDTO detailDTO = enterpriseDTOList.stream().filter(dto -> dto.getWxEnterpriseId().equals(wxEnterpriseId)).findFirst().orElse(null);
detailDTO = enterpriseDTOList.stream().filter(dto -> dto.getWxEnterpriseId().equals(wxEnterpriseId)).findFirst().orElse(null);
} else if (enterpriseDTOList.size() > 1) {
detailDTO = enterpriseDTOList.get(0);
} else {
logger.info("登陆选择多个企业:{}", JSONObject.toJSONString(enterpriseDTOList));
ModelAndView model = new ModelAndView(new RedirectView("/haoban-3/#/login", false, false));
return model;
}
if (null == detailDTO) { if (null == detailDTO) {
logger.info("登录失败,不存在对应企业:{}", o); logger.info("登录失败,不存在对应企业:{}", o);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment