У меня есть ASP.NET Core Identity ApplicationUser
Я унаследовал от IdentityUser
и дал ему ICollection
модели, которую я называю Lockup
. Я должен быть в состоянии позвонить _context.ApplicationUser.Include(u => u.Lockups)
, но Lockup
нигде не найти для ApplicationUser
. Я могу позвонить _context.Lockup.ApplicationUser
просто отлично.
Вот код для двух моих моделей:
public class ApplicationUser : IdentityUser
{
public virtual ICollection<Lockup> Lockups { get; set; }
}
public class Lockup
{
public int ID { get; set; }
public DateTime CreatedAt { get; set; }
[other properties...]
public string ApplicationUserId { get; set; }
public virtual ApplicationUser ApplicationUser { get; set; }
}
Какую простую вещь мне не хватает в отношениях здесь? Спасибо за вашу помощь!
