From c281586a29ca0cfa25ba5861b79da677d349c642 Mon Sep 17 00:00:00 2001 From: Brian Jacobel Date: Wed, 25 May 2016 16:43:29 -0400 Subject: [PATCH] Fix other usages of require_module outside <%block name="js-extra" --- lms/templates/courseware/accordion.html | 4 ++-- lms/templates/courseware/info.html | 8 ++++---- .../instructor/instructor_dashboard_2/certificates.html | 8 ++++---- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/lms/templates/courseware/accordion.html b/lms/templates/courseware/accordion.html index bee38eab0c..b684299539 100644 --- a/lms/templates/courseware/accordion.html +++ b/lms/templates/courseware/accordion.html @@ -84,7 +84,7 @@ else: % if toc: - <%static:require_module module_name="js/courseware/accordion_events" class_name="AccordionEvents"> + <%static:require_module_async module_name="js/courseware/accordion_events" class_name="AccordionEvents"> AccordionEvents(); - + % endif diff --git a/lms/templates/courseware/info.html b/lms/templates/courseware/info.html index 93e479bb74..efa824d81f 100644 --- a/lms/templates/courseware/info.html +++ b/lms/templates/courseware/info.html @@ -38,12 +38,12 @@ from openedx.core.djangolib.markup import HTML, Text <%include file="/courseware/course_navigation.html" args="active_page='info'" /> -<%static:require_module module_name="js/courseware/toggle_element_visibility" class_name="ToggleElementVisibility"> +<%static:require_module_async module_name="js/courseware/toggle_element_visibility" class_name="ToggleElementVisibility"> ToggleElementVisibility(); - -<%static:require_module module_name="js/courseware/course_home_events" class_name="CourseHomeEvents"> + +<%static:require_module_async module_name="js/courseware/course_home_events" class_name="CourseHomeEvents"> CourseHomeEvents(); - + <%block name="js_extra"> ## CourseTalk widget js script diff --git a/lms/templates/instructor/instructor_dashboard_2/certificates.html b/lms/templates/instructor/instructor_dashboard_2/certificates.html index de2f969b70..f5d3bce534 100644 --- a/lms/templates/instructor/instructor_dashboard_2/certificates.html +++ b/lms/templates/instructor/instructor_dashboard_2/certificates.html @@ -6,13 +6,13 @@ from django.utils.translation import ugettext as _ from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string %> -<%static:require_module module_name="js/certificates/factories/certificate_whitelist_factory" class_name="CertificateWhitelistFactory"> +<%static:require_module_async module_name="js/certificates/factories/certificate_whitelist_factory" class_name="CertificateWhitelistFactory"> CertificateWhitelistFactory(${certificate_white_list | n, dump_js_escaped_json}, '${generate_certificate_exceptions_url | n, js_escaped_string}', '${certificate_exception_view_url | n, js_escaped_string}', '${generate_bulk_certificate_exceptions_url | n, js_escaped_string}', ${bool(section_data['active_certificate']) | n, dump_js_escaped_json}); - + -<%static:require_module module_name="js/certificates/factories/certificate_invalidation_factory" class_name="CertificateInvalidationFactory"> +<%static:require_module_async module_name="js/certificates/factories/certificate_invalidation_factory" class_name="CertificateInvalidationFactory"> CertificateInvalidationFactory('${certificate_invalidations | n, dump_js_escaped_json}', '${certificate_invalidation_view_url | n, js_escaped_string}'); - +