mirror of
https://github.com/hs-web/hsweb-framework.git
synced 2026-06-06 05:17:46 +08:00
增加查看当前登录用户的权限
This commit is contained in:
@@ -55,7 +55,6 @@ public class AuthorizationController {
|
||||
private AuthorizationListenerDispatcher authorizationListenerDispatcher;
|
||||
|
||||
@GetMapping("/login-out")
|
||||
@AccessLogger("退出登录")
|
||||
@Authorize
|
||||
@ApiOperation("退出当前登录")
|
||||
public ResponseMessage exit(@ApiParam(hidden = true) Authentication authentication) {
|
||||
@@ -63,8 +62,14 @@ public class AuthorizationController {
|
||||
return ok();
|
||||
}
|
||||
|
||||
@GetMapping("/me")
|
||||
@Authorize
|
||||
@ApiOperation("当前登录用户权限信息")
|
||||
public ResponseMessage<Authentication> me(@ApiParam(hidden = true) Authentication authentication) {
|
||||
return ok(authentication);
|
||||
}
|
||||
|
||||
@PostMapping(value = "/login")
|
||||
@AccessLogger("授权")
|
||||
@ApiOperation("用户名密码登录")
|
||||
public ResponseMessage<String> authorize(@RequestParam @ApiParam("用户名") String username,
|
||||
@RequestParam @ApiParam("密码") String password,
|
||||
|
||||
Reference in New Issue
Block a user