function hook_commerce_cpc_coupon_detached in Commerce Cart Pane 7
Executes after coupon has been detached from the order on Coupon pane of cart page
Parameters
$order: The order object.
$coupon: The coupon object.
1 function implements hook_commerce_cpc_coupon_detached()
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
- commerce_cps_commerce_cpc_coupon_detached in modules/
shipping/ commerce_cps.module - Implements hook_commerce_cpc_coupon_detached().
1 invocation of hook_commerce_cpc_coupon_detached()
- commerce_cpc_remove_from_order_callback in modules/
coupon/ commerce_cpc.module - Override commerce_coupon_remove_coupon_from_order_callback(). Invoke the hook_commerce_cpc_coupon_detached hook after coupon was removed from order.
File
- modules/
coupon/ commerce_cpc.api.php, line 43 - This file contains no working PHP code; it exists to document hooks in the standard Drupal manner.
Code
function hook_commerce_cpc_coupon_detached($order, $coupon) {
// recalculate shipping after coupon has been detached from order.
// Works only of Coupon pane module is activated.
commerce_cps_add_order_shipping($order);
}