How do I utilize Identity Framework and AspNetUser Table?
Hello,
I am building an MVC app where people will need to sign up. They can then upload stuff to the app, so I want to ensure that the relevant information is displayed respective to each user. So for example, if I have a notes table/model, do I just need to add public string? OwnerID { get; set; }?
Should I also create a new model for users?
2 Replies
Unless you want to customize the user model, then just the basic
IdentityUser
is fine
And to create a relationship you can either reference IdentityUser
, reference that and a key, or just a key and use additional configuration
The customary "convention over configuration" way would be
Assuming IdentityUser.Id
is a string
of courseThank you so much! 🙏