forked from MDCPS/DamageAssessment_Backend
		
	Merged new dev changes
This commit is contained in:
		| @ -7,8 +7,15 @@ namespace DamageAssesment.Api.Documents.Db | ||||
| { | ||||
|     public class DocumentDbContext : DbContext | ||||
|     { | ||||
|         public DocumentDbContext(DbContextOptions options) : base(options) | ||||
|         private IConfiguration _Configuration { get; set; } | ||||
|         public DocumentDbContext(DbContextOptions options, IConfiguration configuration) : base(options) | ||||
|         { | ||||
|             _Configuration = configuration; | ||||
|         } | ||||
|         protected override void OnConfiguring(DbContextOptionsBuilder options) | ||||
|         { | ||||
|             // connect to sql server with connection string from app settings | ||||
|             options.UseSqlServer(_Configuration.GetConnectionString("DocumentConnection")); | ||||
|         } | ||||
|         public DbSet<Db.Document> Documents { get; set; } | ||||
|         public DbSet<Db.LinkType> LinkTypes { get; set; } | ||||
|  | ||||
		Reference in New Issue
	
	Block a user