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

raeburn raeburn at source.lon-capa.org
Fri Jan 17 23:37:10 EST 2020


raeburn		Sat Jan 18 04:37:10 2020 EDT

  Modified files:              
    /loncom/interface	lonmenu.pm 
  Log:
  - Perform count of untried parts of problems for resources within the page
    itself, not the enclosing map, when using the "Done" button for a .page.
  
  
Index: loncom/interface/lonmenu.pm
diff -u loncom/interface/lonmenu.pm:1.499 loncom/interface/lonmenu.pm:1.500
--- loncom/interface/lonmenu.pm:1.499	Tue Aug  6 23:10:18 2019
+++ loncom/interface/lonmenu.pm	Sat Jan 18 04:37:10 2020
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Routines to control the menu
 #
-# $Id: lonmenu.pm,v 1.499 2019/08/06 23:10:18 raeburn Exp $
+# $Id: lonmenu.pm,v 1.500 2020/01/18 04:37:10 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1910,7 +1910,11 @@
         my @resources=();
         if ($type eq 'map') {
             my ($mapurl,$rid,$resurl)=&Apache::lonnet::decode_symb($env{'request.symb'});
-            @resources=$navmap->retrieveResources($mapurl,sub { $_[0]->is_problem() });
+            if ($env{'request.symb'} =~ /\.page$/) {
+                @resources=$navmap->retrieveResources($resurl,sub { $_[0]->is_problem() });
+            } else {
+                @resources=$navmap->retrieveResources($mapurl,sub { $_[0]->is_problem() });
+            }
         } else {
             my $res = $navmap->getBySymb($env{'request.symb'});
             if (ref($res)) {




More information about the LON-CAPA-cvs mailing list