Order won't get FINISHED!

13.06.2016 23:59
#1
lemusi
Joomshopping forum user no avatar
Name: Ivan
05.06.2016
Posts: 6
Quote
Order won't get FINISHED!

Hi.. sorry to bug you guys / webmaster with this... but I have been banging my head trying to figure out the finishing process for orders in payments methods. I have been developing my own payment method (sorry I couldn't afford you guys)...

In other words, this field "order_created" in the database always is 0, although with the other payment methods it get's processed correctly and the order is properly finished.

I have tried returning "completed" in function checkTransaction($pmconfigs, $order, $act), like this:

$payment_status = trim(stripslashes($_POST['ok_txn_status']));
if ($payment_status == 'completed'){
return array(1, '');
} elseif ($payment_status == 'pending') {
saveToLog("payment.log", "Status pending. Order ID ".$order->order_id.". Reason: ".$_POST['pending_reason']);
return array(2, trim(stripslashes($_POST['pending_reason'])) );
} elseif ($payment_status == 'failed') {
return array(3, 'Status Failed. Order ID '.$order->order_id );
} elseif ($payment_status == 'refunded') {
return array(3, "Status Refunded. Order ID ".$order->order_id );
}else {
return array(0, "Order number ".$order->order_id."\nOkpay error\nPayment status - $payment_status.");
}

And also this:

function complete($pmconfigs, $order, $payment) {
if ($order->order_status == '1'){
$checkout = JModelLegacy::getInstance('checkout', 'jshop');
$checkout->changeStatusOrder($order->order_id, $pmconfigs['transaction_pending_status'], 0);
return;
} else
return;
}

But still comes up as "Not finished"

What else do I need to do??

I don't understand this: it is too cryptic!
/**
* Exec after notify. Step7.
*/
function nofityFinish($pmconfigs, $order, $rescode){
}

/**
* exec before end. Step7.
*/
function finish($pmconfigs, $order, $rescode, $act){
}

/**
* exec complete. StepFinish.
*/
function complete($pmconfigs, $order, $payment){
}


Thank you in advance...

 
18.06.2016 21:45
#2
Bilmar
Joomshopping forum user no avatar
Name: Mark
23.05.2016
Posts: 124
Quote
Aw: Order won't get FINISHED!

I have the same problem. I even deleted the "Pending" option in the transaction statuses and it still loads as pending?

 
20.06.2016 03:38
#3
Bilmar
Joomshopping forum user no avatar
Name: Mark
23.05.2016
Posts: 124
Quote
Aw: Order won't get FINISHED!

Where does the Order screen get the statuses from?

I have completely deleted the "pending" status as an option and the orders still show as pending when someone checks out with Paypal standard.

If they check out with Paypal Express, everything works as it should.

I have fixed the IPN URL and the log shows the act=notify so what else could be the issue?

 
20.06.2016 21:11
#4
webdesigner
(Support Team)
User webdesigner
Name: Admin
05.08.2010
Posts: 16511
Quote
Aw: Order won't get FINISHED!

https://www.webdesigner-profi.de/joomla-webdesign/shop/support/paypal-configuration.html?lang=en

 
20.06.2016 21:40
#5
Bilmar
Joomshopping forum user no avatar
Name: Mark
23.05.2016
Posts: 124
Quote
Aw: Order won't get FINISHED!

I understand that but something else is wrong then because I completely removed the option for "pending" as an option yet that is the status they still show up in on the order screen?
Aw: Order won't get FINISHED!

 
26.06.2016 16:40
#6
Bilmar
Joomshopping forum user no avatar
Name: Mark
23.05.2016
Posts: 124
Quote
Aw: Order won't get FINISHED!

Would it be possible please for Joomshopping to take a few minutes to just look at the functionality of the core Paypal payment module?

Maybe add some more detailed information on exactly how to have the system automatically finish the orders and send the emails like it does with Paypal Express?

I have attempted every setting and configuration you have suggested and have been all over these forums looking for solutions with no success.

It would be very helpful for myself and lots of other people using Joomshopping to resolve this.

Thank you.

 
26.06.2016 23:39
#7
Bilmar
Joomshopping forum user no avatar
Name: Mark
23.05.2016
Posts: 124
Quote
Aw: Order won't get FINISHED!

SOLUTION!! SOLUTION!! SOLUTION!! SOLUTION!! SOLUTION!! SOLUTION!!

I fixed it after days and days of searching and testing, I finally got it corrected so hopefully this helps others not have to go through all the problems I did!!

First - Check to make sure you are using at least PHP4 or higher. If you are not - None of this will work for you!
Second - Go to your pm_paypal.php file and change the following line:

curl_setopt($ch, CURLOPT_SSLVERSION, $pmconfigs['CURLOPT_SSLVERSION']);
(This is about line 87 in the pm_paypal file)

CHANGE TO:

curl_setopt($ch, CURLOPT_SSLVERSION, CURL_SSLVERSION_TLSv1_2 );


This should be enough for most people and allow the orders to finish properly and the emails to be sent.

IF NOT - then also do the steps here - ONLY IF THE ABOVE 2 STEPS DO NOT FIX THE PROBLEM:

Third - Go to this page https://gist.github.com/VersatilityWerks/5719158/download to get a clean copy of the file cacert.pem

NOTE - Any method involving windows notepad or other editors corrupts the file and gives the cURL error 60 etc and it messes it up and won't work.

Fourth - Take that newly saved file and upload it anywhere on your server you want. I put mine in the PHP/Extras folder just to keep everything together.

Fifth - Now go to your PHP.ini file and find the line:

;curl.cainfo =


CHANGE IT TO

curl.cainfo = "[pathtothisfile]\cacert.pem"


Sixth - Restart your server!

That's it!

If you do not have access to your server then contact your administrator.

After these steps, your orders will complete / finish correctly and the emails will be sent assuming all the other settings and configurations are correct.

Hopefully this helps everyone else who is experiencing the same issues!


Letzte Ă„nderung: 26.06.2016 23:48
 
Copyrights MAXXmarketing GmbH. All Rights Reserved