diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2019-06-20 06:29:11 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2019-06-20 06:29:11 +0000 |
commit | 2663ae66ae28ed65289e869946d4d9f67c36d34b (patch) | |
tree | a5228526ce8ba7ebac12628b256c5a857acdf2ca | |
parent | 001853ef7951b866089015a7d22e07c787e541a8 (diff) | |
download | redmine-2663ae66ae28ed65289e869946d4d9f67c36d34b.tar.gz redmine-2663ae66ae28ed65289e869946d4d9f67c36d34b.zip |
Roadmap shows 100%, but one of its tasks is still set to 90% (#30949).
Patch by Bernhard Rohloff.
git-svn-id: http://svn.redmine.org/redmine/trunk@18265 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r-- | app/helpers/application_helper.rb | 2 | ||||
-rw-r--r-- | app/views/versions/_overview.html.erb | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 6b4ac3041..4ecb558b5 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -1376,7 +1376,7 @@ module ApplicationHelper def progress_bar(pcts, options={}) pcts = [pcts, pcts] unless pcts.is_a?(Array) - pcts = pcts.collect(&:round) + pcts = pcts.collect(&:floor) pcts[1] = pcts[1] - pcts[0] pcts << (100 - pcts[1] - pcts[0]) titles = options[:titles].to_a diff --git a/app/views/versions/_overview.html.erb b/app/views/versions/_overview.html.erb index 21224df43..48c6b5972 100644 --- a/app/views/versions/_overview.html.erb +++ b/app/views/versions/_overview.html.erb @@ -17,9 +17,9 @@ <% if version.visible_fixed_issues.count > 0 %> <%= progress_bar([version.visible_fixed_issues.closed_percent, version.visible_fixed_issues.completed_percent], :titles => - ["%s: %0.0f%%" % [l(:label_closed_issues_plural), version.visible_fixed_issues.closed_percent], - "%s: %0.0f%%" % [l(:field_done_ratio), version.visible_fixed_issues.completed_percent]], - :legend => ('%0.0f%%' % version.visible_fixed_issues.completed_percent)) %> + ["%s: %i%%" % [l(:label_closed_issues_plural), version.visible_fixed_issues.closed_percent], + "%s: %i%%" % [l(:field_done_ratio), version.visible_fixed_issues.completed_percent]], + :legend => ('%i%%' % version.visible_fixed_issues.completed_percent)) %> <p class="progress-info"> <%= link_to(l(:label_x_issues, :count => version.visible_fixed_issues.count), version_filtered_issues_path(version, :status_id => '*')) %> |