version 1.18, 2005/04/27 19:09:30
|
version 1.20, 2005/09/29 20:17:06
|
Line 1
|
Line 1
|
|
# The LearningOnline Network with CAPA |
|
# automated enrollment course setup handler |
|
# |
|
# $Id$ |
|
# |
# Copyright Michigan State University Board of Trustees |
# Copyright Michigan State University Board of Trustees |
# |
# |
# This file is part of the LearningOnline Network with CAPA (LON-CAPA). |
# This file is part of the LearningOnline Network with CAPA (LON-CAPA). |
Line 226 all settings except course code, course
|
Line 231 all settings except course code, course
|
my @roleinfo = split/:/,$_; |
my @roleinfo = split/:/,$_; |
if ( ($roleinfo[0] eq 'cc') && ($roleinfo[2] eq $dom) ) { |
if ( ($roleinfo[0] eq 'cc') && ($roleinfo[2] eq $dom) ) { |
unless (grep/^$roleinfo[1]$/,@local_ccs) { |
unless (grep/^$roleinfo[1]$/,@local_ccs) { |
$active_cc = &LONCAPA::Enrollment::check_user_status($roleinfo[2],$roleinfo[1],$dom,$course,'cc'); |
$active_cc = &Apache::loncommon::check_user_status($roleinfo[2],$roleinfo[1],$dom,$course,'cc'); |
if ($active_cc eq 'ok') { |
if ($active_cc eq 'active') { |
push @local_ccs, $roleinfo[1]; |
push @local_ccs, $roleinfo[1]; |
$pname{$roleinfo[1]} = &Apache::loncommon::plainname($roleinfo[1],$roleinfo[2]); |
$pname{$roleinfo[1]} = &Apache::loncommon::plainname($roleinfo[1],$roleinfo[2]); |
$cc_status{$roleinfo[1]} = $lt{'actv'}; |
$cc_status{$roleinfo[1]} = $lt{'actv'}; |
Line 238 all settings except course code, course
|
Line 243 all settings except course code, course
|
unless ( (grep/^$enrollvar{'courseowner'}$/,@local_ccs) || ($enrollvar{'courseowner'} eq '') ) { |
unless ( (grep/^$enrollvar{'courseowner'}$/,@local_ccs) || ($enrollvar{'courseowner'} eq '') ) { |
push @local_ccs, $enrollvar{'courseowner'}; |
push @local_ccs, $enrollvar{'courseowner'}; |
$pname{$enrollvar{'courseowner'}} = &Apache::loncommon::plainname($enrollvar{'courseowner'},$dom); |
$pname{$enrollvar{'courseowner'}} = &Apache::loncommon::plainname($enrollvar{'courseowner'},$dom); |
$active_cc = &LONCAPA::Enrollment::check_user_status($dom,$enrollvar{'coursecode'},$dom,$course,'cc'); |
$active_cc = &Apache::loncommon::check_user_status($dom,$enrollvar{'coursecode'},$dom,$course,'cc'); |
if ($active_cc eq 'ok') { |
if ($active_cc eq 'active') { |
$cc_status{$enrollvar{'courseowner'}} = $lt{'actv'}; |
$cc_status{$enrollvar{'courseowner'}} = $lt{'actv'}; |
} else { |
} else { |
$cc_status{$enrollvar{'courseowner'}} = $lt{'inac'}; |
$cc_status{$enrollvar{'courseowner'}} = $lt{'inac'}; |