From bb87350628bcaa4713368ad4e707574dd2e5780b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ses=C3=B3stris=20Vieira?= Date: Fri, 17 May 2024 08:53:15 -0300 Subject: [PATCH] Reset de erros apenas se for importar dados --- sigi/apps/convenios/models.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sigi/apps/convenios/models.py b/sigi/apps/convenios/models.py index e0fcf38..2126b87 100644 --- a/sigi/apps/convenios/models.py +++ b/sigi/apps/convenios/models.py @@ -706,8 +706,6 @@ class Gescon(models.Model): requests.packages.urllib3.disable_warnings() report_user = False - Convenio.objects.update(erro_gescon=False) - dominio = get_current_site(None).domain for sigla_gescon, sigla_sigi in subespecies: @@ -752,6 +750,7 @@ class Gescon(models.Model): continue contratos = response.json() + Convenio.objects.filter(projeto=projeto).update(erro_gescon=False) # Pegar só os contratos que possuem alguma das palavras-chave