';
}
@@ -711,15 +725,19 @@ sub DisplayClasslist {
if ($field eq 'fullname' || $field eq 'username') {
$Str .= '';
- $Str .= $student->{$field}.' ';
+ $Str .= $student->{$field};
$Str .= '';
} elsif ($field eq 'status') {
$Str .= &mt($student->{$field});
} else {
- $Str .= $student->{$field};
+ if ($student->{$field} eq 'none') {
+ $Str .= &mt('none')
+ } else {
+ $Str .= $student->{$field};
+ }
}
$Str .= '';
}
@@ -749,7 +767,7 @@ sub CreateMainMenu {
{url => '/adm/statistics?reportSelected=problem_analysis',
permission => 'F',
- icon => 'edit-find.png',
+ icon => 'prob_ana.png',
linktext => ('Detailed Problem Analysis'),
linktitle => ('Detailed statistics and graphs of student performance on problems.')},
]},
@@ -777,7 +795,7 @@ sub CreateMainMenu {
{url => '/adm/statistics?reportSelected=survey_reports',
permission => 'F',
- icon => 'docs.png',
+ icon => 'survey_rep.png',
linktext => ('Survey Reports'),
linktitle => ('Prepare reports on survey results.')},
]});
@@ -792,14 +810,6 @@ sub handler {
my $r=shift;
my $c = $r->connection();
#
- # Check for overloading
- my $loaderror=&Apache::lonnet::overloaderror($r);
- if ($loaderror) { return $loaderror; }
- $loaderror=
- &Apache::lonnet::overloaderror($r,
- $env{'course.'.$env{'request.course.id'}.'.home'});
- if ($loaderror) { return $loaderror; }
- #
# Check for access
if (! &Apache::lonnet::allowed('vgr',$env{'request.course.id'})) {
$env{'user.error.msg'}=
@@ -817,33 +827,13 @@ sub handler {
&Apache::loncommon::content_type($r,'text/html');
$r->send_http_header;
if ($r->header_only) { return OK; }
- my $gcicustom = &Apache::loncommon::needs_gci_custom();
- if ($gcicustom) {
- my $now = time;
- my $cnum = $env{'course.'.$env{'request.course.id'}.'.num'};
- my $cdom = $env{'course.'.$env{'request.course.id'}.'.domain'};
- my $courseopt=&Apache::lonnet::get_courseresdata($cnum,$cdom);
- my $duedate = $courseopt->{$env{'request.course.id'}.'.0.duedate'};
- if ((!$duedate) || ($duedate > $now)) {
- $r->print(&Apache::loncommon::start_page("Course Statistics"));
- $r->print('
'.&mt('Display of statistics').'
');
- if ($duedate > $now) {
- $r->print('
'.&mt('Aggregate test performance data will be available after the Concept Test end date: [_1].',
- &Apache::lonlocal::locallocaltime($duedate)).'
');
- } else {
- $r->print('
'.
- &mt('Aggregate test performance data unavailable without definition of an end date for the Concept Test.').'
');
- }
- $r->print(&Apache::loncommon::end_page());
- return OK;
- }
- }
-
#
# Extract form elements from query string
&Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'},
['sort','reportSelected',
'SelectedStudent']);
+ my $GoToPage = $env{'form.reportSelected'};
+
#
# Give the LON-CAPA page header
my $style = <
ENDSTYLE
-
+
+ my $head_extra = $style;
+ if (($env{'form.reportSelected'} eq 'student_submission_reports') &&
+ ($env{'form.renderprob'})) {
+ my @Symbs = &Apache::lonstathelpers::get_selected_symbs('problemchoice');
+ if (scalar(@Symbs) == 1) {
+ $head_extra .= &Apache::loncommon::css_links($Symbs[0]);
+ }
+ } elsif ($env{'form.reportSelected'} eq 'submissiontime_analysis') {
+ my ($navmap,$current_problem) =
+ &Apache::lonsubmissiontimeanalysis::get_current_problem();
+ if (ref($current_problem) eq 'HASH') {
+ my $symb = $current_problem->{'symb'};
+ if ($symb) {
+ $head_extra .= &Apache::loncommon::css_links($symb);
+ }
+ }
+ } elsif (($env{'form.reportSelected'} eq 'problem_analysis') &&
+ ($env{'form.show_prob'})) {
+ my $problem_types = &Apache::lonproblemanalysis::analyzable_types();
+ my ($navmap,$current_problem) =
+ &Apache::lonproblemanalysis::get_current_problem($problem_types);
+ if (ref($current_problem) eq 'HASH') {
+ my $symb = $current_problem->{'symb'};
+ my $res = $current_problem->{'resource'};
+ if ($symb) {
+ $head_extra .= &Apache::loncommon::css_links($symb);
+ }
+ }
+ }
$r->print(&Apache::loncommon::start_page('Course Statistics and Charts',
- $style));
+ $head_extra));
$r->rflush();
#
# Either print out a menu for them or send them to a report
@@ -866,17 +885,17 @@ ENDSTYLE
text =>'Statistics',
faq=>139,
bug=>'Statistics and Charts'});
- if (! exists($env{'form.reportSelected'}) ||
- $env{'form.reportSelected'} eq '') {
- $r->print(&Apache::lonhtmlcommon::breadcrumbs('Statistics Main Page').
- &CreateMainMenu());
+ if ($GoToPage eq '') {
+ $r->print(&Apache::lonhtmlcommon::breadcrumbs('Statistics Main Page'));
+ &Apache::lonquickgrades::startGradeScreen($r,'statistics');
+ $r->print(&CreateMainMenu());
} else {
#
if (! &Apache::lonmysql::verify_sql_connection()) {
my $serveradmin = $r->dir_config('lonAdmEMail');
- $r->print('
'.
+ $r->print('
'.
&mt('Unable to connect to database!').
- '');
+ '
');
$r->print('
'
.&mt('Please notify the server administrator [_1]',
,''.$serveradmin.'')
@@ -892,18 +911,18 @@ ENDSTYLE
#
# Clean out the caches
if (exists($env{'form.ClearCache'})) {
- &Apache::loncoursedata::delete_caches($env{'requres.course.id'});
+ &Apache::loncoursedata::delete_caches($env{'request.course.id'});
}
#
# Begin form output
$r->print('