public async Task <Volume> UpdateAsync(Volume volume) { using (var dbContext = new Upstart13beerappContext()) { dbContext.Attach(volume); dbContext.Entry(volume).State = EntityState.Modified; await dbContext.SaveChangesAsync(); return(volume); } }
public async Task <FoodPairing> UpdateAsync(FoodPairing foodPairing) { using (var dbContext = new Upstart13beerappContext()) { dbContext.Attach(foodPairing); dbContext.Entry(foodPairing).State = EntityState.Modified; await dbContext.SaveChangesAsync(); return(foodPairing); } }
public async Task <Ingredient> UpdateAsync(Ingredient ingredient) { using (var dbContext = new Upstart13beerappContext()) { dbContext.Attach(ingredient); dbContext.Entry(ingredient).State = EntityState.Modified; await dbContext.SaveChangesAsync(); return(ingredient); } }
public async Task <Method> UpdateAsync(Method method) { using (var dbContext = new Upstart13beerappContext()) { dbContext.Attach(method); dbContext.Entry(method).State = EntityState.Modified; await dbContext.SaveChangesAsync(); return(method); } }
public async Task <Beer> UpdateAsync(Beer beer) { using (var dbContext = new Upstart13beerappContext()) { dbContext.Attach(beer); dbContext.Entry(beer).State = EntityState.Modified; await dbContext.SaveChangesAsync(); return(beer); } }