From 56e972c37167ebd6b001328c86c84234c20d8995 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BE=9D=E7=91=AA=E8=B2=93?= Date: Thu, 9 Mar 2023 22:29:44 +0800 Subject: [PATCH] Fixed so that the download buttons on the report pages are disabled when there is no data. --- .../report/include/toolbar-buttons.html | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/accounting/templates/accounting/report/include/toolbar-buttons.html b/src/accounting/templates/accounting/report/include/toolbar-buttons.html index a72fc2a..7c68ddc 100644 --- a/src/accounting/templates/accounting/report/include/toolbar-buttons.html +++ b/src/accounting/templates/accounting/report/include/toolbar-buttons.html @@ -106,10 +106,17 @@ First written: 2023/3/8 {{ report.period.desc|title }} {% endif %} - - - {{ A_("Download") }} - +{% if report.has_data %} + + + {{ A_("Download") }} + +{% else %} + +{% endif %} {% if use_search %}