Commit fa981e84 by Douglas Hall Committed by GitHub

Merge pull request #15186 from edx/douglashall/WL-1052

Allow for SiteConfiguration override of SOCIAL_SHARING_SETTINGS setting.
parents 6129494a 8f95f799
...@@ -8,6 +8,7 @@ from django.utils.translation import ugettext as _ ...@@ -8,6 +8,7 @@ from django.utils.translation import ugettext as _
from django.template import RequestContext from django.template import RequestContext
import third_party_auth import third_party_auth
from third_party_auth import pipeline from third_party_auth import pipeline
from openedx.core.djangoapps.site_configuration import helpers as configuration_helpers
from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string from openedx.core.djangolib.js_utils import dump_js_escaped_json, js_escaped_string
from openedx.core.djangolib.markup import HTML, Text from openedx.core.djangolib.markup import HTML, Text
%> %>
...@@ -102,7 +103,12 @@ from openedx.core.djangolib.markup import HTML, Text ...@@ -102,7 +103,12 @@ from openedx.core.djangolib.markup import HTML, Text
% if len(course_enrollments) > 0: % if len(course_enrollments) > 0:
<ul class="listing-courses"> <ul class="listing-courses">
<% share_settings = getattr(settings, 'SOCIAL_SHARING_SETTINGS', {}) %> <%
share_settings = configuration_helpers.get_value(
'SOCIAL_SHARING_SETTINGS',
getattr(settings, 'SOCIAL_SHARING_SETTINGS', {})
)
%>
% for dashboard_index, enrollment in enumerate(course_enrollments): % for dashboard_index, enrollment in enumerate(course_enrollments):
<% show_courseware_link = (enrollment.course_id in show_courseware_links_for) %> <% show_courseware_link = (enrollment.course_id in show_courseware_links_for) %>
<% cert_status = cert_statuses.get(enrollment.course_id) %> <% cert_status = cert_statuses.get(enrollment.course_id) %>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment