Commit 9e9825cb by Calen Pennington

Enable the edge virtual university landing page in the lms

parent d21c5761
...@@ -420,7 +420,7 @@ def university_profile(request, org_id): ...@@ -420,7 +420,7 @@ def university_profile(request, org_id):
Return the profile for the particular org_id. 404 if it's not valid. Return the profile for the particular org_id. 404 if it's not valid.
""" """
all_courses = modulestore().get_courses() all_courses = modulestore().get_courses()
valid_org_ids = set(c.org for c in all_courses) valid_org_ids = set(c.org for c in all_courses).union(settings.VIRTUAL_UNIVERSITIES)
if org_id not in valid_org_ids: if org_id not in valid_org_ids:
raise Http404("University Profile not found for {0}".format(org_id)) raise Http404("University Profile not found for {0}".format(org_id))
......
...@@ -58,6 +58,7 @@ LOGGING = get_logger_config(LOG_DIR, ...@@ -58,6 +58,7 @@ LOGGING = get_logger_config(LOG_DIR,
COURSE_LISTINGS = ENV_TOKENS.get('COURSE_LISTINGS', {}) COURSE_LISTINGS = ENV_TOKENS.get('COURSE_LISTINGS', {})
SUBDOMAIN_BRANDING = ENV_TOKENS.get('SUBDOMAIN_BRANDING', {}) SUBDOMAIN_BRANDING = ENV_TOKENS.get('SUBDOMAIN_BRANDING', {})
VIRTUAL_UNIVERSITIES = ENV_TOKENS.get('VIRTUAL_UNIVERSITIES', [])
COMMENTS_SERVICE_URL = ENV_TOKENS.get("COMMENTS_SERVICE_URL",'') COMMENTS_SERVICE_URL = ENV_TOKENS.get("COMMENTS_SERVICE_URL",'')
COMMENTS_SERVICE_KEY = ENV_TOKENS.get("COMMENTS_SERVICE_KEY",'') COMMENTS_SERVICE_KEY = ENV_TOKENS.get("COMMENTS_SERVICE_KEY",'')
......
...@@ -4,6 +4,11 @@ Settings for the LMS that runs alongside the CMS on AWS ...@@ -4,6 +4,11 @@ Settings for the LMS that runs alongside the CMS on AWS
from ..dev import * from ..dev import *
MITX_FEATURES['AUTH_USE_MIT_CERTIFICATES'] = False
SUBDOMAIN_BRANDING['edge'] = 'edge'
VIRTUAL_UNIVERSITIES = ['edge']
modulestore_options = { modulestore_options = {
'default_class': 'xmodule.raw_module.RawDescriptor', 'default_class': 'xmodule.raw_module.RawDescriptor',
'host': 'localhost', 'host': 'localhost',
...@@ -24,6 +29,6 @@ CONTENTSTORE = { ...@@ -24,6 +29,6 @@ CONTENTSTORE = {
'ENGINE': 'xmodule.contentstore.mongo.MongoContentStore', 'ENGINE': 'xmodule.contentstore.mongo.MongoContentStore',
'OPTIONS': { 'OPTIONS': {
'host': 'localhost', 'host': 'localhost',
'db' : 'xcontent', 'db': 'xcontent',
} }
} }
...@@ -101,6 +101,10 @@ SUBDOMAIN_BRANDING = { ...@@ -101,6 +101,10 @@ SUBDOMAIN_BRANDING = {
'harvard': 'HarvardX', 'harvard': 'HarvardX',
} }
# List of `university` landing pages to display, even though they may not
# have an actual course with that org set
VIRTUAL_UNIVERSITIES = []
COMMENTS_SERVICE_KEY = "PUT_YOUR_API_KEY_HERE" COMMENTS_SERVICE_KEY = "PUT_YOUR_API_KEY_HERE"
......
<%inherit file="base.html" /> <%inherit file="base.html" />
<%! from django.core.urlresolvers import reverse %>
<%block name="title">edX edge</%block> <%block name="title">edX edge</%block>
<%block name="bodyclass">no-header edge-landing</%block> <%block name="bodyclass">no-header edge-landing</%block>
......
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