From 6f380eaf8f2f15c6b9c19987adc6813e70416497 Mon Sep 17 00:00:00 2001 From: Romain Derie Date: Fri, 9 Nov 2018 14:27:36 +0100 Subject: [PATCH] [FIX] website_sale_coupon: do not show generated coupon code if expired Before this commit, an `expired` generated coupon would be shown to the user. Now we hide these `expired` coupons. Note: An `expired` generated coupon might typically come from a SO that does not meet a 'on_next_order' program anymore. So the generated coupon that was set to `reserved` got canceled and set to `expired`. Step to reproduce: - Create a program oferring a product B on next order if you buy 2 product A - Add 2 product A to cart, you then see the message that you got a coupon for your next order - Remove on product A, you still see the message even if the generated coupon is now expired and not valid anymore. Closes #3062 --- views/website_sale_templates.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/website_sale_templates.xml b/views/website_sale_templates.xml index 83203f81d79..4fd4f51f6f0 100644 --- a/views/website_sale_templates.xml +++ b/views/website_sale_templates.xml @@ -42,7 +42,7 @@ - +
Your reward is available on a next order with this coupon code: