Skip to content

Instantly share code, notes, and snippets.

@jjwilliams42
Created November 18, 2017 07:57
Show Gist options
  • Save jjwilliams42/ca1a6ae4703f1d9975e69be218b00920 to your computer and use it in GitHub Desktop.
Save jjwilliams42/ca1a6ae4703f1d9975e69be218b00920 to your computer and use it in GitHub Desktop.
AspNetUser : IUserAuth
[Alias("AspNetUsers")]
public class User : IUserAuth
{
[Index]
public string Email { get; set; }
[Required]
public bool EmailConfirmed { get; set; } = false;
public string PasswordHash { get; set; }
public string SecurityStamp { get; set; }
public string PhoneNumber { get; set; }
[Required]
public bool PhoneNumberConfirmed { get; set; }
[Required]
public bool TwoFactorEnabled { get; set; }
public DateTime? LockoutEndDateUtc { get; set; }
[Required]
public bool LockoutEnabled { get; set; }
[Required]
public int AccessFailedCount { get; set; }
[Required]
[Index]
public string UserName { get; set; }
[Required]
public bool IsActive { get; set; }
[Required]
public bool Deleted { get; set; }
[Reference]
public List<UserPermission> UserPermissions { get; set; }
[Reference]
public List<AspNetUserRole> UserRoles { get; set; }
// Properties from IUserAuth
[AutoIncrement]
public int Id { get; set; }
public string PrimaryEmail { get; set; }
public string Salt { get; set; }
public string DigestHa1Hash { get; set; }
public List<string> Roles { get; set; }
public List<string> Permissions { get; set; }
public int? RefId { get; set; }
public string RefIdStr { get; set; }
public int InvalidLoginAttempts { get; set; }
public DateTime? LastLoginAttempt { get; set; }
public DateTime? LockedDate { get; set; }
public DateTime CreatedDate { get; set; }
public DateTime ModifiedDate { get; set; }
public string DisplayName { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string Company { get; set; }
public DateTime? BirthDate { get; set; }
public string BirthDateRaw { get; set; }
public string Address { get; set; }
public string Address2 { get; set; }
public string City { get; set; }
public string State { get; set; }
public string Country { get; set; }
public string Culture { get; set; }
public string FullName { get; set; }
public string Gender { get; set; }
public string Language { get; set; }
public string MailAddress { get; set; }
public string Nickname { get; set; }
public string PostalCode { get; set; }
public string TimeZone { get; set; }
public Dictionary<string, string> Meta { get; set; }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment