Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions conf/defaults.config
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ $mail{feedbackSubjectFormat} = "[WWfeedback] course:%c user:%u set:%s prob:%p se
# 2: as in 1, plus the problem environment (debugging data)
$mail{feedbackVerbosity} = 1;

# If this is 1, then the links included in feedback emails when feedback is sent
# from a problem will open the problem grader when followed. If this is 0, then
# the problem grader will not be open when those links are followed.
$mail{linksOpenProblemGrader} = 1;

# Should the studentID be included in the feedback email when feedbackVerbosity > 0:
# The default is yes
$blockStudentIDinFeedback = 0;
Expand Down
5 changes: 5 additions & 0 deletions conf/localOverrides.conf.dist
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ $mail{feedbackRecipients} = [
#'prof2@yourserver.yourdomain.edu',
];

# If this is 1, then the links included in feedback emails when feedback is sent
# from a problem will open the problem grader when followed. If this is 0, then
# the problem grader will not be open when those links are followed.
#$mail{linksOpenProblemGrader} = 0;

# Should the studentID be included in the feedback email when feedbackVerbosity > 0:
# The default is yes. Uncomment the line below to block it from being included.
# Blocking it from being included is recommended if the studentID is "personal"
Expand Down
11 changes: 11 additions & 0 deletions lib/WeBWorK/ConfigValues.pm
Original file line number Diff line number Diff line change
Expand Up @@ -886,6 +886,17 @@ sub getConfigValues ($ce) {
),
type => 'boolean'
},
{
var => 'mail{linksOpenProblemGrader}',
doc => x('Feedback links open problem grader'),
doc2 => x(
'If this is true, then the links included in feedback emails sent from a problem will have the '
. 'problem grader open when followed. If this is false, then the problem grader will not '
. 'be open when those links are followed. The problem grader may still be opened in any '
. 'case by using the "Show Problem Grader" button.'
),
type => 'boolean'
},
],
];

Expand Down
2 changes: 1 addition & 1 deletion lib/WeBWorK/Utils.pm
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ sub generateURLs ($c, %params) {
for my $name ('displayMode', 'showCorrectAnswers', 'showHints', 'showOldAnswers', 'showSolutions') {
$args{$name} = [ $c->param($name) ] if defined $c->param($name) && $c->param($name) ne '';
}
$args{showProblemGrader} = 1;
$args{showProblemGrader} = 1 if $c->ce->{mail}{linksOpenProblemGrader};
} else {
$routePath = $c->url_for('problem_list', setID => $params{set_id});
}
Expand Down