Show: '.&Apache::loncommon::multiple_select_form('show',\@sel,6,\%fields,\@order).
+');
+ $r->print('');
+ $r->print(' '.&mt('Show').' | '.&mt('Open').' |
---|
'.&Apache::loncommon::multiple_select_form('show',\@show,6,\%show_fields,\@show_order).
+ ' | '.&Apache::loncommon::select_form($when,'when',%when_fields).
' |
');
+ $r->print(' ');
+ $r->print('');
my $linkstart='
+ $r->print('
| ');
- foreach my $which (@order) {
- if ($which ne 'proctor' && exists($sel{$which})) {
- $r->print(''.$linkstart.$which.'">'.$fields{$which}.' | ');
+ foreach my $which (@show_order) {
+ if ($which ne 'proctor' && exists($show{$which})) {
+ $r->print(''.$linkstart.$which.'">'.$show_fields{$which}.' | ');
}
}
$r->print('Scheduled Students | ');
@@ -539,6 +600,7 @@ sub show_table {
return $slots{$a}->{'starttime'} <=> $slots{$b}->{'starttime'};
};
foreach my $slot (sort $slotsort (keys(%slots))) {
+ if (!&to_show($when,$slots{$slot})) { next; }
if (defined($slots{$slot}->{'type'})
&& $slots{$slot}->{'type'} ne 'schedulable_student') {
#next;
@@ -574,7 +636,7 @@ sub show_table {
my @proctors;
my $rowspan=1;
my $colspan=1;
- if (exists($sel{'proctor'})) {
+ if (exists($show{'proctor'})) {
$rowspan=2;
@proctors= map {
my ($uname,$udom)=split(/@/,$_);
@@ -598,41 +660,41 @@ sub show_table {
EDITFORM
$r->print("\n$edit | \n");
- if (exists($sel{'name'})) {
+ if (exists($show{'name'})) {
$colspan++;$r->print("$slot | ");
}
- if (exists($sel{'type'})) {
+ if (exists($show{'type'})) {
$colspan++;$r->print("$slots{$slot}->{'type'} | \n");
}
- if (exists($sel{'description'})) {
+ if (exists($show{'description'})) {
$colspan++;$r->print("$description | \n");
}
- if (exists($sel{'starttime'})) {
+ if (exists($show{'starttime'})) {
$colspan++;$r->print("$start | \n");
}
- if (exists($sel{'endtime'})) {
+ if (exists($show{'endtime'})) {
$colspan++;$r->print("$end | \n");
}
- if (exists($sel{'startreserve'})) {
+ if (exists($show{'startreserve'})) {
$colspan++;$r->print("$start_reserve | \n");
}
- if (exists($sel{'secret'})) {
+ if (exists($show{'secret'})) {
$colspan++;$r->print("$slots{$slot}{'secret'} | \n");
}
- if (exists($sel{'maxspace'})) {
+ if (exists($show{'maxspace'})) {
$colspan++;$r->print("$slots{$slot}{'maxspace'} | \n");
}
- if (exists($sel{'ip'})) {
+ if (exists($show{'ip'})) {
$colspan++;$r->print("$slots{$slot}{'ip'} | \n");
}
- if (exists($sel{'symb'})) {
+ if (exists($show{'symb'})) {
$colspan++;$r->print("$title | \n");
}
- if (exists($sel{'uniqueperiod'})) {
+ if (exists($show{'uniqueperiod'})) {
$colspan++;$r->print("$unique | \n");
}
$colspan++;$r->print("$ids | \n \n");
- if (exists($sel{'proctor'})) {
+ if (exists($show{'proctor'})) {
$r->print(<
$proctors |
@@ -872,6 +934,13 @@ sub csv_upload_assign {
sub handler {
my $r=shift;
+ &Apache::loncommon::content_type($r,'text/html');
+ &Apache::loncommon::no_cache($r);
+ if ($r->header_only()) {
+ $r->send_http_header();
+ return OK;
+ }
+
&Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'});
my $vgr=&Apache::lonnet::allowed('vgr',$env{'request.course.id'});
|