teodoro 0.47.3 → 0.47.6

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
  SHA256:
3
- metadata.gz: 4ecaf85c64ac4f15c382e55b9eb6200297237d33a460c983bc77ad2df9e7a11e
4
- data.tar.gz: 03cf6186d6f652604f35073806d07d47ce2d4e50c962b590c4621e726c7371fb
3
+ metadata.gz: fa5e2e0addc5cb7a29360fbf85213f4c431612016d6c52e38a9e3dff9153bbfb
4
+ data.tar.gz: bbea454a6e236bcccd8b67abe44deb0d9bbb35a4054eca11b04d55d6780a99d8
5
5
  SHA512:
6
- metadata.gz: df807dc609c9cd3a42171eba8364b1fa045f173135703af391dccd751bc00f5c13d29996e0b582940f5250a86d224e45c1743b7dc70f2268eb90b1b4e87b9004
7
- data.tar.gz: 0b877be7010a912dcbc5676e3136640184761c4d0643fdba67c2c96491ed8251969c7780632eb1098e36589b5627a1ac39af4aca3c311cce352ec93e8d987818
6
+ metadata.gz: cd652d20d5a15cb2c952784eadfe903c75cfb23cebef6f0e573a65e886623932f034d245c0dd1b5a9288d6d32d5679c9a2f89eb0f23b7fbc9b0f123afeed2bee
7
+ data.tar.gz: c3b8b0692eace8f887cafcc077836522d485d92041025190c350af5737e4703b4934ce9c29c9b624d5bab60df1a21c49ecad6dc2f53bdeba4aea9ad99c913274
@@ -59,15 +59,9 @@ module Teodoro
59
59
  @to_str ||=
60
60
  File.join(
61
61
  diretorio,
62
- "#{windows? ? nome_do_arquivo.to_s.gsub(%r{[<|>:"/\\?*]}, '_') : nome_do_arquivo}.data"
62
+ "#{nome_do_arquivo.to_s.gsub(%r{[<|>:"/\\?*]}, '_')}.data"
63
63
  )
64
64
  end
65
-
66
- private
67
-
68
- def windows?
69
- OS.windows?
70
- end
71
65
  end
72
66
 
73
67
  class Valor
@@ -114,7 +114,10 @@ module Teodoro
114
114
  private
115
115
 
116
116
  def nome_base_do_arquivo_data
117
- identificacao[0] + identificacao[1..].map { "[#{_1}]" }.join
117
+ identificacao[0] + identificacao[1..].map { "[#{_1}]" }
118
+ .join
119
+ .tr('àáäâãèéëẽêìíïîĩòóöôõùúüûũñç'.then{_1 + _1.upcase},
120
+ 'aaaaaeeeeeiiiiiooooouuuuunc'.then{_1 + _1.upcase})
118
121
  end
119
122
  end
120
123
  end
@@ -178,6 +178,7 @@ module Teodoro
178
178
  ['dataAdmissao', data_de_admissao, :data],
179
179
  ['InformacoesCeletista_TipoRegimeJornada', evento['altContratual/vinculo/infoRegimeTrab/infoCeletista/tpRegJor']],
180
180
  ['InformacoesCeletista_NaturezaAtividade', alteracao_contratual.natureza_da_atividade],
181
+ ['InformacoesCeletista_CnpjSindicatoCategoriaProfissional', evento['altContratual/vinculo/infoRegimeTrab/infoCeletista/cnpjSindCategProf']],
181
182
  ['DescricaoProcEmi', processo_de_emissao_do_evento],
182
183
  ['VerProc', versao_do_processo_de_emissao_do_evento],
183
184
  ['InformacoesContrato_Remuneracao_UnidadeSalarioFixo', evento['altContratual/vinculo/infoContrato/remuneracao/undSalFixo']],
@@ -8,7 +8,7 @@ module Teodoro
8
8
  def dados_dos_arquivos_data
9
9
  [
10
10
  Obj.new(
11
- nome: "CAT_#{numero_do_recibo}",
11
+ nome: "CAT[#{cpf_trab}][#{matricula}][#{dt_acid.delete('-')}]_#{numero_do_recibo}",
12
12
  itens_do_conteudo: itens_do_conteudo
13
13
  )
14
14
  ]
@@ -21,10 +21,10 @@ module Teodoro
21
21
  ['verProc', versao_do_processo_de_emissao_do_evento],
22
22
  ['ideEmpregador/tpInsc', tipo_de_inscricao_do_empregador],
23
23
  ['ideEmpregador/nrInsc', numero_de_inscricao_do_empregador],
24
- ['cpfTrab', evento['ideVinculo/cpfTrab']],
25
- ['matricula', evento['ideVinculo/matricula']],
24
+ ['cpfTrab', cpf_trab],
25
+ ['matricula', matricula],
26
26
  ['codCateg', evento['ideVinculo/codCateg']],
27
- ['dtAcid', evento['cat/dtAcid']],
27
+ ['dtAcid', dt_acid],
28
28
  ['tpAcid', evento['cat/tpAcid']],
29
29
  ['hrAcid', evento['cat/hrAcid']],
30
30
  ['hrsTrabAntesAcid', evento['cat/hrsTrabAntesAcid']],
@@ -70,6 +70,18 @@ module Teodoro
70
70
  ['nrRecibo', numero_do_recibo]
71
71
  ]
72
72
  end
73
+
74
+ def cpf_trab
75
+ @cpf_trab ||= evento['ideVinculo/cpfTrab']
76
+ end
77
+
78
+ def matricula
79
+ @matricula ||= evento['ideVinculo/matricula']
80
+ end
81
+
82
+ def dt_acid
83
+ @dt_acid ||= evento['cat/dtAcid']
84
+ end
73
85
  end
74
86
  end
75
87
  end
@@ -8,7 +8,7 @@ module Teodoro
8
8
  def dados_dos_arquivos_data
9
9
  [
10
10
  Obj.new(
11
- nome: "ASO_#{numero_do_recibo}",
11
+ nome: "ASO[#{cpf_trab}][#{matricula}][#{dt_aso.delete('-')}]_#{numero_do_recibo}",
12
12
  itens_do_conteudo: itens_do_conteudo
13
13
  )
14
14
  ]
@@ -21,11 +21,11 @@ module Teodoro
21
21
  ['verProc', versao_do_processo_de_emissao_do_evento],
22
22
  ['ideEmpregador/tpInsc', tipo_de_inscricao_do_empregador],
23
23
  ['ideEmpregador/nrInsc', numero_de_inscricao_do_empregador],
24
- ['cpfTrab', evento['ideVinculo/cpfTrab']],
25
- ['matricula', evento['ideVinculo/matricula']],
24
+ ['cpfTrab', cpf_trab],
25
+ ['matricula', matricula],
26
26
  ['codCateg', evento['ideVinculo/codCateg']],
27
27
  ['tpExameOcup', evento['exMedOcup/tpExameOcup']],
28
- ['dtAso', evento['exMedOcup/aso/dtAso']],
28
+ ['dtAso', dt_aso],
29
29
  ['resAso', evento['exMedOcup/aso/resAso']],
30
30
  *evento.*('exMedOcup/aso/exame').map.with_index(1) do |exame, seq|
31
31
  [
@@ -46,6 +46,18 @@ module Teodoro
46
46
  ['nrRecibo', numero_do_recibo]
47
47
  ]
48
48
  end
49
+
50
+ def cpf_trab
51
+ @cpf_trab ||= evento['ideVinculo/cpfTrab']
52
+ end
53
+
54
+ def matricula
55
+ @matricula ||= evento['ideVinculo/matricula']
56
+ end
57
+
58
+ def dt_aso
59
+ @dt_aso ||= evento['exMedOcup/aso/dtAso']
60
+ end
49
61
  end
50
62
  end
51
63
  end
@@ -8,7 +8,7 @@ module Teodoro
8
8
  def dados_dos_arquivos_data
9
9
  [
10
10
  Obj.new(
11
- nome: "AMB_#{numero_do_recibo}",
11
+ nome: "AMB[#{cpf_trab}][#{matricula}][#{dt_ini_condicao.delete('-')}]_#{numero_do_recibo}",
12
12
  itens_do_conteudo: itens_do_conteudo
13
13
  )
14
14
  ]
@@ -21,10 +21,10 @@ module Teodoro
21
21
  ['verProc', versao_do_processo_de_emissao_do_evento],
22
22
  ['ideEmpregador/tpInsc', tipo_de_inscricao_do_empregador],
23
23
  ['ideEmpregador/nrInsc', numero_de_inscricao_do_empregador],
24
- ['cpfTrab', evento['ideVinculo/cpfTrab']],
25
- ['matricula', evento['ideVinculo/matricula']],
24
+ ['cpfTrab', cpf_trab],
25
+ ['matricula', matricula],
26
26
  ['codCateg', evento['ideVinculo/codCateg']],
27
- ['dtIniCondicao', evento['infoExpRisco/dtIniCondicao']],
27
+ ['dtIniCondicao', dt_ini_condicao],
28
28
  ['localAmb', evento['infoExpRisco/infoAmb/localAmb']],
29
29
  ['dscSetor', evento['infoExpRisco/infoAmb/dscSetor']],
30
30
  ['infoAmb/tpInsc', evento['infoExpRisco/infoAmb/tpInsc']],
@@ -70,6 +70,18 @@ module Teodoro
70
70
  ['nrRecibo', numero_do_recibo]
71
71
  ]
72
72
  end
73
+
74
+ def cpf_trab
75
+ @cpf_trab ||= evento['ideVinculo/cpfTrab']
76
+ end
77
+
78
+ def matricula
79
+ @matricula ||= evento['ideVinculo/matricula']
80
+ end
81
+
82
+ def dt_ini_condicao
83
+ @dt_ini_condicao ||= evento['infoExpRisco/dtIniCondicao']
84
+ end
73
85
  end
74
86
  end
75
87
  end
@@ -1,3 +1,3 @@
1
1
  module Teodoro
2
- VERSION = '0.47.3'.freeze
2
+ VERSION = '0.47.6'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: teodoro
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.47.3
4
+ version: 0.47.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fortes Tecnologia
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-04-13 00:00:00.000000000 Z
11
+ date: 2022-05-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri