imasei 0.1.6 → 0.1.7
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 +4 -4
- data/README.md +2 -2
- data/bin/console +1 -1
- data/lib/imasei/estruturas/documento.rb +16 -3
- data/lib/imasei/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1416ee05354605149be4b5066a0b98839a1b04e4
|
4
|
+
data.tar.gz: 01288baa47645ae510d171d49f1ae9e77279053f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dcdfd4bebfc544b567eacb93a927c0d66f0000b5167517669dbf17b6a3a3874439eb6c65200ae4604c97b31936a3012f9d45092827488feecd0410839982899e
|
7
|
+
data.tar.gz: e7a8d32d2a327e52c2e66368002e9c76074e4eb92505cc3862f8e8bf225d94acbc7a56bcc09fb87fab267f08e52b499e32d73a7117d8dacbe3f86c06c30ffd12
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ Esta gem facilita o acesso ao webservice do SEI!. Ela possui a implementação d
|
|
7
7
|
Adicione esta linha no Gemfile da sua aplicação:
|
8
8
|
|
9
9
|
```ruby
|
10
|
-
gem '
|
10
|
+
gem 'imasei'
|
11
11
|
```
|
12
12
|
|
13
13
|
E execute:
|
@@ -16,7 +16,7 @@ E execute:
|
|
16
16
|
|
17
17
|
Ou instale através do seguinte comando:
|
18
18
|
|
19
|
-
$ gem install
|
19
|
+
$ gem install imasei
|
20
20
|
|
21
21
|
## Uso
|
22
22
|
|
data/bin/console
CHANGED
@@ -25,7 +25,8 @@ module Imasei
|
|
25
25
|
end
|
26
26
|
|
27
27
|
def data(data)
|
28
|
-
|
28
|
+
#@data = data.strftime('%d/%m/%Y') rescue nil
|
29
|
+
@data = data.to_datetime.strftime('%d/%m/%Y') rescue nil
|
29
30
|
self
|
30
31
|
end
|
31
32
|
|
@@ -72,15 +73,27 @@ module Imasei
|
|
72
73
|
end
|
73
74
|
|
74
75
|
def conteudo(conteudo)
|
75
|
-
|
76
|
+
if conteudo.nil?
|
77
|
+
conteudo = ''
|
78
|
+
end
|
79
|
+
if @tipo == 'R' && @conteudo_raw.present?
|
80
|
+
@conteudo = @conteudo_raw
|
81
|
+
else
|
82
|
+
@conteudo = Base64.strict_encode64(conteudo)
|
83
|
+
end
|
76
84
|
self
|
77
85
|
end
|
78
86
|
|
79
87
|
def conteudo_mtom(conteudo_mtom)
|
80
|
-
@conteudo_mtom = File.read(conteudo_mtom)
|
88
|
+
@conteudo_mtom = Base64.strict_encode64(File.read(conteudo_mtom))
|
81
89
|
self
|
82
90
|
end
|
83
91
|
|
92
|
+
def conteudo_raw(conteudo_raw)
|
93
|
+
@conteudo_raw = conteudo_raw
|
94
|
+
self
|
95
|
+
end
|
96
|
+
|
84
97
|
def nivel_de_acesso(nivel_de_acesso)
|
85
98
|
@nivel_de_acesso = nivel_de_acesso
|
86
99
|
self
|
data/lib/imasei/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: imasei
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexandre Soares feat Leandro Telles
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04
|
11
|
+
date: 2017-05-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|