Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
edx-platform-release
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hsin-Yu Chien
edx-platform-release
Commits
0ff4d1ca
Commit
0ff4d1ca
authored
11 years ago
by
Greg Price
Browse files
Options
Downloads
Plain Diff
Merge pull request #1968 from edx/feature/gprice/drupal-course-redirects
Redirect from LMS courses page to marketing courses page
parents
63612800
93cbb2e4
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lms/djangoapps/branding/views.py
+6
-2
6 additions, 2 deletions
lms/djangoapps/branding/views.py
with
6 additions
and
2 deletions
lms/djangoapps/branding/views.py
+
6
−
2
View file @
0ff4d1ca
...
...
@@ -6,6 +6,7 @@ from django_future.csrf import ensure_csrf_cookie
import
student.views
import
branding
import
courseware.views
from
mitxmako.shortcuts
import
marketing_link
from
util.cache
import
cache_if_anonymous
...
...
@@ -36,9 +37,12 @@ def index(request):
@cache_if_anonymous
def
courses
(
request
):
"""
Render the
"
find courses
"
page. If subdomain branding is on, this is the
university profile page, otherwise it
'
s the edX courseware.views.courses page
Render the
"
find courses
"
page. If the marketing site is enabled, redirect
to that. Otherwise, if subdomain branding is on, this is the university
profile page. Otherwise, it
'
s the edX courseware.views.courses page
"""
if
settings
.
MITX_FEATURES
.
get
(
'
ENABLE_MKTG_SITE
'
,
False
):
return
redirect
(
marketing_link
(
'
COURSES
'
),
permanent
=
True
)
university
=
branding
.
get_university
(
request
.
META
.
get
(
'
HTTP_HOST
'
))
if
university
is
None
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment