Christopher Short Posted October 30, 2023 Share Posted October 30, 2023 Is it possible for a declined transaction to mark the pending order as such? Quote Link to comment Share on other sites More sharing options...
bsmither Posted October 30, 2023 Share Posted October 30, 2023 Yes. The Authorize.net gateway code (version 1.1.1 is what I am looking at) will tell CubeCart to set the order to Pending if the response code is anything other than Approved. That is: Declined, Error, and Held for Review. It will do this regardless whatever status the order had previously. This module (which might not be the same as the latest Authorize module from the MarketPlace) has two modes: SIM and AIM. The SIM mode does not record the order status in the respective order's Transaction Logs tab. The AIM mode does. Quote Link to comment Share on other sites More sharing options...
Christopher Short Posted October 31, 2023 Author Share Posted October 31, 2023 Update order status to processing for auth only check box should be off for that to work then? Here is what I see in the code: if($data["x_response_code"]=='1'){ switch($data["x_type"]) { case "auth_only": $status = 'Authorized'; if($this->_module['process_auth']=='1') { $order->orderStatus(Order::ORDER_PROCESS, $data["x_invoice_num"]); $order->paymentStatus(Order::PAYMENT_SUCCESS, $data["x_invoice_num"]); } break; case "auth_capture": $status = 'Captured'; $order->orderStatus(Order::ORDER_PROCESS, $data["x_invoice_num"]); $order->paymentStatus(Order::PAYMENT_SUCCESS, $data["x_invoice_num"]); break; case "void": $status = 'Void'; $order->orderStatus(Order::ORDER_CANCELLED, $data["x_invoice_num"]); $order->paymentStatus(Order::PAYMENT_CANCEL, $data["x_invoice_num"]); break; } } else { switch($data["x_response_code"]) { case '2': $status = 'Declined'; break; case '3': $status = 'Error'; break; case '4': $status = 'Held for Review'; break; } $order->orderStatus(Order::ORDER_PENDING, $data["cart_order_id"]); $order->paymentStatus(Order::PAYMENT_PENDING, $data["cart_order_id"]); } Quote Link to comment Share on other sites More sharing options...
bsmither Posted October 31, 2023 Share Posted October 31, 2023 So your question at first was not "Is this how it happens?", but rather "Can I make it do this?" And by "this", perhaps you meant that the module should tell CubeCart to set the order's status to "Declined" when Authorize.net sends back a response code of 'Declined' (case 2). The gateway.class.php file will need to be customized so that it will tell CubeCart to set the order's status to match that that of Authorize.net's response. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.