public Restaurant Update(Restaurant restaurant) { _context.Attach(restaurant).State = Microsoft.EntityFrameworkCore.EntityState.Modified; _context.SaveChanges(); return(Get(restaurant.Id)); }
public Restaurant Update(Restaurant restaurant) { _context.Attach(restaurant).State = EntityState.Modified; _context.SaveChanges(); return(restaurant); }
public void Update(Restaurant restaurant) { _dbContext.Attach(restaurant).State = EntityState.Modified; _dbContext.SaveChanges(); }