version 1.13, 2006/03/16 21:34:04
|
version 1.15, 2006/03/16 22:01:44
|
Line 77 sub handler {
|
Line 77 sub handler {
|
my %grouplist=&Apache::lonnet::get_group_membership($cdom,$cnum); |
my %grouplist=&Apache::lonnet::get_group_membership($cdom,$cnum); |
my $now = time; |
my $now = time; |
my %allgroups; |
my %allgroups; |
my @coursegroups = (); |
&Apache::loncommon::coursegroups(\%allgroups,$cdom,$cnum); |
if (&Apache::loncommon::coursegroups(\%allgroups,$cdom,$cnum)) { |
|
@coursegroups = keys(%allgroups); |
|
} |
|
|
|
# --------------------------------------- There is such a user, get environment |
# --------------------------------------- There is such a user, get environment |
|
|
Line 121 ENDSCRIPT
|
Line 118 ENDSCRIPT
|
if ($filter ne '.') { |
if ($filter ne '.') { |
$r->print('<br/ >'.&mt('Name starting with').' "'.$filter.'"<br />'); |
$r->print('<br/ >'.&mt('Name starting with').' "'.$filter.'"<br />'); |
} |
} |
$r->print('</p><p><table><tr><th> </th><th>username</th><th>domain</th><th>Name</th><th>ID</th><th>section</th><th>active group(s)</th>'); |
$r->print('</p><p><table><tr><th> </th><th>username</th><th>domain</th><th>Name</th><th>ID</th><th>section</th><th>active group(s)</th></tr>'); |
# ------------------------------------------------------------------ Students |
# ------------------------------------------------------------------ Students |
foreach (sort keys %$classlist) { |
foreach (sort keys %$classlist) { |
# the following undefs are for 'domain', and 'username' respectively. |
# the following undefs are for 'domain', and 'username' respectively. |
Line 135 ENDSCRIPT
|
Line 132 ENDSCRIPT
|
if (($uname=~/^$filter/) || |
if (($uname=~/^$filter/) || |
($fullname=~/^$filter/i)) { |
($fullname=~/^$filter/i)) { |
my $grouplist = ''; |
my $grouplist = ''; |
foreach my $group (@coursegroups) { |
foreach my $group (sort(keys(%allgroups))) { |
if (exists($grouplist{$group.':'.$uname.':'.$udom})) { |
if (exists($grouplist{$group.':'.$uname.':'.$udom})) { |
my ($end,$start) = split(/:/,$grouplist{$group.':'.$uname.':'.$udom}); |
my ($end,$start) = split(/:/,$grouplist{$group.':'.$uname.':'.$udom}); |
if (($end!=0) && ($end<$now)) { next; } |
if (($end!=0) && ($end<$now)) { next; } |