From 0a92c55c7eb74c3dc6f539dab7e97e6d56702772 Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Thu, 1 Feb 2024 11:28:44 -0500 Subject: [PATCH] Bug 34478: Manual fix - add op - members/maninvoice Signed-off-by: Jonathan Druart --- .../intranet-tmpl/prog/en/modules/members/maninvoice.tt | 1 + members/maninvoice.pl | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt index cfdb92536d..b64dfb26ad 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/maninvoice.tt @@ -75,6 +75,7 @@ [% END %]
+ [% INCLUDE 'csrf-token.inc' %]
diff --git a/members/maninvoice.pl b/members/maninvoice.pl index a7d12fd4fb..18d44af307 100755 --- a/members/maninvoice.pl +++ b/members/maninvoice.pl @@ -75,11 +75,16 @@ output_and_exit_if_error( ); my $library_id = C4::Context->userenv->{'branch'}; + +my $op = $input->param('op') // q{}; + +my $add = $input->param('add'); my $desc = $input->param('desc'); my $amount = $input->param('amount'); my $note = $input->param('note'); my $debit_type = $input->param('type'); my $barcode = $input->param('barcode'); + $template->param( desc => $desc, amount => $amount, @@ -88,8 +93,7 @@ $template->param( barcode => $barcode ); -my $add = $input->param('cud-add'); -if ($add) { +if ( $op eq 'cud-add' ) { # Note: If the logged in user is not allowed to see this patron an invoice can be forced # Here we are trusting librarians not to hack the system my $desc = $input->param('desc'); -- 2.39.5