• Toll-free  888-665-8637
  • International  +1 717-220-0012
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

2 Pages<12
bedek
#21 Posted : Wednesday, December 23, 2009 3:47:18 PM(UTC)
bedek

Rank: Member

Joined: 7/15/2007(UTC)
Posts: 54

Please address this issue noted in several messages in this thread.

1) When a customer uses a different ship to than bill to the Bill to Name is being put into the Ship to Name. This has to be a bug.
shanplourde
#22 Posted : Thursday, October 14, 2010 6:36:08 AM(UTC)
shanplourde

Rank: Member

Joined: 9/19/2010(UTC)
Posts: 104

I agree, this seems to be a bug in the current 5.74 version. I guess I'll have to customize this to get it to work properly from what I've read here.
Best regards,
Shan Plourde
www.pahsah.com
+1 (416) 628-1280
--------------------------------
shanplourde
#23 Posted : Friday, October 15, 2010 6:42:29 AM(UTC)
shanplourde

Rank: Member

Joined: 9/19/2010(UTC)
Posts: 104

I just finished customizing the cart for a client to support separate Bill To and Ship To Addresses with PayPal express. If anyone is interested let me know.
Best regards,
Shan Plourde
www.pahsah.com
+1 (416) 628-1280
--------------------------------
CM3 Solutions
#24 Posted : Thursday, October 21, 2010 2:59:12 PM(UTC)
CM3 Solutions

Rank: Member

Joined: 8/20/2008(UTC)
Posts: 81
United States

Thanks: 2 times
Shan.. I'm interested in what you did to fix this issue.
shanplourde
#25 Posted : Friday, October 22, 2010 10:41:20 PM(UTC)
shanplourde

Rank: Member

Joined: 9/19/2010(UTC)
Posts: 104

Hi CM3, this is a pretty raw rundown of what I did, I only tested it a bit. It would be great to hear any feedback that you might have regarding these changes that I've made and the relevant process changes.

I changed $/BVModules/Checkouts/PayPal Express Checkout/Checkout.aspx and Checkout.aspx.vb. I prevent BV from setting the bill to and ship to the same address, which it does by default when the PayPal Express process completes.

Granted I don't know very much about the entire PayPal Express payment process. I have disabled the "Pay with Paypal Express" button that appears on every product page when PayPal express is enabled in BV. So I'm forcing PayPal Express to occur at the checkout page step. I understand that may not be compliant with the PayPal Express requirement of having a payment button right on every product page. Also I'm allowing payments from unconfirmed addresses, which is a PayPal Express option in the BV Admin area, so I'm not sure how this code would impact that if those payments were disallowed.

When the user returns from PayPal they have already specified their shipping and optionally billing address if different, on the shopping cart checkout page.

The relevant source changes that I've made to Checkout.aspx.vb follow. Let me know if you need anything else.


Protected Function GetExpressCheckoutDetails(ByVal ppAPI As PayPalAPI, ByRef ppResponse As GetExpressCheckoutDetailsResponseType) As Boolean
ppResponse = ppAPI.GetExpressCheckoutDetails(Request.QueryString("token"))
If ppResponse.Ack = AckCodeType.Success OrElse ppResponse.Ack = AckCodeType.SuccessWithWarning Then
Dim Basket As Orders.Order = SessionManager.CurrentShoppingCart

EmailLabel.Text = ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Payer
FirstNameLabel.Text = Basket.ShippingAddress.FirstName
'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.PayerName.FirstName
If Basket.ShippingAddress.MiddleInitial.Length > 0 Then
MiddleInitialLabel.Text = Basket.ShippingAddress.MiddleInitial
Else
MiddleInitialLabel.Text = String.Empty
End If
LastNameLabel.Text = Basket.ShippingAddress.LastName 'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.PayerName.LastName
'CompanyLabel.Text = ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.PayerBusiness
StreetAddress1Label.Text = Basket.ShippingAddress.Line1 'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.Street1
StreetAddress2Label.Text = Basket.ShippingAddress.Line2 'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.Street2
CountryLabel.Text = Basket.ShippingAddress.CountryName 'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.CountryName
ViewState("CountryCode") = Content.Country.FindByBvin(Basket.ShippingAddress.CountryBvin).IsoCode
'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.Country.ToString()
CityLabel.Text = Basket.ShippingAddress.City ''ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.CityName
StateLabel.Text = Basket.ShippingAddress.RegionName 'ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.StateOrProvince
ZipLabel.Text = Basket.ShippingAddress.PostalCode ' ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.PostalCode

' 5.7 fix PhoneNumberLabel.Text = ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.ContactPhone
PhoneNumberLabel.Text = Basket.ShippingAddress.Phone
'If String.IsNullOrEmpty(ppResponse.GetExpressCheckoutDetailsResponseDetails.ContactPhone) Then
' PhoneNumberLabel.Text = ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.ContactPhone
' Else
' PhoneNumberLabel.Text = ppResponse.GetExpressCheckoutDetailsResponseDetails.ContactPhone
' End If

lblTotal.Text = Basket.GrandTotal.ToString("c")
If ppResponse.GetExpressCheckoutDetailsResponseDetails.PayerInfo.Address.AddressStatus = AddressStatusCodeType.Confirmed Then
AddressStatusLabel.Text = "Confirmed"
Else
AddressStatusLabel.Text = "Unconfirmed"
End If
Return True
Else
Return False
End If
End Function


Private Function GetAddress() As Contacts.Address
Dim a As New Contacts.Address
Dim country As Content.Country = Content.Country.FindByISOCode(ViewState("CountryCode"))
If country.Bvin = String.Empty Then
MessageBox1.ShowError("Could not retreive address properly, country could not be found.")
CheckoutImageButton.Enabled = False
Else
CheckoutImageButton.Enabled = True
End If

If Not country.Active Then
MessageBox1.ShowError("This country is not active for this store.")
CheckoutImageButton.Enabled = False
Else
CheckoutImageButton.Enabled = True
End If

If (country.Bvin <> String.Empty) AndAlso (country.Active) Then
a.CountryBvin = country.Bvin
a.CountryName = country.DisplayName
a.RegionName = StateLabel.Text
For Each region As Content.Region In Content.Region.FindByCountry(country.Bvin)
If (String.Compare(region.Abbreviation, a.RegionName, True) = 0) OrElse (String.Compare(region.Name, a.RegionName, True) = 0) Then
a.RegionBvin = region.Bvin
a.RegionName = region.Name
End If
Next
a.FirstName = FirstNameLabel.Text
a.MiddleInitial = MiddleInitialLabel.Text
a.LastName = LastNameLabel.Text
'a.Company = CompanyLabel.Text
a.Line1 = StreetAddress1Label.Text
a.Line2 = StreetAddress2Label.Text
a.City = CityLabel.Text
a.PostalCode = ZipLabel.Text
a.Phone = PhoneNumberLabel.Text
a.Fax = ""
a.WebSiteUrl = ""
Return a
Else
Return Nothing
End If
End Function
Best regards,
Shan Plourde
www.pahsah.com
+1 (416) 628-1280
--------------------------------
2 Pages<12
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

©2024 Develisys. All rights reserved.
  • Toll-free  888-665-8637
  • International  +1 717-220-0012