Index: show.rhtml =================================================================== --- app/views/versions/show.rhtml (revision 1682) +++ app/views/versions/show.rhtml (working copy) @@ -9,14 +9,23 @@
Index: app/views/versions/_issue_counts.rhtml =================================================================== --- app/views/versions/_issue_counts.rhtml (revision 1682) +++ app/views/versions/_issue_counts.rhtml (working copy) @@ -8,26 +8,97 @@ :onchange => remote_function(:url => { :action => :status_by, :id => version }, :with => "Form.serialize('status_by_form')"))) %> -<% if counts.empty? %> +<% if grouped_metrics.empty? %><%= l(:label_no_data) %>
<% else %> -- <%= link_to count[:group], {:controller => 'issues', - :action => 'index', - :project_id => version.project, - :set_filter => 1, - :fixed_version_id => version, - "#{criteria}_id" => count[:group]} %> - | -- <%= progress_bar((count[:closed].to_f / count[:total])*100, - :legend => "#{count[:closed]}/#{count[:total]}", - :width => "#{(count[:total].to_f / max * 200).floor}px;") %> - | -
+ <%= criteria_operator = category ? "=" : "!*" + link_to category || "[#{l(:text_not_assigned)}]", + {:controller => 'issues', + :action => 'index', + :project_id => version.project, + :set_filter => 1, + :fields => ["#{criteria}_id", "fixed_version_id", "status_id"], + :values => {"#{criteria}_id" => [category], "fixed_version_id" => [version], "status_id" => [1]}, + :operators => {"#{criteria}_id" => criteria_operator, "fixed_version_id" => "=", "status_id" => "*"} + } + %> + | +||||
<%= l(:label_issues_count) %> | + <% if spent_time_allowed %> +<%= l(:label_time) %> | + <% end %> ++ + <%= l(:label_estimated_time_short) %> + + | + <% if spent_time_allowed %> ++ + <%= l(:label_spent_time_short) %> + + | ++ + <%= l(:label_remaining_time_short) %> + + | + <% max_progress_width = 70 %> + <% else + max_progress_width = 150 + end %> +
+ <%= count = metrics[:count]; progress_bar((count[:closed].to_f / count[:total])*100, + :legend => + "" + + "#{count[:closed]}/" + + "" + + "#{count[:total]}", + :width => "#{(count[:total].to_f / max[:count] * max_progress_width).floor}px;") %> + | + <% + time = metrics[:time] + if spent_time_allowed %> ++ <%= progress_bar(time_progress(time)*100, + :legend => + "" + + "#{time[:spent].ceil}/" + + "" + + "#{time[:total].ceil}", + :width => "#{(time[:total] / max[:time] * max_progress_width).floor}px;") %> + | + <% end %> + <% hours = l(:text_hours_short) %> ++ + <%= "#{time[:estimated].ceil}#{hours}" %> + + | + <% if spent_time_allowed %> ++ + <%= "#{time[:spent].ceil}#{hours}" %> + + | ++ + <%= "#{time[:remaining].ceil}#{hours}" %> + + | + <% end %> +