From 0dd1ae1c50110cb793690761ad7bc63d03e0843b Mon Sep 17 00:00:00 2001 From: sandeepsajan0 Date: Thu, 29 Aug 2024 17:57:18 +0530 Subject: [PATCH] Add confirm message for export submission data as csv file --- .../funds/templates/funds/includes/round-block-listing.html | 2 +- .../funds/templates/funds/includes/table_filter_and_search.html | 1 + hypha/apply/funds/templates/submissions/all.html | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/hypha/apply/funds/templates/funds/includes/round-block-listing.html b/hypha/apply/funds/templates/funds/includes/round-block-listing.html index 8897e973a5..369ec71dd7 100644 --- a/hypha/apply/funds/templates/funds/includes/round-block-listing.html +++ b/hypha/apply/funds/templates/funds/includes/round-block-listing.html @@ -22,7 +22,7 @@

{% trans 'View' %} {% if can_export %} - {% trans 'Export' %} + {% trans 'Export' %} {% endif %} {% else %} diff --git a/hypha/apply/funds/templates/funds/includes/table_filter_and_search.html b/hypha/apply/funds/templates/funds/includes/table_filter_and_search.html index 94b4bdc808..58855b0578 100644 --- a/hypha/apply/funds/templates/funds/includes/table_filter_and_search.html +++ b/hypha/apply/funds/templates/funds/includes/table_filter_and_search.html @@ -78,6 +78,7 @@

{{ heading }}

class="px-2 py-1.5 flex items-center transition-colors border rounded hover:bg-gray-100 shadow-sm" aria-label="Submissions: Download as CSV" href="{{path}}{% if '?' in path %}&{%else%}?{% endif %}export=true" + onclick="return confirm('Are you sure you want to download the submissions as a csv file? This file may contain sensitive information, so please handle it carefully.');" role="button" data-tippy-content="Export as CSV" > diff --git a/hypha/apply/funds/templates/submissions/all.html b/hypha/apply/funds/templates/submissions/all.html index d4faa0336e..1c49304762 100644 --- a/hypha/apply/funds/templates/submissions/all.html +++ b/hypha/apply/funds/templates/submissions/all.html @@ -126,6 +126,7 @@ class="px-2 py-1.5 transition-colors border rounded hover:bg-gray-100 shadow-sm" aria-label="Submissions: Download as CSV" href="{% modify_query "page" format="csv" %}" + onclick="return confirm('Are you sure you want to download the submissions as a csv file? This file may contain sensitive information, so please handle it carefully.');" data-tippy-content="Export as CSV" > {% heroicon_mini "arrow-down-tray" %}