Paypal sandbox does not complete payment

Phoca Cart - complex e-commerce extension
p38
Phoca Member
Phoca Member
Posts: 33
Joined: 02 Aug 2014, 23:39

Paypal sandbox does not complete payment

Post by p38 »

Hi,

I noticed that after a successful sandbox paypal payment, the order status changes to Cancelled.

Surely it should change to "Completed"

The logs look correct, and last message is
Order status changed to: 3, User: Anonymous
Looking at the db table, I see status id 3 = Cancelled, it should be 6 = Completed surely.

Is there a default setting I am missing

Any help is appreciated

Paul
jpeters
Phoca Professional
Phoca Professional
Posts: 225
Joined: 31 Dec 2020, 09:46

Re: Paypal sandbox does not complete payment

Post by jpeters »

are the settings correct in the payment configuration.
based on the return you can define the order status
p38
Phoca Member
Phoca Member
Posts: 33
Joined: 02 Aug 2014, 23:39

Re: Paypal sandbox does not complete payment

Post by p38 »

Thanks for the reply, much appreciated

Are you referring to these settings, I did not change them, so I assume these are the defaults.

Somehow it does not seem to be picking up this value assigned to the Completed status.

Is it possible that a successful paypal transaction returns "Processed" instead of "Completed"?

If so, does this mean the administrator has to manually complete each and every successful payment? I would not imagine this, esp if you have 100's or 1000's of payments.

Image
jpeters
Phoca Professional
Phoca Professional
Posts: 225
Joined: 31 Dec 2020, 09:46

Re: Paypal sandbox does not complete payment

Post by jpeters »

Hello,
yes i am referring to those settings.
based on the feedback url the order should change to the order state selected.
based on your screenshot a succesfull payment should result in a order status Completed.
and indead, you should not manualy change the order payment status manualy.
perhaps some other issue is preventing of changing the order payment status to completed.

i quicky did a test on my testing site. it's working like expacted.
is the (sandbox) payment processed succesfully and are you getting returned to your website?
jpeters
Phoca Professional
Phoca Professional
Posts: 225
Joined: 31 Dec 2020, 09:46

Re: Paypal sandbox does not complete payment

Post by jpeters »

the name completed status is just the internal phoca cart name of your order status.
this has nothing to do with paypal return url. the return url should trigger the correct status (first colum " completed status" .
the payment plugin then should change the order payment status to the status configured (Completed) in this case / screenshot
p38
Phoca Member
Phoca Member
Posts: 33
Joined: 02 Aug 2014, 23:39

Re: Paypal sandbox does not complete payment

Post by p38 »

Hi there,

Yes, it returns back to my site and says successful transaction. I have set a file download link and the link is available afer sucecssful.

So all indications are everything works as expected except the correct status change.

I can also point out, I bypassed the sandbox and tested with a proper paypal transaction, and it returned the same results, ie: it came back with a log message the same as sandbox
Order status changed to: 3
jpeters
Phoca Professional
Phoca Professional
Posts: 225
Joined: 31 Dec 2020, 09:46

Re: Paypal sandbox does not complete payment

Post by jpeters »

Based on the fact that the downloadable product is available the order status schould be completed.. Assuming default settings.

Can you sent me PM with url and admin credentials to have a look.
p38
Phoca Member
Phoca Member
Posts: 33
Joined: 02 Aug 2014, 23:39

Re: Paypal sandbox does not complete payment

Post by p38 »

Many thanks for your help.

PM sent.

Paul
jpeters
Phoca Professional
Phoca Professional
Posts: 225
Joined: 31 Dec 2020, 09:46

Re: Paypal sandbox does not complete payment

Post by jpeters »

okay.. i checked and did some testing. i don't know what's wrong.
but i see what happens.
normally when enduser checkout with payment, after payment you return to the shop and order status is changed.
when i cancel the payment, i return to the webshop (still logged in with the user).
when i finish the payment, i retrun to the website using the url of paypal. i return but now no user is logged in.

i think that is the issue. the info page is also empty without order status (thank you page) phoca cart.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Paypal sandbox does not complete payment

Post by Jan »

Hi, the flow is following:

- When user makes the order - the order status changes (e.g. to pending)
- Then he/she will be redirected to PayPal and makes the payment
- Then PayPal server contacts the vendor server and set the status e.g. to completed

So in fact if you go back to the site or not, it has no effect on the status.

All this can be viewed when logging is enabled in Phoca Cart. The log logs the first event (sending data to PayPal and even the second event - getting info from PayPal server). There are similar topics in this forum when the first event was Ok but not the second because PayPal could not contact the server (e.g. disabling Verify SSL Certificate parameter, etc.)

Jan
If you find Phoca extensions useful, please support the project
Post Reply