ipiranga-inovai-project-lib 3.5__py3-none-any.whl → 3.7__py3-none-any.whl

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.
inovai/entities.py CHANGED
@@ -7,6 +7,7 @@ from sqlalchemy.orm import relationship
7
7
  Base = declarative_base()
8
8
  DATETIME_NOW = 'NOW()'
9
9
  INTEGRATION_BATCH_KEY = 'fiscal.lote_integracao.cd_integr'
10
+ BATCH_KEY = 'fiscal.lote.cd_seq_lote'
10
11
  OBI_KIT_KEY = 'fiscal.kit_obi.no_seq_kit'
11
12
 
12
13
 
@@ -206,6 +207,8 @@ class Batch(Base):
206
207
  last_date = Column('dt_fim', Date)
207
208
  status = Column('ds_safx_taxone', String(), nullable=False)
208
209
 
210
+ batch_processing = relationship('BatchProcessing', back_populates='batch')
211
+
209
212
  def __init__(self, batch_id, employer_number, first_date, last_date, status):
210
213
  super().__init__()
211
214
  self.batch_id = batch_id
@@ -334,6 +337,29 @@ class IntegrationProcessing(Base):
334
337
  self.created_at = datetime.now()
335
338
 
336
339
 
340
+ class BatchProcessing(Base):
341
+ __tablename__ = 'processamento_lote'
342
+ __table_args__ = {'schema': 'fiscal'}
343
+
344
+ batch_id = Column('no_seq_lote', Integer, ForeignKey(BATCH_KEY),
345
+ primary_key=True, nullable=False)
346
+ param_processing_kit_id = Column('no_seq_proc', Numeric(precision=8, scale=0),
347
+ ForeignKey('fiscal.param_processamento_kit.no_seq_proc'),
348
+ primary_key=True, nullable=False)
349
+ created_at = Column('dt_incl', DateTime, nullable=False)
350
+
351
+ batch = relationship('Batch', back_populates='batch_processing')
352
+ param_processing_kit = relationship(ParamProcessingKit,
353
+ primaryjoin="BatchProcessing.param_processing_kit_id == "
354
+ "ParamProcessingKit.param_processing_kit_id")
355
+
356
+ def __init__(self, batch_id, param_processing_kit_id):
357
+ super().__init__()
358
+ self.param_processing_kit_id = param_processing_kit_id
359
+ self.batch_id = batch_id
360
+ self.created_at = datetime.now()
361
+
362
+
337
363
  # @deprecated('Tabela "lote_documento_integracao" foi substituida pela tabela "lote_integracao_obi"')
338
364
  class IntegrationDocumentBatch(Base):
339
365
  __tablename__ = 'lote_documento_integracao'
inovai/enums.py CHANGED
@@ -11,9 +11,10 @@ class DataIntegrationStatus(Enum):
11
11
  PENDING_INTEGRATION = 'PENDENTE_INTEGRACAO'
12
12
  PROCESSING = 'PROCESSANDO'
13
13
  SENT = 'ENVIADO'
14
- INTEGRATED = 'INTEGRADO'
15
14
  CONVERTER_ERROR = 'ERRO_CONVERSAO'
15
+ VALIDATION_ERROR = 'ERRO_VALIDACAO'
16
16
  ERROR = "ERRO"
17
+ INTEGRATED = 'INTEGRADO'
17
18
 
18
19
 
19
20
  class BatchStatus(Enum):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ipiranga-inovai-project-lib
3
- Version: 3.5
3
+ Version: 3.7
4
4
  Summary: Projeto criado para importação genérica de entidades
5
5
  Home-page: https://gitlab.ipirangacloud.com/clayton.monteiro.ext/ipiranga-inovai-project-lib
6
6
  Author: Clayton Sandes Monteiro
@@ -1,7 +1,7 @@
1
1
  inovai/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  inovai/dtos.py,sha256=qaWZB7n5SHcC58RP351IQ1HLjv7fx3VAdILj-GugVWs,1587
3
- inovai/entities.py,sha256=XDRP9B1u4yILzwPGJyU94XZQ1iaOlVkzQ1r7O4oC5o4,19510
4
- inovai/enums.py,sha256=QvkbjJKKTkmgeNwwR33EfZDD6Bvr0fDqYUqdO8j5LRU,2326
3
+ inovai/entities.py,sha256=sf0bPQ4pxURWtgcHkTDK4_zVgYEPYGKZva4z2u4vuZg,20766
4
+ inovai/enums.py,sha256=M3-DaPs6154wR8OE1cUsnbMeJa3UteAUqT7G3lCDBmI,2367
5
5
  inovai/models/Endereco.py,sha256=Vft20vMwYwTXtEuh5NH7O5FxXVahnLmgaXMDOVdBxY4,3519
6
6
  inovai/models/NFe.py,sha256=3PiMvK6AODaagZU7KEpnjYfulz8PvcQYGChIa-QCvg0,13023
7
7
  inovai/models/NFeBoleto.py,sha256=tLWqsOlszA6UiJdxesJKQkgwNk_4DuI3NRBCYZh7RKc,5006
@@ -34,8 +34,8 @@ inovai/models/NFeVolume.py,sha256=_cayb-rrz1mSxQ3wFFnB4KCi524jtAsdTTcS4WQTBOc,19
34
34
  inovai/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
35
35
  inovai/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
36
36
  inovai/utils/util.py,sha256=tEFFoYhtyZk2pxor2vb23NWr3otPzPXTiTIf-VrGik4,366
37
- ipiranga_inovai_project_lib-3.5.dist-info/LICENSE,sha256=UJ3ql8eZec9Y1kER7QSHAuvdgFPuL47asePHYmdzG_o,198
38
- ipiranga_inovai_project_lib-3.5.dist-info/METADATA,sha256=r8dyI5a-8Z_FwH3NVzAXsg6TcFBxtnLgotRVU8l-ehU,518
39
- ipiranga_inovai_project_lib-3.5.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
40
- ipiranga_inovai_project_lib-3.5.dist-info/top_level.txt,sha256=BD-APH5oIEb_KDXwrfnZiu9QDsD9ttTEkYc32r9thqg,7
41
- ipiranga_inovai_project_lib-3.5.dist-info/RECORD,,
37
+ ipiranga_inovai_project_lib-3.7.dist-info/LICENSE,sha256=UJ3ql8eZec9Y1kER7QSHAuvdgFPuL47asePHYmdzG_o,198
38
+ ipiranga_inovai_project_lib-3.7.dist-info/METADATA,sha256=aTVABvhyIlrDHH7fDmwB_6X4Ng1jX_F9Rsox74K2_Ps,518
39
+ ipiranga_inovai_project_lib-3.7.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
40
+ ipiranga_inovai_project_lib-3.7.dist-info/top_level.txt,sha256=BD-APH5oIEb_KDXwrfnZiu9QDsD9ttTEkYc32r9thqg,7
41
+ ipiranga_inovai_project_lib-3.7.dist-info/RECORD,,