public async Task <IActionResult> PostMThrmsinterviewScheduleRoundDetails([FromBody] MThrmsinterviewScheduleRoundDetails mThrmsinterviewScheduleRoundDetails) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } _context.MThrmsinterviewScheduleRoundDetails.Add(mThrmsinterviewScheduleRoundDetails); await _context.SaveChangesAsync(); return(CreatedAtAction("GetMThrmsinterviewScheduleRoundDetails", new { id = mThrmsinterviewScheduleRoundDetails.MThrmsinterviewScheduleRoundDetailsId }, mThrmsinterviewScheduleRoundDetails)); }
public async Task <IActionResult> PutMThrmsinterviewScheduleRoundDetails([FromRoute] long id, [FromBody] MThrmsinterviewScheduleRoundDetails mThrmsinterviewScheduleRoundDetails) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (id != mThrmsinterviewScheduleRoundDetails.MThrmsinterviewScheduleRoundDetailsId) { return(BadRequest()); } _context.Entry(mThrmsinterviewScheduleRoundDetails).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!MThrmsinterviewScheduleRoundDetailsExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }