public LearnAbp2MigrationsDbContext CreateDbContext(string[] args)
        {
            LearnAbp2EfCoreEntityExtensionMappings.Configure();

            var configuration = BuildConfiguration();

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

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