Summary Update.
This commit is contained in:
@@ -2,9 +2,21 @@ using SurrealDb.Net.Models;
|
||||
|
||||
namespace RelayServer.Models;
|
||||
|
||||
/// <summary>
|
||||
/// Surreal record for the `user_roles` table. Join table linking users to roles.
|
||||
///
|
||||
/// Invariant: ServerBootstrapService.SetUserRoleAsync guarantees exactly one row per user.
|
||||
/// Multi-role-per-user isn't currently supported by the permission ladder — adding it would
|
||||
/// just be a matter of removing the bootstrap's "delete stale rows" step.
|
||||
/// </summary>
|
||||
public class UserRoles : Record
|
||||
{
|
||||
/// <summary>"users:keeper317" — the assignee.</summary>
|
||||
public required string UserId { get; set; }
|
||||
|
||||
/// <summary>"roles:abc" — the role being granted.</summary>
|
||||
public required string RoleId { get; set; }
|
||||
|
||||
/// <summary>When the assignment was made.</summary>
|
||||
public required DateTime AssignedAt { get; set; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user