This commit is contained in:
lsy
2017-12-13 16:10:06 +08:00
parent 7c4689c895
commit 91d0a44eff
3 changed files with 7 additions and 3 deletions
@@ -6,4 +6,6 @@
- `ms.security.browser.rememberMeSeconds` 记住我的时间,单位是秒。默认的时间是3600秒
`JSON` json形式的响应
- 定义自己的根据用户名获取密码的bean,定义自己的bean的名字为`userServiceImpl`即可
- `/authentication/require`处理身份认证跳转的接口地址
- `/authentication/require`处理身份认证跳转的接口地址
- 需要注入`userServiceImpl`获取用户详细信息的bean
- 需要注入数据源`masterDataSource`用于记住我功能的bean
@@ -35,7 +35,7 @@ public class MsUserDetialsService implements UserDetailsService {
log.info("根据username:{}获取密码",username);
User userByUsername = userService.getUserByUsername(username);
return userByUsername;
/*从数据库中去查找用户的密码 admin 是从数据库中查询出来的用户的密
/*从数据库中去查找用户的密码 admin 是从数据库中查询出来的用户的密码
return new User(username,passwordEncoder.encode("admin"), AuthorityUtils.commaSeparatedStringToAuthorityList("admin"));*/
}
+3 -1
View File
@@ -39,4 +39,6 @@ classes
### jRebel ###
.rebel.xml.bak
rebel.xml
rebel.xml
node_modules