public async Task <IActionResult> PutEmployé(int id, Employé employé) { if (id != employé.EmpId) { return(BadRequest()); } _context.Entry(employé).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!EmployéExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutPayementDetail(int id, PayementDetail payementDetail) { if (id != payementDetail.PMId) { return(BadRequest()); } _context.Entry(payementDetail).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PayementDetailExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }