From: jj v. a. <we...@ma...> - 2005-07-27 16:42:21
|
Log Message: ----------- More changes for problem library version 2: changed interface for getting lists of problems so variable amounts of data can be passed. Also removed an unneeded button. Modified Files: -------------- webwork-modperl/lib/WeBWorK/ContentGenerator/Instructor: SetMaker.pm Revision Data ------------- Index: SetMaker.pm =================================================================== RCS file: /webwork/cvs/system/webwork-modperl/lib/WeBWorK/ContentGenerator/Instructor/SetMaker.pm,v retrieving revision 1.43 retrieving revision 1.44 diff -Llib/WeBWorK/ContentGenerator/Instructor/SetMaker.pm -Llib/WeBWorK/ContentGenerator/Instructor/SetMaker.pm -u -r1.43 -r1.44 --- lib/WeBWorK/ContentGenerator/Instructor/SetMaker.pm +++ lib/WeBWorK/ContentGenerator/Instructor/SetMaker.pm @@ -493,15 +493,14 @@ -default=> $subject_selected, -onchange=>"submit();return true" ), - CGI::submit(-name=>"lib_select_subject", -value=>"Update Chapter List")])), + CGI::submit(-name=>"lib_select_subject", -value=>"Update Chapter/Section Lists")])), CGI::Tr( CGI::td(["Chapter:", CGI::popup_menu(-name=> 'library_chapters', -values=>\@chaps, -default=> $chapter_selected, -onchange=>"submit();return true" - ), - CGI::submit(-name=>"lib_select_chapter", -value=>"Update Section List")])), + )])), CGI::Tr( CGI::td("Section:"), CGI::td({-colspan=>2}, @@ -871,11 +870,7 @@ } elsif ($r->param('lib_view')) { @pg_files=(); - my $chap = $r->param('library_chapters') || ""; - $chap = "" if($chap eq "All Chapters"); - my $sect = $r->param('library_sections') || ""; - $sect = "" if($sect eq "All Sections"); - my @dbsearch = WeBWorK::Utils::ListingDB::getSectionListings($r->{ce}, "$chap", "$sect"); + my @dbsearch = WeBWorK::Utils::ListingDB::getSectionListings($r, subject_default => 'All Subjects', chapter_default => 'All Chapters', section_default=>'All Sections'); my ($result, $tolibpath); for $result (@dbsearch) { $tolibpath = "Library/$result->{path}/$result->{filename}"; |