--- loncom/homework/grades.pm 2020/08/31 15:42:52 1.596.2.12.2.51 +++ loncom/homework/grades.pm 2020/09/08 14:09:30 1.596.2.12.2.52 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # The LON-CAPA Grading handler # -# $Id: grades.pm,v 1.596.2.12.2.51 2020/08/31 15:42:52 raeburn Exp $ +# $Id: grades.pm,v 1.596.2.12.2.52 2020/09/08 14:09:30 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -289,6 +289,17 @@ sub showResourceInfo { $result .= ''; } $result .= '
'; + if (!keys(%partsseen)) { + $result = ''; + if ($uploads) { + return '
'. + '

'. + &mt('No dropbox items or essayresponse items with uploadedfiletypes set.'). + '

'; + } else { + return '
'; + } + } return $result; } @@ -3188,7 +3199,7 @@ sub processHandGrade { # Keywords sorted in alphabatical order my $loginuser = $env{'user.name'}.':'.$env{'user.domain'}; $env{'form.keywords'} =~ s/,\s{0,}|\s+/ /g; - $env{'form.keywords'} =~ s/^\s+|\s+$//; + $env{'form.keywords'} =~ s/^\s+|\s+$//g; my (@keywords) = sort(split(/\s+/,$env{'form.keywords'})); $env{'form.keywords'} = join(' ',@keywords); $keyhash{$symb.'_keywords'} = $env{'form.keywords'}; @@ -10866,6 +10877,9 @@ sub handler { } &startpage($request,$symb,[{href=>"", text=>"Student Submissions"}],undef,undef,$stuvcurrent,$stuvdisp,undef,$js,$onload,$divforres); if ($versionform) { + if ($divforres) { + $request->print('
'); + } $request->print($versionform); } ($env{'form.student'} eq '' ? &listStudents($request,$symb,'',$divforres) : &submission($request,0,0,$symb,$divforres,$command)); @@ -11017,6 +11031,7 @@ sub handler { [{href=>&href_symb_cmd($symb,'downloadfilesselect'), text=>'Select which submissions to download'}, {href=>'', text=>'Download submitted files'}], undef,undef,undef,undef,undef,undef,undef,1); + $request->print('
'); &submit_download_link($request,$symb); } elsif ($command) { &startpage($request,$symb,[{href=>'', text=>'Access denied'}]);