From 9197d900ff7cb85d98107ba6521b882d75d0e672 Mon Sep 17 00:00:00 2001 From: Adriano Serighelli Date: Tue, 10 Jun 2025 09:59:43 -0300 Subject: [PATCH] =?UTF-8?q?Adicionado=20estrutura=20para=20n=C3=A3o=20proc?= =?UTF-8?q?essar=20faturas=20da=20Copel=20do=20tipo=20"deposito=20judicial?= =?UTF-8?q?"=20e=20"ajuste=20do=20desconto"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Webhook 4docs/Program.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Webhook 4docs/Program.cs b/Webhook 4docs/Program.cs index 1a55476..4ae88e6 100644 --- a/Webhook 4docs/Program.cs +++ b/Webhook 4docs/Program.cs @@ -118,9 +118,11 @@ namespace Webhook_4docs JsonElement DadosJson = JsonDocument.Parse(root.ToString()).RootElement; - if (root.Get("documentType").ToString().ToLower() != string.Empty) + string tipoDocumento = root.Get("documentType").ToString().ToLower(); + + if (tipoDocumento != string.Empty && tipoDocumento != "nota_fiscal") { - if (root.Get("documentType")?.ToString().ToLower() != "nota_fiscal") { return; } + return; } Fatura fatura = new(fatura_ID, JsonBody);