コード例 #1
0
        public VelaphiMigrationsDbContext CreateDbContext(string[] args)
        {
            VelaphiEfCoreEntityExtensionMappings.Configure();

            var configuration = BuildConfiguration();

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

            return(new VelaphiMigrationsDbContext(builder.Options));
        }
コード例 #2
0
 public override void PreConfigureServices(ServiceConfigurationContext context)
 {
     VelaphiEfCoreEntityExtensionMappings.Configure();
 }