keywords.html.tmpl 1.96 KB
Newer Older
1 2 3
[%# This Source Code Form is subject to the terms of the Mozilla Public
  # License, v. 2.0. If a copy of the MPL was not distributed with this
  # file, You can obtain one at http://mozilla.org/MPL/2.0/.
4
  #
5 6
  # This Source Code Form is "Incompatible With Secondary Licenses", as
  # defined by the Mozilla Public License, v. 2.0.
7 8 9
  #%]

[%# INTERFACE:
10 11
  # keywords: array keyword objects. May be empty. Each has has four members:
  #   id: id of the keyword
12
  #   name: the name of the keyword
13
  #   description: keyword description. Can contain some limited HTML code.
14
  #   bug_count: number of bugs with that keyword
15 16
  # caneditkeywords: boolean. True if this user can edit keywords
 %]
17 18 19

[% PROCESS global/header.html.tmpl
  title = "$terms.Bugzilla Keyword Descriptions"
20 21 22 23 24 25 26
%]

[% FOREACH keyword = keywords %]
  [% IF loop.index % 50 == 0 %]
    [% IF loop.index != 0 %]
       </table>
    [% END %]
27

28 29 30 31
    <table border="1" cellpadding="4" cellspacing="0">
      <tr bgcolor="#6666FF">
        <th align="left">Name</th>
        <th align="left">Description</th>
32 33
        <th align="left">Open [% terms.Bugs %]</th>
        <th align="left">Total [% terms.Bugs %]</th>
34
      </tr>
35 36
  [% END %]

37
  <tr id="[% keyword.name FILTER html %]">
38
    <th>
39
        [% keyword.name FILTER html %]
40
    </th>
41
    <td>[% keyword.description FILTER html_light %]</td>
42
    <td align="center">
43
      [% IF keyword.bug_count > 0 %]
44
        <a href="buglist.cgi?keywords=[% keyword.name FILTER uri %]&amp;resolution=---">
45 46 47 48 49
          Search</a>
      [% ELSE %]
        none
      [% END %]
    </td>
50
    <td align="right">
51
      [% IF keyword.bug_count > 0 %]
52
        <a href="buglist.cgi?keywords=[% keyword.name FILTER uri %]">
53
          [% keyword.bug_count %]</a>
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
      [% ELSE %]
        none
      [% END %]
    </td>
  </tr>
[% END %]

[% IF keywords.size > 0 %]
  </table>
[% END %]

[% IF caneditkeywords %]
  <p>
    <a href="editkeywords.cgi">Edit keywords</a>.
  </p>
[% END %]

71
[% PROCESS global/footer.html.tmpl %]