Jump to content

Bitpay pre-payment order validation


Recommended Posts

Hello Prestavelopers!

I am using PS 1.6.1.9 with Bitpay module. Unfortunately this payment module validates order after payment is done thus it is not possible to send order ID into Bitpay as payment parameter (cart ID is sent instead). 

To achieve this I modified 'ipn.php' and 'bitpay.php' (files attached). 

 

And it worked! Despite one mystery problem;

When I add item to cart and complete order with Bitpay method checked, I get redirect to Bitpay gateway, pay and get redirect back to eshop. <- Everything ok.

BUT when I try it again procedure stops because `Context::getContext()->cart` returns empty cart. <- This repeats until I run the script with `die;` and try again or when I access web from zero. 

 

// No errors found

 

Thank you for ANY ideas or workarounds,

I'd really appreciate help. 

 

Cheers,

Sýček

 

ipn.php

bitpay.php

Edited by Sýček
edited signature (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...