thecore_download_documents 0.1.2 → 2.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ed734a25143470eb58eb8d4689d0e496318e87d1f1ded838027b3240f4b6ac8b
4
- data.tar.gz: 4b2f7d00c1a402282038188d166cbf60ca9ae9f8e9a55e227b49814afafbc7ae
3
+ metadata.gz: 6fc91166f729b2f004d2d881cb26067bd621591ba858bad29ca5df386689cb14
4
+ data.tar.gz: f32140d8376d4a4c7d10d0a8158760491ee3eab14361c9c2254d522fb70c0363
5
5
  SHA512:
6
- metadata.gz: fe5fc98d2223e47773ef2be8b732794b21855c08b3b98781bca9180573a69f75fe7d2e2208b8afebc870209527b2dcb2dfd184ef4528c7716b11c238cd54e4aa
7
- data.tar.gz: '08b507e08f8c6fee494b1093dfaa0d450e5c9f1246cc8da69eb0a5d17232fa3a0c320d4b5b46a9ff22e95241f796d7b356d36c5b832ab7e06e3db4fb86b4e507'
6
+ metadata.gz: b6a912311f857bf6f603fb4035973159fe117f695b329914b34a4581bbdf6b22131c2fdfe6cfd9e8f130c74f9855669f811755d56141348ce72f07362bb371dc
7
+ data.tar.gz: f4655cab22dae3093ddb5c29e23c1b96e55a6af0ac6b8803279f33ccc9fd9c1f65e13cdf0fb245fbb1199863e82e5a94c47f7862d778a4dc3e1b48a35d7ef411
@@ -1,9 +1,9 @@
1
- require "thecore_download_documents/railtie"
2
-
3
- require 'thecore'
1
+ require 'thecore_ui_rails_admin'
4
2
  require "prawn"
5
3
  require "prawn/table"
6
4
  require 'csv'
5
+ require "thecore_download_documents/railtie"
6
+
7
7
  module ThecoreDownloadDocuments
8
8
  # Your code goes here...
9
9
  def self.pdf_table header, footer, rows, table_headers, filename
@@ -42,9 +42,8 @@ module ThecoreDownloadDocuments
42
42
 
43
43
  def self.csv_table rows, table_headers, filename
44
44
  csv = CSV.generate do |row|
45
- row << table_headers
46
- rows.each do |r|
47
- row << r.values
45
+ rows.unshift(table_headers).each do |data|
46
+ row << data
48
47
  end
49
48
  end
50
49
 
@@ -1,3 +1,3 @@
1
1
  module ThecoreDownloadDocuments
2
- VERSION = '0.1.2'
2
+ VERSION = "#{`git describe --tags $(git rev-list --tags --max-count=1)`}"
3
3
  end
metadata CHANGED
@@ -1,15 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thecore_download_documents
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 2.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gabriele Tassoni
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-25 00:00:00.000000000 Z
11
+ date: 2021-01-26 00:00:00.000000000 Z
12
12
  dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: thecore_ui_commons
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '2.0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '2.0'
13
27
  - !ruby/object:Gem::Dependency
14
28
  name: prawn
15
29
  requirement: !ruby/object:Gem::Requirement
@@ -72,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
72
86
  - !ruby/object:Gem::Version
73
87
  version: '0'
74
88
  requirements: []
75
- rubygems_version: 3.0.6
89
+ rubygems_version: 3.0.3
76
90
  signing_key:
77
91
  specification_version: 4
78
92
  summary: Common methods to help exporting to csv, pdf documents.