public MoveDep Update(MoveDep updateMoveDep) { var MoveDep = context.MoveDeps.Attach(updateMoveDep); MoveDep.State = EntityState.Modified; context.SaveChanges(); return(updateMoveDep); }
public MoveDep Delete(string id) { MoveDep department = context.MoveDeps.Find(id); if (department != null) { context.MoveDeps.Remove(department); context.SaveChanges(); } return(department); }
public MoveDep Add(MoveDep move) { context.MoveDeps.Add(move); context.SaveChanges(); return(move); }