]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 583287: Some fields should not be displayed in bugmail for new bugs
authorFrédéric Buclin <LpSolit@gmail.com>
Mon, 2 Aug 2010 23:16:05 +0000 (01:16 +0200)
committerFrédéric Buclin <LpSolit@gmail.com>
Mon, 2 Aug 2010 23:16:05 +0000 (01:16 +0200)
r/a=mkanat

Bugzilla/BugMail.pm
Bugzilla/Field.pm

index 3e97b4457bbd4d2257a4fdfd8e25144855d4d4f8..5688c1e7fbe0eb76d6d66dca77f1c28df713c2cd 100644 (file)
@@ -408,10 +408,10 @@ sub sendMail {
                 $value = $value->name;
             }
             elsif ($name eq 'estimated_time') {
-                $value = format_time_decimal($value);
+                $value = ($value == 0) ? 0 : format_time_decimal($value);
             }
             elsif ($name eq 'deadline') {
-                $value = time2str("%Y-%m-%d", str2time($value));
+                $value = time2str("%Y-%m-%d", str2time($value)) if $value;
             }
 
             # If there isn't anything to show, don't include this header.
index 484d6536a0fa122c69ec99dbc540adf0e0b09b36..ee11689361a549836430f2da53baab19f5bac61a 100644 (file)
@@ -214,9 +214,9 @@ use constant DEFAULT_FIELDS => (
     {name => 'target_milestone',      desc => 'Target Milestone',
      buglist => 1},
     {name => 'creation_ts',           desc => 'Creation date',
-     in_new_bugmail => 1, buglist => 1},
+     buglist => 1},
     {name => 'delta_ts',              desc => 'Last changed date',
-     in_new_bugmail => 1, buglist => 1},
+     buglist => 1},
     {name => 'longdesc',              desc => 'Comment'},
     {name => 'longdescs.isprivate',   desc => 'Comment is private'},
     {name => 'alias',                 desc => 'Alias', buglist => 1},