From b6406e8923e3ab53b635d181c9f2b7103cd47674 Mon Sep 17 00:00:00 2001 From: Jeremy Kersten Date: Fri, 30 Sep 2016 18:30:28 +0200 Subject: [PATCH] [IMP] website_sale: add payment terms page and update checkout. Old terms feature display the default terms from company. But if you have more than that 10 words, it was just unusable. Now, we just add a link to a page. --- addons/website_sale/controllers/main.py | 5 +++ addons/website_sale/views/templates.xml | 57 ++++++++++++++++++++----- 2 files changed, 52 insertions(+), 10 deletions(-) diff --git a/addons/website_sale/controllers/main.py b/addons/website_sale/controllers/main.py index ab98a1dcb0b..1c4123a8893 100644 --- a/addons/website_sale/controllers/main.py +++ b/addons/website_sale/controllers/main.py @@ -902,6 +902,11 @@ class WebsiteSale(http.Controller): return request.redirect('/shop/confirmation') + + @http.route(['/shop/terms'], type='http', auth="public", website=True) + def terms(self, **kw): + return request.render("website_sale.terms") + @http.route(['/shop/confirmation'], type='http', auth="public", website=True) def payment_confirmation(self, **post): """ End of checkout process controller. Confirmation is basically seing diff --git a/addons/website_sale/views/templates.xml b/addons/website_sale/views/templates.xml index e0ccf72f222..e18181e410b 100644 --- a/addons/website_sale/views/templates.xml +++ b/addons/website_sale/views/templates.xml @@ -1410,17 +1410,15 @@ - + +