teodoro 0.66.0 → 0.67.1
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/lib/teodoro/arquivo_xml.rb +2 -0
- data/lib/teodoro/leiaute/arquivo_s2230.rb +11 -6
- data/lib/teodoro/leiaute/arquivo_s2298.rb +62 -0
- data/lib/teodoro/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dd434d937c342ccebfd1946cbce175d3f752f2084dfeb3e6c55af824f3000942
|
4
|
+
data.tar.gz: 731f94e39d2a467522b5d57f3711261e5fa9897ff34c47fbf076f3b3f2d5aa45
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a89cfe230bde7f4ba322bb9c4c47d250cdaac3ab785d19807fdaf11a774e9653ceffa0efeca065b47aa7bd185c49ffcfcfd01f56b9a188b2a4d7cbc8bf99eabc
|
7
|
+
data.tar.gz: 78b3cea554caf9c3f01c7dee1af176ad3e84a784f5c3892a8fdfabc6ce24abeb0512b75ece47ab766fda9e8c4f1c59209a0c4b85f0c32b7428897667982d4050
|
data/lib/teodoro/arquivo_xml.rb
CHANGED
@@ -23,6 +23,7 @@ require_relative 'leiaute/arquivo_s2220'
|
|
23
23
|
require_relative 'leiaute/arquivo_s2230'
|
24
24
|
require_relative 'leiaute/arquivo_s2240'
|
25
25
|
require_relative 'leiaute/arquivo_s2250'
|
26
|
+
require_relative 'leiaute/arquivo_s2298'
|
26
27
|
require_relative 'leiaute/arquivo_s2299'
|
27
28
|
require_relative 'leiaute/arquivo_s2300'
|
28
29
|
require_relative 'leiaute/arquivo_s2306'
|
@@ -55,6 +56,7 @@ module Teodoro
|
|
55
56
|
S2230
|
56
57
|
S2240
|
57
58
|
S2250
|
59
|
+
S2298
|
58
60
|
S2299
|
59
61
|
S2300
|
60
62
|
S2306
|
@@ -74,17 +74,17 @@ module Teodoro
|
|
74
74
|
end
|
75
75
|
|
76
76
|
def empregado?
|
77
|
-
|
78
|
-
end
|
79
|
-
|
80
|
-
def matricula_do_trabalhador
|
81
|
-
@matricula_do_trabalhador ||= evento['ideVinculo/matricula']
|
77
|
+
contrato_de_emprego
|
82
78
|
end
|
83
79
|
|
84
80
|
def contrato_de_emprego
|
85
81
|
@contrato_de_emprego ||= contratos_de_emprego[matricula_do_trabalhador]
|
86
82
|
end
|
87
83
|
|
84
|
+
def matricula_do_trabalhador
|
85
|
+
@matricula_do_trabalhador ||= evento['ideVinculo/matricula']
|
86
|
+
end
|
87
|
+
|
88
88
|
def contratos_de_emprego
|
89
89
|
empresa.contratos_de_emprego
|
90
90
|
end
|
@@ -176,7 +176,12 @@ module Teodoro
|
|
176
176
|
end
|
177
177
|
|
178
178
|
def nome_do_arquivo_data_identif_do_tsv
|
179
|
-
|
179
|
+
[
|
180
|
+
'TSV',
|
181
|
+
contrato_de_trabalho_sem_vinculo.categoria_do_trabalhador,
|
182
|
+
data_de_inicio_do_contrato_de_trabalho.delete('-'),
|
183
|
+
*matricula_do_trabalhador
|
184
|
+
].join('_')
|
180
185
|
end
|
181
186
|
|
182
187
|
def data_de_inicio_do_contrato_de_trabalho
|
@@ -0,0 +1,62 @@
|
|
1
|
+
module Teodoro
|
2
|
+
module Leiaute
|
3
|
+
class ArquivoS2298
|
4
|
+
include ArquivoDeEventoNaoPeriodicoNaoCancelavel
|
5
|
+
|
6
|
+
private
|
7
|
+
|
8
|
+
def dados_dos_arquivos_data # rubocop:disable Metrics/MethodLength, Metrics/AbcSize
|
9
|
+
[
|
10
|
+
Obj.new(
|
11
|
+
operacao: :inclusao,
|
12
|
+
nome: [
|
13
|
+
'TRA',
|
14
|
+
"[#{cpf_do_trabalhador}]",
|
15
|
+
"[EPG_#{matricula_do_trabalhador}_#{data_de_admissao.delete('-')}]",
|
16
|
+
'-',
|
17
|
+
"REI[#{data_do_efetivo_retorno.delete('-')}]"
|
18
|
+
].join,
|
19
|
+
itens_do_conteudo: [
|
20
|
+
['IdeVinculo_Cpf', cpf_do_trabalhador],
|
21
|
+
['IdeVinculo_Matricula', matricula_do_trabalhador],
|
22
|
+
['TipoReintegracao', evento['infoReintegr/tpReint']],
|
23
|
+
['DataEfetivoRetorno', data_do_efetivo_retorno, :data],
|
24
|
+
['DataEfeito', evento['infoReintegr/dtEfeito'], :data],
|
25
|
+
['IdEventoXml', id_do_evento],
|
26
|
+
['NrReciboEventoOriginal', numero_do_recibo],
|
27
|
+
['VerProc', versao_do_processo_de_emissao_do_evento],
|
28
|
+
['ESX_CPF', cpf_do_trabalhador],
|
29
|
+
['ESX_MATRICULA', matricula_do_trabalhador],
|
30
|
+
['ESX_DATAADMISSAO', data_de_admissao.delete('-')],
|
31
|
+
['NumeroProcessoJudicial', evento['infoReintegr/nrProcJud']]
|
32
|
+
]
|
33
|
+
)
|
34
|
+
]
|
35
|
+
end
|
36
|
+
|
37
|
+
def cpf_do_trabalhador
|
38
|
+
@cpf_do_trabalhador ||= evento['ideVinculo/cpfTrab']
|
39
|
+
end
|
40
|
+
|
41
|
+
def matricula_do_trabalhador
|
42
|
+
@matricula_do_trabalhador ||= evento['ideVinculo/matricula']
|
43
|
+
end
|
44
|
+
|
45
|
+
def data_de_admissao
|
46
|
+
contrato_de_emprego.data_de_admissao
|
47
|
+
end
|
48
|
+
|
49
|
+
def contrato_de_emprego
|
50
|
+
@contrato_de_emprego ||= contratos_de_emprego[matricula_do_trabalhador]
|
51
|
+
end
|
52
|
+
|
53
|
+
def contratos_de_emprego
|
54
|
+
empresa.contratos_de_emprego
|
55
|
+
end
|
56
|
+
|
57
|
+
def data_do_efetivo_retorno
|
58
|
+
evento['infoReintegr/dtEfetRetorno']
|
59
|
+
end
|
60
|
+
end
|
61
|
+
end
|
62
|
+
end
|
data/lib/teodoro/version.rb
CHANGED
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.
|
4
|
+
version: 0.67.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fortes Tecnologia
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-02-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -118,6 +118,7 @@ files:
|
|
118
118
|
- lib/teodoro/leiaute/arquivo_s2230.rb
|
119
119
|
- lib/teodoro/leiaute/arquivo_s2240.rb
|
120
120
|
- lib/teodoro/leiaute/arquivo_s2250.rb
|
121
|
+
- lib/teodoro/leiaute/arquivo_s2298.rb
|
121
122
|
- lib/teodoro/leiaute/arquivo_s2299.rb
|
122
123
|
- lib/teodoro/leiaute/arquivo_s2300.rb
|
123
124
|
- lib/teodoro/leiaute/arquivo_s2306.rb
|