version 1.1409, 2019/04/29 22:19:45
|
version 1.1410, 2019/05/06 19:28:24
|
Line 8089 sub allowed {
|
Line 8089 sub allowed {
|
($env{'course.'.$env{'request.course.id'}.'.internal.courseowner'} eq $env{'user.name'}.':'.$env{'user.domain'})) { |
($env{'course.'.$env{'request.course.id'}.'.internal.courseowner'} eq $env{'user.name'}.':'.$env{'user.domain'})) { |
my $cdom = $env{'course.'.$env{'request.course.id'}.'.domain'}; |
my $cdom = $env{'course.'.$env{'request.course.id'}.'.domain'}; |
if ($cdom ne '') { |
if ($cdom ne '') { |
my %passwdconf = &Apache::lonnet::get_passwdconf($cdom); |
my %passwdconf = &get_passwdconf($cdom); |
if ($passwdconf{'crsownerchg'}) { |
if (ref($passwdconf{'crsownerchg'}) eq 'HASH') { |
$thisallowed.=$rem; |
if (ref($passwdconf{'crsownerchg'}{'by'}) eq 'ARRAY') { |
|
if (@{$passwdconf{'crsownerchg'}{'by'}}) { |
|
my @inststatuses = split(':',$env{'environment.inststatus'}); |
|
unless (@inststatuses) { |
|
@inststatuses = ('default'); |
|
} |
|
foreach my $status (@inststatuses) { |
|
if (grep(/^\Q$status\E$/,@{$passwdconf{'crsownerchg'}{'by'}})) { |
|
$thisallowed.=$rem; |
|
} |
|
} |
|
} |
|
} |
} |
} |
} |
} |
} |
} |