[LON-CAPA-cvs] cvs: loncom /interface lonprintout.pm

raeburn raeburn at source.lon-capa.org
Sat Jun 11 14:12:28 EDT 2022


raeburn		Sat Jun 11 18:12:28 2022 EDT

  Modified files:              
    /loncom/interface	lonprintout.pm 
  Log:
  - When displaying list of selectable resources to include in a PDF printout,
    exclude any "Table of Contents" (i.e., /adm/navmaps) items themselves.
  
  
Index: loncom/interface/lonprintout.pm
diff -u loncom/interface/lonprintout.pm:1.681 loncom/interface/lonprintout.pm:1.682
--- loncom/interface/lonprintout.pm:1.681	Sat Jun 11 17:32:32 2022
+++ loncom/interface/lonprintout.pm	Sat Jun 11 18:12:28 2022
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Printout
 #
-# $Id: lonprintout.pm,v 1.681 2022/06/11 17:32:32 raeburn Exp $
+# $Id: lonprintout.pm,v 1.682 2022/06/11 18:12:28 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -4790,7 +4790,7 @@
         (!$is_published || (($subdir eq '') && ($url eq '/adm/navmaps')))) {
         push(@$printChoices,[&mt('Selected [_1]Resources[_2] from [_3]selected folder[_4] in course',
                                  '<b>','</b>','<b>','</b>'),
-                             'select_sequences','CHOOSE_SEQUENCE']); 
+                             'select_sequences','CHOOSE_SEQUENCE']);
         my $escapedSequenceName;
         if ($helper->{VARS}->{'SEQUENCE'} ne '') {
             $escapedSequenceName = $helper->{VARS}->{'SEQUENCE'};
@@ -4805,7 +4805,9 @@
         #Escape apostrophes and backslashes for Perl
         $escapedSequenceName =~ s/\\/\\\\/g;
         $escapedSequenceName =~ s/'/\\'/g;
+        my $nocurrloc;
         if (($subdir eq '') && ($url eq '/adm/navmaps')) {
+            $nocurrloc = 'nocurrloc="1"';
             if ($perm{'pfo'}) {
                 push(@{$printChoices},
                     [&mt('Selected [_1]Problems[_2] from [_3]selected folder[_4] in course for [_5]selected people[_6]',
@@ -4880,7 +4882,7 @@
   <state name="CHOOSE_FROM_ANY_SEQUENCE" title="Select Resources To Print">
     <message>(mark desired resources then click "next" button) <br /></message>
     <resource variable="RESOURCES" multichoice="1" toponly='1' addstatus="1"
-              closeallpages="1" modallink="1">
+              closeallpages="1" modallink="1" $nocurrloc>
       <nextstate>PAGESIZE</nextstate>
       <filterfunc>return $isNotMap</filterfunc>
       <mapurl evaluate='1'>return '$escapedSequenceName';</mapurl>
@@ -4904,7 +4906,7 @@
   <state name="CHOOSE_FROM_ANY_SEQUENCE" title="Select Resources To Print">
     <message>(mark desired resources then click "next" button) <br /></message>
     <resource variable="RESOURCES" multichoice="1" toponly='1' addstatus="1"
-              closeallpages="1" modallink="1">
+              closeallpages="1" modallink="1" $nocurrloc>
       <nextstate>PAGESIZE</nextstate>
       <filterfunc>return $isNotMap</filterfunc>
       <mapurl evaluate='1'>return '$escapedSequenceName';</mapurl>




More information about the LON-CAPA-cvs mailing list