Posted: July 17, 2015 at 5:56 am
|
Hello, $payment = $transaction->last_payment(); What I get is that when proceeded by the ipn, the treatment goes to the approved_status line, but the only mail I get is the confirmed payment and the registration is still pending. After checking, the only difference after having approved the payment in data is the STS_ID field : TFL in the first case and TCM in the second. What could I do so the payment would be approved at first in the ipn and the email with informations sent at once, given some people don’t make it through to website ? Thank you already ! |
Hi there, This can be tricky because you may also find that in some cases the IPN hits the site after people return to your site as well. You can examine how the Event Espresso 4 PayPal Standard handles these scenarios. For example, the handle_payment_update() method in the EEG_Paypal_Standard class has some code that checks to see if the payment/transaction status was already updated (from the IPN or from when the return page is loaded) before it processes the transaction. |
|
|
Hi ! My main problem is not that I may have 2 message confirmation, that would come later (though there is indeed a great source of inspiration in the Paypal gateway), After looking at the DB before and after returning to the website, the only difference I saw in tables transaction, payment and registration_payment is that in transaction I have no txn_session_data before the returning to the shop. If so, would there be a way I could “forge” the session data to set it at the same time the IPN does trigger to validate to transaction in regards of the registration please ? Thank you for your time ! |
Hi there, As far as I can tell, the EE_Payment_Processor::update_txn_based_on_payment method should handle the IPN and use that to update the payment status. If that’s not working for you, you can open up an issue on the Github project and one of the developers can weigh in: |
|
|
Hi ! Ok, I will do that as soon as I will have my plugin perfectly packaged ! As a tomporary fix, I forced the gateway to bring back customer to the website … Thank you |
You’re welcome. |
|
The support post ‘Payment Gateway : handle_payment_update different behavior’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.