axlsx_report 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/examples/totals_report.rb +16 -0
- data/lib/axlsx_report/base.rb +1 -1
- data/lib/axlsx_report/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c280100376262e4f650b7057c773cc99d11ac6b5
|
4
|
+
data.tar.gz: ba45f8119fcf8f496d61c213426cc6e1e538e869
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd521331de96830ce6095f8dcedfa7b57275825944d04262ff0ce851570c6b0b8bd26801804138701d49ab6e6107548314a481eff0107b083832a1a2946240c3
|
7
|
+
data.tar.gz: 7e6b0ef54416cec34496222a34804e6f9f48c5bd8be014838c65536b5dee8f0b8e4e125459ac1dbfa0c05f11535ddd6196021d77459b55f32a90f28e43e1a797
|
@@ -0,0 +1,16 @@
|
|
1
|
+
$LOAD_PATH.unshift "#{File.dirname(__FILE__)}/../lib"
|
2
|
+
|
3
|
+
require 'axlsx_report'
|
4
|
+
|
5
|
+
class TotalsReport < AxlsxReport::Base
|
6
|
+
column 'Integer', ->(i) { i }, total: 'Total'
|
7
|
+
column 'Square', ->(i) { i * i }, total: :sum
|
8
|
+
end
|
9
|
+
|
10
|
+
if __FILE__ == $0
|
11
|
+
report = TotalsReport.new
|
12
|
+
(1..10).each { |i| report << i }
|
13
|
+
report.save('totals_report.xlsx')
|
14
|
+
end
|
15
|
+
|
16
|
+
|
data/lib/axlsx_report/base.rb
CHANGED
data/lib/axlsx_report/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: axlsx_report
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexey Volochnev
|
@@ -104,6 +104,7 @@ files:
|
|
104
104
|
- examples/base_report.rb
|
105
105
|
- examples/group_report.rb
|
106
106
|
- examples/lambda_report.rb
|
107
|
+
- examples/totals_report.rb
|
107
108
|
- examples/width_report.rb
|
108
109
|
- lib/axlsx_report.rb
|
109
110
|
- lib/axlsx_report/base.rb
|