version 1.20, 2009/08/21 13:18:46
|
version 1.23, 2009/08/22 21:08:39
|
Line 792 sub print_request_form {
|
Line 792 sub print_request_form {
|
$message = '<div class="LC_warning">'. |
$message = '<div class="LC_warning">'. |
&mt('No course was found matching your choice of institutional course category.'); |
&mt('No course was found matching your choice of institutional course category.'); |
} |
} |
unless ($code_chk eq 'ok') { |
unless ($code_chk eq 'valid') { |
$prev = 'crstype'; |
$prev = 'crstype'; |
} |
} |
$r->print($message); |
$r->print($message); |
Line 1873 sub print_request_outcome {
|
Line 1873 sub print_request_outcome {
|
} |
} |
} |
} |
} |
} |
$xlistinfo .= $env{'form.crosslist_'.$i.'_instsec'}; |
$crosslistings{$i}{'instcode'} = $xlistinfo; |
$crosslistings{$i}{'inst'} = $xlistinfo; |
$crosslistings{$i}{'instsec'} = $env{'form.crosslist_'.$i.'_instsec'}; |
$crosslistings{$i}{'loncapa'} = $env{'form.crosslist_'.$i.'_lcsec'}; |
$crosslistings{$i}{'loncapa'} = $env{'form.crosslist_'.$i.'_lcsec'}; |
} |
} |
} |
} |
Line 2024 sub print_request_outcome {
|
Line 2024 sub print_request_outcome {
|
$disposition = &check_autolimit($env{'user.name'},$env{'user.domain'}, |
$disposition = &check_autolimit($env{'user.name'},$env{'user.domain'}, |
$dom,$crstype,$limit,\$message); |
$dom,$crstype,$limit,\$message); |
} elsif ($val eq 'validate') { |
} elsif ($val eq 'validate') { |
my $inststatuslist; |
my ($inststatuslist,$validationchk,$validation); |
if (@inststatuses > 0) { |
if (@inststatuses > 0) { |
$inststatuslist = join(',',@inststatuses); |
$inststatuslist = join(',',@inststatuses); |
} |
} |
Line 2032 sub print_request_outcome {
|
Line 2032 sub print_request_outcome {
|
if (@instsections > 0) { |
if (@instsections > 0) { |
$instseclist = join(',',@instsections); |
$instseclist = join(',',@instsections); |
} |
} |
my $validation = |
$validationchk = |
&Apache::lonnet::auto_validate_instcode('',$dom,$instcode, |
&Apache::lonnet::auto_courserequest_validation($dom, |
$env{'user.name'}.':'.$env{'user.domain'},$inststatuslist, |
$env{'user.name'}.':'.$env{'user.domain'},$crstype, |
$instseclist); |
$inststatuslist,$instcode,$instseclist); |
if ($validation eq 'valid') { |
if ($validationchk =~ /:/) { |
$disposition = 'process'; |
($validation,$message) = split(':',$validationchk); |
} elsif ($validation eq 'rejected') { |
} else { |
$disposition = 'rejected'; |
$validation = $validationchk; |
} elsif ($validation eq 'pending') { |
} |
$disposition = 'pending'; |
if ($validation =~ /^error(.*)$/) { |
} elsif ($disposition eq 'approval') { |
|
$disposition = 'approval'; |
|
} elsif ($disposition =~ /^error(.*)$/) { |
|
$disposition = 'approval'; |
$disposition = 'approval'; |
$validationerror = $1; |
$validationerror = $1; |
} else { |
} else { |
$disposition = 'approval'; |
$disposition = $validation; |
} |
} |
} else { |
} else { |
$disposition = 'approval'; |
$disposition = 'approval'; |
Line 2212 sub get_processtype {
|
Line 2209 sub get_processtype {
|
if (ref($domconfig->{'requestcourses'}) eq 'HASH') { |
if (ref($domconfig->{'requestcourses'}) eq 'HASH') { |
%settings = %{$domconfig->{'requestcourses'}}; |
%settings = %{$domconfig->{'requestcourses'}}; |
if (ref($settings{$crstype}) eq 'HASH') { |
if (ref($settings{$crstype}) eq 'HASH') { |
if (($env{'user.adv'}) && (exists($settings{$crstype}{'_LC_adv'}))) { |
if (($env{'user.adv'}) && ($settings{$crstype}{'_LC_adv'} ne '')) { |
$val = $settings{$crstype}{'_LC_adv'}; |
$val = $settings{$crstype}{'_LC_adv'}; |
@{$inststatuses} = ('_LC_adv_'); |
@{$inststatuses} = ('_LC_adv_'); |
} else { |
} else { |
Line 2371 sub retrieve_settings {
|
Line 2368 sub retrieve_settings {
|
my %crscode = ( |
my %crscode = ( |
$i => $reqinfo{'crosslistings'}{$i}{'instcode'}, |
$i => $reqinfo{'crosslistings'}{$i}{'instcode'}, |
); |
); |
&extract_instcode($dom,'crosslist',\%crscode,$1,$xlistsec); |
&extract_instcode($dom,'crosslist',\%crscode,$i,$xlistsec); |
} |
} |
} |
} |
} |
} |