summaryrefslogtreecommitdiffstats
path: root/template/en/default
diff options
context:
space:
mode:
authorlpsolit%gmail.com <>2006-04-07 07:49:29 +0200
committerlpsolit%gmail.com <>2006-04-07 07:49:29 +0200
commitdfa63026620220b2f252291ae41c6bd7e966e0a9 (patch)
tree8ac92237c004381d8c366e6de0be820b75b72ffc /template/en/default
parent6ce5f4a89c6409142945f71015a60b3cc3c65f34 (diff)
downloadbugzilla-dfa63026620220b2f252291ae41c6bd7e966e0a9.tar.gz
bugzilla-dfa63026620220b2f252291ae41c6bd7e966e0a9.tar.xz
Bug 323525: Style the group table as all other admin tables in Bugzilla - Patch by Colin Ogilvie <colin.ogilvie@gmail.com> r=LpSolit a=justdave
Diffstat (limited to 'template/en/default')
-rw-r--r--template/en/default/admin/groups/list.html.tmpl122
1 files changed, 80 insertions, 42 deletions
diff --git a/template/en/default/admin/groups/list.html.tmpl b/template/en/default/admin/groups/list.html.tmpl
index b7897c5e7..f32e715d6 100644
--- a/template/en/default/admin/groups/list.html.tmpl
+++ b/template/en/default/admin/groups/list.html.tmpl
@@ -37,53 +37,91 @@
h2 = "This lets you edit the groups available to put users in."
%]
+[% edit_contentlink = "editgroups.cgi?action=changeform&amp;group=%%id%%" %]
+[% del_contentlink = "editgroups.cgi?action=del&amp;group=%%id%%" %]
-<table border="1">
- <tr>
- <th>Name</th>
- <th>Description</th>
- <th>User RegExp</th>
- <th>Use For [% terms.Bugs %]</th>
- <th>Type</th>
- <th>Action</th>
- </tr>
-
- [% FOREACH group = groups %]
- <tr>
- <td>
- <a href="editgroups.cgi?action=changeform&amp;group=[% group.id FILTER url_quote %]">
- [% group.name FILTER html %]</a>
- </td>
- <td>[% group.description FILTER html %]</td>
- <td>[% group.userregexp FILTER html %]&nbsp;</td>
+[% columns =
+ [{name => 'name'
+ heading => 'Name'
+ contentlink => edit_contentlink
+ }
+ {name => 'description'
+ heading => 'Description'
+ }
+ {name => 'userregexp'
+ heading => 'User RegExp'
+ }
+ {name => 'use_for'
+ heading => "Use For $terms.Bugs"
+ align => 'center'
+ }
+ {name => 'type'
+ heading => 'Type'
+ align => 'center'
+ }
+ {name => 'action'
+ heading => 'Action'
+ }
+ ]
+%]
- <td align="center">
- [% IF (group.isactive != 0) && (group.isbuggroup) %]
- X
- [% ELSE %]
- &nbsp;
- [% END %]
- </td>
+[% overrides.use_for = [ {
+ match_value => "0"
+ match_field => 'use_for'
+ override_content => 1
+ content => "&nbsp;"
+ },
+ {
+ match_value => "1"
+ match_field => 'use_for'
+ override_content => 1
+ content => "X"
+ }]
+ overrides.userregexp = [ {
+ match_value => ""
+ match_field => 'userregexp'
+ override_content => 1
+ content => "&nbsp;"
+ }]
+ overrides.action = [ {
+ match_value => "0"
+ match_field => 'isbuggroup'
+ override_content => 1
+ content => "&nbsp;"
+ },
+ {
+ match_value => "1"
+ match_field => 'isbuggroup'
+ override_content => 1
+ content => "Delete"
+ override_contentlink => 1
+ contentlink => del_contentlink
+ }]
+ overrides.type = [ {
+ match_value => "0"
+ match_field => 'isbuggroup'
+ override_content => 1
+ content => "system"
+ },
+ {
+ match_value => "1"
+ match_field => 'isbuggroup'
+ override_content => 1
+ content => "user"
+ }]
+%]
- <td align="center">
- [% (group.isbuggroup) ? "user" : "system" %]
- </td>
+[% FOREACH group = groups %]
+ [% group.use_for = (group.isactive != 0) && (group.isbuggroup) %]
+[% END %]
- <td align="center" valign="middle">
- [% IF (group.isbuggroup) %]
- <a href="editgroups.cgi?action=del&amp;group=[% group.id FILTER url_quote %]">Delete</a>
- [% ELSE %]
- &nbsp;
- [% END %]
- </td>
- </tr>
- [% END %]
+[% PROCESS admin/table.html.tmpl
+ columns = columns
+ data = groups
+ overrides = overrides
+%]
- <tr>
- <td colspan="5"></td>
- <td><a href="editgroups.cgi?action=add">Add Group</a></td>
- </tr>
-</table>
+<p><a href="editgroups.cgi?action=add">Add Group</a></p>
<p>
<b>Name</b> is what is used with the UserInGroup() function in any