';
$Str .= ''.
&Apache::lonstatistics::SectionSelect('Section','multiple',5).
' | ';
+ $Str .= ''.
+ &Apache::lonstatistics::GroupSelect('Group','multiple',5).
+ ' | ';
$Str .= ''.
&Apache::lonhtmlcommon::StatusOptions(undef,undef,5).
' | ';
@@ -964,42 +948,43 @@ sub DisplayClasslist {
$r->print($Str);
$r->rflush();
#
- my @Fields = ('fullname','username','domain','id','section','status');
+ my @Fields = ('fullname','username','domain','id','section','status','groups');
#
$Str = '';
+ my @selected_sections = &get_selected_sections();
if (! @Students) {
- if ($SelectedSections[0] eq 'all') {
- if (lc($ENV{'form.Status'}) eq 'any') {
- $Str .= 'There are no students in the course.
';
- } elsif (lc($ENV{'form.Status'}) eq 'active') {
- $Str .= 'There are no currently enrolled students in '.
- 'the course.
';
- } elsif (lc($ENV{'form.Status'}) eq 'expired') {
- $Str .= 'There are no previously enrolled '.
- 'students in the course.
';
+ if ($selected_sections[0] eq 'all') {
+ if (lc($env{'form.Status'}) eq 'any') {
+ $Str .= ''.
+ &mt('There are no students in the course.').
+ '
';
+ } elsif (lc($env{'form.Status'}) eq 'active') {
+ $Str .= ''.
+ &mt('There are no currently enrolled students in the course.').
+ '
';
+ } elsif (lc($env{'form.Status'}) eq 'expired') {
+ $Str .= ''.
+ &mt('There are no previously enrolled students in the course.').
+ '
';
}
} else {
my $sections;
- if (@SelectedSections == 1) {
- $sections = 'section '.$SelectedSections[0];
- } elsif (@SelectedSections > 2) {
- $sections = 'sections '.join(', ',@SelectedSections);
- $sections =~ s/, ([^,])*$/, and $1/;
- } else {
- $sections = 'sections '.join(' and ',@SelectedSections);
- }
- if (lc($ENV{'form.Status'}) eq 'any') {
- $Str .= 'There are no students in '.$sections.'.
';
- } elsif (lc($ENV{'form.Status'}) eq 'active') {
- $Str .= 'There are no currently enrolled students '.
- 'in '.$sections.'.
';
- } elsif (lc($ENV{'form.Status'}) eq 'expired') {
- $Str .= 'There are no previously enrolled students '.
- 'in '.$sections.'.
';
+ if (lc($env{'form.Status'}) eq 'any') {
+ $Str .= ''.
+ &mt('There are no students in the selected sections.').
+ '
';
+ } elsif (lc($env{'form.Status'}) eq 'active') {
+ $Str .= ''.
+ &mt('There are no currently enrolled students in the selected sections.').
+ '
';
+ } elsif (lc($env{'form.Status'}) eq 'expired') {
+ $Str .= ''.
+ &mt('There are no previously enrolled students in the selected sections.').
+ '
';
}
}
$Str.= ''.
- 'Return to the chart.';
+ &mt('Click here to return to the chart').'';
$r->print($Str);
$r->rflush();
return;
@@ -1013,7 +998,7 @@ sub DisplayClasslist {
$Str .= ''.$field.
+ 'sort='.$field.'">'.&mt($field).
' | ';
}
$Str .= '
'."\n";
@@ -1033,11 +1018,13 @@ sub DisplayClasslist {
if ($field eq 'fullname' || $field eq 'username') {
$Str .= '