forest_admin_agent 1.0.0.pre.beta.86 → 1.0.0.pre.beta.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ba603df0dd8d88da6e6f10f251d3c24a682e9085799bbe097533863db88e1691
|
4
|
+
data.tar.gz: 3552261f4d9113775875d559886f53fd2370a018994cb03be83605135f51306f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cff8663ff0b641b59b695b3bff3400438082f86ba99bfd8138413fff16aa5cb76f5995e254dbd2d7b39a2885ad499afe80f046adb123007ec9307c15b8c78e9d
|
7
|
+
data.tar.gz: fe61ddd0ca3110d4904f012a379e03507fd415561c22a12f04587bc5e0b9031b1987dc304ca940678dbdbb11698fd1cf4b712c66fe3529e47458f6ae4ca1157c
|
@@ -99,7 +99,7 @@ module ForestAdminAgent
|
|
99
99
|
|
100
100
|
result = @collection.aggregate(@caller, @filter, aggregation)
|
101
101
|
|
102
|
-
PieChart.new(result.map { |row| { key: row[
|
102
|
+
PieChart.new(result.map { |row| { key: row['group'][group_field], value: row['value'] } }).serialize
|
103
103
|
end
|
104
104
|
|
105
105
|
def make_line
|
@@ -124,7 +124,7 @@ module ForestAdminAgent
|
|
124
124
|
)
|
125
125
|
|
126
126
|
values = {}
|
127
|
-
rows.each { |row| values[row[
|
127
|
+
rows.each { |row| values[row['group'][group_by_field_name]] = row['value'] }
|
128
128
|
dates = values.keys.sort
|
129
129
|
current = dates[0]
|
130
130
|
last = dates.last
|
@@ -189,8 +189,8 @@ module ForestAdminAgent
|
|
189
189
|
|
190
190
|
result = rows.map do |row|
|
191
191
|
{
|
192
|
-
key: row[
|
193
|
-
value: row[
|
192
|
+
key: row['group'][aggregation.groups[0][:field]],
|
193
|
+
value: row['value']
|
194
194
|
}
|
195
195
|
end
|
196
196
|
|
@@ -206,7 +206,7 @@ module ForestAdminAgent
|
|
206
206
|
field: @args[:params][:aggregateFieldName])
|
207
207
|
result = @collection.aggregate(@caller, filter, aggregation)
|
208
208
|
|
209
|
-
result[0][
|
209
|
+
result[0]['value'] || 0
|
210
210
|
end
|
211
211
|
end
|
212
212
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: forest_admin_agent
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.pre.beta.
|
4
|
+
version: 1.0.0.pre.beta.88
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matthieu
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2025-01-
|
12
|
+
date: 2025-01-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|