public async Task <ActionResult <typeDotation> > PosttypeDotation(typeDotation typeDotation)
        {
            _context.typeDotations.Add(typeDotation);
            await _context.SaveChangesAsync();

            return(CreatedAtAction("GettypeDotation", new { id = typeDotation.Id }, typeDotation));
        }
        public async Task <IActionResult> PuttypeDotation(int id, typeDotation typeDotation)
        {
            if (id != typeDotation.Id)
            {
                return(BadRequest());
            }

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

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

            return(NoContent());
        }