I right click my context and and select either of the View Entity Data Model options and get an error similar to:
Could not load type \'*.Business.Entities.Authentication.ApplicationUser\' from assembly \'*.Business.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'.
ApplicationUser inherits from Microsoft.AspNet.Identity.EntityFramework.IdentityUser
I've modified relationships on the other Identity tables, so that my ApplicationUser class could take advantage of the correct foreign key association(userId instead of ApplicationUser_Id).
FluentAPI for ApplicationUser:
Public Class Mappings
Inherits Data.Entity.ModelConfiguration.EntityTypeConfiguration(Of ApplicationUser)
Public Sub New()
Me.ToTable("TableUser")
Me.Property(Function(p) p.Id).HasColumnName("USERID")
Me.Property(Function(p) p.Email).HasMaxLength(256).IsUnicode(False)
Me.Property(Function(p) p.UserName).HasMaxLength(256).IsUnicode(False)
Me.Property(Function(p) p.PasswordHash).HasMaxLength(256).IsUnicode(False)
Me.Property(Function(p) p.SecurityStamp).HasMaxLength(256).IsUnicode(False)
Me.Property(Function(p) p.PhoneNumber).HasMaxLength(256).IsUnicode(False)
'Me.HasMany(Function(s) s.Logins).WithRequired().HasForeignKey(Function(f) f.UserId)
'Me.HasMany(Function(s) s.Roles).WithRequired().HasForeignKey(Function(f) f.UserId)
'Me.HasMany(Function(s) s.Claims).WithRequired().HasForeignKey(Function(f) f.UserId)
End Sub
End Class
I right click my context and and select either of the View Entity Data Model options and get an error similar to:
ApplicationUser inherits from Microsoft.AspNet.Identity.EntityFramework.IdentityUser
I've modified relationships on the other Identity tables, so that my ApplicationUser class could take advantage of the correct foreign key association(userId instead of ApplicationUser_Id).
FluentAPI for ApplicationUser: