diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2017-06-15 04:14:58 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2017-06-15 04:14:58 +0000 |
commit | ce9edd07e35d5999473f62e5847810fbffb4c1ab (patch) | |
tree | c3738924f41af74f5402e44af341ae647292ec2d /lib/redmine/helpers/gantt.rb | |
parent | d54bff9fc6048a92fb02dfdd17f8f40a34f6bfd6 (diff) | |
download | redmine-ce9edd07e35d5999473f62e5847810fbffb4c1ab.tar.gz redmine-ce9edd07e35d5999473f62e5847810fbffb4c1ab.zip |
gannt: not show %done if the field is disabled for the tracker (#25876)
Contributed by Jens Krämer.
git-svn-id: http://svn.redmine.org/redmine/trunk@16663 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/helpers/gantt.rb')
-rw-r--r-- | lib/redmine/helpers/gantt.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/redmine/helpers/gantt.rb b/lib/redmine/helpers/gantt.rb index 79902d370..62ad843ac 100644 --- a/lib/redmine/helpers/gantt.rb +++ b/lib/redmine/helpers/gantt.rb @@ -314,7 +314,10 @@ module Redmine def line_for_issue(issue, options) # Skip issues that don't have a due_before (due_date or version's due_date) if issue.is_a?(Issue) && issue.due_before - label = "#{issue.status.name} #{issue.done_ratio}%" + label = issue.status.name.dup + unless issue.disabled_core_fields.include?('done_ratio') + label << " #{issue.done_ratio}%" + end markers = !issue.leaf? line(issue.start_date, issue.due_before, issue.done_ratio, markers, label, options, issue) end |