From 7c577fd34d221a1e552f7f58bf8fef25de2f0825 Mon Sep 17 00:00:00 2001 From: roen-odoo Date: Mon, 18 Dec 2023 15:10:23 +0000 Subject: [PATCH] [FIX] pos_loyalty: display "enter code" correctly Current behavior: When you only used the "Next order coupons" loyalty program, the "enter code" button was not displayed. Steps to reproduce: - Install the pos_loyalty module - Archive all the loyalty programs - Create a loyalty program with "Next order coupons" as reward - Open a PoS session opw-3608894 closes odoo/odoo#147101 X-original-commit: 55ad2020e4b56a2ce525959f0c021b83198446bc Signed-off-by: Adrien Guilliams (adgu) Signed-off-by: Robin Engels (roen) --- .../app/control_buttons/promo_code_button/promo_code_button.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/pos_loyalty/static/src/app/control_buttons/promo_code_button/promo_code_button.js b/addons/pos_loyalty/static/src/app/control_buttons/promo_code_button/promo_code_button.js index d3b497d0124..378e533fed4 100644 --- a/addons/pos_loyalty/static/src/app/control_buttons/promo_code_button/promo_code_button.js +++ b/addons/pos_loyalty/static/src/app/control_buttons/promo_code_button/promo_code_button.js @@ -34,7 +34,7 @@ ProductScreen.addControlButton({ component: PromoCodeButton, condition: function () { return this.pos.programs.some((p) => - ["coupons", "promotion", "gift_card", "promo_code"].includes(p.program_type) + ["coupons", "promotion", "gift_card", "promo_code", "next_order_coupons"].includes(p.program_type) ); }, });