From 455c254ee01095d574ff1a26171ec4cca251b7b5 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Tue, 22 May 2018 11:46:10 -0300 Subject: [PATCH] Bug 20703: Add confirmation modal when making a credit void Signed-off-by: Tomas Cohen Arazi Signed-off-by: Kyle M Hall Signed-off-by: Nick Clemens --- .../prog/en/modules/members/boraccount.tt | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt index 7ecaeb718d..a7f508d7ae 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt @@ -77,7 +77,7 @@ Reverse [% END %] [% IF account.amount < 0 %] - Void + Void [% END %] [% ELSE %]   @@ -141,6 +141,14 @@ table_account_fines.fnFilter(filteredValue, 4, true, false); $(this).toggleClass('filtered'); }); + + $(".void").on("click",function(e){ + if( confirm( _("Are you sure you want to void this credit?") ) ) { + return true; + } else { + e.preventDefault(); + } + }); }); [% END %] -- 2.39.5