Adds missing parameters to partials

This commit is contained in:
kikito
2016-12-22 20:27:01 +01:00
parent 7acedb30f6
commit eb648b7269
4 changed files with 24 additions and 9 deletions

View File

@@ -1,5 +1,8 @@
<% if @investments.present? %>
<% @investments.each do |investment| %>
$("#<%= dom_id(investment) %>_ballot").html('<%= j render("budgets/investments/ballot", investment: investment) %>');
$("#<%= dom_id(investment) %>_ballot").html('<%= j render("/budgets/investments/ballot",
investment: investment,
investment_ids: investment_ids,
ballot: ballot) %>');
<% end %>
<% end %>
<% end %>

View File

@@ -1,5 +1,11 @@
$("#progress_bar").html('<%= j render("budgets/ballot/progress_bar", ballot: @ballot) %>');
$("#sidebar").html('<%= j render("budgets/investments/sidebar") %>');
$("#<%= dom_id(@investment) %>_ballot").html('<%= j render("budgets/investments/ballot", investment: @investment) %>');
$("#progress_bar").html('<%= j render("/budgets/ballot/progress_bar", ballot: @ballot) %>');
$("#sidebar").html('<%= j render("/budgets/investments/sidebar") %>');
$("#<%= dom_id(@investment) %>_ballot").html('<%= j render("/budgets/investments/ballot",
investment: @investment,
investment_ids: @investment_ids,
ballot: @ballot) %>');
<%= render 'refresh_ballots' %>
<%= render 'refresh_ballots',
investment: @investment,
investment_ids: @investment_ids,
ballot: @ballot %>

View File

@@ -1,6 +1,12 @@
$("#progress_bar").html('<%= j render("budgets/ballot/progress_bar", ballot: @ballot) %>');
$("#sidebar").html('<%= j render("budgets/investments/sidebar") %>');
$("#ballot").html('<%= j render("budgets/ballot/ballot") %>')
$("#<%= dom_id(@investment) %>_ballot").html('<%= j render("budgets/investments/ballot", investment: @investment) %>');
<%= render 'refresh_ballots' %>
$("#<%= dom_id(@investment) %>_ballot").html('<%= j render("/budgets/investments/ballot",
investment: @investment,
investment_ids: @investment_ids,
ballot: @ballot) %>');
<%= render 'refresh_ballots',
investment: @investment,
investment_ids: @investment_ids,
ballot: @ballot %>

View File

@@ -8,7 +8,7 @@
<main id="budget-investments-main">
<% unless params[:search].present? %>
<%= render 'header' %>
<%= render '/budgets/investments/header' %>
<% end %>
<div class="wrap row">