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
616d18e1
Commit
616d18e1
authored
11 years ago
by
Brian Wilson
Browse files
Options
Downloads
Patches
Plain Diff
Post-rebasing fixes to re-enable masquerading.
parent
1984cfec
Loading
Loading
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
lms/djangoapps/courseware/module_render.py
+4
-4
4 additions, 4 deletions
lms/djangoapps/courseware/module_render.py
lms/urls.py
+1
-1
1 addition, 1 deletion
lms/urls.py
with
5 additions
and
5 deletions
lms/djangoapps/courseware/module_render.py
+
4
−
4
View file @
616d18e1
...
...
@@ -183,6 +183,10 @@ def get_module_for_descriptor(user, request, descriptor, model_data_cache, cours
See get_module() docstring for further details.
"""
# allow course staff to masquerade as student
if
has_access
(
user
,
descriptor
,
'
staff
'
,
course_id
):
setup_masquerade
(
request
,
True
)
track_function
=
make_track_function
(
request
)
xqueue_callback_url_prefix
=
get_xqueue_callback_url_prefix
(
request
)
...
...
@@ -202,10 +206,6 @@ def get_module_for_descriptor_internal(user, descriptor, model_data_cache, cours
See get_module() docstring for further details.
"""
# allow course staff to masquerade as student
if
has_access
(
user
,
descriptor
,
'
staff
'
,
course_id
):
setup_masquerade
(
request
,
True
)
# Short circuit--if the user shouldn't have access, bail without doing any work
if
not
has_access
(
user
,
descriptor
,
'
load
'
,
course_id
):
return
None
...
...
This diff is collapsed.
Click to expand it.
lms/urls.py
+
1
−
1
View file @
616d18e1
...
...
@@ -58,7 +58,7 @@ urlpatterns = ('', # nopep8
name
=
'
auth_password_reset_done
'
),
url
(
r
'
^heartbeat$
'
,
include
(
'
heartbeat.urls
'
)),
url
(
r
'
^course_task_log_status/$
'
,
'
courseware.task
s
.course_task_log_status
'
,
name
=
'
course_task_log_status
'
),
url
(
r
'
^course_task_log_status/$
'
,
'
courseware.task
_queue
.course_task_log_status
'
,
name
=
'
course_task_log_status
'
),
)
# University profiles only make sense in the default edX context
...
...
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