예제 #1
0
        // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(IApplicationBuilder app,
                              IHostingEnvironment env,
                              ILoggerFactory loggerFactory,
                              IServiceProvider serviceProvider,
                              IncidentContext incidentContext)
        {
            LoggingStartup.AddLogging(env, loggerFactory, serviceProvider, _configuration);

            app.AddMiddleware(env, _configuration);

            AutoMapperStartup.InitializeAutomapper();

            if (_env.IsDevelopment())
            {
                SeedType seedType = _configuration["seedDataType"] == "manyEvents" ? SeedType.ManyEvents : SeedType.Basic;

                SeedData.Add(incidentContext, seedType);
            }
        }
예제 #2
0
 public void ConfigureAutomapper()
 => AutoMapperStartup.InitializeAutomapper();