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
511a38ac
Commit
511a38ac
authored
Jul 25, 2014
by
Joe Blaylock
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Resolve conflicts from upstream release merge
Thanks to David and Giulio for their assistance.
parent
1aa630b9
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
7 additions
and
69 deletions
+7
-69
AUTHORS
+0
-4
cms/djangoapps/contentstore/views/component.py
+1
-5
cms/djangoapps/contentstore/views/tests/test_checklists.py
+1
-7
cms/urls.py
+0
-21
lms/djangoapps/courseware/access.py
+1
-6
lms/djangoapps/courseware/views.py
+4
-17
lms/templates/courseware/course_about.html
+0
-4
lms/templates/main_django.html
+0
-5
No files found.
AUTHORS
View file @
511a38ac
...
@@ -155,14 +155,10 @@ Johnny Brown <johnnybrown7@gmail.com>
...
@@ -155,14 +155,10 @@ Johnny Brown <johnnybrown7@gmail.com>
Ben McMorran <bmcmorran@edx.org>
Ben McMorran <bmcmorran@edx.org>
Mat Peterson <mpeterson@edx.org>
Mat Peterson <mpeterson@edx.org>
Tim Babych <tim.babych@gmail.com>
Tim Babych <tim.babych@gmail.com>
<<<<<<< HEAD
Se Won Jang <swjang@stanford.edu>
Se Won Jang <swjang@stanford.edu>
=======
Brandon DeRosier <btd@cheesekeg.com>
Brandon DeRosier <btd@cheesekeg.com>
Daniel Li <swli@edx.org>
Daniel Li <swli@edx.org>
Daniel Friedman <dfriedman@edx.org>
Daniel Friedman <dfriedman@edx.org>
Asad Iqbal <aiqbal@edx.org>
Asad Iqbal <aiqbal@edx.org>
Peter Pinch <pdpinch@mit.edu>
Peter Pinch <pdpinch@mit.edu>
Muhammad Shoaib <mshoaib@edx.org>
Muhammad Shoaib <mshoaib@edx.org>
>>>>>>> upstream/rc/2014-07-23
cms/djangoapps/contentstore/views/component.py
View file @
511a38ac
...
@@ -66,13 +66,9 @@ else:
...
@@ -66,13 +66,9 @@ else:
'concept'
,
# Concept mapper. See https://github.com/pmitros/ConceptXBlock
'concept'
,
# Concept mapper. See https://github.com/pmitros/ConceptXBlock
'done'
,
# Lets students mark things as done. See https://github.com/pmitros/DoneXBlock
'done'
,
# Lets students mark things as done. See https://github.com/pmitros/DoneXBlock
'audio'
,
# Embed an audio file. See https://github.com/pmitros/AudioXBlock
'audio'
,
# Embed an audio file. See https://github.com/pmitros/AudioXBlock
<<<<<<<
HEAD
'edx_sga'
,
# that weird grading xblock thing - remove this next merge
'split_test'
,
'edx_sga'
=======
SPLIT_TEST_COMPONENT_TYPE
,
# Adds A/B test support
SPLIT_TEST_COMPONENT_TYPE
,
# Adds A/B test support
'recommender'
# Crowdsourced recommender. Prototype by dli&pmitros. Intended for roll-out in one place in one course.
'recommender'
# Crowdsourced recommender. Prototype by dli&pmitros. Intended for roll-out in one place in one course.
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
]
+
OPEN_ENDED_COMPONENT_TYPES
+
NOTE_COMPONENT_TYPES
]
+
OPEN_ENDED_COMPONENT_TYPES
+
NOTE_COMPONENT_TYPES
ADVANCED_COMPONENT_CATEGORY
=
'advanced'
ADVANCED_COMPONENT_CATEGORY
=
'advanced'
...
...
cms/djangoapps/contentstore/views/tests/test_checklists.py
View file @
511a38ac
...
@@ -136,15 +136,9 @@ class ChecklistTestCase(CourseTestCase):
...
@@ -136,15 +136,9 @@ class ChecklistTestCase(CourseTestCase):
# Verify no side effect in the original list.
# Verify no side effect in the original list.
self
.
assertEqual
(
get_action_url
(
checklist
,
index
),
stored
)
self
.
assertEqual
(
get_action_url
(
checklist
,
index
),
stored
)
<<<<<<<
HEAD
test_expansion
(
self
.
course
.
checklists
[
0
],
0
,
'ManageUsers'
,
'/course_team/slashes:mitX+333+Checklists_Course/'
)
test_expansion
(
self
.
course
.
checklists
[
1
],
1
,
'CourseOutline'
,
'/course/slashes:mitX+333+Checklists_Course'
)
test_expansion
(
self
.
course
.
checklists
[
2
],
0
,
'http://www.youtube.com'
,
'http://www.youtube.com'
)
=======
test_expansion
(
self
.
course
.
checklists
[
0
],
0
,
'ManageUsers'
,
'/course_team/mitX/333/Checklists_Course/'
)
test_expansion
(
self
.
course
.
checklists
[
0
],
0
,
'ManageUsers'
,
'/course_team/mitX/333/Checklists_Course/'
)
test_expansion
(
self
.
course
.
checklists
[
1
],
1
,
'CourseOutline'
,
'/course/mitX/333/Checklists_Course'
)
test_expansion
(
self
.
course
.
checklists
[
1
],
1
,
'CourseOutline'
,
'/course/mitX/333/Checklists_Course'
)
test_expansion
(
self
.
course
.
checklists
[
2
],
0
,
'http://help.edge.edx.org/'
,
'http://help.edge.edx.org/'
)
test_expansion
(
self
.
course
.
checklists
[
2
],
0
,
'http://www.youtube.com'
,
'http://www.youtube.com'
)
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
def
get_first_item
(
checklist
):
def
get_first_item
(
checklist
):
...
...
cms/urls.py
View file @
511a38ac
...
@@ -72,29 +72,9 @@ urlpatterns += patterns(
...
@@ -72,29 +72,9 @@ urlpatterns += patterns(
r'^course_info_update/{}/(?P<provided_id>\d+)?$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
r'^course_info_update/{}/(?P<provided_id>\d+)?$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'course_info_update_handler'
'course_info_update_handler'
),
),
<<<<<<<
HEAD
url
(
r'^course/(?P<course_key_string>[^/]+)?$'
,
'course_handler'
,
name
=
'course_handler'
),
url
(
r'^subsection/(?P<usage_key_string>[^/]+)$'
,
'subsection_handler'
),
url
(
r'^unit/(?P<usage_key_string>[^/]+)$'
,
'unit_handler'
),
url
(
r'^container/(?P<usage_key_string>[^/]+)$'
,
'container_handler'
),
url
(
r'^checklists/(?P<course_key_string>[^/]+)/(?P<checklist_index>\d+)?$'
,
'checklists_handler'
),
url
(
r'^orphan/(?P<course_key_string>[^/]+)$'
,
'orphan_handler'
),
url
(
r'^assets/(?P<course_key_string>[^/]+)/(?P<asset_key_string>.+)?$'
,
'assets_handler'
),
url
(
r'^import/(?P<course_key_string>[^/]+)$'
,
'import_handler'
),
url
(
r'^import_status/(?P<course_key_string>[^/]+)/(?P<filename>.+)$'
,
'import_status_handler'
),
url
(
r'^export/(?P<course_key_string>[^/]+)$'
,
'export_handler'
),
url
(
r'^xblock/(?P<usage_key_string>[^/]+)/(?P<view_name>[^/]+)$'
,
'xblock_view_handler'
),
url
(
r'^xblock/(?P<usage_key_string>[^/]+)?$'
,
'xblock_handler'
),
url
(
r'^tabs/(?P<course_key_string>[^/]+)$'
,
'tabs_handler'
),
url
(
r'^settings/details/(?P<course_key_string>[^/]+)$'
,
'settings_handler'
),
url
(
r'^settings/grading/(?P<course_key_string>[^/]+)(/)?(?P<grader_index>\d+)?$'
,
'grading_handler'
),
url
(
r'^settings/advanced/(?P<course_key_string>[^/]+)$'
,
'advanced_settings_handler'
),
url
(
r'^textbooks/(?P<course_key_string>[^/]+)$'
,
'textbooks_list_handler'
),
url
(
r'^textbooks/(?P<course_key_string>[^/]+)/(?P<textbook_id>\d[^/]*)$'
,
'textbooks_detail_handler'
),
url
(
r'^utilities/(?P<course_key_string>[^/]+)$'
,
'utility_handler'
),
url
(
r'^utilities/(?P<course_key_string>[^/]+)$'
,
'utility_handler'
),
url
(
r'^utility/captions/(?P<course_key_string>[^/]+)$'
,
'utility_captions_handler'
),
url
(
r'^utility/captions/(?P<course_key_string>[^/]+)$'
,
'utility_captions_handler'
),
url
(
r'^utility/bulksettings/(?P<course_key_string>[^/]+)$'
,
'utility_bulksettings_handler'
),
url
(
r'^utility/bulksettings/(?P<course_key_string>[^/]+)$'
,
'utility_bulksettings_handler'
),
=======
url
(
r'^course/{}?$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'course_handler'
,
name
=
'course_handler'
),
url
(
r'^course/{}?$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'course_handler'
,
name
=
'course_handler'
),
url
(
r'^subsection/{}$'
.
format
(
settings
.
USAGE_KEY_PATTERN
),
'subsection_handler'
),
url
(
r'^subsection/{}$'
.
format
(
settings
.
USAGE_KEY_PATTERN
),
'subsection_handler'
),
url
(
r'^unit/{}$'
.
format
(
settings
.
USAGE_KEY_PATTERN
),
'unit_handler'
),
url
(
r'^unit/{}$'
.
format
(
settings
.
USAGE_KEY_PATTERN
),
'unit_handler'
),
...
@@ -113,7 +93,6 @@ urlpatterns += patterns(
...
@@ -113,7 +93,6 @@ urlpatterns += patterns(
url
(
r'^settings/advanced/{}$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'advanced_settings_handler'
),
url
(
r'^settings/advanced/{}$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'advanced_settings_handler'
),
url
(
r'^textbooks/{}$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'textbooks_list_handler'
),
url
(
r'^textbooks/{}$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'textbooks_list_handler'
),
url
(
r'^textbooks/{}/(?P<textbook_id>\d[^/]*)$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'textbooks_detail_handler'
),
url
(
r'^textbooks/{}/(?P<textbook_id>\d[^/]*)$'
.
format
(
settings
.
COURSE_KEY_PATTERN
),
'textbooks_detail_handler'
),
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
)
)
if
settings
.
FEATURES
.
get
(
'ENABLE_GROUP_CONFIGURATIONS'
):
if
settings
.
FEATURES
.
get
(
'ENABLE_GROUP_CONFIGURATIONS'
):
...
...
lms/djangoapps/courseware/access.py
View file @
511a38ac
...
@@ -170,16 +170,14 @@ def _has_access_course_desc(user, action, course):
...
@@ -170,16 +170,14 @@ def _has_access_course_desc(user, action, course):
else
:
else
:
reg_method_ok
=
True
# if not using this access check, it's always OK.
reg_method_ok
=
True
# if not using this access check, it's always OK.
<<<<<<<
HEAD
if
reg_method_ok
and
within_enrollment_period
():
if
reg_method_ok
and
within_enrollment_period
():
# in enrollment period, so any user is allowed to enroll.
# in enrollment period, so any user is allowed to enroll.
debug
(
"Allow: in enrollment period"
)
debug
(
"Allow: in enrollment period"
)
return
True
return
True
=======
now
=
datetime
.
now
(
UTC
())
now
=
datetime
.
now
(
UTC
())
start
=
course
.
enrollment_start
or
datetime
.
min
.
replace
(
tzinfo
=
pytz
.
UTC
)
start
=
course
.
enrollment_start
or
datetime
.
min
.
replace
(
tzinfo
=
pytz
.
UTC
)
end
=
course
.
enrollment_end
or
datetime
.
max
.
replace
(
tzinfo
=
pytz
.
UTC
)
end
=
course
.
enrollment_end
or
datetime
.
max
.
replace
(
tzinfo
=
pytz
.
UTC
)
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
# if user is in CourseEnrollmentAllowed with right course key then can also enroll
# if user is in CourseEnrollmentAllowed with right course key then can also enroll
# (note that course.id actually points to a CourseKey)
# (note that course.id actually points to a CourseKey)
...
@@ -315,11 +313,8 @@ def _has_access_descriptor(user, action, descriptor, course_key=None):
...
@@ -315,11 +313,8 @@ def _has_access_descriptor(user, action, descriptor, course_key=None):
students to see modules. If not, views should check the course, so we
students to see modules. If not, views should check the course, so we
don't have to hit the enrollments table on every module load.
don't have to hit the enrollments table on every module load.
"""
"""
<<<<<<<
HEAD
=======
if
descriptor
.
visible_to_staff_only
and
not
_has_staff_access_to_descriptor
(
user
,
descriptor
,
course_key
):
if
descriptor
.
visible_to_staff_only
and
not
_has_staff_access_to_descriptor
(
user
,
descriptor
,
course_key
):
return
False
return
False
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
# If start dates are off, can always load
# If start dates are off, can always load
if
settings
.
FEATURES
[
'DISABLE_START_DATES'
]
and
not
is_masquerading_as_student
(
user
):
if
settings
.
FEATURES
[
'DISABLE_START_DATES'
]
and
not
is_masquerading_as_student
(
user
):
...
...
lms/djangoapps/courseware/views.py
View file @
511a38ac
...
@@ -649,7 +649,6 @@ def course_about(request, course_id):
...
@@ -649,7 +649,6 @@ def course_about(request, course_id):
reg_then_add_to_cart_link
=
"{reg_url}?course_id={course_id}&enrollment_action=add_to_cart"
.
format
(
reg_then_add_to_cart_link
=
"{reg_url}?course_id={course_id}&enrollment_action=add_to_cart"
.
format
(
reg_url
=
reverse
(
'register_user'
),
course_id
=
course
.
id
.
to_deprecated_string
())
reg_url
=
reverse
(
'register_user'
),
course_id
=
course
.
id
.
to_deprecated_string
())
<<<<<<<
HEAD
# only allow course sneak peek if
# only allow course sneak peek if
# 1) within enrollment period
# 1) within enrollment period
# 2) course specifies it's okay
# 2) course specifies it's okay
...
@@ -658,49 +657,37 @@ def course_about(request, course_id):
...
@@ -658,49 +657,37 @@ def course_about(request, course_id):
CoursePreference
.
course_allows_nonregistered_access
(
course_key
)
and
CoursePreference
.
course_allows_nonregistered_access
(
course_key
)
and
not
UserProfile
.
has_registered
(
request
.
user
))
not
UserProfile
.
has_registered
(
request
.
user
))
# see if we have already filled up all allowed enrollments
is_course_full
=
CourseEnrollment
.
is_course_full
(
course
)
context
=
{
=======
# Used to provide context to message to student if enrollment not allowed
# Used to provide context to message to student if enrollment not allowed
can_enroll
=
has_access
(
request
.
user
,
'enroll'
,
course
)
can_enroll
=
has_access
(
request
.
user
,
'enroll'
,
course
)
invitation_only
=
course
.
invitation_only
invitation_only
=
course
.
invitation_only
# see if we have already filled up all allowed enrollments
is_course_full
=
CourseEnrollment
.
is_course_full
(
course
)
is_course_full
=
CourseEnrollment
.
is_course_full
(
course
)
# Register button should be disabled if one of the following is true:
# Register button should be disabled if one of the following is true:
# - Student is already registered for course
# - Student is already registered for course
# - Course is already full
# - Course is already full
# - Student cannot enroll in course
# - Student cannot enroll in course
active_reg_button
=
not
(
registered
or
is_course_full
or
not
can_enroll
)
active_reg_button
=
not
(
reg
ularly_reg
istered
or
is_course_full
or
not
can_enroll
)
is_shib_course
=
uses_shib
(
course
)
is_shib_course
=
uses_shib
(
course
)
return
render_to_response
(
'courseware/course_about.html'
,
{
return
render_to_response
(
'courseware/course_about.html'
,
{
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
'course'
:
course
,
'course'
:
course
,
'regularly_registered'
:
regularly_registered
,
'sneakpeek_allowed'
:
sneakpeek_allowed
,
'staff_access'
:
staff_access
,
'staff_access'
:
staff_access
,
'studio_url'
:
studio_url
,
'studio_url'
:
studio_url
,
'regularly_registered'
:
regularly_registered
,
'sneakpeek_allowed'
:
sneakpeek_allowed
,
'course_target'
:
course_target
,
'course_target'
:
course_target
,
'registration_price'
:
registration_price
,
'registration_price'
:
registration_price
,
'in_cart'
:
in_cart
,
'in_cart'
:
in_cart
,
'reg_then_add_to_cart_link'
:
reg_then_add_to_cart_link
,
'reg_then_add_to_cart_link'
:
reg_then_add_to_cart_link
,
'show_courseware_link'
:
show_courseware_link
,
'show_courseware_link'
:
show_courseware_link
,
<<<<<<<
HEAD
'is_course_full'
:
is_course_full
}
return
render_to_response
(
'courseware/course_about.html'
,
context
)
=======
'is_course_full'
:
is_course_full
,
'is_course_full'
:
is_course_full
,
'can_enroll'
:
can_enroll
,
'can_enroll'
:
can_enroll
,
'invitation_only'
:
invitation_only
,
'invitation_only'
:
invitation_only
,
'active_reg_button'
:
active_reg_button
,
'active_reg_button'
:
active_reg_button
,
'is_shib_course'
:
is_shib_course
,
'is_shib_course'
:
is_shib_course
,
})
})
>>>>>>>
upstream
/
rc
/
2014
-
07
-
23
@ensure_csrf_cookie
@ensure_csrf_cookie
...
...
lms/templates/courseware/course_about.html
View file @
511a38ac
...
@@ -387,14 +387,10 @@
...
@@ -387,14 +387,10 @@
</section>
</section>
</section>
</section>
<
<<<<<<
HEAD
%
if
not
regularly_registered:
=
======
## Need to put this hidden form on the page so that the registration button works.
## Need to put this hidden form on the page so that the registration button works.
## Since it's no harm to display a hidden form, we display it with the most permissive conditional
## Since it's no harm to display a hidden form, we display it with the most permissive conditional
## which is when the student is not registered.
## which is when the student is not registered.
%if active_reg_button or is_shib_course:
%if active_reg_button or is_shib_course:
>
>>>>>> upstream/rc/2014-07-23
<div
style=
"display: none;"
>
<div
style=
"display: none;"
>
<form
id=
"class_enroll_form"
method=
"post"
data-remote=
"true"
action=
"${reverse('change_enrollment')}"
>
<form
id=
"class_enroll_form"
method=
"post"
data-remote=
"true"
action=
"${reverse('change_enrollment')}"
>
<fieldset
class=
"enroll_fieldset"
>
<fieldset
class=
"enroll_fieldset"
>
...
...
lms/templates/main_django.html
View file @
511a38ac
...
@@ -45,17 +45,12 @@
...
@@ -45,17 +45,12 @@
{% block bodyextra %}{% endblock %}
{% block bodyextra %}{% endblock %}
</div>
</div>
<
<<<<<<
HEAD
{% if FEATURES.USE_CUSTOM_THEME %}
{% if FEATURES.USE_CUSTOM_THEME %}
{% include "theme-footer.html" %}
{% include "theme-footer.html" %}
{% else %}
{% else %}
{% include "footer.html" %}
{% include "footer.html" %}
{% endif %}
{% endif %}
=======
{%
include
"
edx_footer
.
html
"
%}
>
>>>>>> upstream/rc/2014-07-23
{% compressed_js 'application' %}
{% compressed_js 'application' %}
{% compressed_js 'module-js' %}
{% compressed_js 'module-js' %}
...
...
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