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
0049c97d
Commit
0049c97d
authored
Jan 11, 2015
by
jsa
Committed by
Andy Armstrong
Jan 15, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use bulk_ops on course_about
parent
9607aa23
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
lms/djangoapps/courseware/views.py
+3
-5
No files found.
lms/djangoapps/courseware/views.py
View file @
0049c97d
...
@@ -737,16 +737,14 @@ def course_about(request, course_id):
...
@@ -737,16 +737,14 @@ def course_about(request, course_id):
course_key
=
SlashSeparatedCourseKey
.
from_deprecated_string
(
course_id
)
course_key
=
SlashSeparatedCourseKey
.
from_deprecated_string
(
course_id
)
with
modulestore
()
.
bulk_operations
(
course_key
):
permission_name
=
microsite
.
get_value
(
permission_name
=
microsite
.
get_value
(
'COURSE_ABOUT_VISIBILITY_PERMISSION'
,
'COURSE_ABOUT_VISIBILITY_PERMISSION'
,
settings
.
COURSE_ABOUT_VISIBILITY_PERMISSION
settings
.
COURSE_ABOUT_VISIBILITY_PERMISSION
)
)
course
=
get_course_with_access
(
request
.
user
,
permission_name
,
course_key
)
course
=
get_course_with_access
(
request
.
user
,
permission_name
,
course_key
)
if
microsite
.
get_value
(
if
microsite
.
get_value
(
'ENABLE_MKTG_SITE'
,
settings
.
FEATURES
.
get
(
'ENABLE_MKTG_SITE'
,
False
)):
'ENABLE_MKTG_SITE'
,
settings
.
FEATURES
.
get
(
'ENABLE_MKTG_SITE'
,
False
)
):
return
redirect
(
reverse
(
'info'
,
args
=
[
course
.
id
.
to_deprecated_string
()]))
return
redirect
(
reverse
(
'info'
,
args
=
[
course
.
id
.
to_deprecated_string
()]))
registered
=
registered_for_course
(
course
,
request
.
user
)
registered
=
registered_for_course
(
course
,
request
.
user
)
...
@@ -768,7 +766,7 @@ def course_about(request, course_id):
...
@@ -768,7 +766,7 @@ def course_about(request, course_id):
reg_then_add_to_cart_link
=
""
reg_then_add_to_cart_link
=
""
_is_shopping_cart_enabled
=
is_shopping_cart_enabled
()
_is_shopping_cart_enabled
=
is_shopping_cart_enabled
()
if
(
_is_shopping_cart_enabled
)
:
if
_is_shopping_cart_enabled
:
registration_price
=
CourseMode
.
min_course_price_for_currency
(
course_key
,
registration_price
=
CourseMode
.
min_course_price_for_currency
(
course_key
,
settings
.
PAID_COURSE_REGISTRATION_CURRENCY
[
0
])
settings
.
PAID_COURSE_REGISTRATION_CURRENCY
[
0
])
if
request
.
user
.
is_authenticated
():
if
request
.
user
.
is_authenticated
():
...
...
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