// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IWebHostEnvironment env, HumanResourcesContext db) { //if (env.IsDevelopment()) //{ // app.UseDeveloperExceptionPage(); //} //else //{ // app.UseExceptionHandler("/Error"); //} // FE: To send back consistent error message object even with stack trace // Test endpoint: }/api/Buggy/servererror app.UseMiddleware <ExceptionMiddleware>(); app.UseStatusCodePagesWithReExecute("/errors/{0}"); db.Database.EnsureCreated(); app.UseStaticFiles(); if (!env.IsDevelopment()) { app.UseSpaStaticFiles(); } app.UseRouting(); // FE app.UseCors("CorsPolicy"); app.UseEndpoints(endpoints => { endpoints.MapControllerRoute( name: "default", pattern: "{controller}/{action=Index}/{id?}"); }); app.UseSpa(spa => { // To learn more about options for serving an Angular SPA from ASP.NET Core, // see https://go.microsoft.com/fwlink/?linkid=864501 spa.Options.SourcePath = "ClientApp"; if (env.IsDevelopment()) { spa.UseAngularCliServer(npmScript: "start"); } }); }
public EmployeeRepository(HumanResourcesContext context) : base(context) { }
public JobsController(HumanResourcesContext context) { this.context = context; }
protected Repository(HumanResourcesContext humanResourcesContext) { _context = humanResourcesContext; _dbSet = _context.Set <T>(); }
public EmployeesRepository(HumanResourcesContext _db) { db = _db; }
public BuggyController(HumanResourcesContext context) { _context = context; }
public DepartmentsRepository(HumanResourcesContext _db) { db = _db; }
public BaseRepository(HumanResourcesContext context) { _context = context; }
public SkillRepository(HumanResourcesContext context) : base(context) { }
public EmployeeRepository(HumanResourcesContext context) { _context = context; }
public UserRepository(HumanResourcesContext context) : base(context) { _context = context; }
public EmployeesController(HumanResourcesContext context) { _context = context; }
public HumanResourcesController(HumanResourcesContext context, IHostingEnvironment appEnvironment) { _context = context; _appEnvironment = appEnvironment; }
public JobsRepository(HumanResourcesContext _db) { db = _db; }
public GenderRepository(HumanResourcesContext context) : base(context) { }