version 1.401, 2014/05/31 15:55:18
|
version 1.402, 2014/06/13 11:22:41
|
Line 7310 sub course_level_table {
|
Line 7310 sub course_level_table {
|
((($role eq 'cc') || ($role eq 'co')) && ($isowner))) { |
((($role eq 'cc') || ($role eq 'co')) && ($isowner))) { |
$table .= &course_level_row($protectedcourse,$role,$area,$domain, |
$table .= &course_level_row($protectedcourse,$role,$area,$domain, |
$plrole,\%sections_count,\%lt, |
$plrole,\%sections_count,\%lt, |
$defaultcredits,$crstype); |
$showcredits,$defaultcredits,$crstype); |
} elsif ($env{'request.course.sec'} ne '') { |
} elsif ($env{'request.course.sec'} ne '') { |
if (&Apache::lonnet::allowed('c'.$role,$thiscourse.'/'. |
if (&Apache::lonnet::allowed('c'.$role,$thiscourse.'/'. |
$env{'request.course.sec'})) { |
$env{'request.course.sec'})) { |
$table .= &course_level_row($protectedcourse,$role,$area,$domain, |
$table .= &course_level_row($protectedcourse,$role,$area,$domain, |
$plrole,\%sections_count,\%lt, |
$plrole,\%sections_count,\%lt, |
$defaultcredits,$crstype); |
$showcredits,$defaultcredits,$crstype); |
} |
} |
} |
} |
} |
} |
Line 7325 sub course_level_table {
|
Line 7325 sub course_level_table {
|
next if ($crstype eq 'Community' && $customroles{$cust} =~ /bre\&S/); |
next if ($crstype eq 'Community' && $customroles{$cust} =~ /bre\&S/); |
my $role = 'cr_cr_'.$env{'user.domain'}.'_'.$env{'user.name'}.'_'.$cust; |
my $role = 'cr_cr_'.$env{'user.domain'}.'_'.$env{'user.name'}.'_'.$cust; |
$table .= &course_level_row($protectedcourse,$role,$area,$domain, |
$table .= &course_level_row($protectedcourse,$role,$area,$domain, |
$cust,\%sections_count,\%lt); |
$cust,\%sections_count,\%lt, |
|
$showcredits,$defaultcredits,$crstype); |
} |
} |
} |
} |
} |
} |
Line 7339 sub course_level_table {
|
Line 7340 sub course_level_table {
|
&Apache::loncommon::start_data_table(). |
&Apache::loncommon::start_data_table(). |
&Apache::loncommon::start_data_table_header_row(). |
&Apache::loncommon::start_data_table_header_row(). |
'<th>'.$lt{'act'}.'</th><th>'.$lt{'rol'}.'</th>'."\n". |
'<th>'.$lt{'act'}.'</th><th>'.$lt{'rol'}.'</th>'."\n". |
'<th>'.$lt{'ext'}.'</th><th>'.$lt{'crd'}.'</th>'."\n". |
'<th>'.$lt{'ext'}.'</th><th>'."\n"; |
|
if ($showcredits) { |
|
$result .= $lt{'crd'}.'</th>'; |
|
} |
|
$result .= |
'<th>'.$lt{'grs'}.'</th><th>'.$lt{'sta'}.'</th>'."\n". |
'<th>'.$lt{'grs'}.'</th><th>'.$lt{'sta'}.'</th>'."\n". |
'<th>'.$lt{'end'}.'</th>'. |
'<th>'.$lt{'end'}.'</th>'. |
&Apache::loncommon::end_data_table_header_row(). |
&Apache::loncommon::end_data_table_header_row(). |
Line 7350 $table.
|
Line 7355 $table.
|
|
|
sub course_level_row { |
sub course_level_row { |
my ($protectedcourse,$role,$area,$domain,$plrole,$sections_count, |
my ($protectedcourse,$role,$area,$domain,$plrole,$sections_count, |
$lt,$defaultcredits,$crstype) = @_; |
$lt,$showcredits,$defaultcredits,$crstype) = @_; |
my $creditem; |
my $creditem; |
my $row = &Apache::loncommon::start_data_table_row(). |
my $row = &Apache::loncommon::start_data_table_row(). |
' <td><input type="checkbox" name="act_'. |
' <td><input type="checkbox" name="act_'. |
$protectedcourse.'_'.$role.'" /></td>'."\n". |
$protectedcourse.'_'.$role.'" /></td>'."\n". |
' <td>'.$plrole.'</td>'."\n". |
' <td>'.$plrole.'</td>'."\n". |
' <td>'.$area.'<br />Domain: '.$domain.'</td>'."\n"; |
' <td>'.$area.'<br />Domain: '.$domain.'</td>'."\n"; |
if (($role eq 'st') && ($crstype eq 'Course')) { |
if (($showcredits) && ($role eq 'st') && ($crstype eq 'Course')) { |
$row .= |
$row .= |
'<td><input type="text" name="credits_'.$protectedcourse.'_'. |
'<td><input type="text" name="credits_'.$protectedcourse.'_'. |
$role.'" size="3" value="'.$defaultcredits.'" /></td>'; |
$role.'" size="3" value="'.$defaultcredits.'" /></td>'; |