public async Task <IActionResult> PutMeetings(long id, [FromBody] Meetings meetings) { if (id != meetings.Id) { return(BadRequest()); } _context.Entry(meetings).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!MeetingsExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutOffices(long id, Offices offices) { if (id != offices.Id) { return(BadRequest()); } _context.Entry(offices).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!OfficesExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }