Coupons updating the cart total but free_order_check_total() never gets called
budda - July 20, 2009 - 15:57
| Project: | UC Free Order Payment Method |
| Version: | 5.x-1.0 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | postponed (maintainer needs more info) |
Jump to:
Description
If a uc_coupon is used to take off 100% of the value the price becomes £0.
But this also causes the payment pane to reload. Reloading causes the JavaScript click that was attached to the hidden form field $('#edit-panes-payment-current-total').click(function() { free_order_check_total(this.value); }); to be lost during the AHAH reload.
In 6.x i think this can be resolved with Drupals "behaviors" feature?
So we end up with a total of £0 but still the option to pay because the free_order_check_total() JS call never got executed when the payment pane was re-loaded.

#1
I don't understand why the behavior you're describing is happening unless the uc_coupon module is doing something funny here. The whole pane shouldn't be reloading, and since the hidden current total field is outside of the line items div (that's what should actually be getting reloaded) it isn't affected by a normal line item update. Perhaps the coupon module is doing its own reloading that overwrites this?