worker-automate-hub 0.5.329__py3-none-any.whl → 0.5.331__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.
@@ -2442,6 +2442,7 @@ async def devolucao_prazo_a_faturar(task: RpaProcessoEntradaDTO) -> RpaRetornoPr
2442
2442
  btn_no.click()
2443
2443
 
2444
2444
 
2445
+ await worker_sleep(7)
2445
2446
  erro_screen = await is_window_open_by_class("TFrmDadosFaturamentoPreVenda","Confirm")
2446
2447
  if erro_screen["IsOpened"] == True:
2447
2448
  console.print("Janela aberta, fechando")
@@ -2468,7 +2469,7 @@ async def devolucao_prazo_a_faturar(task: RpaProcessoEntradaDTO) -> RpaRetornoPr
2468
2469
  app = Application().connect(class_name="TMemo", timeout=10)
2469
2470
  main_window = app["TMemo"]
2470
2471
  main_window.set_focus()
2471
- await worker_sleep(2)
2472
+ await worker_sleep(5)
2472
2473
  main_window.close()
2473
2474
 
2474
2475
 
@@ -2487,7 +2488,7 @@ async def devolucao_prazo_a_faturar(task: RpaProcessoEntradaDTO) -> RpaRetornoPr
2487
2488
  btn_cancelar.click()
2488
2489
 
2489
2490
 
2490
- await worker_sleep(5)
2491
+ await worker_sleep(10)
2491
2492
  console.print("Verificando se a tela de Faturamento Pre venda esta aberta")
2492
2493
  close_dados_faturamento = await is_window_open_by_class("TFrmDadosFaturamentoPreVenda","TFrmDadosFaturamentoPreVenda")
2493
2494
  if close_dados_faturamento["IsOpened"] == True:
@@ -3314,7 +3315,7 @@ async def devolucao_prazo_a_faturar(task: RpaProcessoEntradaDTO) -> RpaRetornoPr
3314
3315
  tags=[RpaTagDTO(descricao=RpaTagEnum.Tecnico)]
3315
3316
  )
3316
3317
 
3317
-
3318
+
3318
3319
  #VERIFICANDO SE POSSUI POP UP WARNING
3319
3320
  console.print("Verificando a presença de Warning... \n")
3320
3321
  warning_boo = False
@@ -3603,57 +3604,43 @@ async def devolucao_prazo_a_faturar(task: RpaProcessoEntradaDTO) -> RpaRetornoPr
3603
3604
  else:
3604
3605
  console.print("Não possui warning para alterar tributação... \n")
3605
3606
 
3606
- try:
3607
- #Clcica no OK para seguir a transmissão da pré-venda
3608
- console.print("Clicando em ok para fatura pré-venda... \n")
3609
- app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=60)
3610
- main_window = app["TFrmDadosFaturamentoPreVenda"]
3611
- main_window.set_focus()
3612
- btn_ok = main_window.child_window(class_name="TBitBtn", found_index=1)
3613
- btn_ok.click()
3614
- except:
3615
- console.print("Clicando em OK no except... \n")
3616
- btn_ok = main_window.child_window(title="&Ok")
3617
- btn_ok.click()
3607
+ # try:
3608
+ # #Clcica no OK para seguir a transmissão da pré-venda
3609
+ # app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=60)
3610
+ # main_window = app["TFrmDadosFaturamentoPreVenda"]
3611
+ # main_window.set_focus()
3612
+ # btn_ok = main_window.child_window(class_name="TBitBtn", found_index=1)
3613
+ # btn_ok.click()
3614
+ # except:
3615
+ # btn_ok = main_window.child_window(title="&Ok")
3616
+ # btn_ok.click()
3617
+ # await worker_sleep(5)
3618
3618
 
3619
- await worker_sleep(5)
3620
-
3621
- try:
3622
- console.print("Clicando em sim para faturar pre-venda... \n")
3623
- app = Application().connect(class_name="TMessageForm", timeout=10, title="Confirm")
3624
- main_window = app["TMessageForm"]
3625
- main_window.set_focus()
3626
- main_window.chiwld_window(title="&Yes").click()
3627
- except:
3628
- ...
3629
-
3630
- #Lucas Fim
3631
- #ADICIONANDO MENSAGEM
3632
-
3619
+ #Lucas Fim
3620
+ #ADICIONANDO MENSAGEM
3621
+ await worker_sleep(5)
3633
3622
  try:
3634
- console.print("Identificando tela - 'TFrmDadosFaturamentoPreVenda' 1 ")
3623
+ console.print("Identificando - TFrmDadosFaturamentoPreVenda 1")
3635
3624
  app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=10)
3636
3625
  main_window = app["Confirm"]
3637
3626
  main_window.set_focus()
3638
3627
  except:
3639
- console.print("Identificando tela - 'TMessageForm' 1 ")
3640
- app = Application().connect(class_name="TMessageForm", timeout=10)
3628
+ console.print("Identificando - TMessageForm 1")
3629
+ app = Application().connect(class_name="TMessageForm", timeout=10, title='Confirm')
3641
3630
  main_window = app["TMessageForm"]
3642
3631
  main_window.set_focus()
3643
-
3644
- console.print("Clicando em sim para faturar pre-venda... \n")
3645
- btn_yes = main_window.child_window(class_name="TButton", found_index=1)
3632
+
3633
+ btn_yes = main_window.child_window(class_name="TButton", title="&Yes")
3646
3634
  btn_yes.click()
3647
3635
 
3648
3636
  await worker_sleep(5)
3649
3637
 
3650
3638
  try:
3651
- console.print("Identificando tela - 'TFrmDadosFaturamentoPreVenda' 2 ")
3639
+ console.print('Identificando - TFrmDadosFaturamentoPreVenda 2')
3652
3640
  app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=10)
3653
3641
  main_window = app["TMessageForm"]
3654
3642
  except Exception as ex:
3655
- console.print(f'{ex}')
3656
- console.print("Identificando tela - 'TMessageForm' 2 ")
3643
+ console.print(f'{ex} - TMessageForm 2')
3657
3644
  app = Application().connect(class_name="TMessageForm", timeout=10)
3658
3645
  main_window = app["TMessageForm"]
3659
3646
 
@@ -3823,33 +3810,113 @@ async def devolucao_prazo_a_faturar(task: RpaProcessoEntradaDTO) -> RpaRetornoPr
3823
3810
  )
3824
3811
  except:
3825
3812
  console.print("Janela TFrmProcessamentoNFe2 ja fechada")
3813
+
3826
3814
 
3827
- try:
3828
- await worker_sleep(10)
3829
- app = Application().connect(class_name="TFrmGerenciadorNFe2", timeout=10)
3830
- window_gerenciador = app["TFrmGerenciadorNFe2"]
3831
- window_gerenciador.set_focus()
3832
- window_gerenciador.close()
3833
- except:
3834
- console.print("Janela TFrmGerenciadorNFe2 ja fechada")
3815
+ console.print("Verificando se possui pop-up imprimir boleta")
3816
+ boleta_screen = await is_window_open("Confirm")
3817
+ if boleta_screen["IsOpened"] == True:
3818
+ console.print("Janela aberta, fechando")
3819
+ try:
3820
+ console.print("Confirm")
3821
+ app = Application().connect(title="Confirm", timeout=10)
3822
+ main_window = app["Confirm"]
3823
+ main_window.set_focus()
3824
+ except:
3825
+ console.print("Identificando - TMessageForm 1")
3826
+ app = Application().connect(class_name="TMessageForm", timeout=10, title='Confirm')
3827
+ main_window = app["TMessageForm"]
3828
+ main_window.set_focus()
3829
+
3830
+ btn_no = main_window.child_window(class_name="TButton", title="&No")
3831
+ btn_no.click()
3832
+
3833
+
3834
+ await worker_sleep(7)
3835
+ erro_screen = await is_window_open_by_class("TFrmDadosFaturamentoPreVenda","Confirm")
3836
+ if erro_screen["IsOpened"] == True:
3837
+ console.print("Janela aberta, fechando")
3838
+ try:
3839
+ console.print("Identificando - TFrmDadosFaturamentoPreVenda 1")
3840
+ app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=10)
3841
+ main_window = app["Confirm"]
3842
+ main_window.set_focus()
3843
+ except:
3844
+ console.print("Identificando - TMessageForm 1")
3845
+ app = Application().connect(class_name="TMessageForm", timeout=10, title='Confirm')
3846
+ main_window = app["TMessageForm"]
3847
+ main_window.set_focus()
3835
3848
 
3849
+ btn_no = main_window.child_window(class_name="TButton", title="&No")
3850
+ btn_no.click()
3851
+
3836
3852
 
3853
+ await worker_sleep(10)
3854
+ console.print("Verificando se a tela de Mensagem esta aberta")
3837
3855
  erro_screen = await is_window_open_by_class("TMemo","TMemo")
3838
3856
  if erro_screen["IsOpened"] == True:
3857
+ console.print("Janela aberta, fechando")
3839
3858
  app = Application().connect(class_name="TMemo", timeout=10)
3840
3859
  main_window = app["TMemo"]
3841
3860
  main_window.set_focus()
3842
- await worker_sleep(2)
3861
+ await worker_sleep(5)
3843
3862
  main_window.close()
3863
+
3844
3864
 
3865
+ console.print("Verificando se a tela de Faturamento Pre venda esta aberta")
3866
+ close_dados_faturamento = await is_window_open_by_class("TFrmDadosFaturamentoPreVenda","TFrmDadosFaturamentoPreVenda")
3867
+ if close_dados_faturamento["IsOpened"] == True:
3868
+ console.print("Janela aberta, fechando")
3869
+ try:
3870
+ app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=60)
3871
+ main_window = app["TFrmDadosFaturamentoPreVenda"]
3872
+ main_window.set_focus()
3873
+ btn_cancelar = main_window.child_window(class_name="TBitBtn", found_index=0)
3874
+ btn_cancelar.click()
3875
+ except:
3876
+ btn_cancelar = main_window.child_window(title="&Cancela")
3877
+ btn_cancelar.click()
3845
3878
 
3879
+
3880
+ await worker_sleep(10)
3881
+ console.print("Verificando se a tela de Faturamento Pre venda esta aberta")
3846
3882
  close_dados_faturamento = await is_window_open_by_class("TFrmDadosFaturamentoPreVenda","TFrmDadosFaturamentoPreVenda")
3847
3883
  if close_dados_faturamento["IsOpened"] == True:
3848
- app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=10)
3849
- main_window = app["TFrmDadosFaturamentoPreVenda"]
3850
- main_window.set_focus()
3884
+ console.print("Janela aberta, fechando")
3885
+ try:
3886
+ app = Application().connect(class_name="TFrmDadosFaturamentoPreVenda", timeout=180)
3887
+ main_window = app["TFrmDadosFaturamentoPreVenda"]
3888
+ main_window.set_focus()
3889
+ await worker_sleep(2)
3890
+ main_window.close()
3891
+ except Exception as e:
3892
+ console.print(f"Erro ao fechar a janela de dados faturamento pre venda {e}")
3893
+
3894
+
3895
+ await worker_sleep(5)
3896
+ console.print("Verificando se a tela de Gerenciador esta aberta")
3897
+ window_gerenciador_screen = await is_window_open_by_class("TFrmGerenciadorNFe2","TFrmGerenciadorNFe2")
3898
+ if window_gerenciador_screen["IsOpened"] == True:
3899
+ app = Application().connect(class_name="TFrmGerenciadorNFe2", timeout=10)
3900
+ window_gerenciador = app["TFrmGerenciadorNFe2"]
3901
+ window_gerenciador.set_focus()
3851
3902
  await worker_sleep(2)
3852
- main_window.close()
3903
+ window_gerenciador.close()
3904
+ else:
3905
+ console.print("Janela TFrmGerenciadorNFe2 ja fechada")
3906
+
3907
+
3908
+ await worker_sleep(10)
3909
+ console.print("Verificando se a tela de Pre venda esta aberta")
3910
+ window_gerenciador_screen = await is_window_open_by_class("TFrmPreVenda","TFrmPreVenda")
3911
+ if window_gerenciador_screen["IsOpened"] == True:
3912
+ app = Application().connect(class_name="TFrmPreVenda", timeout=10)
3913
+ window_gerenciador = app["TFrmPreVenda"]
3914
+ window_gerenciador.set_focus()
3915
+ await worker_sleep(2)
3916
+ window_gerenciador.close()
3917
+ else:
3918
+ console.print("Janela TFrmPreVenda ja fechada")
3919
+
3853
3920
 
3854
3921
  except Exception as e:
3855
3922
  retorno = f"Não foi possivel concluir o processo de pré venda {e} \nEtapas Executadas:\n{steps}"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: worker-automate-hub
3
- Version: 0.5.329
3
+ Version: 0.5.331
4
4
  Summary: Worker Automate HUB é uma aplicação para automatizar rotinas de RPA nos ambientes Argenta.
5
5
  Author: Joel Paim
6
6
  Requires-Python: >=3.12,<4.0
@@ -42,7 +42,7 @@ worker_automate_hub/tasks/jobs/cte_manual.py,sha256=JucHpRMjMiy-QEJ0wtFnytLpN53t
42
42
  worker_automate_hub/tasks/jobs/descartes.py,sha256=2zODOekSJSr7nuO9sUzT_F3YeG7N5EHuxnp05RguirE,41361
43
43
  worker_automate_hub/tasks/jobs/despesas_cte.py,sha256=TWbjBMZjYDugiqYUa_1DtCAUWOyVetoZI2SPs7AdDNc,13264
44
44
  worker_automate_hub/tasks/jobs/devolucao_ctf.py,sha256=A41O9a6kVUweUBy7Lc2dpJoeAi8QYxu-pMc8u-g0yTg,110241
45
- worker_automate_hub/tasks/jobs/devolucao_prazo_a_faturar.py,sha256=d6s9b5XyFJ7RrxYQz7fmaW783bcAXRuJryK1ioPliFM,239602
45
+ worker_automate_hub/tasks/jobs/devolucao_prazo_a_faturar.py,sha256=l75ybIiVb9VIo6dhiEoszFOaJIJq7dUbkGLNtqGDHXw,243961
46
46
  worker_automate_hub/tasks/jobs/ecac_estadual_go.py,sha256=dKkf22nH5gp3RErq5u0UzRsKyJ81fc6ZZ4vLtUuMwHA,21002
47
47
  worker_automate_hub/tasks/jobs/ecac_estadual_main.py,sha256=8WmKe4-MRtzHobXz2S4YBDNN8alfawkC-BBlRY-mn1g,1726
48
48
  worker_automate_hub/tasks/jobs/ecac_estadual_mt.py,sha256=C26zmpGQGUq6sP9lU9nanM3Fje-rkyx5tjwmRy4lyL8,25300
@@ -85,7 +85,7 @@ worker_automate_hub/utils/updater.py,sha256=en2FCGhI8aZ-JNP3LQm64NJDc4awCNW7UhbV
85
85
  worker_automate_hub/utils/util.py,sha256=sadsyNEdhkhMHU2jVdDCJK59kHd4TWVDmmfQ62gc5Q8,182626
86
86
  worker_automate_hub/utils/utils_nfe_entrada.py,sha256=wmnpuOesmPSryZszmapa37b9YNC0E2MkeDYnbwr-0rU,33315
87
87
  worker_automate_hub/worker.py,sha256=axdrr1xLTjWEyWfcyH3OCSpPTsyzck_fL_0u1DBLjvw,6525
88
- worker_automate_hub-0.5.329.dist-info/entry_points.txt,sha256=sddyhjx57I08RY8X7UxcTpdoOsWULAWNKN9Xr6pp_Kw,54
89
- worker_automate_hub-0.5.329.dist-info/METADATA,sha256=8Kfx5tf_pzA4A7LoM8w1I5Qp8XZHa2uf5t5W_CDcVQY,3041
90
- worker_automate_hub-0.5.329.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
91
- worker_automate_hub-0.5.329.dist-info/RECORD,,
88
+ worker_automate_hub-0.5.331.dist-info/entry_points.txt,sha256=sddyhjx57I08RY8X7UxcTpdoOsWULAWNKN9Xr6pp_Kw,54
89
+ worker_automate_hub-0.5.331.dist-info/METADATA,sha256=160zZC56WQlRv-qL1CES4poUbcwE3Pw2O2LikJ_T4NQ,3041
90
+ worker_automate_hub-0.5.331.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
91
+ worker_automate_hub-0.5.331.dist-info/RECORD,,