Refactor authentication logic to unify user account handling and update database schema for user accounts

This commit is contained in:
zyh
2025-08-24 15:54:21 +08:00
parent be437a360d
commit c65c03b933
22 changed files with 256 additions and 288 deletions

View File

@@ -10,7 +10,7 @@ import reactor.core.publisher.Mono;
@RestController
@RequestMapping("/api/users")
public class UserController {
public class UserController {
private final UserService userService;
public UserController(UserService userService) {

View File

@@ -40,9 +40,8 @@ public class AuthController {
put("userType", c.get("userType"));
put("userId", c.get("userId"));
put("username", c.get("username"));
put("role", c.get("role"));
if ("admin".equals(c.get("userType"))) put("role", c.get("role"));
put("exp", c.getExpiration());
}};
}
}