Order XML not refreshed when order marked as 'Captured'
I've a 'Download' button on my website. I don't enable this button unless the current member has purchased a certain product. Part of the logic to dertmine whether they have purchased it is to get all their orders that have not been cancelled and are marked as either 'Authorized' or 'Captured', (I'm using PayPal).
XPathNodeIterator orders = TeaCommerce.Library.GetFinalizedOrdersXmlForMember(CurrentMemberID).Current.Select("order [(orderStatus/@name != 'Cancelled') and ((@paymentStatus = 'Authorized') or (@paymentStatus = 'Captured'))]");
Everything works well if PayPal returns an 'Authorized' response. It does not work however if PayPal returns a 'Captured' response.
I have discoverd that it will work if I manually refresh the Orders XML from the back-end so I'm thinking there may be a bug that is preventing this from automatically happening for Captured payments.
First - upgrade Tea Commerce so we can be sure it is not an old bug :)
It sounds like the xml isnt refreshed correctly but the weird part is that it happens in the saved method. And both an Authorized and Captured order is saved. I know that paypal sometimes gives a status of "Pending.." because it need to figure something out. But try look in the DB when this happens. What payment status has the order and what is in the xml?
I think the upgrade is a good idea and I thought you might suggest it. The site is Umbraco 4.7.x. When you say upgrade do you mean to Tea Commerce 1.4.4.3?
I see version 2.0 is available but I and my client would be nervous of anything with an Alpha tag being installed to a production site. ;-)
Order XML not refreshed when order marked as 'Captured'
I've a 'Download' button on my website.
I don't enable this button unless the current member has purchased a certain product.
Part of the logic to dertmine whether they have purchased it is to get all their orders that have not been cancelled and are marked as either 'Authorized' or 'Captured', (I'm using PayPal).
Everything works well if PayPal returns an 'Authorized' response.
It does not work however if PayPal returns a 'Captured' response.
I have discoverd that it will work if I manually refresh the Orders XML from the back-end so I'm thinking there may be a bug that is preventing this from automatically happening for Captured payments.
What do you think?
The site is currently using 1.4.2.0 Beta 8.
Regards, Matt
Hi Matt
First - upgrade Tea Commerce so we can be sure it is not an old bug :)
It sounds like the xml isnt refreshed correctly but the weird part is that it happens in the saved method. And both an Authorized and Captured order is saved. I know that paypal sometimes gives a status of "Pending.." because it need to figure something out. But try look in the DB when this happens. What payment status has the order and what is in the xml?
Kind regards
Anders
Thanks Anders,
I think the upgrade is a good idea and I thought you might suggest it.
The site is Umbraco 4.7.x.
When you say upgrade do you mean to Tea Commerce 1.4.4.3?
I see version 2.0 is available but I and my client would be nervous of anything with an Alpha tag being installed to a production site. ;-)
Yeah I mean 1.4.4.3 - be sure to read the revision notes
http://www.teacommerce.net/en/documentation/revision-history.aspx
2.0 is still not available for production :)
is working on a reply...