Hello team.
I just downloaded the asp net plus module zero start up application for my own project. I have added my additional properties into the user class which inherited from abpuser but my primary key is a string not a long. Please how do I override the primary key?
5 Answer(s)
-
0
Unfortunately, ABP forces that UserId always must be long. You can not change it. This is by design.
-
0
So is there a way to work around it
-
0
No. Have you an existing application? If you are creating a new one, it should not be a problem actually.
-
0
I am trying to create a new application that relate to staffs and the staff id is unique. This is what I wanted to use as the primary key initially. Is there another way I can go about it.thanks.
-
0
If you have a staffId that is string, then you can add it to User as a normal property, not primary key. You can define a unique index to prevent duplicate entries.