Commit 75760c8a authored by Frédéric Buclin's avatar Frédéric Buclin

Bug 1046241: All links to the documentation displayed besides error messages are broken

r=gerv a=dkl
parent e5a69b5d
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
the error [% bug.error FILTER html %]. the error [% bug.error FILTER html %].
[% ELSIF error == "chart_data_not_generated" %] [% ELSIF error == "chart_data_not_generated" %]
[% admindocslinks = {'extraconfig.html' => 'Setting up Charting'} %] [% docslinks = {'using/reports-and-charts.html' => 'Setting up Charting'} %]
[% IF product.id %] [% IF product.id %]
Charts for the <em>[% product.name FILTER html %]</em> product are not Charts for the <em>[% product.name FILTER html %]</em> product are not
available yet because no charting data has been collected for it since it available yet because no charting data has been collected for it since it
......
...@@ -7,29 +7,29 @@ ...@@ -7,29 +7,29 @@
#%] #%]
[%# INTERFACE: [%# INTERFACE:
# docslinks: hash. Hash keys will be used as text of the documentation links, # docslinks: hash. Hash values will be used as text of the documentation links,
# hash values will be used as links to the document, relative to # hash keys will be used as links to the document, relative to
# the main Bugzilla documentation directory. # the main Bugzilla documentation directory.
# Example: If you want a 'FAQ' link to point to, the "faq-general" # Example: If you want a 'FAQ' link to point to, the "faq-general"
# named anchor on faq.html, assign # named anchor on faq.html, assign
# { 'FAQ' => "faq.html#faq-general" } # { "faq.html#faq-general" => 'FAQ' }
# to docslinks. # to docslinks.
# You may only link to sections by their given ID; it is not allowed # You may only link to sections by their given ID; it is not allowed
# to link to a section which is not given an ID (thus getting # to link to a section which is not given an ID (thus getting
# assigned an automatically generated ID). Otherwise, the link # assigned an automatically generated ID). Otherwise, the link
# would break on a recompilation of the documentation. # would break on a recompilation of the documentation.
# admindocslinks: hash. Same as docslinks, but will only be displayed to # admindocslinks: hash. Same as docslinks, but will only be displayed to
# members of the admin group. # members of the 'editcomponents' group.
#%] #%]
[% IF docslinks.keys.size || (admindocslinks.keys.size && user.in_group('admin')) %] [% IF docslinks.keys.size || (admindocslinks.keys.size && user.in_group('editcomponents')) %]
<div id="docslinks"> <div id="docslinks">
<h2>Related documentation</h2> <h2>Related documentation</h2>
<ul> <ul>
[% IF user.in_group('admin') %] [% IF user.in_group('editcomponents') %]
[% PROCESS docslinkslist docstype = admindocslinks %] [% PROCESS docslinkslist docstype = admindocslinks admin = 1 %]
[% END %] [% END %]
[% PROCESS docslinkslist docstype = docslinks %] [% PROCESS docslinkslist docstype = docslinks admin = 0 %]
</ul> </ul>
</div> </div>
[% END %] [% END %]
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
[% BLOCK docslinkslist %] [% BLOCK docslinkslist %]
[% FOREACH docslink = docstype.keys %] [% FOREACH docslink = docstype.keys %]
<li> <li>
<a href="[% docs_urlbase FILTER html %] <a href="[% docs_urlbase FILTER html %][% "administering/" IF admin %]
[% docslink FILTER none %]">[% docstype.$docslink FILTER html %]</a> [% docslink FILTER none %]">[% docstype.$docslink FILTER html %]</a>
</li> </li>
[% END %] [% END %]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment