From: Frank Lichtenheld Date: Thu, 12 Apr 2007 21:00:42 +0000 (+0200) Subject: show.tmpl: Add a 'Source' entry in the navigation bar for source packages X-Git-Url: https://git.deb.at/w?a=commitdiff_plain;h=f894275000c49160da816e40e2dd0dfb6862e58a;p=deb%2Fpackages.git show.tmpl: Add a 'Source' entry in the navigation bar for source packages Make 'Source' a replacement for the suite link and make the latter not go to the source index page but the normal index page. --- diff --git a/templates/html/show.tmpl b/templates/html/show.tmpl index 16ea7e4..fd10281 100644 --- a/templates/html/show.tmpl +++ b/templates/html/show.tmpl @@ -1,4 +1,8 @@ [% PROCESS 'config/archive_layout.tmpl' %] +[%- nav_arr = [ { prefix=>'Distribution:', title=>'Overview over this suite', url=>make_url('/','','source',''), name=>suite }, ]; + nav_arr.push( { title => 'Source packages', url=>make_url('/'), name=>'Source' } ) IF is_source; + nav_arr.push( { prefix=>'Section:', title=>'All packages in this section', url=>make_url("$subsection/"), name=>subsection } ); + nav_arr.push( { prefix=>'Package:', name=>pkg } ); -%] [%- PROCESS 'html/head.tmpl' title_tag = ( is_source ? "Details of source package $pkg in $suite" : "Details of package $pkg in $suite" ) @@ -8,9 +12,7 @@ search_field_values = { searchon => is_source ? 'sourcenames' : 'names', } - navigation = [ { prefix=>'Distribution:', title=>'Overview over this suite', url=>make_url('/'), name=>suite }, - { prefix=>'Section:', title=>'All packages in this section', url=>make_url("$subsection/"), name=>subsection }, - { prefix=>'Package:', name=>pkg } ] + navigation = nav_arr -%] [% PROCESS 'html/menu.inc' %]