From fcefc9f5371e63b468e37551d7d23b3e8097217a Mon Sep 17 00:00:00 2001 From: Domejko Date: Thu, 23 May 2024 15:11:26 +0200 Subject: [PATCH 1/2] Reformated by djLint --- .../overrides/partials/integrations/analytics/custom.html | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/docs/overrides/partials/integrations/analytics/custom.html b/docs/overrides/partials/integrations/analytics/custom.html index ccbe14e2..d8dc5b80 100644 --- a/docs/overrides/partials/integrations/analytics/custom.html +++ b/docs/overrides/partials/integrations/analytics/custom.html @@ -1,9 +1,7 @@ {% if config.extra.analytics.property %} - - + + {{ config.extra.analytics.property | safe }} {% else %} - + {% endif %} From 8485dd54e44ecd411c83b7b0275046a7fa591b93 Mon Sep 17 00:00:00 2001 From: Domejko Date: Thu, 23 May 2024 15:12:31 +0200 Subject: [PATCH 2/2] Added Invoice Not Found error msg for user --- backend/api/invoices/delete.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/api/invoices/delete.py b/backend/api/invoices/delete.py index 55dca70b..00126f7d 100644 --- a/backend/api/invoices/delete.py +++ b/backend/api/invoices/delete.py @@ -18,7 +18,8 @@ def delete_invoice(request: HtmxHttpRequest): try: invoice = Invoice.objects.get(id=delete_items.get("invoice", "")) except Invoice.DoesNotExist: - return JsonResponse({"message": "Invoice not found"}, status=404) + messages.error(request, "Invoice Not Found") + return render(request, "base/toasts.html") if not invoice.has_access(request.user): return JsonResponse({"message": "You do not have permission to delete this invoice"}, status=404)