diff --git a/app/assets/stylesheets/participation.scss b/app/assets/stylesheets/participation.scss
index d516f4c44..800e38119 100644
--- a/app/assets/stylesheets/participation.scss
+++ b/app/assets/stylesheets/participation.scss
@@ -929,12 +929,13 @@
.debate-featured {
background: $votes-bg;
+ margin: rem-calc(12) 0 !important;
.panel h3 a {
color: #0D3F54;
}
- .info {
+ .info, .info a {
color: white !important;
}
@@ -960,7 +961,6 @@
}
.debate-featured, .proposal-featured {
-
margin-bottom: 0;
margin-top: 0;
padding-left: 0;
diff --git a/app/controllers/debates_controller.rb b/app/controllers/debates_controller.rb
index b75274b7d..8a5def88b 100644
--- a/app/controllers/debates_controller.rb
+++ b/app/controllers/debates_controller.rb
@@ -12,24 +12,11 @@ class DebatesController < ApplicationController
load_and_authorize_resource
respond_to :html, :js
- def index_customization
- @featured_debates = Debate.all.sort_by_confidence_score.limit(3) if (@search_terms.blank? && @tag_filter.blank?)
- if @featured_debates.present?
- set_featured_debate_votes(@featured_debates)
- @resources = @resources.where('debates.id NOT IN (?)', @featured_debates.map(&:id))
- end
- end
-
def vote
@debate.register_vote(current_user, params[:value])
set_debate_votes(@debate)
end
- def vote_featured
- @debate.register_vote(current_user, 'yes')
- set_featured_debate_votes(@debate)
- end
-
private
def debate_params
@@ -40,7 +27,4 @@ class DebatesController < ApplicationController
Debate
end
- def set_featured_debate_votes(debates)
- @featured_debates_votes = current_user ? current_user.debate_votes(debates) : {}
- end
end
diff --git a/app/views/debates/_featured_debate.html.erb b/app/views/debates/_featured_debate.html.erb
deleted file mode 100644
index ddf8f4e40..000000000
--- a/app/views/debates/_featured_debate.html.erb
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
<%= link_to debate.title, debate %>
-
-
- <% if debate.author.hidden? || debate.author.erased? %>
- <%= t("debates.show.author_deleted") %>
- <% else %>
- <%= debate.author.name %>
- <% end %>
-
- •
- <%= t("debates.debate.votes", count: debate.total_votes) %>
-
-
-
-
diff --git a/app/views/debates/_featured_debates_static.html.erb b/app/views/debates/_featured_debates_static.html.erb
new file mode 100644
index 000000000..69fdecf91
--- /dev/null
+++ b/app/views/debates/_featured_debates_static.html.erb
@@ -0,0 +1,27 @@
+
+
+
+
+ <%= link_to "¿Y si cualquiera pudiera entrevistar a manuela carmena o los otros concejales?", "https://decide.madrid.es/debates/4299" %>
+
+
+ <%= link_to "ParticipaciónYTransparenciaAytoMadrid", "https://decide.madrid.es/users/52055"%>
+
+
+
+
+
+
+
+
+
+
+ <%= link_to "#Túpreguntas: carlos sánchez mato, concejal de economía y hacienda.", "https://decide.madrid.es/debates/4298" %>
+
+
+ <%= link_to "CARLOS SANCHEZ", "https://decide.madrid.es/users/13"%>
+
+
+
+
+
diff --git a/app/views/debates/index.html.erb b/app/views/debates/index.html.erb
index 17db79cc7..01d986af3 100644
--- a/app/views/debates/index.html.erb
+++ b/app/views/debates/index.html.erb
@@ -44,23 +44,19 @@
<%= link_to t("debates.index.start_debate"), new_debate_path, class: 'button radius expand' %>
- <% if @featured_debates.present? %>
-
-
-
- <%= t("debates.index.featured_proposals_html") %>
-
-
- <%= image_tag("featured_debates.jpg", size: "210x135") %>
-
-
-
- <% @featured_debates.each do |featured_debate| %>
- <%= render "featured_debate", debate: featured_debate %>
- <% end %>
-
+
+
+
+ <%= t("debates.index.featured_debates_html") %>
+
+
+ <%= image_tag("featured_debates.jpg", size: "210x135") %>
+
- <% end %>
+
+ <%= render "featured_debates_static", debate: @debate %>
+
+
<%= render @debates %>
<%= paginate @debates %>
diff --git a/config/locales/en.yml b/config/locales/en.yml
index 479d8c79e..45439641f 100755
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -79,7 +79,7 @@ en:
debates:
index:
title: "Debates"
- featured_proposals_html: "Featured
debates"
+ featured_debates_html: "Featured
debates"
start_debate: "Start a debate"
select_order: "Order by"
select_order_long: "You are viewing debates according to:"
diff --git a/config/locales/es.yml b/config/locales/es.yml
index 1b81e0a99..0ceb68676 100644
--- a/config/locales/es.yml
+++ b/config/locales/es.yml
@@ -79,7 +79,7 @@ es:
debates:
index:
title: "Debates"
- featured_proposals_html: "Debates
destacados"
+ featured_debates_html: "Debates
destacados"
start_debate: "Empieza un debate"
select_order: "Ordenar por"
select_order_long: "Estás viendo los debates"