- <%= link_to admin_banners_path, class: "back" do %>
-
- <%= t("admin.banners.edit.back") %>
- <% end %>
+ <%= back_link_to admin_banners_path %>
<%= t("admin.banners.edit.editing") %>
diff --git a/app/views/admin/banners/index.html.erb b/app/views/admin/banners/index.html.erb
index db58c1303..11f2ef6ab 100644
--- a/app/views/admin/banners/index.html.erb
+++ b/app/views/admin/banners/index.html.erb
@@ -7,36 +7,48 @@
<%= page_entries_info @banners %>
-
- <% @banners.each do |banner| %>
-
-
-
- <%= t("admin.banners.banner.post_started_at")%> <%= banner.post_started_at %>
- |
- <%= t("admin.banners.banner.post_ended_at")%> <%= banner.post_ended_at%>
-
-
-
-
- <%= link_to banner.target_url do %>
- <%= banner.title %>
- <%= banner.description %>
- <% end %>
+<% @banners.each do |banner| %>
+
+
+
+ | <%= t("admin.banners.banner.post_started_at")%> |
+ <%= t("admin.banners.banner.post_ended_at")%> |
+ <%= t("admin.actions.actions")%> |
+
+
+
+
+ | <%= banner.post_started_at %> |
+ <%= banner.post_ended_at %> |
+
+
+ <%= link_to t("admin.banners.index.edit"), edit_admin_banner_path(banner),
+ class: 'button hollow expanded' %>
-
- |
-
-
- <%= link_to t("admin.banners.index.edit"), edit_admin_banner_path(banner),
- class: 'edit-banner button hollow' %>
-
- <%= link_to t("admin.banners.index.delete"), admin_banner_path(banner),
- method: :delete,
- class: 'button hollow alert' %>
- |
-
- <% end %>
-
+
+ <%= link_to t("admin.banners.index.delete"), admin_banner_path(banner),
+ method: :delete,
+ class: 'button hollow alert expanded' %>
+
+ |
+
+
+ | <%= t("admin.banners.index.preview") %> |
+
+
+
+
+
+ <%= link_to banner.target_url do %>
+ <%= banner.title %>
+ <%= banner.description %>
+ <% end %>
+
+
+ |
+
+
+
+<% end %>
<%= paginate @banners %>
\ No newline at end of file
diff --git a/app/views/admin/banners/new.html.erb b/app/views/admin/banners/new.html.erb
index 41a48084d..dc5eb4ca3 100644
--- a/app/views/admin/banners/new.html.erb
+++ b/app/views/admin/banners/new.html.erb
@@ -1,10 +1,7 @@
- <%= link_to admin_banners_path, class: "back" do %>
-
- <%= t("admin.banners.new.back") %>
- <% end %>
+ <%= back_link_to admin_banners_path %>
<%= t("admin.banners.new.creating") %>
diff --git a/app/views/debates/index.html.erb b/app/views/debates/index.html.erb
index e38c52233..fd5e45059 100644
--- a/app/views/debates/index.html.erb
+++ b/app/views/debates/index.html.erb
@@ -27,7 +27,7 @@
<% end %>
- <% if has_banners %>
+ <% if has_banners? %>
<%= render "shared/banner" %>
<% end %>
diff --git a/app/views/proposals/index.html.erb b/app/views/proposals/index.html.erb
index e04e563e2..e612567ab 100644
--- a/app/views/proposals/index.html.erb
+++ b/app/views/proposals/index.html.erb
@@ -29,7 +29,7 @@
<% end %>
- <% if has_banners %>
+ <% if has_banners? %>
<%= render "shared/banner" %>
<% end %>
diff --git a/app/views/shared/_banner.html.erb b/app/views/shared/_banner.html.erb
index 6776e24a5..0ba7a2bd1 100644
--- a/app/views/shared/_banner.html.erb
+++ b/app/views/shared/_banner.html.erb
@@ -1,9 +1,9 @@
-<% banner = @banners.sample%>
+<% banner = @banners.sample %>
<%= link_to banner.target_url do %>
-
<%=banner.title%>
- <%=banner.description%>
- <% end %>
+ <%=banner.title %>
+ <%=banner.description %>
+ <% end %>
-
\ No newline at end of file
+
diff --git a/config/locales/admin.en.yml b/config/locales/admin.en.yml
index f99ef1780..2cedf0a5b 100755
--- a/config/locales/admin.en.yml
+++ b/config/locales/admin.en.yml
@@ -24,6 +24,7 @@ en:
all: All
with_active: Active
with_inactive: Inactive
+ preview: Preview
banner:
title: Title
description: Description
@@ -33,7 +34,6 @@ en:
post_started_at: Post started at
post_ended_at: Post ended at
edit:
- back: Back
editing: Edit banner
form:
submit_button: Save changes
@@ -43,7 +43,6 @@ en:
one: "prevented this banner from being saved"
other: 'prevented this banner from being saved'
new:
- back: Back
creating: Create banner
activity:
show:
diff --git a/config/locales/admin.es.yml b/config/locales/admin.es.yml
index 817576494..e66247227 100644
--- a/config/locales/admin.es.yml
+++ b/config/locales/admin.es.yml
@@ -24,6 +24,7 @@ es:
all: Todos
with_active: Activos
with_inactive: Inactivos
+ preview: Vista previa
banner:
title: Título
description: Descripción
@@ -33,7 +34,6 @@ es:
post_started_at: Inicio de publicación
post_ended_at: Fin de publicación
edit:
- back: Volver
editing: Editar el banner
form:
submit_button: Guardar Cambios
@@ -43,7 +43,6 @@ es:
one: "error impidió guardar el banner"
other: "errores impidieron guardar el banner."
new:
- back: Volver
creating: Crear banner
activity:
show: