diff options
author | lpsolit%gmail.com <> | 2007-02-27 01:21:05 +0100 |
---|---|---|
committer | lpsolit%gmail.com <> | 2007-02-27 01:21:05 +0100 |
commit | 4827e4de822cbc33acbf66c1d5b4a392c5a3f90c (patch) | |
tree | 55049f23a365b2f3dce24c537690949d52542f57 /template/en/default/account | |
parent | 79dd481670c0a1d3862062121a8ed9190f4a0edb (diff) | |
download | bugzilla-4827e4de822cbc33acbf66c1d5b4a392c5a3f90c.tar.gz bugzilla-4827e4de822cbc33acbf66c1d5b4a392c5a3f90c.tar.xz |
Bug 369982: Meaningless column in userprefs.cgi if the user cannot share his saved searches - Patch by Frédéric Buclin <LpSolit@gmail.com> r=wicked a=LpSolit
Diffstat (limited to 'template/en/default/account')
-rw-r--r-- | template/en/default/account/prefs/saved-searches.html.tmpl | 27 |
1 files changed, 11 insertions, 16 deletions
diff --git a/template/en/default/account/prefs/saved-searches.html.tmpl b/template/en/default/account/prefs/saved-searches.html.tmpl index e4bbc51ae..399f31b17 100644 --- a/template/en/default/account/prefs/saved-searches.html.tmpl +++ b/template/en/default/account/prefs/saved-searches.html.tmpl @@ -45,15 +45,10 @@ Show in Footer </th> - [% querysharegroup_regexp = '^' _ Param('querysharegroup') _ '$' %] - [% may_share = user.groups.keys.grep($querysharegroup_regexp).size %] + [% may_share = user.in_group(Param('querysharegroup')) && queryshare_groups.size %] [% IF may_share %] <th> - Share With - a Group - [% UNLESS queryshare_groups.size %] - (there are no groups you may share queries with) - [% END %] + Share With a Group </th> [% END %] </tr> @@ -75,9 +70,11 @@ value="1" [% " checked" IF user.showmybugslink %]> </td> - <td> - — - </td> + [% IF may_share %] + <td> + — + </td> + [% END %] </tr> [% FOREACH q = user.queries %] <tr> @@ -104,8 +101,8 @@ alt="[% q.name FILTER html %]" [% " checked" IF q.link_in_footer %]> </td> - <td> - [% IF queryshare_groups.size %] + [% IF may_share %] + <td> <select name="share_[% q.id FILTER html %]"> <option value="">Don't share</option> [% FOREACH group = queryshare_groups %] @@ -115,10 +112,8 @@ >[% group.name FILTER html %]</option> [% END %] </select> - [% ELSE %] - — - [% END %] - </td> + </td> + [% END %] </tr> [% END %] </table> |