lecca_client 0.3.0 → 0.4.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 90837fd2aa51b821a7c035c0c87ff97f700fd9c9
4
- data.tar.gz: 9792b07d23fd78ac57710c4faeaf1a4ded849fa5
3
+ metadata.gz: 7aff0f48ab6de57b07f429177fc40e12aada8928
4
+ data.tar.gz: 42ce52fbca25d1124f7ce4178fe811baf7a1b649
5
5
  SHA512:
6
- metadata.gz: d1f6de097a7d89ce2e1f4a01338285d1d09cc4e410579faccc1b62692d88cb09d2ab68a3880a2ea7886e83a4b0958090058b2e9961a183dec7e9265d1559bd26
7
- data.tar.gz: 509d20847c885bc017f05b2e4d70783f98a55bc956ced8ee2151cded21ceb5a2574be0eefdc1b9bf6b7468530ed0a1653ff2e5ef8befdaecb7e627f87dc64c00
6
+ metadata.gz: 145bf902d9dc1b51dc03a66c6c42ce27708a12c48e51fb22cd6e0fc69765e2a8696681e679f193c4341c658b242ac56ff22e330d7d74e4cfeabc12fabf1363ff
7
+ data.tar.gz: 6ebec4cd9f7425115055e34b3db824bb9b2127c6534a57306ab69f98706cd8b60287f35a21c6d671b73ec0c7a30629b38b4d5cad89599c0c34a430ab22ea2927
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## 0.4.0
4
+
5
+ * Add fund part in proposal file
6
+
3
7
  ## 0.3.0
4
8
 
5
9
  * Remove useless time.zone config
@@ -9,9 +9,10 @@ module LeccaClient
9
9
  property :telefone, coerce: Phone, required: true
10
10
  property :emprego, coerce: Job, required: true
11
11
  property :conta_bancaria, coerce: BankAccount , required: true
12
+ property :fundo, coerce: Fund, required: true
12
13
 
13
14
  def line
14
- [operacao, cliente, endereco, telefone, emprego, conta_bancaria].map(&:build).reduce(:+)
15
+ [operacao, cliente, endereco, telefone, emprego, conta_bancaria, fundo].map(&:build).reduce(:+)
15
16
  end
16
17
 
17
18
  def upload
@@ -0,0 +1,27 @@
1
+ module LeccaClient
2
+ module Proposal
3
+ class Fund < Hashie::Dash
4
+ include LeccaClient::Utils
5
+
6
+ property :rating
7
+ property :cnpj_conveniada, default: 0
8
+ property :cnpj_fundo, default: 0
9
+ property :nome_fundo, default: ''
10
+ property :banco, default: 0
11
+ property :agencia, default: ''
12
+ property :conta_corrente, default: ''
13
+
14
+ def build
15
+ parts = ''
16
+
17
+ parts << justify_string(rating, 2)
18
+ parts << justify_number(cnpj_conveniada, 14)
19
+ parts << justify_number(cnpj_fundo, 14)
20
+ parts << justify_string(nome_fundo, 40)
21
+ parts << justify_number(banco, 3)
22
+ parts << justify_string(agencia, 4)
23
+ parts << justify_string(conta_corrente, 8)
24
+ end
25
+ end
26
+ end
27
+ end
@@ -1,3 +1,3 @@
1
1
  module LeccaClient
2
- VERSION = "0.3.0"
2
+ VERSION = "0.4.0"
3
3
  end
data/lib/lecca_client.rb CHANGED
@@ -21,6 +21,7 @@ require 'lecca_client/proposal/phone'
21
21
  require 'lecca_client/proposal/address'
22
22
  require 'lecca_client/proposal/job'
23
23
  require 'lecca_client/proposal/bank_account'
24
+ require 'lecca_client/proposal/fund'
24
25
  require 'lecca_client/proposal/builder'
25
26
 
26
27
  require 'lecca_client/cnab/loan/parser'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lecca_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Noverde Team
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2016-09-30 00:00:00.000000000 Z
13
+ date: 2017-03-06 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: bundler
@@ -147,6 +147,7 @@ files:
147
147
  - lib/lecca_client/proposal/bank_account.rb
148
148
  - lib/lecca_client/proposal/builder.rb
149
149
  - lib/lecca_client/proposal/customer.rb
150
+ - lib/lecca_client/proposal/fund.rb
150
151
  - lib/lecca_client/proposal/job.rb
151
152
  - lib/lecca_client/proposal/operation.rb
152
153
  - lib/lecca_client/proposal/phone.rb