cnpq_ws 0.0.7 → 0.0.8

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
  SHA1:
3
- metadata.gz: 933469b3dfb0ce652872f2b1a31a6c20fb2189eb
4
- data.tar.gz: 18003c5d5f618da44488738a242eae0bae608136
3
+ metadata.gz: a3f85f4b6d04cf125d00e18501c060e5895aa30a
4
+ data.tar.gz: 8af0be67c06b1bf65f0417d003a320fb3a93c8f7
5
5
  SHA512:
6
- metadata.gz: 52f287245affa3f27de38fbec720bdafd462e18287f040266922de33b50e4484c94b467f07b847d01248f2c5de7ee01bbb573d16d90d509aec2e40924cadae79
7
- data.tar.gz: 52134bb76b14cadfae8ff47a816d5678446ad6cda3ee31013c40407a2bd74dff5da34ea462948fbb5fa28e45d7943c6f36fe6d0ab47d98ca0934af3cf2e64be9
6
+ metadata.gz: 57137d71a40a72887a74f3cda4b3373315935e3c655ded779605ed89c952e0fd1d8c61e9fe448e337f6d57ce6d18f673bf59ff43f9cbf085c579d6e9da69ece7
7
+ data.tar.gz: d9ff0c04ff8749e595e09dd683b0fb2d9294ca4c9818f3784f5dc0644c07533bba3f7e31b089376a33464226ed40afa7e80d57a6f58ae24389b8eaf1805dd11c
data/README.md CHANGED
@@ -7,7 +7,7 @@ Gem de apoio a respostas do serviço web CPNq (Apenas Currículos). Para esta ve
7
7
  ### 1. Adicione no Gemfile:
8
8
 
9
9
  ```ruby
10
- gem 'cnpq_ws', '~> 0.0.7'
10
+ gem 'cnpq_ws', '~> 0.0.8'
11
11
  ```
12
12
 
13
13
  ### 2. execute:
data/cnpq_ws.gemspec CHANGED
@@ -21,6 +21,6 @@ Gem::Specification.new do |spec|
21
21
  spec.add_development_dependency "bundler", "~> 1.7"
22
22
  spec.add_development_dependency "rake", "~> 10.0"
23
23
 
24
- spec.add_runtime_dependency 'rubyzip', '~> 1.1', '>= 1.1.7'
25
- spec.add_runtime_dependency 'savon', '~> 2.10', '>= 2.10.1'
24
+ spec.add_dependency 'rubyzip', '~> 1.1.7'
25
+ spec.add_dependency 'savon', '~> 2.10.1'
26
26
  end
@@ -1,5 +1,6 @@
1
1
  require 'zip'
2
2
  require "cnpq_ws/projeto_pesquisa"
3
+ require 'savon'
3
4
 
4
5
  module CnpqWs
5
6
  module CurriculoLattes
@@ -34,13 +35,21 @@ module CnpqWs
34
35
 
35
36
  def get_curriculo_compactado
36
37
  client = Savon.client(endpoint: CnpqWs.curriculo_end_point, wsdl: CnpqWs.curriculo_wsdl, ssl_verify_mode: :none)
37
- response = client.call(:get_curriculo_compactado, message: {id: get_identificador_cn_pq})
38
- response.body[:get_curriculo_compactado_response][:return]
38
+ begin
39
+ response = client.call(:get_curriculo_compactado, message: {id: get_identificador_cn_pq})
40
+ response.body[:get_curriculo_compactado_response][:return]
41
+ rescue Exception => e
42
+ return e
43
+ end
39
44
  end
40
45
 
41
46
  def get_curriculo_compactado_por_usuario
42
47
  client = Savon.client(endpoint: CnpqWs.curriculo_end_point, wsdl: CnpqWs.curriculo_wsdl, ssl_verify_mode: :none)
43
- client.call(:get_curriculo_compactado_por_usuario, message: {id: get_identificador_cn_pq, login: CnpqWs.cnpq_login})
48
+ begin
49
+ client.call(:get_curriculo_compactado_por_usuario, message: {id: get_identificador_cn_pq, login: CnpqWs.cnpq_login})
50
+ rescue Exception => e
51
+ return e
52
+ end
44
53
  end
45
54
 
46
55
  def get_data_atualizacao_cv
@@ -52,8 +61,12 @@ module CnpqWs
52
61
 
53
62
  def get_identificador_cn_pq
54
63
  client = Savon.client(endpoint: CnpqWs.curriculo_end_point, wsdl: CnpqWs.curriculo_wsdl, ssl_verify_mode: :none)
55
- response = client.call(:get_identificador_cn_pq, message: {cpf: self.login, nomeCompleto: self.name, dataNascimento: self.birth_date})
56
- response.body[:get_identificador_cn_pq_response][:return]
64
+ begin
65
+ response = client.call(:get_identificador_cn_pq, message: {cpf: self.login, nomeCompleto: self.name, dataNascimento: self.birth_date})
66
+ response.body[:get_identificador_cn_pq_response][:return]
67
+ rescue Exception => e
68
+ return e
69
+ end
57
70
  end
58
71
 
59
72
  def get_identificador_cn_pq_por_usuario
@@ -1,3 +1,3 @@
1
1
  module CnpqWs
2
- VERSION = "0.0.7"
2
+ VERSION = "0.0.8"
3
3
  end
metadata CHANGED
@@ -1,81 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cnpq_ws
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.7
4
+ version: 0.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Renato Carvalho de Souza
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-20 00:00:00.000000000 Z
11
+ date: 2015-03-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ~>
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.7'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ~>
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.7'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
31
+ - - ~>
32
32
  - !ruby/object:Gem::Version
33
33
  version: '10.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ~>
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rubyzip
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: '1.1'
48
- - - ">="
45
+ - - ~>
49
46
  - !ruby/object:Gem::Version
50
47
  version: 1.1.7
51
48
  type: :runtime
52
49
  prerelease: false
53
50
  version_requirements: !ruby/object:Gem::Requirement
54
51
  requirements:
55
- - - "~>"
56
- - !ruby/object:Gem::Version
57
- version: '1.1'
58
- - - ">="
52
+ - - ~>
59
53
  - !ruby/object:Gem::Version
60
54
  version: 1.1.7
61
55
  - !ruby/object:Gem::Dependency
62
56
  name: savon
63
57
  requirement: !ruby/object:Gem::Requirement
64
58
  requirements:
65
- - - "~>"
66
- - !ruby/object:Gem::Version
67
- version: '2.10'
68
- - - ">="
59
+ - - ~>
69
60
  - !ruby/object:Gem::Version
70
61
  version: 2.10.1
71
62
  type: :runtime
72
63
  prerelease: false
73
64
  version_requirements: !ruby/object:Gem::Requirement
74
65
  requirements:
75
- - - "~>"
76
- - !ruby/object:Gem::Version
77
- version: '2.10'
78
- - - ">="
66
+ - - ~>
79
67
  - !ruby/object:Gem::Version
80
68
  version: 2.10.1
81
69
  description: Write a longer description. Optional.
@@ -85,7 +73,7 @@ executables: []
85
73
  extensions: []
86
74
  extra_rdoc_files: []
87
75
  files:
88
- - ".gitignore"
76
+ - .gitignore
89
77
  - Gemfile
90
78
  - LICENSE.txt
91
79
  - README.md
@@ -110,17 +98,17 @@ require_paths:
110
98
  - lib
111
99
  required_ruby_version: !ruby/object:Gem::Requirement
112
100
  requirements:
113
- - - ">="
101
+ - - '>='
114
102
  - !ruby/object:Gem::Version
115
103
  version: '0'
116
104
  required_rubygems_version: !ruby/object:Gem::Requirement
117
105
  requirements:
118
- - - ">="
106
+ - - '>='
119
107
  - !ruby/object:Gem::Version
120
108
  version: '0'
121
109
  requirements: []
122
110
  rubyforge_project:
123
- rubygems_version: 2.4.3
111
+ rubygems_version: 2.2.2
124
112
  signing_key:
125
113
  specification_version: 4
126
114
  summary: Gem de suporte a respostas do serviço web do CNPq.