thecore_download_documents 0.1.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/thecore_download_documents.rb +5 -7
- data/lib/thecore_download_documents/version.rb +1 -1
- metadata +17 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a4eecb36121272d878633dbd2117e60425b6dbd657dc5ba616f4b40455175e63
|
4
|
+
data.tar.gz: 8dbc901e30b61ec60d2f1e373c4bb48d6555e6985bcacd8a4f4a0adc030381c4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aaa70a53308467f33ae2f033bb64eb8d950a10721c1ccd44d4c47199bc613e7164656d7a4224dedf19d579c1e634cdc03ace4cfd648d25114597948e3c4db4ea
|
7
|
+
data.tar.gz: 6e00830657c00bd4a5079f2105562e547753f552b4d4388d0d47ac5d1d3d96e936dc567f07c20748d7178c65be1d7185cf970d35af5a29fbf7914605812cab2f
|
@@ -1,9 +1,9 @@
|
|
1
|
-
require
|
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,10 +42,8 @@ module ThecoreDownloadDocuments
|
|
42
42
|
|
43
43
|
def self.csv_table rows, table_headers, filename
|
44
44
|
csv = CSV.generate do |row|
|
45
|
-
|
46
|
-
|
47
|
-
rows.each do |r|
|
48
|
-
row << r.values
|
45
|
+
rows.unshift(table_headers).each do |data|
|
46
|
+
row << data
|
49
47
|
end
|
50
48
|
end
|
51
49
|
|
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.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriele Tassoni
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-11-03 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.
|
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.
|