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

            app.UseHttpsRedirection();
            app.UseRouting();
            //garante que o banco sera criado
            //sVTADbContext.Database.EnsureCreated();
            app.UseAuthentication();
            app.UseStaticFiles();
            app.UseAuthorization();

            app.UseEndpoints(endpoints =>
            {
                endpoints.MapControllers();
            });
        }
Esempio n. 2
0
 public ImagesController(SVTADbContext sVTADbContext)
 {
     _svtaDbContext = sVTADbContext;
 }
 public CategoriasController(SVTADbContext sVTADbContext)
 {
     _sVTADbContext = sVTADbContext;
 }
 public ContasController(IConfiguration configuration, SVTADbContext dbContext)
 {
     _svtaDbContext = dbContext;
     _configuration = configuration;
     _auth          = new AuthService(_configuration);
 }
Esempio n. 5
0
 public VeiculosController(SVTADbContext sVTADbContext)
 {
     _sVTADbContext = sVTADbContext;
 }