From 4080154f2ba35fbd2fe839aef85be1bfdbb31436 Mon Sep 17 00:00:00 2001 From: Luciano Gervasoni Date: Thu, 14 Aug 2025 14:12:57 +0200 Subject: [PATCH] View fix (2) --- app_urls/fetcher/views_base.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/app_urls/fetcher/views_base.py b/app_urls/fetcher/views_base.py index 8311768..6a788e8 100644 --- a/app_urls/fetcher/views_base.py +++ b/app_urls/fetcher/views_base.py @@ -116,7 +116,16 @@ def notify_status(request): } # POST + response = requests.post(url, params={"chat_id": chat_id, "text": "Hola!"}) + response = requests.post(url, params=params) # print(response.json()) # Check the response + import json + from django.forms.models import model_to_dict + readable = json.dumps(list(urls_data_status), indent=2, default=str) + readable_ = [model_to_dict(obj) for obj in urls_data_status] + response = requests.post(url, params={"chat_id": chat_id, "text": str(readable)}) + response = requests.post(url, params={"chat_id": chat_id, "text": str(readable_)}) + return HttpResponse( "\n".join([str(e) for e in message]) ) \ No newline at end of file