| | |
| | | return loginResult; |
| | | } |
| | | |
| | | //4、判断密码是否正确(平台的checkLogin方法好像有对密码进行比对的方法) |
| | | /*if (checkPassword) { |
| | | boolean passwordIsEqual = userQueryService.checkPasswordEqual(userDTO.getPassword(), user.getOid()); |
| | | if (!passwordIsEqual) { |
| | | if (logger.isDebugEnabled()) { |
| | | logger.debug("{}密码不正确", user.getId()); |
| | | } |
| | | } |
| | | }*/ |
| | | |
| | | //5、调用平台登录接口,进行登录 |
| | | MachineInfo machine = getMachieInfo(clientInfo); |
| | | machine.country = clientInfo.getCountry(); |
| | |
| | | * @throws VciBaseException 删除会话信息出错的时候会抛出异常 |
| | | */ |
| | | @Override |
| | | public void logout(String userToken) throws VciBaseException { |
| | | public void logout(String userToken) throws Exception { |
| | | VciBaseUtil.alertNotNull(userToken,"用户的会话许可"); |
| | | Map<String, Object> logoutpluginBeanMap =ApplicationContextProvider.getApplicationContext().getBeansWithAnnotation(VciLogoutPlugin.class); |
| | | if(!CollectionUtils.isEmpty(logoutpluginBeanMap)){ |
| | |
| | | } |
| | | //清除存当前登录的用户(总数-1) |
| | | redisService.decreOnlineUser(VConstant.CURRENT_LOGGED_USERS_KEY); |
| | | sessionForLogin.logout(userToken); |
| | | sessionForLogin.logout( |
| | | WebThreadLocalUtil.getCurrentUserSessionInfoInThread().getToken() |
| | | ,WebThreadLocalUtil.getCurrentUserSessionInfoInThread().getUserId() |
| | | ); |
| | | if(!CollectionUtils.isEmpty(logoutpluginBeanMap)){ |
| | | logoutpluginBeanMap.forEach((k,v) -> { |
| | | Method[] methods = v.getClass().getDeclaredMethods(); |