15832d1ae3
Removed all UserType logic and references, replacing them with a new Role model and management system. Introduced RoleManager service, repository, and API endpoint for role CRUD operations. Updated user flows and JWT claims to use RoleCode. Removed admin-only user CRUD endpoints. Updated DI, documentation, and error handling for consistency. Appsettings and DTOs now reflect the new role-based approach.
14 lines
498 B
C#
14 lines
498 B
C#
using AuthHex.Models;
|
|
|
|
namespace AuthHex.Interfaces
|
|
{
|
|
public interface IRoleManageRepository
|
|
{
|
|
Task<Role> AddRoleAsync(Role role, CancellationToken ct = default);
|
|
Task<Role?> GetRoleByIdAsync(Guid roleId, CancellationToken ct = default);
|
|
Task<List<Role>> ListRolesAsync(CancellationToken ct = default);
|
|
//Task<bool> RoleInUseAsync(Guid roleId, CancellationToken ct = default);
|
|
Task DeleteRoleAsync(Role role, CancellationToken ct = default);
|
|
}
|
|
}
|