version 1.81, 2008/12/25 01:52:49
|
version 1.85, 2009/01/27 15:59:30
|
Line 1330 sub print_quotas {
|
Line 1330 sub print_quotas {
|
'</label></span> '; |
'</label></span> '; |
} |
} |
$datatable .= '<span class="LC_nobreak">('.&mt('overrides affiliation'). |
$datatable .= '<span class="LC_nobreak">('.&mt('overrides affiliation'). |
')</span</td></tr>'; |
')</span></td></tr>'; |
$$rowtotal += $typecount; |
$$rowtotal += $typecount; |
return $datatable; |
return $datatable; |
} |
} |
Line 1894 sub usercreation_types {
|
Line 1894 sub usercreation_types {
|
any => 'Any', |
any => 'Any', |
official => 'Institutional only ', |
official => 'Institutional only ', |
unofficial => 'Non-institutional only', |
unofficial => 'Non-institutional only', |
email => 'Email address', |
email => 'E-mail address', |
login => 'Institutional Login', |
login => 'Institutional Login', |
sso => 'SSO', |
sso => 'SSO', |
none => 'None', |
none => 'None', |
Line 4977 sub modify_serverstatuses {
|
Line 4977 sub modify_serverstatuses {
|
my %serverstatushash = ( |
my %serverstatushash = ( |
serverstatuses => \%newserverstatus, |
serverstatuses => \%newserverstatus, |
); |
); |
my $putresult = &Apache::lonnet::put_dom('configuration',\%serverstatushash, |
|
$dom); |
|
my %changes; |
my %changes; |
foreach my $type (@pages) { |
foreach my $type (@pages) { |
if (ref($currserverstatus{$type}) eq 'HASH') { |
foreach my $setting ('namedusers','machines') { |
my @currnamed = split(/,/,$currserverstatus{$type}{'namedusers'}); |
my (@current,@new); |
my @newusers = split(/,/,$newserverstatus{$type}{'namedusers'}); |
if (ref($currserverstatus{$type}) eq 'HASH') { |
foreach my $item (@currnamed) { |
if ($currserverstatus{$type}{$setting} ne '') { |
if (!grep(/^\Q$item\E$/,@newusers)) { |
@current = split(/,/,$currserverstatus{$type}{$setting}); |
$changes{$type}{'namedusers'} = 1; |
|
last; |
|
} |
|
} |
|
foreach my $item (@newusers) { |
|
if (!grep(/^\Q$item\E$/,@currnamed)) { |
|
$changes{$type}{'namedusers'} = 1; |
|
last; |
|
} |
|
} |
|
my @currmachines = split(/,/,$currserverstatus{$type}{'machines'}); |
|
my @newmachines = split(/,/,$newserverstatus{$type}{'machines'}); |
|
foreach my $item (@currmachines) { |
|
if (!grep(/^\Q$item\E$/,@newmachines)) { |
|
$changes{$type}{'machines'} = 1; |
|
last; |
|
} |
|
} |
|
foreach my $item (@newmachines) { |
|
if (!grep(/^\Q$item\E$/,@currmachines)) { |
|
$changes{$type}{'machines'} = 1; |
|
last; |
|
} |
} |
} |
} |
|
if ($newserverstatus{$type}{$setting} ne '') { |
|
@new = split(/,/,$newserverstatus{$type}{$setting}); |
|
} |
|
if (@current > 0) { |
|
if (@new > 0) { |
|
foreach my $item (@current) { |
|
if (!grep(/^\Q$item\E$/,@new)) { |
|
$changes{$type}{$setting} = 1; |
|
last; |
|
} |
|
} |
|
foreach my $item (@new) { |
|
if (!grep(/^\Q$item\E$/,@current)) { |
|
$changes{$type}{$setting} = 1; |
|
last; |
|
} |
|
} |
|
} else { |
|
$changes{$type}{$setting} = 1; |
|
} |
|
} elsif (@new > 0) { |
|
$changes{$type}{$setting} = 1; |
|
} |
} |
} |
} |
} |
if (keys(%changes) > 0) { |
if (keys(%changes) > 0) { |
Line 5020 sub modify_serverstatuses {
|
Line 5018 sub modify_serverstatuses {
|
if ($putresult eq 'ok') { |
if ($putresult eq 'ok') { |
$resulttext .= &mt('Changes made:').'<ul>'; |
$resulttext .= &mt('Changes made:').'<ul>'; |
foreach my $type (@pages) { |
foreach my $type (@pages) { |
if (defined($changes{$type})) { |
if (ref($changes{$type}) eq 'HASH') { |
$resulttext .= '<li>'.$titles->{$type}.'<ul>'; |
$resulttext .= '<li>'.$titles->{$type}.'<ul>'; |
if (defined($changes{$type}{'namedusers'})) { |
if ($changes{$type}{'namedusers'}) { |
if ($newserverstatus{$type}{'namedusers'} eq '') { |
if ($newserverstatus{$type}{'namedusers'} eq '') { |
$resulttext .= '<li>'.&mt("Access terminated for all specific (named) users").'</li>'."\n"; |
$resulttext .= '<li>'.&mt("Access terminated for all specific (named) users").'</li>'."\n"; |
} else { |
} else { |
$resulttext .= '<li>'.&mt("Access available for the following specified users: ").$newserverstatus{$type}{'namedusers'}.'</li>'."\n"; |
$resulttext .= '<li>'.&mt("Access available for the following specified users: ").$newserverstatus{$type}{'namedusers'}.'</li>'."\n"; |
} |
} |
} elsif (defined($changes{$type}{'machines'})) { |
} |
|
if ($changes{$type}{'machines'}) { |
if ($newserverstatus{$type}{'machines'} eq '') { |
if ($newserverstatus{$type}{'machines'} eq '') { |
$resulttext .= '<li>'.&mt("Access terminated for all specific IP addresses").'</li>'."\n"; |
$resulttext .= '<li>'.&mt("Access terminated for all specific IP addresses").'</li>'."\n"; |
} else { |
} else { |