I am implementing Stripe JS into my project which upon validation will give me a token per user. I want to store that token in the AbpUsers table. The ABP dbContext file seems to be compiled. Do I just manually update the SQL table or do you have another standard way of doing this?
I guess a better way of asking this is how do I update the out of the box ABP database tables?
I am using the .Net Core template.
4 Answer(s)
-
0
Just change(extend,..) the user class and update by using code-first migrations. Certainly don't do it manually on your sql database.
-
0
Please forgive me but this is my first code-first project. I'm used to the .edmx file doing these types of things for me.
Your answer is exactly what I thought but I do not see the AbpUser.cs class anywhere. Do you mean extend it here "MyProjectName.Authorization.Users.User.cs"? Or, do yo mean create my own User.cs that inherits AbpUser like "public class User : AbpUser<User>" and extend it here?
-
0
I figured it out.
I just added this:
public virtual string StripeToken { get; set; }
to this file: MyProjectName.Authorization.Users.User.cs
Thanks
-
0
Hi,
You can also take a look at this document <a class="postlink" href="https://aspnetzero.com/Documents/Extending-Existing-Entities">https://aspnetzero.com/Documents/Extend ... g-Entities</a>