PIbd-42_Kashin_M.I_CPO_Cour.../EmployeeManagmentDataBaseImplement/DatabaseContext.cs

25 lines
731 B
C#

using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace EmployeeManagmentDataBaseImplement
{
public class DatabaseContext : DbContext
{
public DbSet<Employee> Employees { get; set; }
public DbSet<PhysicalPerson> PhysicalPersons { get; set; }
public DbSet<Salary> Salaries { get; set; }
public DbSet<Vacation> Vacations { get; set; }
public DatabaseContext(DbContextOptions<DatabaseContext> options) : base(options) { }
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
base.OnModelCreating(modelBuilder);
}
}
}