version 1.1524, 2024/03/29 17:32:03
|
version 1.1527, 2024/05/21 02:57:16
|
Line 2802 sub get_domain_defaults {
|
Line 2802 sub get_domain_defaults {
|
$domdefaults{'requestauthor'} = $domconfig{'requestauthor'}; |
$domdefaults{'requestauthor'} = $domconfig{'requestauthor'}; |
} |
} |
if (ref($domconfig{'authordefaults'}) eq 'HASH') { |
if (ref($domconfig{'authordefaults'}) eq 'HASH') { |
foreach my $item ('nocodemirror','copyright','sourceavail','domcoordacc','editors') { |
foreach my $item ('nocodemirror','copyright','sourceavail','domcoordacc','editors','archive') { |
if ($item eq 'editors') { |
if ($item eq 'editors') { |
if (ref($domconfig{'authordefaults'}{'editors'}) eq 'ARRAY') { |
if (ref($domconfig{'authordefaults'}{'editors'}) eq 'ARRAY') { |
$domdefaults{$item} = join(',',@{$domconfig{'authordefaults'}{'editors'}}); |
$domdefaults{$item} = join(',',@{$domconfig{'authordefaults'}{'editors'}}); |
Line 2858 sub get_domain_defaults {
|
Line 2858 sub get_domain_defaults {
|
} else { |
} else { |
$domdefaults{$type.'crsauthor'} = 1; |
$domdefaults{$type.'crsauthor'} = 1; |
} |
} |
|
if (ref($domconfig{'coursedefaults'}{'crseditors'}) eq 'ARRAY') { |
|
$domdefaults{'crseditors'}=join(',',@{$domconfig{'coursedefaults'}{'crseditors'}}); |
|
} |
} |
} |
if (ref($domconfig{'coursedefaults'}{'canclone'}) eq 'HASH') { |
if (ref($domconfig{'coursedefaults'}{'canclone'}) eq 'HASH') { |
if (ref($domconfig{'coursedefaults'}{'canclone'}{'instcode'}) eq 'ARRAY') { |
if (ref($domconfig{'coursedefaults'}{'canclone'}{'instcode'}) eq 'ARRAY') { |
Line 5620 sub coauthorrolelog {
|
Line 5623 sub coauthorrolelog {
|
return; |
return; |
} |
} |
|
|
|
sub authorarchivelog { |
|
my ($hashref,$size,$filesdest,$action) = @_; |
|
my $lonprtdir = $Apache::lonnet::perlvar{'lonPrtDir'}; |
|
my $londocroot = $Apache::lonnet::perlvar{'lonDocRoot'}; |
|
$filesdest =~ s{^\Q$lonprtdir/\E}{}; |
|
if ($filesdest =~ m{^($match_username)_($match_domain)_archive_(\d+_\d+_\d+(|[.\w]+))$}) { |
|
my ($auname,$audom,$id) = ($1,$2,$3); |
|
if (ref($hashref) eq 'HASH') { |
|
my $namespace = 'archivelog'; |
|
my $dir; |
|
if ($hashref->{dir} =~ m{^\Q$londocroot/priv/$audom/$auname\E(.*)$}) { |
|
$dir = $1; |
|
} |
|
my $delflag = 0; |
|
my %storehash = ( |
|
id => $id, |
|
dir => $dir, |
|
files => $hashref->{numfiles}, |
|
subdirs => $hashref->{numdirs}, |
|
bytes => $hashref->{bytes}, |
|
size => $size, |
|
action => $action, |
|
); |
|
if ($action eq 'delete') { |
|
$delflag = 1; |
|
} |
|
&write_log('author',$namespace,\%storehash,$delflag,$auname, |
|
$audom,$auname,$audom); |
|
} |
|
} |
|
return; |
|
} |
|
|
sub get_course_adv_roles { |
sub get_course_adv_roles { |
my ($cid,$codes) = @_; |
my ($cid,$codes) = @_; |
$cid=$env{'request.course.id'} unless (defined($cid)); |
$cid=$env{'request.course.id'} unless (defined($cid)); |
Line 8302 sub usertools_access {
|
Line 8338 sub usertools_access {
|
%tools = ( |
%tools = ( |
aboutme => 1, |
aboutme => 1, |
blog => 1, |
blog => 1, |
|
webdav => 1, |
portfolio => 1, |
portfolio => 1, |
portaccess => 1, |
portaccess => 1, |
timezone => 1, |
timezone => 1, |