summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbuglist.cgi62
-rwxr-xr-xcolchange.cgi11
-rw-r--r--globals.pl5
-rw-r--r--template/en/default/global/field-descs.html.tmpl2
-rw-r--r--template/en/default/list/change-columns.html.tmpl31
-rw-r--r--template/en/default/list/table.html.tmpl41
6 files changed, 78 insertions, 74 deletions
diff --git a/buglist.cgi b/buglist.cgi
index 18d5b1b55..ef12d1242 100755
--- a/buglist.cgi
+++ b/buglist.cgi
@@ -216,7 +216,7 @@ sub GetGroupsByUserId {
while (MoreSQLData()) {
my $group = {};
- ($group->{'id'}, $group->{'name'},
+ ($group->{'bug_id'}, $group->{'name'},
$group->{'description'}, $group->{'isactive'}) = FetchSQLData();
push(@groups, $group);
}
@@ -363,7 +363,7 @@ elsif ($::FORM{'cmdtype'} eq "doit" && $::FORM{'remember'}) {
# Note: There are a few hacks in the code that deviate from these definitions.
# In particular, when the list is sorted by the "votes" field the word
# "DESC" is added to the end of the field to sort in descending order,
-# and the redundant summaryfull column is removed when the client
+# and the redundant short_desc column is removed when the client
# requests "all" columns.
my $columns = {};
@@ -373,33 +373,33 @@ sub DefineColumn {
}
# Column: ID Name Title
-DefineColumn("id" , "bugs.bug_id" , "ID" );
+DefineColumn("bug_id" , "bugs.bug_id" , "ID" );
DefineColumn("opendate" , "bugs.creation_ts" , "Opened" );
DefineColumn("changeddate" , "bugs.delta_ts" , "Changed" );
-DefineColumn("severity" , "bugs.bug_severity" , "Severity" );
+DefineColumn("bug_severity" , "bugs.bug_severity" , "Severity" );
DefineColumn("priority" , "bugs.priority" , "Priority" );
-DefineColumn("platform" , "bugs.rep_platform" , "Platform" );
-DefineColumn("owner" , "map_assigned_to.login_name" , "Owner" );
-DefineColumn("owner_realname" , "map_assigned_to.realname" , "Owner" );
+DefineColumn("rep_platform" , "bugs.rep_platform" , "Hardware" );
+DefineColumn("assigned_to" , "map_assigned_to.login_name" , "Assignee" );
+DefineColumn("assigned_to_realname", "map_assigned_to.realname" , "Assignee" );
DefineColumn("reporter" , "map_reporter.login_name" , "Reporter" );
DefineColumn("reporter_realname" , "map_reporter.realname" , "Reporter" );
DefineColumn("qa_contact" , "map_qa_contact.login_name" , "QA Contact" );
DefineColumn("qa_contact_realname", "map_qa_contact.realname" , "QA Contact" );
-DefineColumn("status" , "bugs.bug_status" , "State" );
+DefineColumn("bug_status" , "bugs.bug_status" , "Status" );
DefineColumn("resolution" , "bugs.resolution" , "Result" );
-DefineColumn("summary" , "bugs.short_desc" , "Summary" );
-DefineColumn("summaryfull" , "bugs.short_desc" , "Summary" );
+DefineColumn("short_short_desc" , "bugs.short_desc" , "Summary" );
+DefineColumn("short_desc" , "bugs.short_desc" , "Summary" );
DefineColumn("status_whiteboard" , "bugs.status_whiteboard" , "Status Summary" );
DefineColumn("component" , "map_components.name" , "Component" );
DefineColumn("product" , "map_products.name" , "Product" );
DefineColumn("version" , "bugs.version" , "Version" );
-DefineColumn("os" , "bugs.op_sys" , "OS" );
+DefineColumn("op_sys" , "bugs.op_sys" , "OS" );
DefineColumn("target_milestone" , "bugs.target_milestone" , "Target Milestone" );
DefineColumn("votes" , "bugs.votes" , "Votes" );
DefineColumn("keywords" , "bugs.keywords" , "Keywords" );
-DefineColumn("estimated_time" , "bugs.estimated_time" , "Estimated Hours" );
-DefineColumn("remaining_time" , "bugs.remaining_time" , "Remaining Hours" );
-DefineColumn("actual_time" , "(SUM(ldtime.work_time)*COUNT(DISTINCT ldtime.bug_when)/COUNT(bugs.bug_id)) AS actual_time", "Actual Hours");
+DefineColumn("estimated_time" , "bugs.estimated_time" , "Estimated Hours" );
+DefineColumn("remaining_time" , "bugs.remaining_time" , "Remaining Hours" );
+DefineColumn("actual_time" , "(SUM(ldtime.work_time)*COUNT(DISTINCT ldtime.bug_when)/COUNT(bugs.bug_id)) AS actual_time", "Actual Hours");
DefineColumn("percentage_complete","(100*((SUM(ldtime.work_time)*COUNT(DISTINCT ldtime.bug_when)/COUNT(bugs.bug_id))/((SUM(ldtime.work_time)*COUNT(DISTINCT ldtime.bug_when)/COUNT(bugs.bug_id))+bugs.remaining_time))) AS percentage_complete", "% Complete");
################################################################################
# Display Column Determination
@@ -411,16 +411,26 @@ my @displaycolumns = ();
if (defined $params->param('columnlist')) {
if ($params->param('columnlist') eq "all") {
# If the value of the CGI parameter is "all", display all columns,
- # but remove the redundant "summaryfull" column.
- @displaycolumns = grep($_ ne 'summaryfull', keys(%$columns));
+ # but remove the redundant "short_desc" column.
+ @displaycolumns = grep($_ ne 'short_desc', keys(%$columns));
}
else {
@displaycolumns = split(/[ ,]+/, $params->param('columnlist'));
}
}
elsif (defined $::COOKIE{'COLUMNLIST'}) {
+ # 2002-10-31 Rename column names (see bug 176461)
+ my $columnlist = $::COOKIE{'COLUMNLIST'};
+ $columnlist =~ s/owner/assigned_to/;
+ $columnlist =~ s/owner_realname/assigned_to_realname/;
+ $columnlist =~ s/[^_]platform/rep_platform/;
+ $columnlist =~ s/[^_]severity/bug_severity/;
+ $columnlist =~ s/[^_]status/bug_status/;
+ $columnlist =~ s/summaryfull/short_desc/;
+ $columnlist =~ s/summary/short_short_desc/;
+
# Use the columns listed in the user's preferences.
- @displaycolumns = split(/ /, $::COOKIE{'COLUMNLIST'});
+ @displaycolumns = split(/ /, $columnlist);
}
else {
# Use the default list of columns.
@@ -434,7 +444,7 @@ else {
# Remove the "ID" column from the list because bug IDs are always displayed
# and are hard-coded into the display templates.
-@displaycolumns = grep($_ ne 'id', @displaycolumns);
+@displaycolumns = grep($_ ne 'bug_id', @displaycolumns);
# Add the votes column to the list of columns to be displayed
# in the bug list if the user is searching for bugs with a certain
@@ -464,7 +474,7 @@ if (!UserInGroup(Param("timetrackinggroup"))) {
# Generate the list of columns that will be selected in the SQL query.
# The bug ID is always selected because bug IDs are always displayed
-my @selectcolumns = ("id");
+my @selectcolumns = ("bug_id");
# remaining and actual_time are required for precentage_complete calculation:
if (lsearch(\@displaycolumns, "percentage_complete") >= 0) {
@@ -480,7 +490,7 @@ push (@selectcolumns, @displaycolumns);
# has for modifying the bugs.
if ($dotweak) {
push(@selectcolumns, "product") if !grep($_ eq 'product', @selectcolumns);
- push(@selectcolumns, "status") if !grep($_ eq 'status', @selectcolumns);
+ push(@selectcolumns, "bug_status") if !grep($_ eq 'bug_status', @selectcolumns);
}
@@ -662,9 +672,9 @@ while (my @row = FetchSQLData()) {
($bug->{'opendate'} = DiffDate($bug->{'opendate'})) if $bug->{'opendate'};
# Record the owner, product, and status in the big hashes of those things.
- $bugowners->{$bug->{'owner'}} = 1 if $bug->{'owner'};
+ $bugowners->{$bug->{'assigned_to'}} = 1 if $bug->{'assigned_to'};
$bugproducts->{$bug->{'product'}} = 1 if $bug->{'product'};
- $bugstatuses->{$bug->{'status'}} = 1 if $bug->{'status'};
+ $bugstatuses->{$bug->{'bug_status'}} = 1 if $bug->{'bug_status'};
$bug->{isingroups} = 0;
@@ -672,7 +682,7 @@ while (my @row = FetchSQLData()) {
push(@bugs, $bug);
# Add id to list for checking for bug privacy later
- push(@bugidlist, $bug->{id});
+ push(@bugidlist, $bug->{'bug_id'});
}
# Switch back from the shadow database to the regular database so PutFooter()
@@ -688,11 +698,11 @@ if (@bugidlist) {
"WHERE bugs.bug_id = bug_group_map.bug_id " .
"AND bugs.bug_id IN (" . join(',',@bugidlist) . ")");
while (MoreSQLData()) {
- my ($id) = FetchSQLData();
- $privatebugs{$id} = 1;
+ my ($bug_id) = FetchSQLData();
+ $privatebugs{$bug_id} = 1;
}
foreach my $bug (@bugs) {
- if ($privatebugs{$bug->{id}}) {
+ if ($privatebugs{$bug->{'bug_id'}}) {
$bug->{isingroups} = 1;
}
}
diff --git a/colchange.cgi b/colchange.cgi
index 2cdf4f630..22ff8c562 100755
--- a/colchange.cgi
+++ b/colchange.cgi
@@ -41,10 +41,11 @@ GetVersionTable();
# The master list not only says what fields are possible, but what order
# they get displayed in.
-my @masterlist = ("opendate", "changeddate", "severity", "priority",
- "platform", "owner", "owner_realname", "reporter",
- "reporter_realname", "status", "resolution",
- "product", "component", "version", "os", "votes");
+my @masterlist = ("opendate", "changeddate", "bug_severity", "priority",
+ "rep_platform", "assigned_to", "assigned_to_realname",
+ "reporter", "reporter_realname", "bug_status",
+ "resolution", "product", "component", "version", "op_sys",
+ "votes");
if (Param("usetargetmilestone")) {
push(@masterlist, "target_milestone");
@@ -65,7 +66,7 @@ if (UserInGroup(Param("timetrackinggroup"))) {
"percentage_complete"));
}
-push(@masterlist, ("summary", "summaryfull"));
+push(@masterlist, ("short_desc", "short_short_desc"));
$vars->{'masterlist'} = \@masterlist;
diff --git a/globals.pl b/globals.pl
index 79c2f92b4..25a949e38 100644
--- a/globals.pl
+++ b/globals.pl
@@ -334,8 +334,9 @@ sub FetchOneColumn {
-@::default_column_list = ("severity", "priority", "platform", "owner",
- "status", "resolution", "summary");
+@::default_column_list = ("bug_severity", "priority", "rep_platform",
+ "assigned_to", "bug_status", "resolution",
+ "short_short_desc");
sub AppendComment {
my ($bugid, $who, $comment, $isprivate, $timestamp, $work_time) = @_;
diff --git a/template/en/default/global/field-descs.html.tmpl b/template/en/default/global/field-descs.html.tmpl
index 3e83da7c0..6d8086423 100644
--- a/template/en/default/global/field-descs.html.tmpl
+++ b/template/en/default/global/field-descs.html.tmpl
@@ -28,6 +28,7 @@
"bug_id" => "Bug ID",
"bug_severity" => "Severity",
"bug_status" => "Status",
+ "changeddate" => "Last Changed Date",
"cc" => "CC",
"cclist_accessible" => "CC list accessible?",
"component_id" => "Component ID",
@@ -40,6 +41,7 @@
"keywords" => "Keywords",
"newcc" => "CC",
"op_sys" => "OS",
+ "opendate" => "Open Date",
"percentage_complete" => "%Complete",
"priority" => "Priority",
"product_id" => "Product ID",
diff --git a/template/en/default/list/change-columns.html.tmpl b/template/en/default/list/change-columns.html.tmpl
index fbdc145a9..d049d0c6c 100644
--- a/template/en/default/list/change-columns.html.tmpl
+++ b/template/en/default/list/change-columns.html.tmpl
@@ -28,36 +28,19 @@
this feature requires cookies to work.
</p>
-[% desc = { "opendate" => "Open Date",
- "changeddate" => "Last Changed Date",
- "severity" => "Severity",
- "priority" => "Priority",
- "platform" => "Hardware",
- "owner" => "Owner",
- "owner_realname" => "Owner Realname",
- "reporter" => "Reporter",
- "reporter_realname" => "Reporter Realname",
- "status" => "Status",
- "resolution" => "Resolution",
- "product" => "Product",
- "component" => "Component",
- "version" => "Version",
- "os" => "OS",
- "votes" => "Votes",
- "keywords" => "Keywords",
- "target_milestone" => "Target",
- "qa_contact" => "QA Contact",
- "qa_contact_realname" => "QA Contact Realname",
- "status_whiteboard" => "Whiteboard",
- "summary" => "Summary (first 60 characters)",
- "summaryfull" => "Full Summary" } %]
+[% PROCESS "global/field-descs.html.tmpl" %]
+[% field_descs.short_short_desc = "Summary (first 60 characters)" %]
+[% field_descs.short_desc = "Full Summary" %]
+[% field_descs.assigned_to_realname = "Assignee Realname" %]
+[% field_descs.reporter_realname = "Reporter Realname" %]
+[% field_descs.qa_contact_realname = "QA Contact Realname" %]
<form action="colchange.cgi">
<input type="hidden" name="rememberedquery" value="[% buffer %]">
[% FOREACH column = masterlist %]
<input type="checkbox" id="[% column %]" name="column_[% column %]"
[% "checked='checked'" IF lsearch(collist, column) != -1 %]>
- <label for="[% column %]">[% desc.${column} || column %]</label>
+ <label for="[% column %]">[% field_descs.${column} || column %]</label>
<br>
[% END %]
diff --git a/template/en/default/list/table.html.tmpl b/template/en/default/list/table.html.tmpl
index 1de7f4efa..455cf1222 100644
--- a/template/en/default/list/table.html.tmpl
+++ b/template/en/default/list/table.html.tmpl
@@ -31,26 +31,33 @@
# wrap is set if a column's contents should be allowed to be word-wrapped
# by the browser.
#%]
+
+[% PROCESS "global/field-descs.html.tmpl" %]
+[% field_descs.short_short_desc = field_descs.short_desc %]
+[% field_descs.assigned_to_realname = field_descs.assigned_to %]
+[% field_descs.reporter_realname = field_descs.reporter %]
+[% field_descs.qa_contact_realname = field_descs.qa_contact %]
+
[% abbrev =
{
- "severity" => { maxlength => 3 , title => "Sev" } ,
- "priority" => { maxlength => 3 , title => "Pri" } ,
- "platform" => { maxlength => 3 , title => "Plt" } ,
- "status" => { maxlength => 4 } ,
- "reporter" => { maxlength => 30 , ellipsis => "..." } ,
- "reporter_realname" => { maxlength => 20 , ellipsis => "..." } ,
- "owner" => { maxlength => 30 , ellipsis => "..." } ,
- "owner_realname" => { maxlength => 20 , ellipsis => "..." } ,
- "qa_contact" => { maxlength => 30 , ellipsis => "..." , title => "QAContact" } ,
- "qa_contact_realname" => { maxlength => 20 , ellipsis => "..." , title => "QAContact" } ,
+ "bug_severity" => { maxlength => 3 , title => "Sev" } ,
+ "priority" => { maxlength => 3 , title => "Pri" } ,
+ "rep_platform" => { maxlength => 3 , title => "Plt" } ,
+ "bug_status" => { maxlength => 4 } ,
+ "assigned_to" => { maxlength => 30 , ellipsis => "..." } ,
+ "assigned_to_realname" => { maxlength => 20 , ellipsis => "..." } ,
+ "reporter" => { maxlength => 30 , ellipsis => "..." } ,
+ "reporter_realname" => { maxlength => 20 , ellipsis => "..." } ,
+ "qa_contact" => { maxlength => 30 , ellipsis => "..." , title => "QAContact" } ,
+ "qa_contact_realname" => { maxlength => 20 , ellipsis => "..." , title => "QAContact" } ,
"resolution" => { maxlength => 4 } ,
- "summary" => { maxlength => 60 , ellipsis => "..." , wrap => 1 } ,
- "summaryfull" => { wrap => 1 } ,
+ "short_desc" => { wrap => 1 } ,
+ "short_short_desc" => { maxlength => 60 , ellipsis => "..." , wrap => 1 } ,
"status_whiteboard" => { title => "StatusSummary" , wrap => 1 } ,
"component" => { maxlength => 8 , title => "Comp" } ,
"product" => { maxlength => 8 } ,
"version" => { maxlength => 5 , title => "Vers" } ,
- "os" => { maxlength => 4 } ,
+ "op_sys" => { maxlength => 4 } ,
"target_milestone" => { title => "TargetM" } ,
"percentage_complete" => { format_value => "%d %%" } ,
}
@@ -111,7 +118,7 @@
<a href="buglist.cgi?[% urlquerypart %]&amp;order=
[% column.name FILTER url_quote FILTER html %]
[% ",$qorder" FILTER html IF order %]">
- [%- abbrev.$id.title || column.title -%]</a>
+ [%- abbrev.$id.title || field_descs.$id || column.title -%]</a>
</th>
[% END %]
@@ -128,11 +135,11 @@
[% tableheader %]
[% END %]
- <tr class="bz_[% bug.severity %] bz_[% bug.priority %] [%+ "bz_secure" IF bug.isingroups %]">
+ <tr class="bz_[% bug.bug_severity %] bz_[% bug.priority %] [%+ "bz_secure" IF bug.isingroups %]">
<td>
- [% IF dotweak %]<input type="checkbox" name="id_[% bug.id %]">[% END %]
- <a href="show_bug.cgi?id=[% bug.id %]">[% bug.id %]</a>
+ [% IF dotweak %]<input type="checkbox" name="id_[% bug.bug_id %]">[% END %]
+ <a href="show_bug.cgi?id=[% bug.bug_id %]">[% bug.bug_id %]</a>
</td>
[% FOREACH column = displaycolumns %]