// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IWebHostEnvironment env, DAL.Data.BD ctx) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); ctx.Database.EnsureDeleted(); ctx.Database.EnsureCreated(); } app.UseHttpsRedirection(); // Enable middleware to serve generated Swagger as a JSON endpoint. app.UseSwagger(); // Enable middleware to serve swagger-ui (HTML, JS, CSS, etc.), // specifying the Swagger JSON endpoint. app.UseSwaggerUI(c => { c.SwaggerEndpoint("/swagger/v1/swagger.json", "My API V1"); }); app.UseRouting(); app.UseAuthorization(); app.UseEndpoints(endpoints => { endpoints.MapControllers(); }); }
public FaturasController(DAL.Data.BD context) { _context = context; }
public LinhasDeFaturasController(DAL.Data.BD context) { _context = context; }
public EmpregadosController(DAL.Data.BD context) { _context = context; }