summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2012-10-04 13:30:23 +0200
committerFrédéric Buclin <LpSolit@gmail.com>2012-10-04 13:30:23 +0200
commitddb8cd75f535c7db8e072f85e44a6b1b1d9405b6 (patch)
treeed2a956e9877b7e023081a11f25a2938f5ef2208
parentf956cb59539b58585a9f6723c04b3b465a53fd51 (diff)
downloadbugzilla-ddb8cd75f535c7db8e072f85e44a6b1b1d9405b6.tar.gz
bugzilla-ddb8cd75f535c7db8e072f85e44a6b1b1d9405b6.tar.xz
Bug 794389: There is no field named 'actual_time' when generating reports
r=glob a=LpSolit
-rwxr-xr-xreport.cgi4
1 files changed, 4 insertions, 0 deletions
diff --git a/report.cgi b/report.cgi
index 4230ade36..cc43e66e4 100755
--- a/report.cgi
+++ b/report.cgi
@@ -304,6 +304,10 @@ $template->process("$format->{'template'}", $vars)
sub get_names {
my ($names, $isnumeric, $field_name) = @_;
my ($field, @sorted);
+ # XXX - This is a hack to handle the actual_time/work_time field,
+ # because it's named 'actual_time' in Search.pm but 'work_time' in Field.pm.
+ $_[2] = $field_name = 'work_time' if $field_name eq 'actual_time';
+
# _realname fields aren't real Bugzilla::Field objects, but they are a
# valid axis, so we don't vailidate them as Bugzilla::Field objects.
$field = Bugzilla::Field->check($field_name)