Auth DB schema migration, ef design, auth

This commit is contained in:
femsci 2023-10-01 09:41:10 +02:00
parent a0d5df1c52
commit 5e4bfaa95e
Signed by: femsci
GPG key ID: 08F7911F0E650C67
22 changed files with 1106 additions and 38 deletions

View file

@ -0,0 +1,31 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text.Json.Serialization;
using System.Threading.Tasks;
using Interlinked.Shared.Model;
using Microsoft.AspNetCore.Identity;
namespace Interlinked.User.Models;
public class UserDomain : IdentityUser<long>
{
[EmailAddress]
public required string Email { get; set; }
[MaxLength(96)]
public string? Name { get; set; }
[JsonIgnore]
public byte[] Salt { get; set; } = default!;
[JsonIgnore]
public byte[] Hash { get; set; } = default!;
public string? City { get; set; }
[StringLength(2)]
public string CountryCode { get; set; } = "XX";
public string? Gender { get; set; } = "cat";
public DateTime? DayOfBirth { get; set; }
public ICollection<Tag> Interests { get; set; } = default!;
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public DateTime CreatedTimestamp { get; set; }
}