public async Task <ActionResult <Guid> > Put(Guid guid, [FromBody] PromocionViewModel pr) { var p = await _promocionService.GetByGuidAsync(guid); if (p == null) { return(NotFound()); } if (ModelState.IsValid) { await _promocionService.Update(guid, pr); } else { return(BadRequest()); } return(Ok(pr.Id)); }
public bool UpdatePromocion(Promocion datos) { return(_promocionService.Update(datos)); }