diff --git a/app/views/admin/budget_investments/_investments.html.erb b/app/views/admin/budget_investments/_investments.html.erb
index a60e2ac11..e3cea1026 100644
--- a/app/views/admin/budget_investments/_investments.html.erb
+++ b/app/views/admin/budget_investments/_investments.html.erb
@@ -16,84 +16,89 @@
<%= t("admin.budget_investments.index.table_feasibility") %> |
<%= t("admin.budget_investments.index.table_valuation_finished") %> |
<%= t("admin.budget_investments.index.table_selection") %> |
- <% if params[:filter] == 'selected' %>
+ <% if params[:filter] == "selected" %>
<%= t("admin.budget_investments.index.table_incompatible") %> |
<% end %>
- <% @investments.each do |investment| %>
-
- |
- <%= investment.id %>
- |
-
- <%= link_to investment.title,
- admin_budget_budget_investment_path(budget_id: @budget.id,
- id: investment.id,
- params: Budget::Investment.filter_params(params)),
- target: "_blank" %>
- |
-
- <%= investment.total_votes %>
- |
-
- <% if investment.administrator.present? %>
-
- <%= investment.administrator.name %>
-
- <% else %>
- <%= t("admin.budget_investments.index.no_admin_assigned") %>
- <% end %>
- |
-
- <% if investment.valuators.size == 0 %>
- <%= t("admin.budget_investments.index.no_valuators_assigned") %>
- <% else %>
- <%= investment.valuators.collect(&:description_or_name).join(', ') %>
- <% end %>
- |
-
- <%= investment.heading.name %>
- |
-
- <%= t("admin.budget_investments.index.feasibility.#{investment.feasibility}",
- price: investment.formatted_price)
- %>
- |
-
- <%= investment.valuation_finished? ? t('shared.yes'): t('shared.no') %>
- |
-
- <% if investment.selected? %>
- <%= link_to_unless investment.budget.finished?,
- t("admin.budget_investments.index.selected"),
- toggle_selection_admin_budget_budget_investment_path(@budget,
- investment,
- filter: params[:filter],
- page: params[:page]),
- method: :patch,
- remote: true,
- class: "button small expanded" %>
- <% elsif investment.feasible? && investment.valuation_finished? %>
- <%= link_to_unless investment.budget.finished?,
- t("admin.budget_investments.index.select"),
- toggle_selection_admin_budget_budget_investment_path(@budget,
- investment,
- filter: params[:filter],
- page: params[:page]),
- method: :patch,
- remote: true,
- class: "button small hollow expanded" %>
- <% end %>
- |
- <% if params[:filter] == 'selected' %>
-
- <%= investment.incompatible? ? t('shared.yes'): t('shared.no') %>
+ |
+ <% @investments.each do |investment| %>
+
+ |
+ <%= investment.id %>
|
- <% end %>
-
- <% end %>
+
+ <%= link_to investment.title,
+ admin_budget_budget_investment_path(budget_id: @budget.id,
+ id: investment.id,
+ params: Budget::Investment.filter_params(params)),
+ target: "_blank" %>
+ |
+
+ <%= investment.total_votes %>
+ |
+
+ <% if investment.administrator.present? %>
+
+ <%= investment.administrator.name %>
+
+ <% else %>
+ <%= t("admin.budget_investments.index.no_admin_assigned") %>
+ <% end %>
+ |
+
+ <% if investment.valuators.size.zero? %>
+ <%= t("admin.budget_investments.index.no_valuators_assigned") %>
+ <% else %>
+ <%= investment.valuators.collect(&:description_or_name).join(", ") %>
+ <% end %>
+ |
+
+ <%= investment.heading.name %>
+ |
+
+ <%= t("admin.budget_investments.index.feasibility.#{investment.feasibility}",
+ price: investment.formatted_price) %>
+ |
+
+ <%= investment.valuation_finished? ? t("shared.yes"): t("shared.no") %>
+ |
+
+ <% if investment.selected? %>
+ <%= link_to_unless investment.budget.finished?,
+ t("admin.budget_investments.index.selected"),
+ toggle_selection_admin_budget_budget_investment_path(@budget,
+ investment,
+ filter: params[:filter],
+ second_filter: params[:second_filter],
+ max_per_heading: params[:max_per_heading],
+ page: params[:page]),
+ method: :patch,
+ remote: true,
+ class: "button small expanded" %>
+ <% elsif investment.feasible? && investment.valuation_finished? %>
+ <%= link_to_unless investment.budget.finished?,
+ t("admin.budget_investments.index.select"),
+ toggle_selection_admin_budget_budget_investment_path(@budget,
+ investment,
+ filter: params[:filter],
+ second_filter: params[:second_filter],
+ max_per_heading: params[:max_per_heading],
+ page: params[:page]),
+ method: :patch,
+ remote: true,
+ class: "button small hollow expanded" %>
+ <% end %>
+ |
+ <% if params[:filter] == "selected" %>
+
+ <%= investment.incompatible? ? t("shared.yes"): t("shared.no") %>
+ |
+ <% end %>
+
+ <% end %>
+
<%= paginate @investments %>