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

albertel lon-capa-cvs@mail.lon-capa.org
Tue, 10 Oct 2006 01:52:45 -0000


albertel		Mon Oct  9 21:52:45 2006 EDT

  Modified files:              
    /loncom/interface	lonannounce.pm 
  Log:
  - restroe the ability for course parameter to end up on the CLDR (BUG#5051)
  
  
Index: loncom/interface/lonannounce.pm
diff -u loncom/interface/lonannounce.pm:1.60 loncom/interface/lonannounce.pm:1.61
--- loncom/interface/lonannounce.pm:1.60	Sat Sep  2 16:47:11 2006
+++ loncom/interface/lonannounce.pm	Mon Oct  9 21:52:45 2006
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Announce
 #
-# $Id: lonannounce.pm,v 1.60 2006/09/02 20:47:11 albertel Exp $
+# $Id: lonannounce.pm,v 1.61 2006/10/10 01:52:45 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -80,8 +80,13 @@
 	   $returnhash{$courseid.'@'.$item}=$thiscal{$item};
         }
     }
-    my $can_see_hidden = $env{'request.role.adv'};
-    my $navmap;# = Apache::lonnavmaps::navmap->new();
+    my $can_see_hidden = ($env{'request.role.adv'} &&
+			  ($courseid eq $env{'request.course.id'}));
+    
+    my $navmap;
+    if ($courseid eq $env{'request.course.id'}) {
+	$navmap = Apache::lonnavmaps::navmap->new();
+    }
     my %resourcedata=
 	&Apache::lonnet::dump('resourcedata',$coursedom,$coursenum);
     foreach my $thiskey (sort keys %resourcedata) {