public async Task <IActionResult> PutPiecesJointesReceptionC(int id, PiecesJointesReceptionC piecesJointesReceptionC) { if (id != piecesJointesReceptionC.Id) { return(BadRequest()); } _context.Entry(piecesJointesReceptionC).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PiecesJointesReceptionCExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <PiecesJointesReceptionC> > PostPiecesJointesReceptionC(PiecesJointesReceptionC piecesJointesReceptionC) { _context.piecesJointesReceptionCs.Add(piecesJointesReceptionC); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPiecesJointesReceptionC", new { id = piecesJointesReceptionC.Id }, piecesJointesReceptionC)); }