Example #1
0
 public async void Pay()
 {
     var pp = new PaymentInformation()
     {
         GroupId = RecieverArtist.Id,
         Amount = long.Parse(Amount),
         Cvc = int.Parse(CVV),
         CardNumber = CardNumber,
         ExpirationMonth = int.Parse(ExpMonth),
         Description = RecieverArtist.Name,
         ExpirationYear = int.Parse(ExpYear)
     };
     _storageService.SaveText("paymentInfo",JsonConvert.SerializeObject(pp));
     //var validationStatus = await _naneService.ValidateCard(long.Parse(CardNumber));
     //if (!validationStatus)
     //{
     //    OnPropertyChanged("_Your credit card is invalid.Please try again with another card in order to process your donation.");
     //    return;
     //}
     var paymentRes = await _naneService.PostPayment(pp);
     if (paymentRes)
     {
         OnPropertyChanged("_Your donation has been succesfully sent.Thank you !");
     }
 }
Example #2
0
 public async Task<bool> PostPayment(PaymentInformation _payment)
 {
     return await _coreService.PostToAPI<bool>("payment/Pay", _payment);
 }