version 1.41, 2009/08/19 18:43:31
|
version 1.43, 2010/08/20 21:44:59
|
Line 92 sub update_LC {
|
Line 92 sub update_LC {
|
open(FILE,"<$$configvars{'lonTabDir'}.'/rolesplain.tab"); |
open(FILE,"<$$configvars{'lonTabDir'}.'/rolesplain.tab"); |
my @rolesplain = <FILE>; |
my @rolesplain = <FILE>; |
close(FILE); |
close(FILE); |
foreach (@rolesplain) { |
foreach my $item (@rolesplain) { |
if ($_ =~ /^(st|ta|ex|ad|in|cc):([\w\s]+)$/) { |
if ($_ =~ /^(st|ta|ex|ad|in|cc|co):([\w\s]+):?([\w\s]*)/) { |
$longroles{$1} = $2; |
if ($courseinfo{'type'} eq 'Community') { |
|
unless($1 eq 'cc') { |
|
$longroles{$1} = $3; |
|
} |
|
} else { |
|
unless($1 eq 'co') { |
|
$longroles{$1} = $2; |
|
} |
|
} |
} |
} |
} |
} |
|
|
Line 767 sub parse_classlist {
|
Line 775 sub parse_classlist {
|
push @state, $tagname; |
push @state, $tagname; |
if ("@state" eq "students student") { |
if ("@state" eq "students student") { |
$uname = $attr->{username}; |
$uname = $attr->{username}; |
|
$$studentsref{$uname}[ $$placeref{'groupID'} ] = $groupID; |
} |
} |
}, "tagname, attr"], |
}, "tagname, attr"], |
text_h => |
text_h => |
[sub { |
[sub { |
my ($text) = @_; |
my ($text) = @_; |
if ("@state" eq "students student groupID") { |
if ("@state" eq "students student startdate") { |
$$studentsref{$uname}[ $$placeref{'groupID'} ] = $groupID; |
|
} elsif ("@state" eq "students student startdate") { |
|
my $start = $text; |
my $start = $text; |
unless ($text eq '') { |
unless ($text eq '') { |
$start = &process_date($text); |
$start = &process_date($text); |