Пример #1
0
 public override void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     // Console.WriteLine("Scanning Canceled!");
     paymentViewController.DismissViewController(true, null);
     // ccPage.OnScanCancelled();
     Xamarin.Forms.MessagingCenter.Send <CreditCard_PCL>(ccPCL, "CreditCardScanCancelled");
 }
Пример #2
0
        public override void UserDidProvideCreditCardInfo(CreditCardInfo card, CardIOPaymentViewController paymentViewController)
        {
            paymentViewController.DismissViewController(true, null);

            if (card == null)
            {
                Console.WriteLine("Scanning Canceled!");

                //ccPage.OnScanCancelled();
                Xamarin.Forms.MessagingCenter.Send <CreditCard_PCL>(ccPCL, "CreditCardScanCancelled");
            }
            else
            {
                //Console.WriteLine("Card Scanned: " + card.CardNumber);

                // Feel free to extend the CreditCard_PCL object to include more than what's here.
                ccPCL.cardNumber         = card.CardNumber;
                ccPCL.ccv                = card.Cvv;
                ccPCL.expr               = card.ExpiryMonth.ToString() + card.ExpiryYear.ToString();
                ccPCL.redactedCardNumber = card.RedactedCardNumber;
                ccPCL.cardholderName     = card.CardholderName;

                //ccPage.OnScanSucceeded (ccPCL);
                Xamarin.Forms.MessagingCenter.Send <CreditCard_PCL>(ccPCL, "CreditCardScanSuccess");
            }
        }
Пример #3
0
 public override void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     ScanningDone?.BeginInvoke(this, new CardInfoEventArgs
     {
         CardInfo = null
     }, null, null);
 }
Пример #4
0
 public void UserDidProvideCreditCardInfo(CardIOCreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     _retrieveCardSuccess?.Invoke(cardInfo);
     if (!_formsConfig.StoreUserData)
     {
         ClearUserData();
     }
 }
Пример #5
0
 public void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     _retrieveCardCancelled?.Invoke();
     if (!_formsConfig.StoreUserData)
     {
         ClearUserData();
     }
 }
Пример #6
0
        public override void UserDidProvideCreditCardInfo(CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
        {
            _creditCardInfo = cardInfo;

            Debug.WriteLine($"CardholderName : {cardInfo.CardholderName}");
            Debug.WriteLine($"Card Type : {cardInfo.CardType}");
            Debug.WriteLine($"ExpiryMonth : {cardInfo.ExpiryMonth}");
            Debug.WriteLine($"ExpiryYear : {cardInfo.ExpiryYear}");

            paymentViewController.DismissViewController(true, null);
        }
Пример #7
0
        public void UserDidProvideCreditCardInfo (CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
        {
            if (cardInfo == null) {
                elemCardNumber.Caption = "xxxx xxxx xxxx xxxx";
                Console.WriteLine("Cancelled");
            } else {
                elemCardNumber.Caption = cardInfo.CardNumber;
            }

            ReloadData();

            paymentViewController.DismissViewController(true, null);        
        }
Пример #8
0
        public void UserDidProvideCreditCardInfo(Card.IO.CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
        {
            if (cardInfo == null)
            {
                Console.WriteLine("Scanning Cancelled!");
            }
            else
            {
                this.cardInfo = cardInfo;
            }

            paymentViewController.DismissViewController(true, null);
        }
Пример #9
0
 public override void UserDidProvideCreditCardInfo(CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     ScanningDone?.BeginInvoke(this, new CardInfoEventArgs
     {
         CardInfo = new CardInfo
         {
             PAN    = cardInfo.CardNumber,
             CVV    = cardInfo.Cvv,
             Expiry = cardInfo.ExpiryMonth + "/" + cardInfo.ExpiryYear,
             Name   = cardInfo.CardholderName
         }
     }, null, null);
 }
Пример #10
0
        public void UserDidProvideCreditCardInfo(CreditCardInfo card, CardIOPaymentViewController paymentViewController)
        {
            paymentViewController.DismissViewController(true, null);

            if (card != null)
            {
                var creditCardInfo = new CreditCardInformation
                {
                    CardNumber      = card.CardNumber,
                    ExpirationMonth = card.ExpiryMonth.ToString(),
                    ExpirationYear  = card.ExpiryYear.ToString()
                };

                MessagingCenter.Send(creditCardInfo, MessengerKeys.CreditCardScanned);
            }
        }
        public void UserDidProvideCreditCardInfo(CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
        {
            if (cardInfo == null)
            {
                elemCardNumber.Caption = "xxxx xxxx xxxx xxxx";
                Console.WriteLine("Cancelled");
            }
            else
            {
                elemCardNumber.Caption = cardInfo.CardNumber;
            }

            ReloadData();

            paymentViewController.DismissViewController(true, null);
        }
        public void UserDidProvideCreditCardInfo(CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
        {
            creditCardInfo = cardInfo;


            edtCreditCardData.Text = cardInfo.RedactedCardNumber;            // String.Format ("#### #### #### {0} {1}/{2}", cardInfo.RedactedCardNumber.Substring (l, 4).ToString (), cardInfo.ExpiryMonth, cardInfo.ExpiryYear.ToString ().Substring (2, 2));
            edtCCV.Text            = cardInfo.Cvv;
            edtCreditDate.Text     = String.Format("{0}/{1}", cardInfo.ExpiryMonth.ToString(), cardInfo.ExpiryYear.ToString());

            switch (creditCardInfo.CardType)
            {
            case CreditCardType.Mastercard:
                imgAddCard.Image = UIImage.FromBundle(@"fa-cc-mastercard");
                crditCardType    = CardType.Mastercard;
                break;

            case CreditCardType.Visa:
                imgAddCard.Image = UIImage.FromBundle(@"fa-cc-visa");
                crditCardType    = CardType.Visa;
                break;

            case CreditCardType.Amex:
                imgAddCard.Image = UIImage.FromBundle(@"fa-cc-amex");
                crditCardType    = CardType.AmericanExpress;
                break;

            case CreditCardType.Discover:
                imgAddCard.Image = UIImage.FromBundle(@"fa-cc-discover");
                crditCardType    = CardType.Discover;
                break;

            case CreditCardType.JCB:
                imgAddCard.Image = UIImage.FromBundle(@"fa-cc-diners-club");
                crditCardType    = CardType.DinersClub;
                break;

            default:
                imgAddCard.Image = UIImage.FromBundle(@"oi-credit-card");
                crditCardType    = CardType.Unknown;
                break;
            }

            paymentViewController.DismissViewController(true, null);
        }
Пример #13
0
        public void UserDidProvideCreditCardInfo(CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
        {
            if (cardInfo != null)
            {
                if (CardFound != null)
                {
                    CardFound(cardInfo.RedactedCardNumber, (int)cardInfo.ExpiryMonth, (int)cardInfo.ExpiryYear, cardInfo.CardholderName, cardInfo.CardType);
                }
            }

            //if (cardInfo == null)
            //{
            //	Console.WriteLine("Scanning Canceled!");
            //}
            //else {
            //	Console.WriteLine("Card Scanned: " + cardInfo.CardNumber);
            //}

            paymentViewController.DismissViewController(true, null);
        }
 public void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     _callback?.Invoke(AddCreditCard.Empty);
     _paymentViewController.DismissViewController(true, null);
     _modalHost.NativeModalViewControllerDisappearedOnItsOwn();
 }
Пример #15
0
 public override void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     Console.WriteLine("Scanning Canceled!");
     paymentViewController.DismissViewController(true, null);
 }
Пример #16
0
 public void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     RetrieveCardCancelled?.Invoke();
 }
Пример #17
0
 public void UserDidProvideCreditCardInfo(CardIOCreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     RetrieveCardSuccess?.Invoke(cardInfo);
 }
Пример #18
0
 public void UserDidProvideCreditCardInfo(CardIOCreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     RetrieveCardSuccess?.Invoke(cardInfo);
 }
Пример #19
0
 public void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
     RetrieveCardCancelled?.Invoke();
 }
Пример #20
0
 public override void UserDidProvideCreditCardInfo(CreditCardInfo cardInfo, CardIOPaymentViewController paymentViewController)
 {
     _cardScanned(cardInfo);
     paymentViewController.DismissViewController(true, null);
 }
Пример #21
0
 public void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     paymentViewController.DismissViewController(true, null);
 }
Пример #22
0
 public void UserDidCancelPaymentViewController (CardIOPaymentViewController paymentViewController)
 {
 	paymentViewController.DismissViewController(true, null);
 }
 public void UserDidCancelPaymentViewController(CardIOPaymentViewController paymentViewController)
 {
     //App.Current
     //this.DismissViewController(true, null);
     paymentViewController.DismissViewController(true, null);
 }