public async Task <ActionResult <ApiResponse <PaymentMethod> > > Get(string paymentMethodId) { try { var paymentMethod = await _paymentMethodService.GetById(paymentMethodId); return(paymentMethod.CreateSuccessResponse()); } catch (Exception exception) { return(BadRequest(exception.CreateErrorResponse())); } }
public async Task <IActionResult> GetByID(int id) { var result = await _paymentService.GetById(id); return(Ok(result)); }
public PaymentMethod Get(int id) { return(service.GetById(id)); }