Skip to content

Commit

Permalink
Link to custom /resultados without heading unless its on the results …
Browse files Browse the repository at this point in the history
…menu
  • Loading branch information
bertocq committed Jul 12, 2017
1 parent e1d7fa8 commit 1382b47
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/views/budgets/results/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<ul class="tabs">
<li class="tabs-title is-active">
<span class="show-for-sr"><%= t("shared.you_are_in") %></span>
<%= link_to t("budgets.results.link"), custom_budget_heading_result_path(@budget, heading_id: @budget.headings.first.to_param), class: "is-active" %>
<%= link_to t("budgets.results.link"), custom_budget_results_path(@budget), class: "is-active" %>
</li>
<li class="tabs-title">
<%= link_to t("budgets.stats.link"), custom_budget_stats_path(@budget)%>
Expand Down
2 changes: 1 addition & 1 deletion app/views/budgets/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
<% if @budget.finished? %>
<%= link_to t("budgets.show.see_results"),
custom_budget_heading_result_path(@budget, heading_id: @budget.headings.first),
custom_budget_results_path(@budget),
class: "button margin-top expanded" %>
<% end %>
</div>
Expand Down
2 changes: 1 addition & 1 deletion app/views/budgets/stats/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<% if @budget.finished? %>
<li class="tabs-title">
<span class="show-for-sr"><%= t("shared.you_are_in") %></span>
<%= link_to t("budgets.results.link"), custom_budget_heading_result_path(@budget, heading_id: @budget.headings.first.to_param) %>
<%= link_to t("budgets.results.link"), custom_budget_results_path(@budget) %>
</li>
<% end %>
<li class="tabs-title is-active">
Expand Down
2 changes: 1 addition & 1 deletion spec/features/budgets/results_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
other_heading = create(:budget_heading, group: group)
other_investment = create(:budget_investment, :winner, heading: other_heading)

visit custom_budget_heading_result_path(budget)
visit custom_budget_results_path(budget)

within("#budget-investments-compatible") do
expect(page).to have_content investment1.title
Expand Down

0 comments on commit 1382b47

Please sign in to comment.