version 1.33, 2008/06/30 04:07:06
|
version 1.34, 2008/07/04 15:40:04
|
Line 341 sub cat_header {
|
Line 341 sub cat_header {
|
text=>"Select courses"}); |
text=>"Select courses"}); |
$r->print(&Apache::lonhtmlcommon::breadcrumbs('Select courses')); |
$r->print(&Apache::lonhtmlcommon::breadcrumbs('Select courses')); |
} |
} |
$r->print('<table border="0"><tr>'. |
$r->print('<form name="coursecatdom" method="post" action="/adm/coursecatalog">'. |
'<form name="coursecatdom" method="post" action="/adm/coursecatalog">'. |
'<table border="0"><tr><td><b>'.&mt('Domain:').'</b></td><td>'. |
'<td><b>'.&mt('Domain:').'</b></td><td>'. |
|
&Apache::loncommon::select_dom_form($codedom,'showdom','',1). |
&Apache::loncommon::select_dom_form($codedom,'showdom','',1). |
' <input type="submit" name="godom" value="'.&mt('Change').'"></td></form></tr>'. |
' <input type="submit" name="godom" value="'.&mt('Change').'" /></td></tr></table></form>'. |
'<tr><form name="coursecats" method="post" action="/adm/coursecatalog">'. |
'<form name="coursecats" method="post" action="/adm/coursecatalog">'. |
$catlinks.'</form></tr></table>'); |
'<table border="0"><tr>'.$catlinks.'</tr></table></form>'); |
return; |
return; |
} |
} |
|
|
Line 383 sub category_breadcrumbs {
|
Line 382 sub category_breadcrumbs {
|
if (ref($cats[0]) eq 'ARRAY') { |
if (ref($cats[0]) eq 'ARRAY') { |
if ((@{$cats[0]} == 1) && ($cats[0][0] eq 'instcode')) { |
if ((@{$cats[0]} == 1) && ($cats[0][0] eq 'instcode')) { |
$catlinks .= &mt('Official courses (with institutional codes)'). |
$catlinks .= &mt('Official courses (with institutional codes)'). |
'<input type="hidden" name="currcat_0" value="instcode::0">'; |
'<input type="hidden" name="currcat_0" value="instcode::0" />'; |
$env{'form.currcat_0'} = 'instcode::0'; |
$env{'form.currcat_0'} = 'instcode::0'; |
} else { |
} else { |
$catlinks .= '<select name="currcat_0">'."\n"; |
$catlinks .= '<select name="currcat_0">'."\n"; |
Line 414 sub category_breadcrumbs {
|
Line 413 sub category_breadcrumbs {
|
} |
} |
} else { |
} else { |
$catlinks .= &mt('Official courses (with institutional codes)'). |
$catlinks .= &mt('Official courses (with institutional codes)'). |
'<input type="hidden" name="currcat_0" value="instcode::0">'; |
'<input type="hidden" name="currcat_0" value="instcode::0" />'; |
$env{'form.currcat_0'} = 'instcode::0'; |
$env{'form.currcat_0'} = 'instcode::0'; |
} |
} |
} else { |
} else { |
Line 860 sub build_courseinfo_hash {
|
Line 859 sub build_courseinfo_hash {
|
if ( defined($coursehash{'default_enrollment_end_date'}) ) { |
if ( defined($coursehash{'default_enrollment_end_date'}) ) { |
$endaccess = &Apache::lonlocal::locallocaltime($coursehash{'default_enrollment_end_date'}); |
$endaccess = &Apache::lonlocal::locallocaltime($coursehash{'default_enrollment_end_date'}); |
if ($coursehash{'default_enrollment_end_date'} == 0) { |
if ($coursehash{'default_enrollment_end_date'} == 0) { |
$endaccess = "No ending date"; |
$endaccess = &mt('No ending date'); |
} |
} |
} |
} |
if ($startaccess) { |
if ($startaccess) { |
Line 869 sub build_courseinfo_hash {
|
Line 868 sub build_courseinfo_hash {
|
if ($endaccess) { |
if ($endaccess) { |
$accessdates .= &mt('<i>To:</i> ').$endaccess.'<br />'; |
$accessdates .= &mt('<i>To:</i> ').$endaccess.'<br />'; |
} |
} |
|
if (($selfenroll_types ne '') && |
|
($selfenroll_end > 0 && $selfenroll_end > $now)) { |
|
my ($selfenroll_start_access,$selfenroll_end_access); |
|
if (($coursehash{'default_enrollment_start_date'} ne |
|
$coursehash{'internal.selfenroll_start_access'}) || |
|
($coursehash{'default_enrollment_end_date'} ne |
|
$coursehash{'internal.selfenroll_end_access'})) { |
|
if ( defined($coursehash{'internal.selfenroll_start_access'}) ) { |
|
$selfenroll_start_access = &Apache::lonlocal::locallocaltime($coursehash{'internal.selfenroll_start_access'}); |
|
} |
|
if ( defined($coursehash{'default_enrollment_end_date'}) ) { |
|
$selfenroll_end_access = &Apache::lonlocal::locallocaltime($coursehash{'internal.selfenroll_end_access'}); |
|
if ($coursehash{'internal.selfenroll_end_access'} == 0) { |
|
$selfenroll_end_access = &mt('No ending date'); |
|
} |
|
} |
|
if ($selfenroll_start_access || $selfenroll_end_access) { |
|
$accessdates .= '<br/><br /><i>'.&mt('Self-enrollers:').'</i><br />'; |
|
if ($selfenroll_start_access) { |
|
$accessdates .= &mt('<i>From:</i> ').$selfenroll_start_access.'<br />'; |
|
} |
|
if ($selfenroll_end_access) { |
|
$accessdates .= &mt('<i>To:</i> ').$selfenroll_end_access.'<br />'; |
|
} |
|
} |
|
} |
|
} |
$courseinfo{$course}{'access'} = $accessdates; |
$courseinfo{$course}{'access'} = $accessdates; |
} |
} |
if ($xlist_items eq '') { |
if ($xlist_items eq '') { |