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
64a9ec5b
Commit
64a9ec5b
authored
Feb 22, 2014
by
ichuang
Committed by
Carson Gee
Apr 23, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add problem reset link to staff debug page
parent
3b49c17c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
65 additions
and
1 deletions
+65
-1
lms/templates/courseware/instructor_dashboard.html
+1
-1
lms/templates/staff_problem_info.html
+64
-0
No files found.
lms/templates/courseware/instructor_dashboard.html
View file @
64a9ec5b
...
@@ -592,7 +592,7 @@ function goto( mode)
...
@@ -592,7 +592,7 @@ function goto( mode)
##-----------------------------------------------------------------------------
##-----------------------------------------------------------------------------
%if msg:
%if msg:
<p></p><p>
${msg}
</p>
<p></p><p
id=
"idash_msg"
>
${msg}
</p>
%endif
%endif
##-----------------------------------------------------------------------------
##-----------------------------------------------------------------------------
...
...
lms/templates/staff_problem_info.html
View file @
64a9ec5b
...
@@ -52,6 +52,70 @@ ${block_content}
...
@@ -52,6 +52,70 @@ ${block_content}
<header>
<header>
<h2>
${_('Staff Debug')}
</h2>
<h2>
${_('Staff Debug')}
</h2>
</header>
</header>
<script
type=
"text/javascript"
>
var
StaffDebug
=
(
function
(){
geturl
=
function
(
action
){
var
pathname
=
window
.
location
.
pathname
;
var
url
=
pathname
.
substr
(
0
,
pathname
.
indexOf
(
'/courseware'
))
+
'/'
+
action
;
return
url
;
}
get_user
=
function
(
locname
){
var
uname
=
$
(
'#sd_fu_'
+
locname
).
val
();
if
(
uname
==
""
){
uname
=
"${user.username}"
;
}
return
uname
;
}
do_idash_action
=
function
(
locname
,
idaction
){
var
pdata
=
{
'csrfmiddlewaretoken'
:
"${csrf_token}"
,
'action'
:
idaction
,
'problem_for_student'
:
locname
,
'unique_student_identifier'
:
get_user
(
locname
)
}
$
.
ajax
({
type
:
"POST"
,
url
:
geturl
(
'instructor'
),
data
:
pdata
,
success
:
function
(
data
){
var
msg
=
$
(
"#idash_msg"
,
data
);
$
(
"#result_"
+
locname
).
html
(
msg
);
},
dataType
:
'html'
});
}
reset
=
function
(
locname
){
do_idash_action
(
locname
,
"Reset student's attempts"
);
}
sdelete
=
function
(
locname
){
do_idash_action
(
locname
,
"Delete student state for module"
);
}
reload
=
function
(
locname
){
var
url
=
geturl
(
'jump_to_id/'
+
locname
);
window
.
location
.
replace
(
url
);
}
return
{
reset
:
reset
,
reload
:
reload
,
sdelete
:
sdelete
,
do_idash_action
:
do_idash_action
}
})();
</script>
[
<a
href=
'javascript:StaffDebug.reset("${location.name}")'
>
${_('Reset Attempts')}
</a>
|
<a
href=
'javascript:StaffDebug.reload("${location.name}")'
>
${_('Reload Page')}
</a>
|
<a
href=
'javascript:StaffDebug.sdelete("${location.name}")'
>
${_('Delete State')}
</a>
]
<span
style=
"float:right"
>
For user:
<input
type=
"text"
id=
"sd_fu_${location.name}"
/></span>
<div
id=
"result_${location.name}"
/>
<div
class=
"staff_info"
style=
"display:block"
>
<div
class=
"staff_info"
style=
"display:block"
>
is_released = ${is_released}
is_released = ${is_released}
location = ${location | h}
location = ${location | h}
...
...
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