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
65f84963
Commit
65f84963
authored
Aug 08, 2012
by
Rocky Duan
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'ccp0101/moderation' into lol
Conflicts: lms/urls.py
parents
2e45b8c3
c4538854
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
8 additions
and
22 deletions
+8
-22
cms/envs/common.py
+1
-0
common/djangoapps/util/middleware.py
+0
-16
lms/djangoapps/courseware/module_render.py
+1
-1
lms/envs/common.py
+3
-1
lms/templates/staff_problem_info.html
+3
-3
lms/urls.py
+0
-1
No files found.
cms/envs/common.py
View file @
65f84963
...
@@ -121,6 +121,7 @@ MIDDLEWARE_CLASSES = (
...
@@ -121,6 +121,7 @@ MIDDLEWARE_CLASSES = (
)
)
############################ SIGNAL HANDLERS ################################
############################ SIGNAL HANDLERS ################################
# This is imported to register the exception signal handling that logs exceptions
import
monitoring.exceptions
# noqa
import
monitoring.exceptions
# noqa
############################ DJANGO_BUILTINS ################################
############################ DJANGO_BUILTINS ################################
...
...
common/djangoapps/util/middleware.py
deleted
100644 → 0
View file @
2e45b8c3
import
logging
from
django.conf
import
settings
from
django.http
import
HttpResponseServerError
log
=
logging
.
getLogger
(
"mitx"
)
class
ExceptionLoggingMiddleware
(
object
):
"""Just here to log unchecked exceptions that go all the way up the Django
stack"""
if
not
settings
.
TEMPLATE_DEBUG
:
def
process_exception
(
self
,
request
,
exception
):
log
.
exception
(
exception
)
return
HttpResponseServerError
(
"Server Error - Please try again later."
)
lms/djangoapps/courseware/module_render.py
View file @
65f84963
...
@@ -142,7 +142,7 @@ def get_module(user, request, location, student_module_cache, position=None):
...
@@ -142,7 +142,7 @@ def get_module(user, request, location, student_module_cache, position=None):
shared_module
=
None
shared_module
=
None
instance_state
=
instance_module
.
state
if
instance_module
is
not
None
else
{}
instance_state
=
instance_module
.
state
if
instance_module
is
not
None
else
'{}'
shared_state
=
shared_module
.
state
if
shared_module
is
not
None
else
None
shared_state
=
shared_module
.
state
if
shared_module
is
not
None
else
None
# TODO (vshnayder): fix hardcoded urls (use reverse)
# TODO (vshnayder): fix hardcoded urls (use reverse)
...
...
lms/envs/common.py
View file @
65f84963
...
@@ -174,6 +174,9 @@ MODULESTORE = {
...
@@ -174,6 +174,9 @@ MODULESTORE = {
}
}
}
}
############################ SIGNAL HANDLERS ################################
# This is imported to register the exception signal handling that logs exceptions
import
monitoring.exceptions
# noqa
############################### DJANGO BUILT-INS ###############################
############################### DJANGO BUILT-INS ###############################
# Change DEBUG/TEMPLATE_DEBUG in your environment settings files, not here
# Change DEBUG/TEMPLATE_DEBUG in your environment settings files, not here
...
@@ -286,7 +289,6 @@ TEMPLATE_LOADERS = (
...
@@ -286,7 +289,6 @@ TEMPLATE_LOADERS = (
)
)
MIDDLEWARE_CLASSES
=
(
MIDDLEWARE_CLASSES
=
(
'util.middleware.ExceptionLoggingMiddleware'
,
'django_comment_client.middleware.AjaxExceptionMiddleware'
,
'django_comment_client.middleware.AjaxExceptionMiddleware'
,
'django.middleware.common.CommonMiddleware'
,
'django.middleware.common.CommonMiddleware'
,
'django.contrib.sessions.middleware.SessionMiddleware'
,
'django.contrib.sessions.middleware.SessionMiddleware'
,
...
...
lms/templates/staff_problem_info.html
View file @
65f84963
...
@@ -2,14 +2,14 @@ ${module_content}
...
@@ -2,14 +2,14 @@ ${module_content}
%if edit_link:
%if edit_link:
<div><a
href=
"${edit_link}"
>
Edit
</a></div>
<div><a
href=
"${edit_link}"
>
Edit
</a></div>
% endif
% endif
<div><a
href=
"javascript:void(0)"
onclick=
"javascript:$('#${element_id}_debug').slideToggle()"
>
Staff Debug Info
</a></div>
<div
class=
"staff_info"
>
<a
href=
"javascript:void(0)"
onclick=
"javascript:$('#${element_id}_debug').toggle()"
>
Staff Debug Info
</a>
<span
style=
"display:none"
id=
"${element_id}_debug"
>
<span
style=
"display:none"
id=
"${element_id}_debug"
>
<div
class=
"staff_info"
>
definition =
<pre>
${definition | h}
</pre>
definition =
<pre>
${definition | h}
</pre>
metadata = ${metadata | h}
metadata = ${metadata | h}
</span>
</div>
</div>
%if render_histogram:
%if render_histogram:
<div
id=
"histogram_${element_id}"
class=
"histogram"
data-histogram=
"${histogram}"
></div>
<div
id=
"histogram_${element_id}"
class=
"histogram"
data-histogram=
"${histogram}"
></div>
%endif
%endif
</span>
lms/urls.py
View file @
65f84963
...
@@ -142,7 +142,6 @@ if settings.COURSEWARE_ENABLED:
...
@@ -142,7 +142,6 @@ if settings.COURSEWARE_ENABLED:
# discussion
# discussion
url
(
r'^courses/(?P<course_id>[^/]+/[^/]+/[^/]+)/discussion/'
,
url
(
r'^courses/(?P<course_id>[^/]+/[^/]+/[^/]+)/discussion/'
,
include
(
'django_comment_client.urls'
)),
include
(
'django_comment_client.urls'
)),
# For the instructor
# For the instructor
url
(
r'^courses/(?P<course_id>[^/]+/[^/]+/[^/]+)/gradebook$'
,
url
(
r'^courses/(?P<course_id>[^/]+/[^/]+/[^/]+)/gradebook$'
,
'courseware.views.gradebook'
),
'courseware.views.gradebook'
),
...
...
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