Add signup/signin with backend-issued JWT (Argon2 passwords in SurrealDB), role-based authorization policies, per-user data access levels, consent register and read audit log. Protect user endpoints and record sensitive reads.
15 lines
333 B
C#
15 lines
333 B
C#
using TarninaHub.Application.Dtos;
|
|
using TarninaHub.Application.Models;
|
|
|
|
namespace TarninaHub.Application.Mappings;
|
|
|
|
public static class UserMappings
|
|
{
|
|
public static UserResponse ToResponse(this UserAccount user) => new(
|
|
user.Id,
|
|
user.Phone,
|
|
user.Email,
|
|
user.Role,
|
|
user.OrganizationId);
|
|
}
|