Witajcie,
Mój problem jest taki, że nie mogę rozszerzyć identity o własne pola. Rozszerzyłem klasę IdentityUser
public class ApplicationUser : IdentityUser
{
public virtual ICollection<Order> Orders { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string Addresss { get; set; }
public string CodeAndCity { get; set; }
[RegularExpression(@"(\+\d{2})*[\d\s-]+", ErrorMessage = "Błędny format numeru telefonu.")]
public string PhonrNumber { get; set; }
[EmailAddress(ErrorMessage = "Błędny format adresu e-mail.")]
public string Email { get; set; }
public UserData UserData { get; internal set; }
}
oraz zmodyfikowałem startup
services.AddIdentity<ApplicationUser, IdentityRole>().AddEntityFrameworkStores<StoreContext>();
Niestety migracje nie dodają instrukcji do utworzenia nowych kolumn.
Pozdrawiam!