I am trying to use ABP Framework Core 8.
After running Add-Migration and Update-Database, all of the created tables have Abp
prefix.
Such as: AbpUsers
, AbpRoles
, AbpFeatures
, ...
How can I remove Abp
from table names?
Is it possible to remove prefix in free version for default tables?
Can I use ABP Framework for backend only not for frontend?
I have tried following:
protected override void OnModelCreating(DbModelBuilder modelBuilder)
{
base.OnModelCreating(modelBuilder);
modelBuilder.ChangeAbpTablePrefix<Tenant, Role, User>("");
}
builder.Entity<IdentityUser>(b =>
{
b.ToTable("Users", AbpIdentityDbProperties.DbSchema);
}); inside some override class in migrator.
Go to:
public static class *YourProjectName*EfCoreEntityExtensionMappings{
}
Inside it there will be a method
public static void Configure()
Inside it there will be
OneTimeRunner.Run(() =>
{}
Inside this scope, add:
string newDbTablePrefix = "";
AbpIdentityDbProperties.DbTablePrefix = newDbTablePrefix; //Identity
It will rename AbpUsers to Users.