using Monitoring.Core.Domain;

namespace Monitoring.Features.Users;

public record UserModel(Guid Id, string Username, string Role)
{
	public static UserModel FromEntity(User user)
	{
		return new UserModel(user.Id.Value, user.Username.Value, user.Role!.Name.Value);
	}
}