added some labels

Merge changes to list
bug fixes

git-svn-id: https://dev.finn.de/svn/cockpit/trunk@253 7926756e-e54e-46e6-9721-ed318f58905e
pull/6827/head
hjust 15 years ago
parent 7e84e846fd
commit 029a629a19
  1. 4
      app/models/cost_query.rb
  2. 4
      app/views/cost_reports/_group_by.rhtml
  3. 11
      app/views/cost_reports/_list_items.rhtml
  4. 1
      lang/de.yml
  5. 1
      lang/en.yml

@ -267,8 +267,10 @@ class CostQuery < ActiveRecord::Base
end
grouping_scope(:issues) do
grouping_column(:tracker_id, :fixed_version_id, :subproject_id)
grouping_column :tracker_id, :display => from_field(Tracker, :name)
grouping_column :fixed_version_id, :display => from_field(Version, :name)
grouping_column(:cost_object_id, :display => from_field(CostObject, :subject))
grouping_column :subproject_id, :display => from_field(Project, :name)
end
grouping_scope(:costs) do

@ -9,10 +9,10 @@
</script>
<%=
select_tag "group_by[name]", options_for_select(@query.group_by_columns_for_select, (@query.group_by[:name].to_sym unless @query.group_by[:name].blank?)),
select_tag "group_by[name]", options_for_select(@query.group_by_columns_for_select, (@query.group_by[:name].to_s unless @query.group_by[:name].blank?)),
:class => "select-small", :onchange => "group_by_changed();"
%>
<%=
select_tag("group_by[granularity]", options_for_select([[l(:label_year), "year"], [l(:label_month), "month"], [l(:label_week), "week"], [l(:label_day), "day"]], @query.group_by[:granularity]),
select_tag("group_by[granularity]", options_for_select([[l(:label_year), "year"], [l(:label_month), "month"], [l(:label_week), "week"], [l(:label_day_plural), "day"]], @query.group_by[:granularity]),
:class => "select-small", :onload => "group_by_changed();", :style => ("display: none" if @query.group_by["name"].blank? || !@query.time_groups.include?(@query.group_by["name"].to_sym)))
%>

@ -7,7 +7,6 @@
<th></th>
<%= sort_header_tag("entry__issue_id", :caption => l(:caption_issue), :default_order => 'desc') %>
<th><%= l(:caption_cost_unit_plural) %></th>
<!-- <th><%= l(:field_hours) %></th> -->
<%= sort_header_tag("entry__cost_type_id", :caption => l(:caption_cost_type), :default_order => 'asc') %>
<%= sort_header_tag("entry__activity_id", :caption => l(:label_activity), :default_order => 'asc') %>
<%= sort_header_tag("entry__spent_on", :caption => l(:caption_spent), :default_order => 'desc') %>
@ -33,14 +32,10 @@
<td class="currency"><%= number_to_currency(entry.real_costs) %></td>
</tr>
<% end %>
<tr>
<td colspan="7">&nbsp;</td>
<td class="currency"><strong><%= number_to_currency page_costs %></strong></td>
</tr>
</tbody>
</table>
<p class="pagination splitcontentleft"><%= pagination_links_full @entry_pages, @entry_count %></p>
<p class="pagination"><%= pagination_links_full @entry_pages, @entry_count %></p>
<p><%=l :label_overall_costs %>: <%= number_to_currency @entry_sum %></p>
<div class="currency"><%= l(:label_costs_per_page)%>: <%= number_to_currency page_costs %></div>
<div class="currency" style="clear: left"><strong><%=l :label_overall_costs %>: <%= number_to_currency @entry_sum %></strong></div>
<% end %>

@ -33,6 +33,7 @@ label_cost_object_new: "Neuer Liefergegenstand"
label_cost_object_id: "Liefergegenstand #%s"
label_view_all_cost_objects: "Alle Liefergegenstände anzeigen"
label_overall_costs: "Gesamtkosten"
label_costs_per_page: "Kosten dieser Seite"
label_spent_costs: "Gebuchte Kosten"
label_spent_units: "Gebuchte Einheiten"
label_cost_plural: "Kosten"

@ -33,6 +33,7 @@ label_cost_object_new: "New Cost Object"
label_cost_object_id: "Cost Object #%s"
label_view_all_cost_objects: "View all Cost Objects"
label_overall_costs: "Overall costs"
label_costs_per_page: "Costs per page"
label_spent_costs: "Spent costs"
label_spent_units: "Spent units"
label_cost_plural: "Costs"

Loading…
Cancel
Save