From 8af944ce56b4ad91cf3c9ccc3c07da557c4d6b14 Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Wed, 7 Sep 2016 13:13:06 +0200 Subject: [PATCH 1/2] Fixes failing spec for badges. spec/features/official_positions_spec.rb:56 was failing because the expected badge was not being shown in featured proposals. --- app/views/proposals/_featured_proposal.html.erb | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/app/views/proposals/_featured_proposal.html.erb b/app/views/proposals/_featured_proposal.html.erb index 623932c38..90cff6da4 100644 --- a/app/views/proposals/_featured_proposal.html.erb +++ b/app/views/proposals/_featured_proposal.html.erb @@ -7,7 +7,14 @@ <% else %> <%= proposal.author.name %> <% end %> -  •  + + <% if proposal.author.display_official_position_badge? %> +  •  + + <%= proposal.author.official_position %> + + <% end %> + <%= t("proposals.proposal.supports", count: proposal.total_votes) %> From 9c48a46f0a6a2a358041d503e04d453b0b29ac34 Mon Sep 17 00:00:00 2001 From: Jaime Iniesta Date: Wed, 7 Sep 2016 13:22:52 +0200 Subject: [PATCH 2/2] adjusts style for badge in featured proposals --- app/views/proposals/_featured_proposal.html.erb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/views/proposals/_featured_proposal.html.erb b/app/views/proposals/_featured_proposal.html.erb index 90cff6da4..5500b2418 100644 --- a/app/views/proposals/_featured_proposal.html.erb +++ b/app/views/proposals/_featured_proposal.html.erb @@ -8,11 +8,13 @@ <%= proposal.author.name %> <% end %> +  •  + <% if proposal.author.display_official_position_badge? %> -  •  <%= proposal.author.official_position %> +  •  <% end %> <%= t("proposals.proposal.supports", count: proposal.total_votes) %>