public object Get(int id) { try { ServicePaymentFormModel model = new ServicePaymentFormModel(); listaMock = PaymentFormMock.Instancia().Get(id); var result = model.ConvertListPaymentToListModel(listaMock); if (result != null) { return(Request.CreateResponse(HttpStatusCode.OK, result)); } return(Request.CreateResponse(HttpStatusCode.NotFound)); } catch (Exception ex) { log.Error("Mensaje de Error: " + ex.Message); if (ex.InnerException != null) { log.Error("Inner exception: " + ex.InnerException.Message); } throw ex; } }
public object Get(int id) { try { ServicePaymentFormModel model = new ServicePaymentFormModel(); ServicePaymentFormBusiness servicePaymentFormBusiness = new ServicePaymentFormBusiness(id); return(model.ConvertListPaymentToListModel(servicePaymentFormBusiness.RecuperarPagosPorUsuario())); } catch (Exception ex) { log.Error("Error get: " + ex.Message); if (ex.InnerException != null) { log.Error("Inner exception: " + ex.InnerException.Message); } throw ex; } }