Problem with APPROVED status but different Merchant Track ID
-
Hi,
We have option in bank with AUTHORISATION + CAPTURE, where there is no direct charge but first status that we get after successful payment is APPROVED. But we have some cases where even we get APPROVED status visually we get payment failed page.
We did a small exploring and we figure out that for the same transaction Merchant Track ID created in payment initialization is not the same with the one we get in response, and according to the plugin code must be the same in order for the payment to be treated as successful.
if ( ( 'CAPTURED' === $result || 'APPROVED' === $result ) && $trackid === $tracking_id ) { $order->update_status( 'processing', __( 'Transaction ', 'nlb-payment-gateway-for-woocommerce' ) . $result ); if ( 'CAPTURED' === $result ) { $order->payment_complete(); } if ( 'APPROVED' === $result && 'yes' === $pg->instant_capture ) { action_capture_nlb_payment( $order_id ); } $order->reduce_order_stock(); $url = $pg->get_return_url( $order ); } else { $url = get_permalink( $pg->error_url ); $order->update_status( 'cancelled', __( 'Invalid response status', 'nlb-payment-gateway-for-woocommerce' ) ); }
Is this differences in tracking code are some bug of the plugin or there is something with the bank.
Thanks.
- The topic ‘Problem with APPROVED status but different Merchant Track ID’ is closed to new replies.