Inheritance: DefaultsViewModelBase
Exemplo n.º 1
0
		public TokenPaymentPage(Judo judo, TokenPaymentDefaultsViewModel model) : base(judo, model)
		{
			tokenViewModel.Amount = Judo.Amount;
			tokenViewModel.JudoID = Judo.JudoId;
			tokenViewModel.Currency = Judo.Currency;
			tokenViewModel.ConsumerReference = Judo.ConsumerReference;
			tokenViewModel.Token = model.CardToken;
			tokenViewModel.ConsumerToken = model.ConsumerToken;
		}
Exemplo n.º 2
0
		public CardEntryPage(Judo judo, TokenPaymentDefaultsViewModel defaults) : this(judo)
		{
			_isTokenPayment = true;
			SetUpDefaults(defaults);
		}
Exemplo n.º 3
0
		void SetUpDefaults(TokenPaymentDefaultsViewModel defaults)
		{
			cardNumberEntry.Format = "";
			cardNumberEntry.Text = defaults.MaskedCardNumber;
			cardImage.Opacity = !string.IsNullOrWhiteSpace(defaults.MaskedCardNumber) ? 1 : 0.5;
			expiryDateEntry.Text = defaults.ExpiryDate;
			expiryDateEntry.Format = "";
			cardNumberEntry.IsEnabled = false;
			expiryDateEntry.IsEnabled = false;
			startDateEntry.IsEnabled = false;
			issueNumberEntry.IsEnabled = false;
			_currentDiscoveredNetwork = defaults.CardNetork;
			UpdateCardIcons();
			UpdateCvvMaxLength();
			_currentDiscoveredNetwork.SetAvsEnabled(Judo.AvsEnabled);
		}