Hide incompatible and non-winner investments by default
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
<div class="small-12 medium-9 column <%= results_type == :compatible ? 'success' : 'js-discarded' %>" id="<%= results_type %>-container">
|
||||
<div class="small-12 medium-9 column <%= results_type == :compatible ? 'success' : 'js-discarded' %>"
|
||||
style="<%= results_type != :compatible ? 'display: none' : '' %>"
|
||||
id="<%= results_type %>-container">
|
||||
|
||||
<h3 class="inline-block">
|
||||
<%= title %>
|
||||
@@ -28,7 +30,9 @@
|
||||
<tbody>
|
||||
<% amount_available = heading_price %>
|
||||
<% investments.each do |investment| %>
|
||||
<tr id="<%= dom_id(investment) %>" class="budget-investments <%= investment.winner? ? 'success' : 'js-discarded' %>">
|
||||
<tr id="<%= dom_id(investment) %>"
|
||||
class="budget-investments <%= investment.winner? ? 'success' : 'js-discarded' %>"
|
||||
style="<%= investment.winner? ? '' : 'display: none' %>">
|
||||
<td>
|
||||
<% if investment.winner? %>
|
||||
<span class="icon-check">
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<span class="float-right"><%= link_to t("budgets.results.hide_discarded_link"), "#", class: "js-toggle-link button hollow margin-bottom", data: {'toggle-selector' => '.js-discarded', 'toggle-text' => t("budgets.results.show_all_link")} %></span>
|
||||
<span class="float-right"><%= link_to t("budgets.results.show_all_link"), "#", class: "js-toggle-link button hollow margin-bottom", data: {'toggle-selector' => '.js-discarded', 'toggle-text' => t("budgets.results.hide_discarded_link")} %></span>
|
||||
|
||||
|
||||
<%= render 'results_table', results_type: :compatible,
|
||||
|
||||
Reference in New Issue
Block a user