public IdentityMigrationsDbContext CreateDbContext(string[] args)
        {
            IdentityEfCoreEntityExtensionMappings.Configure();

            var configuration = BuildConfiguration();

            var builder = new DbContextOptionsBuilder <IdentityMigrationsDbContext>()
                          .UseSqlServer(configuration.GetConnectionString("Default"));

            return(new IdentityMigrationsDbContext(builder.Options));
        }
Пример #2
0
 public override void PreConfigureServices(ServiceConfigurationContext context)
 {
     IdentityEfCoreEntityExtensionMappings.Configure();
 }