Example #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, SiamaDbContext dbContext)
        {
            if (env.IsDevelopment())
            {
                dbContext.Database.Migrate(); //this will generate the db if it does not exist
            }

            loggerFactory.AddConsole(Configuration.GetSection("Logging"));

            app.UseCors("CorsPolicy");

            app.UseMvc();
        }
Example #2
0
 public UnitOfWork(SiamaDbContext context)
 {
     this._context = context;
 }
Example #3
0
 public InspectionReportRepository(SiamaDbContext context) : base(context)
 {
 }