';
foreach my $item (@usertools) {
my $checked;
@@ -1115,8 +1140,7 @@ sub print_quotas {
'" value="_LC_adv" '.$checked.'/>'.$titles{$item}.
' ';
}
- $datatable .= '('.&mt('overrides affiliation').
- ')
';
+ $datatable .= '';
$$rowtotal += $typecount;
return $datatable;
}
@@ -1448,6 +1472,7 @@ sub tool_titles {
portfolio => 'Portfolio',
official => 'Official courses (with institutional codes)',
unofficial => 'Unofficial courses',
+ community => 'Communities',
);
return %titles;
}
@@ -2697,6 +2722,7 @@ sub color_font_choices {
links => "Link colors",
images => "Images",
font => "Font color",
+ fontmenu => "Font Menu",
pgbg => "Page",
tabbg => "Header",
sidebg => "Border",
@@ -2763,6 +2789,7 @@ sub modify_colors {
@bgs = ('pgbg','tabbg','sidebg');
}
$confhash->{$role}{'font'} = $env{'form.'.$role.'_font'};
+ $confhash->{$role}{'fontmenu'} = $env{'form.'.$role.'_fontmenu'};
foreach my $item (@bgs,@links,@logintext) {
$confhash->{$role}{$item} = $env{'form.'.$role.'_'.$item};
}
@@ -2876,6 +2903,15 @@ sub modify_colors {
$changes{$role}{'font'} = 1;
}
}
+ if ($domconfig->{$role}{'fontmenu'} ne '') {
+ if ($confhash->{$role}{'fontmenu'} ne $domconfig->{$role}{'fontmenu'}) {
+ $changes{$role}{'fontmenu'} = 1;
+ }
+ } else {
+ if ($confhash->{$role}{'fontmenu'}) {
+ $changes{$role}{'fontmenu'} = 1;
+ }
+ }
foreach my $item (@bgs) {
if ($domconfig->{$role}{$item} ne '') {
if ($confhash->{$role}{$item} ne $domconfig->{$role}{$item}) {
@@ -3314,7 +3350,7 @@ sub modify_quotas {
$context = $action;
}
if ($context eq 'requestcourses') {
- @usertools = ('official','unofficial');
+ @usertools = ('official','unofficial','community');
} else {
@usertools = ('aboutme','blog','portfolio');
}
@@ -4200,22 +4236,25 @@ sub modify_usercreation {
$chgtext .= '';
}
} elsif ($type eq 'statustocreate') {
- if (@{$cancreate{'selfcreate'}} > 0) {
- if (@{$cancreate{$type}} == 0) {
- if (!grep(/^email$/,@{$cancreate{'selfcreate'}})) {
- $chgtext .= &mt("However, no institutional affiliations (including 'other') are currently permitted to create accounts.");
- }
- } elsif (ref($usertypes) eq 'HASH') {
- if (grep(/^(login|sso)$/,@{$cancreate{'selfcreate'}})) {
- $chgtext .= &mt('creation of a new account for an institutional user is restricted to the following institutional affiliation(s):').'
';
- foreach my $case (@{$cancreate{$type}}) {
- if ($case eq 'default') {
- $chgtext .= '
'.$othertitle.'
';
- } else {
- $chgtext .= '
'.$usertypes->{$case}.'
';
+ if ((ref($cancreate{'selfcreate'}) eq 'ARRAY') &&
+ (ref($cancreate{'statustocreate'}) eq 'ARRAY')) {
+ if (@{$cancreate{'selfcreate'}} > 0) {
+ if (@{$cancreate{'statustocreate'}} == 0) {
+ if (!grep(/^email$/,@{$cancreate{'selfcreate'}})) {
+ $chgtext .= &mt("However, no institutional affiliations (including 'other') are currently permitted to create accounts.");
+ }
+ } elsif (ref($usertypes) eq 'HASH') {
+ if (grep(/^(login|sso)$/,@{$cancreate{'selfcreate'}})) {
+ $chgtext .= &mt('creation of a new account for an institutional user is restricted to the following institutional affiliation(s):').'
';
+ foreach my $case (@{$cancreate{$type}}) {
+ if ($case eq 'default') {
+ $chgtext .= '