wp-e-commerce / WP-e-Commerce

WP eCommerce - The most popular independent eCommerce platform for WordPress
https://wpecommerce.org
GNU General Public License v2.0
215 stars 216 forks source link

Payment gateways problem #1701

Open pavelevap opened 9 years ago

pavelevap commented 9 years ago

Hi,

I was using Test Merchant gateway and switch to Paypal to test it. But it is not possible to switch back to Test gateway? It is not visible on admin page.

So I switched to Manual Gateway and now there are no Shipping details in our Purchase Logs admin page. They are saved in database, but not shown in administration.

Using latest WP a WP eCommerce 3.9 with wpsc-simple-shipping plugin.

mihaijoldis commented 9 years ago

enable debug in the wp-config.php file and see what errors you get

JustinSainton commented 9 years ago

Hi @pavelevap,

Interesting - I imagine the old test gateway was gone due to this commit: https://github.com/wp-e-commerce/WP-e-Commerce/commit/f31872b169e336a01aa70cf53fdfa8dec25ebd8b#diff-42d4212bc6ad461f9ab90d2e10cf66daR29

That said, I think we're essentially reverting that in 3.9.1, so it should no longer be a problem. In fact, I think we'll be disabling the core 3.0 gateways until we're able to get them a tad more test coverage. See #1697.

If you want to give the master branch a test and see if the issue is resolved, that'd be great!

pavelevap commented 9 years ago

Yes, missing Test payment gate is resolved, thank you! And now there is no special Manual Payment gateway and Test should be used in this case?

Missing info about shipping is probably related to some other problem, I will try to test and find what is going here... Still does not work in latest master branch...

pavelevap commented 9 years ago

OK, I found a problem for missing purchase logs.

In wpsc-admin/includes/purchase-logs-page/item-details.php is following check:

<?php if ( wpsc_has_purchlog_shipping() ): ?>

And this function is checking for shippingfirstname. But this is not filled because user filled only billing information (shipping are only when different). And we do not use checkbox "Same as billing address". So, there are no information in purchase logs (about shipping method, etc).

JustinSainton commented 9 years ago

@pavelevap Awesome, great work debugging the issue. Correct, for the time being, use the Test Gateway.

As far as the shippingfirstname field being used to determine wpsc_has_purchlog_shipping truthiness - that's...weird. My initial instinct would be to actually check for the cost of shipping on the purchase log, but I suppose it could be free. At which point, actually checking for a value for the shipping_method field would make more sense.

What are your thoughts on this?