public void UpdateDepartmemt(Department dept)
 {
     if (DepartmentExists(dept.Id))
     {
         _context.Update(dept);
         _context.SaveChanges();
     }
 }
示例#2
0
 public void UpdateEmployee(Employee employee)
 {
     if (EmployeeExists(employee.Id))
     {
         _context.Update(employee);
         _context.SaveChanges();
     }
 }