From 1d057f02b277d29ad4d232d598c49b0344798b40 Mon Sep 17 00:00:00 2001 From: "bbaetz%acm.org" <> Date: Tue, 3 Jun 2003 16:47:37 +0000 Subject: Bug 180635 - Enhance Bugzilla::User to store additional information r=myk,jake --- template/en/default/attachment/create.html.tmpl | 3 ++- template/en/default/bug/show.xml.tmpl | 2 +- template/en/default/flag/list.html.tmpl | 2 +- template/en/default/global/useful-links.html.tmpl | 30 +++++++++-------------- template/en/default/list/quips.html.tmpl | 4 +-- template/en/default/request/email.txt.tmpl | 4 +-- template/en/default/search/knob.html.tmpl | 2 +- template/en/default/sidebar.xul.tmpl | 25 ++++++++++--------- 8 files changed, 33 insertions(+), 39 deletions(-) (limited to 'template') diff --git a/template/en/default/attachment/create.html.tmpl b/template/en/default/attachment/create.html.tmpl index a298df5a9..56bad7fae 100644 --- a/template/en/default/attachment/create.html.tmpl +++ b/template/en/default/attachment/create.html.tmpl @@ -123,7 +123,8 @@ [% END %] - [% IF (user.userid != bugassignee_id) AND UserInGroup("editbugs") %] + + [% IF (user.id != bugassignee_id) AND user.groups.editbugs %] Reassignment: diff --git a/template/en/default/bug/show.xml.tmpl b/template/en/default/bug/show.xml.tmpl index 618745902..45ef1712a 100644 --- a/template/en/default/bug/show.xml.tmpl +++ b/template/en/default/bug/show.xml.tmpl @@ -25,7 +25,7 @@ diff --git a/template/en/default/flag/list.html.tmpl b/template/en/default/flag/list.html.tmpl index 9ca1c25c7..50752a0df 100644 --- a/template/en/default/flag/list.html.tmpl +++ b/template/en/default/flag/list.html.tmpl @@ -116,7 +116,7 @@ id="requestee-[% flag.id %]" name="requestee-[% flag.id %]" [% IF flag.status == "?" && flag.requestee %] - value="[% flag.requestee.email FILTER html %]" + value="[% flag.requestee.login FILTER html %]" [% END %] >) diff --git a/template/en/default/global/useful-links.html.tmpl b/template/en/default/global/useful-links.html.tmpl index fac714b0e..e7588db7d 100644 --- a/template/en/default/global/useful-links.html.tmpl +++ b/template/en/default/global/useful-links.html.tmpl @@ -19,19 +19,6 @@ # Contributor(s): Gervase Markham #%] -[%# INTERFACE: - # user: hash. Information about the user. If the user is not logged in, - # user.login is undefined. - # login: string. The user's Bugzilla login email address. - # showmybugslink: boolean. True if user wants My Bugs in the footer. - # queries: list of strings. The names of those of the user's named - # queries which should be displayed in the footer. - # groups: hash. Keys are group names, values are true if user in that group. - # The keys used in this template are - # tweakparams, editcomponents, creategroups, editkeywords, confirm, - # editbugs, editusers. - #%] - [%# Migration note: this whole file corresponds to the old %commandmenu% substitution param in 'footerhtml' %] @@ -51,14 +38,14 @@ Reports - [% IF user.login %] + [% IF user %] [% email = user.login FILTER url_quote %] | My Requests [% ELSE %] | Requests [% END %] - [% IF user.login && Param('usevotes') %] + [% IF user && Param('usevotes') %] | My Votes [% END %] @@ -72,7 +59,7 @@ [% ', parameters' IF user.groups.tweakparams %] [% ', users' IF user.groups.editusers - || user.canblessany %] + || user.can_bless %] [% ', products' IF user.groups.editcomponents %] [% ', flags' @@ -91,9 +78,14 @@ [%# Preset queries %] [% preset_queries = user.showmybugslink %] - [% FOREACH q = user.queries %] - [% SET preset_queries = 1 IF q.linkinfooter %] - [% END %] + [% IF NOT preset_queries %] + [% FOREACH q = user.queries %] + [% IF q.linkinfooter %] + [% preset_queries = 1 %] + [% LAST %] + [% END %] + [% END %] + [% END %] [% IF preset_queries %] diff --git a/template/en/default/list/quips.html.tmpl b/template/en/default/list/quips.html.tmpl index 4a6ef1ad5..d9f092db2 100644 --- a/template/en/default/list/quips.html.tmpl +++ b/template/en/default/list/quips.html.tmpl @@ -35,7 +35,7 @@

Your quip '[% added_quip FILTER html %]' has been added. - [% IF Param("enablequips") == "approved" AND !UserInGroup('admin') %] + [% IF Param("enablequips") == "approved" AND !user.groups.admin %] It will be used as soon as it gets approved. [% END %] @@ -58,7 +58,7 @@ Bugzilla will pick a random quip for the headline on each bug list, and you can extend the quip list. Type in something clever or funny or boring (but not obscene or offensive, please) and bonk on the button. - [% IF Param("enablequips") == "approved" AND !UserInGroup('admin') %] + [% IF Param("enablequips") == "approved" AND !user.groups.admin %] Note that your quip has to be approved before it is used. [% END %]

diff --git a/template/en/default/request/email.txt.tmpl b/template/en/default/request/email.txt.tmpl index e35132181..cd7e43358 100644 --- a/template/en/default/request/email.txt.tmpl +++ b/template/en/default/request/email.txt.tmpl @@ -43,7 +43,7 @@ Subject: [% flag.type.name %] [%+ subject_status %]: [Bug [% flag.target.bug.id [%+ USE wrap -%] [%- FILTER bullet = wrap(80) -%] -[% user.realname %] <[% user.login %]> has [% statuses.${flag.status} %] [%+ to_identity %] for [% flag.type.name %]: +[% user.identity %] has [% statuses.${flag.status} %] [%+ to_identity %] for [% flag.type.name %]: Bug [% bugidsummary %] [% END %] @@ -58,7 +58,7 @@ Attachment [% attidsummary %] [%- FILTER bullet = wrap(80) %] [% IF form.comment.length > 0 %] -------- Additional Comments from [% user.realname %] <[% user.login %]> +------- Additional Comments from [% user.identity %] [%+ form.comment %] [% END %] diff --git a/template/en/default/search/knob.html.tmpl b/template/en/default/search/knob.html.tmpl index 50e8fc646..2c99c3f82 100644 --- a/template/en/default/search/knob.html.tmpl +++ b/template/en/default/search/knob.html.tmpl @@ -30,7 +30,7 @@ "Last Changed" => "Last Changed" } %]
-[% IF NOT userid %] +[% IF NOT user %] [% ELSE %]