public async Task <ActionResult <PiecesJointeE> > PostPiecesJointeE(PiecesJointeE piecesJointeE)
        {
            _context.piecesJointeEs.Add(piecesJointeE);
            await _context.SaveChangesAsync();

            return(CreatedAtAction("GetPiecesJointeE", new { id = piecesJointeE.Id }, piecesJointeE));
        }
        public async Task <IActionResult> PutPiecesJointeE(int id, PiecesJointeE piecesJointeE)
        {
            if (id != piecesJointeE.Id)
            {
                return(BadRequest());
            }

            _context.Entry(piecesJointeE).State = EntityState.Modified;

            try
            {
                await _context.SaveChangesAsync();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!PiecesJointeEExists(id))
                {
                    return(NotFound());
                }
                else
                {
                    throw;
                }
            }

            return(NoContent());
        }