version 1.5, 2005/06/01 19:20:32
|
version 1.6, 2005/07/11 20:02:02
|
Line 436 sub build_course {
|
Line 436 sub build_course {
|
'linefeed' => $linefeed, |
'linefeed' => $linefeed, |
'role' => 'cc', |
'role' => 'cc', |
}; |
}; |
$outcome = &LONCAPA::Enrollment::create_newuser($ownerargs,$logmsg,$newusermsg,$enrollcount,$addresult,$longroles,$courseinfo); |
$outcome = &LONCAPA::Enrollment::create_newuser($ownerargs,$logmsg,$newusermsg,$enrollcount,$addresult,$longroles,\%courseinfo); |
} else { |
} else { |
$outcome = 'ok'; |
$outcome = 'ok'; |
} |
} |
|
|
my $courseargs = { |
if ($outcome eq 'ok') { |
|
my $courseargs = { |
ccuname => $$details{$num}{'owner'}, |
ccuname => $$details{$num}{'owner'}, |
ccdomain => $$details{$num}{'domain'}, |
ccdomain => $$details{$num}{'domain'}, |
cdescr => $$details{$num}{'title'}, |
cdescr => $$details{$num}{'title'}, |
Line 479 sub build_course {
|
Line 480 sub build_course {
|
firstres => $firstres |
firstres => $firstres |
}; |
}; |
|
|
if ($outcome eq 'ok') { |
|
my %host_servers = &Apache::loncommon::get_library_servers($cdom); |
my %host_servers = &Apache::loncommon::get_library_servers($cdom); |
if (! exists($host_servers{$$details{$num}{'coursehome'}})) { |
if (! exists($host_servers{$$details{$num}{'coursehome'}})) { |
$$logmsg .= &mt('Invalid home server for course').': '.$$details{$num}{'coursehome'}; |
$$logmsg .= &mt('Invalid home server for course').': '.$$details{$num}{'coursehome'}; |
Line 529 sub build_course {
|
Line 529 sub build_course {
|
'linefeed' => $linefeed, |
'linefeed' => $linefeed, |
'role' => $$details{$num}{'users'}{$userkey}{'roles'}[0], |
'role' => $$details{$num}{'users'}{$userkey}{'roles'}[0], |
}; |
}; |
$outcome = &LONCAPA::Enrollment::create_newuser($userargs,$logmsg,$newusermsg,$enrollcount,$addresult,$longroles,$courseinfo); |
$outcome = &LONCAPA::Enrollment::create_newuser($userargs,$logmsg,$newusermsg,$enrollcount,$addresult,$longroles,\%courseinfo); |
# now add other roles and other sections. |
# now add other roles and other sections. |
if ($outcome eq 'ok') { |
if ($outcome eq 'ok') { |
if (($firstrole ne 'st') && (@{$$details{$num}{'users'}{$userkey}{$firstrole}{'usec'}} > 1)) { |
if (($firstrole ne 'st') && (@{$$details{$num}{'users'}{$userkey}{$firstrole}{'usec'}} > 1)) { |