public async Task <IActionResult> PutCategorium(int id, Categorium categorium) { if (id != categorium.CantId) { return(BadRequest()); } _context.Entry(categorium).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CategoriumExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutMediopago(int id, Mediopago mediopago) { if (id != mediopago.MepId) { return(BadRequest()); } _context.Entry(mediopago).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!MediopagoExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutProducto(int id, Producto producto) { if (id != producto.ProdId) { return(BadRequest()); } _context.Entry(producto).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ProductoExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutOrdene(int id, Ordene ordene) { if (id != ordene.OrdId) { return(BadRequest()); } _context.Entry(ordene).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!OrdeneExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }