diff --git a/classes/Discount.php b/classes/Discount.php index 90f61a823..136d4c3e4 100644 --- a/classes/Discount.php +++ b/classes/Discount.php @@ -172,7 +172,7 @@ class DiscountCore extends CartRule */ public static function getVouchersToCartDisplay($id_lang, $id_customer) { - return array(); + return CartRule::getCustomerCartRules($id_lang, $id_customer); } /** diff --git a/controllers/front/ParentOrderController.php b/controllers/front/ParentOrderController.php index 60533ed6c..aa19154f5 100644 --- a/controllers/front/ParentOrderController.php +++ b/controllers/front/ParentOrderController.php @@ -335,7 +335,7 @@ class ParentOrderControllerCore extends FrontController 'CUSTOMIZE_FILE' => Product::CUSTOMIZE_FILE, 'CUSTOMIZE_TEXTFIELD' => Product::CUSTOMIZE_TEXTFIELD, 'lastProductAdded' => $this->context->cart->getLastProduct(), - 'displayVouchers' => Discount::getVouchersToCartDisplay($this->context->language->id, (isset($this->context->customer->id) ? $this->context->customer->id : 0)), + 'displayVouchers' => CartRule::getCustomerCartRules($this->context->language->id, (isset($this->context->customer->id) ? $this->context->customer->id : 0)), 'currencySign' => $this->context->currency->sign, 'currencyRate' => $this->context->currency->conversion_rate, 'currencyFormat' => $this->context->currency->format, diff --git a/themes/default/css/global.css b/themes/default/css/global.css index 346a0304d..aa9278ae3 100644 --- a/themes/default/css/global.css +++ b/themes/default/css/global.css @@ -805,7 +805,7 @@ table#cart_summary #total_price_container { font-weight:normal; border-top:1px dotted #ccc } -.cart_voucher #display_cart_vouchers .title_offers {margin-top:10px} +.cart_voucher .title_offers {margin-top:10px} .cart_voucher #display_cart_vouchers span {font-weight:bold} .cart_voucher input.discount_name { padding:0 5px; diff --git a/themes/default/shopping-cart.tpl b/themes/default/shopping-cart.tpl index 07ad8a2f5..31f574dc7 100644 --- a/themes/default/shopping-cart.tpl +++ b/themes/default/shopping-cart.tpl @@ -190,16 +190,16 @@

- {if $displayVouchers} -

{l s='Take advantage of our offers:'}

-
- {foreach $displayVouchers as $voucher} - {$voucher.name} - {$voucher.description}
- {/foreach} -
- {/if} + {if $displayVouchers} +

{l s='Take advantage of our offers:'}

+
+ {foreach $displayVouchers as $voucher} + {$voucher.code} - {$voucher.name}
+ {/foreach} +
+ {/if} {/if} {if $use_taxes}