Merge pull request #174 from kytrinyx/pie-chart-bug

Fix off-by-one error in pie chart data
This commit is contained in:
Matt Rogers 2013-03-17 17:12:53 -07:00
commit 55aa387ab9
2 changed files with 2 additions and 2 deletions

View file

@ -355,7 +355,7 @@ class StatsController < ApplicationController
'id' => all_actions_per_context[i][:id]
} }
if size==pie_cutoff
if all_actions_per_context.size > pie_cutoff
@actions_per_context[size-1]['name']=t('stats.other_actions_label')
@actions_per_context[size-1]['total']=@actions_per_context[size-1]['total']
@actions_per_context[size-1]['id']=-1

View file

@ -321,7 +321,7 @@ en:
top10_projects_30days: Top 10 project in past 30 days
spread_of_running_actions_for_visible_contexts: Spread of running actions for visible contexts
actions_selected_from_week: "Actions selected from week "
spread_of_actions_for_all_context: Spread of actions for all context
spread_of_actions_for_all_context: Spread of actions for all contexts
click_to_show_actions_from_week: Click %{link} to show the actions from week %{week} and further.
other_actions_label: (others)
top10_projects: Top 10 projects