//--------------------------------------------------------------------------------------------- public void CheckTransactionStatus(string authTicket, string vendorTxCode, out GatewayTransactionView paymentTransaction) { // Display Form to allow editing of response StubGatewayForm stubForm = new StubGatewayForm(); stubForm.tabControl.SelectedIndex = 2; paymentTransaction = new GatewayTransactionView(); paymentTransaction.CreatedDateTime = DateTime.Now; paymentTransaction.Description = ""; paymentTransaction.GatewayStatusId = 0; paymentTransaction.GatewayTransactionCurrency = "GBP"; paymentTransaction.GatewayTransactionGrossAmount = 0.00M; paymentTransaction.GatewayTransactionId = 0; paymentTransaction.GatewayTransactionTypeId = 0; paymentTransaction.GatewayUserCompanyId = 0; paymentTransaction.GatewayUserCompanyMerchantAccountId = 0; paymentTransaction.GatewayUserCompanyPaymentProviderId = 0; paymentTransaction.GatewayVendorAtsData = ""; paymentTransaction.GatewayVendorCardExpiryDate = ""; paymentTransaction.GatewayVendorCardLast4Digits = ""; paymentTransaction.GatewayVendorCardType = ""; paymentTransaction.GatewayVendorSecurityKey = ""; paymentTransaction.GatewayVendorTxAuthNo = ""; paymentTransaction.GatewayVendorTxCode = ""; paymentTransaction.GatewayVendorVPSTxId = ""; paymentTransaction.IsError = false; paymentTransaction.ServiceName = ""; paymentTransaction.ServiceResponse = ""; paymentTransaction.TypeName = ""; paymentTransaction.VendorTypeName = ""; }
//--------------------------------------------------------------------------------------------- public void RegisterTransactionCardToken(GatewayCOMObject.GatewayCOMClass.Credentials credentials, string ourRef, string currencyCode, long paymentProviderId, long merchantAccountId) { // Display Form to allow setting of response StubGatewayForm stubForm = new StubGatewayForm(); stubForm.tabControl.SelectedIndex = 0; }
public void RegisterTransaction(GatewayCOMObject.GatewayCOMClass.Credentials credentials, ShoppingBasket shoppingBasket, out string authTicket, out string gatewayTransactionGuid) { // Display Form to allow editing of response StubGatewayForm stubForm = new StubGatewayForm(); stubForm.tabControl.SelectedIndex = 0; stubForm.textSiteId.Text = credentials.SiteIdentifier; stubForm.textCompany.Text = credentials.Company; stubForm.textPassword.Text = credentials.Password; stubForm.textAuthTicket.Text = ""; // Need to populate this with something - probably random authTicket = stubForm.textAuthTicket.Text; stubForm.textTransGUID.Text = Guid.NewGuid().ToString(); gatewayTransactionGuid = stubForm.textTransGUID.Text; // Display the contents of the shopping basket // Header stubForm.textContactName.Text = shoppingBasket.ContactName; stubForm.textEmail.Text = shoppingBasket.ContactEmailAddress; stubForm.textPhone.Text = shoppingBasket.ContactTelephone; stubForm.textCurrencyCode.Text = shoppingBasket.CurrencyCode; stubForm.textBAddr1.Text = shoppingBasket.BillingAddressLine1; stubForm.textBAddr2.Text = shoppingBasket.BillingAddressLine2; stubForm.textBTown.Text = shoppingBasket.BillingAddressTown; stubForm.textBCounty.Text = shoppingBasket.BillingAddressCounty; stubForm.textBPostcode.Text = shoppingBasket.BillingAddressPostcode; stubForm.textBCountry.Text = shoppingBasket.BillingAddressCountry; stubForm.textDAddr1.Text = shoppingBasket.DeliveryAddressLine1; stubForm.textDAddr2.Text = shoppingBasket.DeliveryAddressLine2; stubForm.textDTown.Text = shoppingBasket.DeliveryAddressTown; stubForm.textDCounty.Text = shoppingBasket.DeliveryAddressCounty; stubForm.textDPostcode.Text = shoppingBasket.DeliveryAddressPostcode; stubForm.textDCountry.Text = shoppingBasket.DeliveryAddressCountry; stubForm.textMerchantAccount.Text = shoppingBasket.MerchantAccountId.ToString(); stubForm.textPaymentProvider.Text = shoppingBasket.PaymentProviderId.ToString(); // Items foreach (ShoppingBasketItem sbItem in shoppingBasket.Items) { ListViewItem item1 = new ListViewItem(sbItem.ProductId); item1.SubItems.Add(sbItem.Quantity.ToString()); item1.SubItems.Add(sbItem.UnitNetPrice.ToString()); item1.SubItems.Add(sbItem.LineNetPrice.ToString()); item1.SubItems.Add(sbItem.LineVatPrice.ToString()); item1.SubItems.Add(sbItem.VatCode); item1.SubItems.Add(sbItem.VatMultiplier.ToString()); } }