From 6fcfb2a6a37f8b3d9bad52c190feef30f4157a53 Mon Sep 17 00:00:00 2001 From: Chris Dodge Date: Thu, 30 Oct 2014 22:17:02 -0400 Subject: [PATCH] allow for a customized region on the receipt page that is microsite brand specific --- common/djangoapps/microsite_configuration/microsite.py | 2 +- lms/templates/shoppingcart/receipt.html | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/common/djangoapps/microsite_configuration/microsite.py b/common/djangoapps/microsite_configuration/microsite.py index 27f513ebe1..05409fe9e4 100644 --- a/common/djangoapps/microsite_configuration/microsite.py +++ b/common/djangoapps/microsite_configuration/microsite.py @@ -63,7 +63,7 @@ def get_template_path(relative_path): search_path = os.path.join(microsite_template_path, relative_path) if os.path.isfile(search_path): - path = '{0}/templates/{1}'.format( + path = '/{0}/templates/{1}'.format( get_value('microsite_name'), relative_path ) diff --git a/lms/templates/shoppingcart/receipt.html b/lms/templates/shoppingcart/receipt.html index 9c50a4e3db..7d4b8dd3bb 100644 --- a/lms/templates/shoppingcart/receipt.html +++ b/lms/templates/shoppingcart/receipt.html @@ -1,6 +1,7 @@ <%inherit file="shopping_cart_flow.html" /> <%! from django.utils.translation import ugettext as _ %> <%! from django.core.urlresolvers import reverse %> +<%! from microsite_configuration import microsite %> <%! from courseware.courses import course_image_url, get_course_about_section, get_course_by_id %> @@ -356,6 +357,8 @@ from courseware.courses import course_image_url, get_course_about_section, get_c ${_("Total")}: $${"{0:0.2f}".format(order.total_cost)} USD + ## Allow for a microsite to be able to insert additional text at the bottom of the page + <%include file="${microsite.get_template_path('receipt_custom_region.html')}" />