sticutils 1.4.0 → 1.4.1

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
  SHA256:
3
- metadata.gz: 3407eeffb328dacf6769505456923db576f3be18b7741cb9a051504455764b40
4
- data.tar.gz: 47264381861cf5477e1aa1863227b7bbb5aa223441701fded41727321a3e0a55
3
+ metadata.gz: 46a9fe2516c0cda974638b2d5761309281c00642a6d2fbbe3296a482b048e797
4
+ data.tar.gz: 71aceffbd5aa1f9edf644da60b229b6c8eb408683ef4d3a4f8562217e20f4a71
5
5
  SHA512:
6
- metadata.gz: 9d42edd0652fae198ecb97fa7d3234ba0186ada044933df4321c85e6e5989bd111868d9f53f5b66e60ed45563e9868e0386dd1d90836a3f018dde587054fe7dd
7
- data.tar.gz: 3e61304e7405208a6508baa199a716fa5473f69884f4eb8b33ffdf522ce73ccbe0aa75bf5944a5f237f84b739ea6f20f7b10ca70c2f67ab144f063dacf11814e
6
+ metadata.gz: e8e62b4fc05d5def3eb8d02429937b998f0ae030511a4550e118ec3e658c40953d8a21c0807f45dc7461e4eaad197480ef691f080989f969284971f6fd9ee80e
7
+ data.tar.gz: 83d44504eda2f709df81870df3a7800663abb81cb58dc8b34532f6dc8aada8cbb696ba55fe6b56bdc6f63e38a38379cf97f35a82d79c7e91b3cebfba5af209bb
@@ -3,10 +3,15 @@ class Intranet::GlobalPrepessoafisica < Intranet::IntranetRecord
3
3
 
4
4
  belongs_to :cidade_nascimento, :class_name => 'GlobalCidade', :foreign_key => :nascimentoCidade_id
5
5
  belongs_to :global_endereco, :class_name => 'GlobalEndereco', :foreign_key => :endereco_id
6
- belongs_to :global_cidade, :class_name => 'GlobalCidade', :foreign_key => :tituloEleitorCidade_id
6
+ belongs_to :cidade_titulo, :class_name => 'GlobalCidade', :foreign_key => :tituloEleitorCidade_id
7
7
  belongs_to :global_estado, :class_name => 'GlobalEstado', :foreign_key => :rgOrgaoExpedidorUF_sigla
8
- has_many :global_prepessoafisica_contasbancarias, :class_name => 'GlobalPrepessoafisicaContasbancaria'
9
- has_many :global_prepessoafisica_contatos, :class_name => 'GlobalPrepessoafisicaContato'
10
8
  has_many :tjpi_predependentes, :class_name => 'TjpiPredependente', foreign_key: :prePessoaFisica_id
11
- has_many :tjpi_previnculados, :class_name => 'TjpiPrevinculado'
9
+
10
+ has_many :global_prepessoafisica_contasbancarias, class_name: 'GlobalPrepessoafisicaContasbancaria'
11
+ has_many :global_prepessoafisica_contatos, class_name: 'GlobalPrepessoafisicaContato', foreign_key: :pessoaFisica_id
12
+ has_many :global_contatos, through: :global_prepessoafisica_contatos
13
+
14
+ has_one :tjpi_previnculados, :class_name => 'TjpiPrevinculado', foreign_key: :prePessoaFisica_id
15
+ has_one :tjpi_vinculado, :class_name => 'TjpiPrevinculado', foreign_key: :prePessoaFisica_id
16
+ has_many :tjpi_vinculos, through: :tjpi_vinculado, source: :tjpi_vinculo_principal
12
17
  end
@@ -9,11 +9,18 @@ class Intranet::TjpiPrevinculado < Intranet::IntranetRecord
9
9
  has_many :tjpi_previnculado_manifestacoes, :class_name => 'TjpiPrevinculadoManifestaco'
10
10
  has_many :tjpi_previnculadopendencia, :class_name => 'TjpiPrevinculadopendencium'
11
11
  has_many :tjpi_previnculadopendencia, :class_name => 'TjpiPrevinculadopendencium'
12
- has_many :tjpi_vinculados, :class_name => 'TjpiVinculado'
13
- has_many :tjpi_vinculos, :class_name => 'TjpiVinculo'
12
+ # has_many :tjpi_vinculados, :class_name => 'TjpiVinculado'
13
+ # has_many :tjpi_vinculos, :class_name => 'TjpiVinculo'
14
+
15
+ belongs_to :tjpi_vinculo_principal, :class_name => 'TjpiVinculo', foreign_key: :vinculoPrincipal_id
16
+ belongs_to :tjpi_vinculo, :class_name => 'TjpiVinculo', foreign_key: :vinculoPrincipal_id
14
17
 
15
18
  has_many :tjpi_previnculado_declaracoes, class_name: 'TjpiPrevinculadoDeclaracao', foreign_key: :preVinculado_id
16
19
  belongs_to :tjpi_previnculadointervencao_ultima, class_name: 'TjpiPrevinculadointervencao', foreign_key: :intervencao_id
17
20
  belongs_to :tjpi_previnculadointervencao_anterior, class_name: 'TjpiPrevinculadointervencao', foreign_key: :anterior_id
18
21
  has_many :tjpi_previnculadointervencoes, class_name: 'TjpiPrevinculadointervencao', foreign_key: :preVinculado_id
22
+
23
+ def tjpi_vinculos
24
+ [self.tjpi_vinculo_principal]
25
+ end
19
26
  end
@@ -1,3 +1,3 @@
1
1
  module Sticutils
2
- VERSION = "1.4.0"
2
+ VERSION = "1.4.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sticutils
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ricardo Viana
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-10-22 00:00:00.000000000 Z
11
+ date: 2022-01-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails