adminpanel 2.1.3 → 2.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/adminpanel/{theme.css.erb → theme.css.scss.erb} +9 -3
- data/app/helpers/adminpanel/analytics_helper.rb +1 -2
- data/app/models/adminpanel/auth.rb +4 -0
- data/app/views/adminpanel/analytics/_header.html.erb +10 -0
- data/app/views/adminpanel/analytics/_widget_task_statistics.html.erb +2 -2
- data/app/views/adminpanel/analytics/fb.html.erb +95 -87
- data/app/views/adminpanel/analytics/index.html.erb +2 -2
- data/config/locales/es.yml +1 -1
- data/config/routes.rb +1 -0
- data/lib/adminpanel/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 50a4558fb1b120ccab1cffbfb11cf877d59e2b81
|
4
|
+
data.tar.gz: 2980c65b9afe641a8ed4a4fd3acfee9272cabe6b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d8ac895cbcf90906bd85c7633beb4a8b815cfe253799d58ef400e318dd9fb4bcb47f6a19b05cd6cb1a0e81aa1ee873e68f56bab5e658b7467e5fcd4caf9f9e3
|
7
|
+
data.tar.gz: ecd03f0c8a74d459835384dc07583da6b9ef975f1796d528bcc6f6f67444f5a01f8902048f360a335db93e2ea311846ddf1dafce5de04d1c9f73f4bed6a663e1
|
@@ -1,9 +1,9 @@
|
|
1
1
|
/*------- RESPONSIVE -------*/
|
2
2
|
|
3
3
|
*{
|
4
|
-
|
5
|
-
|
6
|
-
|
4
|
+
-webkit-box-sizing: border-box;
|
5
|
+
-moz-box-sizing: border-box;
|
6
|
+
box-sizing: border-box;
|
7
7
|
}
|
8
8
|
html, body{
|
9
9
|
height: auto !important;
|
@@ -1574,3 +1574,9 @@ table.table thead .sorting_desc_disabled { background: url(<%= asset_path 'admin
|
|
1574
1574
|
margin: 0 90px 0 15px;
|
1575
1575
|
}
|
1576
1576
|
}
|
1577
|
+
|
1578
|
+
.widget-tasks-statistics{
|
1579
|
+
.userstats{
|
1580
|
+
.white.facebook-insights { z-index: 0; }
|
1581
|
+
}
|
1582
|
+
}
|
@@ -8,7 +8,7 @@ module Adminpanel
|
|
8
8
|
# end
|
9
9
|
# end
|
10
10
|
# return total
|
11
|
-
metric.first['values'].
|
11
|
+
metric.first['values'].last['value'].to_f
|
12
12
|
end
|
13
13
|
|
14
14
|
def days_to_substract
|
@@ -24,7 +24,6 @@ module Adminpanel
|
|
24
24
|
end
|
25
25
|
|
26
26
|
def divide_metrics(metric_1, metric_2)
|
27
|
-
debugger
|
28
27
|
if first_fb_value(metric_2) != 0.0
|
29
28
|
return first_fb_value(metric_1) / first_fb_value(metric_2)
|
30
29
|
else
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<div class="widget-tasks-statistics">
|
2
|
-
<div class="userstats clearfix" style="margin-top: 25px;">
|
2
|
+
<div class="userstats clearfix" style="margin-top: 25px; background-color: none;">
|
3
3
|
<%= link_to '#', data: { toggle: 'modal', target: "##{metric(inside)}" } do %>
|
4
|
-
<div class="white">
|
4
|
+
<div class="white facebook-insights">
|
5
5
|
<i style="color:<%= color %>" class="fa fa-<%= icon %>"></i>
|
6
6
|
<p style="color:<%= color %>" >
|
7
7
|
<%= "#{first_fb_value(inside).to_i} #{placeholder}" %>
|
@@ -1,98 +1,106 @@
|
|
1
1
|
<% provide(:page_title, I18n.t('analytics.facebook')) -%>
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
2
|
+
<div class="row-fluid">
|
3
|
+
<div class="widget widget-padding span12">
|
4
|
+
<div class="widget-header">
|
5
|
+
<%= render 'header' %>
|
6
|
+
</div>
|
7
|
+
<div class="widget-body">
|
8
|
+
<%= form_tag fb_analytics_path, method: :get %>
|
9
|
+
<%=
|
10
|
+
select_tag(
|
11
|
+
'insight',
|
12
|
+
options_for_select(
|
13
|
+
[
|
14
|
+
[I18n.t('analytics.now'), 'day'],
|
15
|
+
[I18n.t('analytics.week'), 'week'],
|
16
|
+
[I18n.t('analytics.month'), 'days_28']
|
17
|
+
],
|
18
|
+
params[:insight]
|
19
|
+
)
|
20
|
+
)
|
21
|
+
%>
|
22
|
+
<%= button_tag(I18n.t('analytics.search'), type: 'submit', class: 'btn btn-info') %>
|
23
|
+
<h4>Haz click en los íconos para ver su descripción</h4>
|
24
|
+
<% date = Date.parse @new_likes.first['values'].last['end_time'] %>
|
25
|
+
<h3><%= I18n.t('analytics.for') %> <%= date - days_to_substract %> - <%= date %></h3>
|
26
|
+
<div class="overview_boxes">
|
27
|
+
<div class="box_row clearfix">
|
28
|
+
<%=
|
29
|
+
render(
|
30
|
+
'widget_task_statistics',
|
31
|
+
inside: @new_likes,
|
32
|
+
outside: @total_likes,
|
33
|
+
placeholder: '+',
|
34
|
+
icon: 'thumbs-up',
|
35
|
+
color: '#98AEEA',
|
36
|
+
label: 'Likes'
|
37
|
+
)
|
38
|
+
%>
|
33
39
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
40
|
+
<%=
|
41
|
+
render(
|
42
|
+
'widget_task_statistics',
|
43
|
+
inside: @impressions_unique,
|
44
|
+
outside: @impressions,
|
45
|
+
placeholder: I18n.t('analytics.unique'),
|
46
|
+
icon: 'ticket',
|
47
|
+
color: '#6CD0F7',
|
48
|
+
label: I18n.t('analytics.impressions')
|
49
|
+
)
|
50
|
+
%>
|
45
51
|
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
52
|
+
<%=
|
53
|
+
render(
|
54
|
+
'widget_task_statistics',
|
55
|
+
inside: @views_unique,
|
56
|
+
outside: @views,
|
57
|
+
placeholder: 'únicas',
|
58
|
+
icon: 'eye',
|
59
|
+
color: '#6CD0F7',
|
60
|
+
label: 'Vistas'
|
61
|
+
)
|
62
|
+
%>
|
57
63
|
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
64
|
+
<%=
|
65
|
+
render(
|
66
|
+
'widget_task_statistics',
|
67
|
+
inside: @stories,
|
68
|
+
outside: @stories,
|
69
|
+
placeholder: '',
|
70
|
+
icon: 'bullhorn',
|
71
|
+
color: '#6CD0F7',
|
72
|
+
label: 'Hablando de ti'
|
73
|
+
)
|
74
|
+
%>
|
69
75
|
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
76
|
+
<%=
|
77
|
+
render(
|
78
|
+
'widget_task_statistics',
|
79
|
+
inside: @consumptions_unique,
|
80
|
+
outside: @consumptions,
|
81
|
+
placeholder: 'únicas',
|
82
|
+
icon: 'crosshairs',
|
83
|
+
color: '#6CD0F7',
|
84
|
+
label: 'Consumptions'
|
85
|
+
)
|
86
|
+
%>
|
81
87
|
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
88
|
+
<%=
|
89
|
+
render(
|
90
|
+
'widget_task_statistics',
|
91
|
+
inside: @hidden_unique,
|
92
|
+
outside: @hidden,
|
93
|
+
placeholder: '-',
|
94
|
+
icon: 'thumbs-down',
|
95
|
+
color: '#E28270',
|
96
|
+
label: 'Dislike o Hide'
|
97
|
+
)
|
98
|
+
%>
|
93
99
|
|
100
|
+
</div>
|
101
|
+
</div>
|
94
102
|
|
103
|
+
</div>
|
95
104
|
</div>
|
96
105
|
</div>
|
97
|
-
|
98
106
|
<%= yield :modals %>
|
@@ -1,11 +1,11 @@
|
|
1
|
-
<% provide(:page_title,
|
1
|
+
<% provide(:page_title, 'Google Analytics') -%>
|
2
2
|
<% content_for :scripts do %>
|
3
3
|
<%#= javascript_include_tag "adminpanel/analytics/analytics" %>
|
4
4
|
<% end %>
|
5
5
|
<div class="row-fluid">
|
6
6
|
<div class="widget widget-padding span12">
|
7
7
|
<div class="widget-header">
|
8
|
-
|
8
|
+
<%= render 'header' %>
|
9
9
|
</div>
|
10
10
|
<%= content_tag "div", :id => "graphic-container", :class => "widget-body", :data => { :visits => @visits, :dates => @visitDates } do %>
|
11
11
|
<% end %>
|
data/config/locales/es.yml
CHANGED
@@ -107,7 +107,7 @@ es:
|
|
107
107
|
impressions: 'Impresiones'
|
108
108
|
unique: 'Únicas'
|
109
109
|
for: 'Estadísticas para '
|
110
|
-
facebook: '
|
110
|
+
facebook: 'Facebook Insights'
|
111
111
|
explanation: 'Explicación de las métricas'
|
112
112
|
description:
|
113
113
|
page_stories: '(Periodo) El número de historias creadas acerca de tu página (Cuenta total)'
|
data/config/routes.rb
CHANGED
@@ -20,6 +20,7 @@ Adminpanel::Engine.routes.draw do
|
|
20
20
|
when :analytics
|
21
21
|
resources :analytics, resources_parameters(resource).merge({ only: [:index] }) do
|
22
22
|
collection do
|
23
|
+
get :google, to: 'analytics#index', as: 'google', path: 'google'
|
23
24
|
get :fb, to:'analytics#fb', as: 'fb', path:'facebook'
|
24
25
|
end
|
25
26
|
end
|
data/lib/adminpanel/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: adminpanel
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jose Ramon Camacho
|
@@ -482,7 +482,7 @@ files:
|
|
482
482
|
- app/assets/stylesheets/adminpanel/fullcalendar.css
|
483
483
|
- app/assets/stylesheets/adminpanel/fullcalendar.print.css
|
484
484
|
- app/assets/stylesheets/adminpanel/select2.css
|
485
|
-
- app/assets/stylesheets/adminpanel/theme.css.erb
|
485
|
+
- app/assets/stylesheets/adminpanel/theme.css.scss.erb
|
486
486
|
- app/assets/stylesheets/adminpanel/timepicker.css
|
487
487
|
- app/assets/stylesheets/application-admin.css
|
488
488
|
- app/controllers/adminpanel/analytics_controller.rb
|
@@ -518,6 +518,7 @@ files:
|
|
518
518
|
- app/models/contact.rb
|
519
519
|
- app/uploaders/adminpanel/gallery_uploader.rb
|
520
520
|
- app/views/adminpanel/.DS_Store
|
521
|
+
- app/views/adminpanel/analytics/_header.html.erb
|
521
522
|
- app/views/adminpanel/analytics/_widget_task_statistics.html.erb
|
522
523
|
- app/views/adminpanel/analytics/fb.html.erb
|
523
524
|
- app/views/adminpanel/analytics/index.html.erb
|