public IActionResult UpdateShipmentComment(ShipmentCommentUpdate shipmentcomment) { try { return(new JsonResult(ShipmentBAL.UpdateShipmentComment(shipmentcomment))); } catch (Exception ex) { return(StatusCode(StatusCodes.Status500InternalServerError, "Failed to update Shipment Comment")); } }
public ShipmentComment UpdateShipmentComment(ShipmentCommentUpdate shipmentcomment) { using (SqlConnection connection = new SqlConnection(DefaultConnection)) { DynamicParameters p = new DynamicParameters(); p.Add("shipmentcommentid", shipmentcomment.ShipmentCommentID); p.Add("comment", shipmentcomment.Comment); ShipmentComment result = connection.Query <ShipmentComment>("spUpdateShipmentComment", p, commandType: CommandType.StoredProcedure).Single(); return(result); } }
public ShipmentComment UpdateShipmentComment(ShipmentCommentUpdate shipmentcomment) { return(ShipmentDAL.UpdateShipmentComment(shipmentcomment)); }