修改用户缓存结构.

This commit is contained in:
lijiahangmax
2023-11-21 00:39:15 +08:00
parent 6c056cecff
commit 8fe105fc8a
14 changed files with 108 additions and 72 deletions

View File

@@ -35,6 +35,6 @@ public class LoginUser {
private Long timestamp;
@Schema(description = "角色")
private List<String> roles;
private List<UserRole> roles;
}

View File

@@ -0,0 +1,28 @@
package com.orion.ops.framework.common.security;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
/**
* 用户角色
*
* @author Jiahang Li
* @version 1.0.0
* @since 2023/11/20 23:39
*/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(onlyExplicitlyIncluded = true)
@Schema(name = "UserRole", description = "用户角色")
public class UserRole {
@EqualsAndHashCode.Include
@Schema(description = "id")
private Long id;
@Schema(description = "角色")
private String code;
}