--- loncom/interface/slotrequest.pm 2005/09/13 07:31:08 1.15 +++ loncom/interface/slotrequest.pm 2005/10/07 19:44:06 1.19 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler for requesting to have slots added to a students record # -# $Id: slotrequest.pm,v 1.15 2005/09/13 07:31:08 albertel Exp $ +# $Id: slotrequest.pm,v 1.19 2005/10/07 19:44:06 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -58,7 +58,6 @@ sub start_page { $r->print($html.''. &mt('Request another Worktime').''); $r->print(&Apache::loncommon::bodytag('Requesting another Worktime')); - $r->print('

'.$env{'form.command'}.'

'); } sub end_page { @@ -453,20 +452,23 @@ STUFF } sub show_table { - my ($r,$symb,$mgr)=@_; + my ($r,$mgr)=@_; my ($cnum,$cdom)=&get_course(); my %slots=&Apache::lonnet::dump('slots',$cdom,$cnum); + if ( (keys(%slots))[0] =~ /^error: 2 /) { + undef(%slots); + } my $available; if ($mgr eq 'F') { $r->print('
-
'); } $r->print(' + @@ -500,8 +502,16 @@ sub show_table { localtime($slots{$slot}{'uniqueperiod'}[1]); } + my $edit=(< + + + + +EDITFORM $r->print(< + @@ -518,7 +528,7 @@ STUFF } sub upload_start { - my ($r,$symb)=@_; + my ($r)=@_; $r->print(&Apache::grades::checkforfile_js()); my $result.='
Slot name Type Description$edit $slot $slots{$slot}->{'type'} $description
'."\n"; $result.=' '. @@ -529,7 +539,6 @@ sub upload_start { my $ignore=&mt('Ignore First Line'); $result.=< - $upfile_select
@@ -542,7 +551,7 @@ ENDUPFORM } sub csvuploadmap_header { - my ($r,$symb,$datatoken,$distotal)= @_; + my ($r,$datatoken,$distotal)= @_; my $javascript; if ($env{'form.upfile_associate'} eq 'reverse') { $javascript=&csvupload_javascript_reverse_associate(); @@ -566,7 +575,6 @@ to this page if the data selected is ins -