public decimal MakePayment(PaymentViewModel paymentViewModel)
 {
     var payment = AutoMapper.Mapper.Map<PaymentViewModel, Payment>(paymentViewModel);
     payment.ProcessedAt = DateTime.Now;
     var creditRequest = creditUow.CreditRequests.GetFullCreditRequest(payment.CreditRequestId);
     ProcessPayment(creditRequest, payment);
     creditUow.CreditRequests.InsertOrUpdate(creditRequest);
     creditUow.Commit();
     return annuityCreditCalculationService.CalculateBalance(creditRequest.TotalAmount, creditRequest.Payments);
 }
 public HttpResponseMessage MakePayment(PaymentViewModel payment)
 {
     var balance = ProcessViewModel<PaymentViewModel,decimal>(payment, null, paymentService.MakePayment);
     return Request.CreateResponse(HttpStatusCode.OK, balance);
 }