thecore_download_documents 0.1.0 → 2.0.1
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 +46 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 95b27856cf732b4242d097fffe74944e6309b5484017ebbadb3ba5475e5120e4
|
4
|
+
data.tar.gz: bb3bafc279f639fa2b891176be9855eb55c1dcf2435af2e590fe381fb4e3237d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ff2cfb25b34973df1abc3bd58893b97ba48aec1bff1be339e3d1a03009edd0600043f564808260423f61da110d7ff1252636a99d91252fa2b00f9fdb5fdc6f1e
|
7
|
+
data.tar.gz: fac793c5478b668aec80e9395b29f7aa7424c72157073697b4bc201963394168db11b886db6fdd7ee14281e4605799bb59028be12c4b040624d97f946f0b499e
|
@@ -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,57 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: thecore_download_documents
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriele Tassoni
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
12
|
-
dependencies:
|
11
|
+
date: 2020-10-06 00:00:00.000000000 Z
|
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'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: prawn
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '2.2'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '2.2'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: prawn-table
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0.2'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0.2'
|
13
55
|
description: Some helper methods to create pdfs and csvs ina a simple, tabellar notation.
|
14
56
|
for PDF you can also add an header and a footer to each page.
|
15
57
|
email:
|
@@ -44,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
44
86
|
- !ruby/object:Gem::Version
|
45
87
|
version: '0'
|
46
88
|
requirements: []
|
47
|
-
rubygems_version: 3.0.
|
89
|
+
rubygems_version: 3.0.3
|
48
90
|
signing_key:
|
49
91
|
specification_version: 4
|
50
92
|
summary: Common methods to help exporting to csv, pdf documents.
|