From 352f3fa2f9ff21b5a17d9a1cda26505e3e100e4f Mon Sep 17 00:00:00 2001 From: Alberto Garcia Cabeza Date: Thu, 16 Jun 2016 18:07:13 +0200 Subject: [PATCH] Resolves conflicts and improves styles for stats --- .../admin/stats/direct_messages.html.erb | 38 +++++------- .../stats/proposal_notifications.html.erb | 60 +++++++++---------- app/views/admin/stats/show.html.erb | 21 ++++--- 3 files changed, 52 insertions(+), 67 deletions(-) diff --git a/app/views/admin/stats/direct_messages.html.erb b/app/views/admin/stats/direct_messages.html.erb index 17532f00f..432152db5 100644 --- a/app/views/admin/stats/direct_messages.html.erb +++ b/app/views/admin/stats/direct_messages.html.erb @@ -2,30 +2,20 @@

<%= t("admin.stats.direct_messages.title")%>

-
-
-
- -
-
- -
- -
- -
-
+
+
+
+ +
+
+

+ <%= t("admin.stats.direct_messages.users_who_have_sent_message") %>
+ <%= @users_who_have_sent_message.count %> +

-
\ No newline at end of file +
diff --git a/app/views/admin/stats/proposal_notifications.html.erb b/app/views/admin/stats/proposal_notifications.html.erb index 10f620ff6..75b1c04f5 100644 --- a/app/views/admin/stats/proposal_notifications.html.erb +++ b/app/views/admin/stats/proposal_notifications.html.erb @@ -2,40 +2,36 @@

<%= t("admin.stats.proposal_notifications.title")%>

-
-
-
- -
-
- -
- -
- -
-
+
+
+
+ +
+
+

+ <%= t("admin.stats.proposal_notifications.proposals_with_notifications") %>
+ <%= @proposals_with_notifications.count %> +

-
- <% @proposal_notifications.each do |notification| %> -
-

<%= link_to notification.proposal.title, proposal_path(notification.proposal) %>

-

<%= notification.title %>

-

<%= notification.body %>

-
- <% end %> -
+ + + <% @proposal_notifications.each do |notification| %> + + + + <% end %> + +
+

+ <%= notification.title %> + <%= link_to notification.proposal.title, proposal_path(notification.proposal) %> +

+

<%= notification.body %>

+
diff --git a/app/views/admin/stats/show.html.erb b/app/views/admin/stats/show.html.erb index 66d4cbf6c..ef17536c3 100644 --- a/app/views/admin/stats/show.html.erb +++ b/app/views/admin/stats/show.html.erb @@ -1,22 +1,21 @@ <% content_for :head do %> <%= javascript_include_tag "stat_graphs", 'data-turbolinks-track' => true %> <% end %> -
+
-

<%= t "admin.stats.show.stats_title" %>

+

<%= t "admin.stats.show.stats_title" %>

+ +
+ <%= link_to t("admin.stats.show.direct_messages"), + direct_messages_admin_stats_path, class: "button hollow" %> + <%= link_to t("admin.stats.show.proposal_notifications"), + proposal_notifications_admin_stats_path, class: "button hollow" %> -
-
- <%= link_to t("admin.stats.show.direct_messages"), - direct_messages_admin_stats_path %> -
-
- <%= link_to t("admin.stats.show.proposal_notifications"), - proposal_notifications_admin_stats_path %> -
+
+