Download & Extend

Some CIM Orders Stuck In Checkout

Project:Drupal Commerce
Version:7.x-1.x-dev
Component:Payment
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

When paying with a saved card, many (though not all) orders are getting stuck in the checkout stage. The transaction is successful (and logged to the order as such), but the order status is never updated and a confirmation email never sent. It's not all orders, but I haven't been able to find an obvious difference between the good ones and the ones causing problems.

Comments

#1

Are you sure the transaction is successful? Could it be reporting a false positive inside of Drupal Commerce?

#2

Thanks for getting back on this. The transaction is successful and the card is charged. I believe the problem is that I have a one page checkout (no review) and clicking submit even if there are required fields missing or other form errors will still attempt a transaction. The form errors are reported to the user, but the transaction still goes through and the order balance is zeroed. Since the order balance is zero, subsequent transactions don't go through and the user can't complete checkout.

#3

Sounds like that'd do it. The module doesn't do anything atm to accommodate such a scenario

#4

Would it break anything to add something like:

<?php
if ($err = form_get_errors()) {
    return
FALSE;
  }
?>

#5

Project:Commerce Authorize.Net» Drupal Commerce
Version:7.x-1.x-dev» 7.x-1.x-dev
Component:Code» Payment

Form errors on other elements (ie: billing information) do not prevent payment submission when payment form is on the same pane.

AttachmentSizeStatusTest resultOperations
1415670-prevent_payment_callback_when_form_errors_present.patch832 bytesIdlePASSED: [[SimpleTest]]: [MySQL] 3,589 pass(es).View details

#6

Status:active» reviewed & tested by the community

This looks great to me.

#7

Status:reviewed & tested by the community» fixed

Yep, great patch. I added in a warning message so the customer knows that their payment will not be processed until all errors on the page have been addressed.

Commit: http://drupalcode.org/project/commerce.git/commitdiff/044ce3d

#8

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.