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

raeburn raeburn at source.lon-capa.org
Mon Dec 3 18:53:03 EST 2012


raeburn		Mon Dec  3 23:53:03 2012 EDT

  Modified files:              
    /loncom/interface	lonsyllabus.pm 
  Log:
  - No breadcrumbs unless syllabus is being viewed in course and register=1, 
    or the current user can edit it.
  
  
Index: loncom/interface/lonsyllabus.pm
diff -u loncom/interface/lonsyllabus.pm:1.113 loncom/interface/lonsyllabus.pm:1.114
--- loncom/interface/lonsyllabus.pm:1.113	Thu Nov  8 21:33:10 2012
+++ loncom/interface/lonsyllabus.pm	Mon Dec  3 23:53:03 2012
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Syllabus
 #
-# $Id: lonsyllabus.pm,v 1.113 2012/11/08 21:33:10 raeburn Exp $
+# $Id: lonsyllabus.pm,v 1.114 2012/12/03 23:53:03 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -158,15 +158,15 @@
             push(@{$brcrum},
                   {href=>$r->uri,
                    text=>"Course syllabus"});
-        }   
+        }
+        my $args = {'function'       => undef,
+                    'domain'         => $cdom,
+                    'force_register' => $forcereg,};
+        if (@{$brcrum} > 0) {
+            $args->{'bread_crumbs'} = $brcrum;
+        }
         my $start_page =
-         &Apache::loncommon::start_page("Syllabus", $rss_link.$js,
-                       {'function'       => undef,
-                        'domain'         => $cdom,
-                        'force_register' => $forcereg,
-                        'bread_crumbs'   => $brcrum,
-                       });
-
+            &Apache::loncommon::start_page("Syllabus", $rss_link.$js,$args);
         $r->print($start_page);
     }
 # ---------------------------------------------------------- Load syllabus info




More information about the LON-CAPA-cvs mailing list