public IEnumerable <Employee> CreateEmployee(EmployeeViewModel empViewModel) { MVCAppContext _db = new MVCAppContext(); Employee emp = new Employee() { Name = empViewModel.Name, Email = empViewModel.Email, Mobile = empViewModel.Mobile, Team = empViewModel.Team, Dob = empViewModel.Dob, Doj = empViewModel.Doj, CreatedOn = DateTime.Now, UpdatedOn = DateTime.Now }; var addEmp = m_UnitOfWork.EmployeeRepository.Add(emp); return(null); }
public GenericRepository(MVCAppContext context) { _context = context; }
public RepositoryBase(MVCAppContext dbContext) { m_DataContext = dbContext; }
public UnitOfWork(MVCAppContext dbContext) { m_DataContext = dbContext; }