summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPedro Cambra2012-09-14 09:45:20 (GMT)
committer Pedro Cambra2012-09-14 09:45:20 (GMT)
commitfff9273c5584e52ecb44b3fa3ae6c258b144cad8 (patch)
treed3172e8638dd871a911ccae4a5a9b4a9f7578f8f
parentb51f975446d45d6b0cccd828ae28d1e0e04f215f (diff)
Issue #1421280 by freakalis, splatio: Added Don't show/show a message in coupon review pane if no coupons have been applied.
-rw-r--r--includes/commerce_coupon.checkout_pane.inc9
1 files changed, 5 insertions, 4 deletions
diff --git a/includes/commerce_coupon.checkout_pane.inc b/includes/commerce_coupon.checkout_pane.inc
index 088b2a3..6f8386c 100644
--- a/includes/commerce_coupon.checkout_pane.inc
+++ b/includes/commerce_coupon.checkout_pane.inc
@@ -79,11 +79,12 @@ function commerce_coupon_pane_checkout_form_submit($form, &$form_state, $checkou
* Implements the callback for the checkout pane review form
*/
function commerce_coupon_pane_review($form, $form_state, $checkout_pane, $order) {
+ if(!empty($order->commerce_coupon_order_reference)) {
+ // Extract the View and display keys from the cart contents pane setting.
+ list($view_id, $display_id) = explode('|', variable_get('commerce_coupon_review_pane_view', 'commerce_coupon_review_pane|default'));
- // Extract the View and display keys from the cart contents pane setting.
- list($view_id, $display_id) = explode('|', variable_get('commerce_coupon_review_pane_view', 'commerce_coupon_review_pane|default'));
-
- return commerce_embed_view($view_id, $display_id, array($order->order_id));
+ return commerce_embed_view($view_id, $display_id, array($order->order_id));
+ }
}
/**