Commit ce769b36 by Peter Fogg

Convert PARTNER_SUPPORT_EMAIL to a setting.

parent b74e2d9e
...@@ -387,3 +387,6 @@ OAUTH_OIDC_ISSUER = ENV_TOKENS['OAUTH_OIDC_ISSUER'] ...@@ -387,3 +387,6 @@ OAUTH_OIDC_ISSUER = ENV_TOKENS['OAUTH_OIDC_ISSUER']
######################## CUSTOM COURSES for EDX CONNECTOR ###################### ######################## CUSTOM COURSES for EDX CONNECTOR ######################
if FEATURES.get('CUSTOM_COURSES_EDX'): if FEATURES.get('CUSTOM_COURSES_EDX'):
INSTALLED_APPS += ('openedx.core.djangoapps.ccxcon',) INSTALLED_APPS += ('openedx.core.djangoapps.ccxcon',)
# Partner support link for CMS footer
PARTNER_SUPPORT_EMAIL = ENV_TOKENS.get('PARTNER_SUPPORT_EMAIL', PARTNER_SUPPORT_EMAIL)
...@@ -94,7 +94,7 @@ FEATURES['ENABLE_MOBILE_REST_API'] = True # Enable video bumper in Studio ...@@ -94,7 +94,7 @@ FEATURES['ENABLE_MOBILE_REST_API'] = True # Enable video bumper in Studio
FEATURES['ENABLE_VIDEO_BUMPER'] = True # Enable video bumper in Studio settings FEATURES['ENABLE_VIDEO_BUMPER'] = True # Enable video bumper in Studio settings
# Enable partner support link in Studio footer # Enable partner support link in Studio footer
FEATURES['PARTNER_SUPPORT_EMAIL'] = 'partner-support@example.com' PARTNER_SUPPORT_EMAIL = 'partner-support@example.com'
# Disable some block types to test block deprecation logic # Disable some block types to test block deprecation logic
DEPRECATED_BLOCK_TYPES = ['poll', 'survey'] DEPRECATED_BLOCK_TYPES = ['poll', 'survey']
......
...@@ -1110,3 +1110,6 @@ OAUTH_OIDC_ISSUER = 'https://www.example.com/oauth2' ...@@ -1110,3 +1110,6 @@ OAUTH_OIDC_ISSUER = 'https://www.example.com/oauth2'
# 5 minute expiration time for JWT id tokens issued for external API requests. # 5 minute expiration time for JWT id tokens issued for external API requests.
OAUTH_ID_TOKEN_EXPIRATION = 5 * 60 OAUTH_ID_TOKEN_EXPIRATION = 5 * 60
# Partner support link for CMS footer
PARTNER_SUPPORT_EMAIL = ''
...@@ -23,7 +23,7 @@ from django.core.urlresolvers import reverse ...@@ -23,7 +23,7 @@ from django.core.urlresolvers import reverse
<%! <%!
from django.conf import settings from django.conf import settings
partner_email = settings.FEATURES.get('PARTNER_SUPPORT_EMAIL', '') partner_email = settings.PARTNER_SUPPORT_EMAIL
links = [{ links = [{
'href': 'http://docs.edx.org', 'href': 'http://docs.edx.org',
...@@ -49,7 +49,7 @@ from django.core.urlresolvers import reverse ...@@ -49,7 +49,7 @@ from django.core.urlresolvers import reverse
'href': 'mailto:{email}'.format(email=partner_email), 'href': 'mailto:{email}'.format(email=partner_email),
'sr_mouseover_text': _('Send an email to {email}').format(email=partner_email), 'sr_mouseover_text': _('Send an email to {email}').format(email=partner_email),
'text': _('Contact Us'), 'text': _('Contact Us'),
'condition': 'PARTNER_SUPPORT_EMAIL' in settings.FEATURES 'condition': bool(partner_email)
}] }]
%> %>
......
...@@ -23,7 +23,7 @@ from django.core.urlresolvers import reverse ...@@ -23,7 +23,7 @@ from django.core.urlresolvers import reverse
<%! <%!
from django.conf import settings from django.conf import settings
partner_email = settings.FEATURES.get('PARTNER_SUPPORT_EMAIL', '') partner_email = settings.PARTNER_SUPPORT_EMAIL
links = [{ links = [{
'href': 'http://docs.edx.org', 'href': 'http://docs.edx.org',
...@@ -49,7 +49,7 @@ from django.core.urlresolvers import reverse ...@@ -49,7 +49,7 @@ from django.core.urlresolvers import reverse
'href': 'mailto:{email}'.format(email=partner_email), 'href': 'mailto:{email}'.format(email=partner_email),
'sr_mouseover_text': _('Send an email to {email}').format(email=partner_email), 'sr_mouseover_text': _('Send an email to {email}').format(email=partner_email),
'text': _('Contact Us'), 'text': _('Contact Us'),
'condition': 'PARTNER_SUPPORT_EMAIL' in settings.FEATURES 'condition': bool(partner_email)
}] }]
%> %>
......
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