--- loncom/interface/lonuserutils.pm 2012/04/25 21:22:01 1.138
+++ loncom/interface/lonuserutils.pm 2012/08/21 01:50:34 1.140
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Utility functions for managing LON-CAPA user accounts
#
-# $Id: lonuserutils.pm,v 1.138 2012/04/25 21:22:01 raeburn Exp $
+# $Id: lonuserutils.pm,v 1.140 2012/08/21 01:50:34 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1444,8 +1444,9 @@ sub print_userlist {
if ($env{'form.Status'} !~ /^(Any|Expired|Active|Future)$/) {
$env{'form.Status'} = 'Active';
}
+ my $onchange = "javascript:updateCols('Status');";
my $status_select = &Apache::lonhtmlcommon::StatusOptions
- ($env{'form.Status'});
+ ($env{'form.Status'},undef,undef,$onchange);
if ($env{'form.showrole'} eq '') {
if ($context eq 'course') {
@@ -1478,12 +1479,12 @@ sub print_userlist {
$r->print('
');
return;
}
if (!(($context eq 'domain') &&
(($env{'form.roletype'} eq 'course') || ($env{'form.roletype'} eq 'community')))) {
- $r->print(
- "\n\n"
- .''
- .&list_submit_button(&mt('Update Display'))
- ."
\n"
- );
+ $r->print(&list_submit_button(&mt('Update Display'))."\n");
+ }
+
+ my @cols = &infocolumns($context,$mode);
+ if (!@cols) {
+ $r->print('
'.
+ &mt('No user information selected for display.').''.
+ ''."\n");
+ return;
}
my ($indexhash,$keylist) = &make_keylist_array();
my (%userlist,%userinfo,$clearcoursepick);
@@ -1565,7 +1571,7 @@ sub print_userlist {
$r->print('
'.&mt('Searching').' ...
');
}
} else {
- $r->print('
'.&mt('Searching').' ...
');
+ $r->print('
'.&mt('Searching').' ...
');
}
$r->rflush();
if ($context eq 'course') {
@@ -1719,6 +1725,7 @@ sub print_userlist {
}
$r->print('');
+ return;
}
sub role_filter {
@@ -1731,11 +1738,11 @@ sub role_filter {
my ($role_select);
if ($context eq 'domain') {
$role_select = &domain_roles_select();
- $output = '';
+ .'';
} else {
- $role_select = '