// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(
            IApplicationBuilder app,
            IWebHostEnvironment env,
            IInsertDummyService insertDummyService
            )
        {
            if (env.IsDevelopment())
            {
                app.UseDeveloperExceptionPage();
            }

            app.UseHttpsRedirection();

            app.UseRouting();

            app.UseAuthorization();

            app.UseEndpoints(endpoints => { endpoints.MapControllers(); });

            app.UseSwagger();
            app.UseSwaggerUI(c =>
            {
                c.SwaggerEndpoint("/swagger/v1/swagger.json", "v1");
            });

            insertDummyService.Init();
        }
Beispiel #2
0
 protected override void OnInit()
 {
     _productRepo        = Get <IRepository <Product> >();
     _insertDummyService = Get <IInsertDummyService>();
     _insertDummyService.Init();
     base.OnInit();
 }
Beispiel #3
0
 protected override void OnInit()
 {
     _insertDummyService = Get <IInsertDummyService>();
     _insertDummyService.Init();
     base.OnInit();
 }