Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
d69bbf27
Commit
d69bbf27
authored
May 06, 2013
by
John Jarvis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
using new template for "coming-soon"
parent
424d2956
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
8 deletions
+33
-8
lms/djangoapps/courseware/views.py
+3
-4
lms/templates/courseware/mktg_coming_soon.html
+30
-0
lms/templates/courseware/mktg_course_about.html
+0
-4
No files found.
lms/djangoapps/courseware/views.py
View file @
d69bbf27
...
@@ -535,13 +535,13 @@ def course_about(request, course_id):
...
@@ -535,13 +535,13 @@ def course_about(request, course_id):
@cache_if_anonymous
@cache_if_anonymous
def
mktg_course_about
(
request
,
course_id
):
def
mktg_course_about
(
request
,
course_id
):
coming_soon
=
False
try
:
try
:
course
=
get_course_with_access
(
request
.
user
,
course_id
,
'see_exists'
)
course
=
get_course_with_access
(
request
.
user
,
course_id
,
'see_exists'
)
except
Http404
as
e
:
except
Http404
as
e
:
# if a course does not exist yet, display a coming
# if a course does not exist yet, display a coming
# soon button
# soon button
coming_soon
=
True
return
render_to_response
(
'courseware/mktg_coming_soon.html'
,
{
'course_id'
:
course_id
})
registered
=
registered_for_course
(
course
,
request
.
user
)
registered
=
registered_for_course
(
course
,
request
.
user
)
...
@@ -557,8 +557,7 @@ def mktg_course_about(request, course_id):
...
@@ -557,8 +557,7 @@ def mktg_course_about(request, course_id):
{
'course'
:
course
,
{
'course'
:
course
,
'registered'
:
registered
,
'registered'
:
registered
,
'course_target'
:
course_target
,
'course_target'
:
course_target
,
'show_courseware_link'
:
show_courseware_link
,
'show_courseware_link'
:
show_courseware_link
})
'coming_soon'
:
coming_soon
})
...
...
lms/templates/courseware/mktg_coming_soon.html
0 → 100644
View file @
d69bbf27
<
%!
from
django
.
core
.
urlresolvers
import
reverse
from
courseware
.
courses
import
course_image_url
,
get_course_about_section
from
courseware
.
access
import
has_access
%
>
<
%
namespace
name=
'static'
file=
'../static_content.html'
/>
<
%
inherit
file=
"../mktg_iframe.html"
/>
<
%
block
name=
"title"
><title>
About ${course_id}
</title></
%
block>
<
%
block
name=
"bodyclass"
>
view-partial-mktgregister
</
%
block>
<
%
block
name=
"headextra"
>
<
%
include
file=
"../google_analytics.html"
/>
</
%
block>
<
%
block
name=
"content"
>
<script
src=
"${static.url('js/course_info.js')}"
></script>
<ul
class=
"list-actions register"
>
<li
class=
"item"
>
<a
class=
"action action-register is-registered"
href=
"#"
>
Coming Soon
</a>
</li>
</ul>
</
%
block>
lms/templates/courseware/mktg_course_about.html
View file @
d69bbf27
...
@@ -63,9 +63,6 @@
...
@@ -63,9 +63,6 @@
<ul
class=
"list-actions register"
>
<ul
class=
"list-actions register"
>
<li
class=
"item"
>
<li
class=
"item"
>
%if coming_soon:
<a
class=
"action action-register is-registered"
href=
"#"
>
Coming Soon
</a>
%else:
%if user.is_authenticated():
%if user.is_authenticated():
%if registered:
%if registered:
<!-- signed in, registered -->
<!-- signed in, registered -->
...
@@ -78,7 +75,6 @@
...
@@ -78,7 +75,6 @@
<!-- not signed in -->
<!-- not signed in -->
<a
class=
"action action-register is-not-signedin"
href=
"${reverse('register_user')}"
>
Register for
<strong>
${course.number}
</strong></a>
<a
class=
"action action-register is-not-signedin"
href=
"${reverse('register_user')}"
>
Register for
<strong>
${course.number}
</strong></a>
%endif
%endif
%endif
</li>
</li>
</ul>
</ul>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment