Koha/opac/opac-account-pay.pl
Kyle M Hall ebf8d687cc Bug 36088: Remove useless code form opac-account-pay.pl
The script opac-account-pay.pl sums the selected accountlines, formats the amount, pulls the currently active currency, and does nothing with any of this data.

Test Plan:
1) Apply this patch
2) Restart all the things!
3) Note there is no change in behavior

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>

PA amended title (missing 'Bug ####:'

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit dd7ac62d3f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2024-03-11 10:29:19 +01:00

63 lines
1.6 KiB
Perl
Executable file

#!/usr/bin/perl
# Copyright ByWater Solutions 2015
#
# This file is part of Koha.
#
# Koha is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# Koha is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Koha; if not, see <http://www.gnu.org/licenses>.
use utf8;
use Modern::Perl;
use CGI;
use C4::Auth qw( get_template_and_user );
use C4::Output;
use C4::Context;
use Koha::Acquisition::Currencies;
use Koha::Database;
use Koha::Plugins::Handler;
my $cgi = CGI->new;
my $payment_method = $cgi->param('payment_method');
my @accountlines = $cgi->multi_param('accountline');
my $use_plugin = Koha::Plugins::Handler->run(
{ class => $payment_method,
method => 'opac_online_payment',
cgi => $cgi,
}
);
unless ( $use_plugin ) {
print $cgi->redirect("/cgi-bin/koha/errors/404.pl");
exit;
}
my ( $template, $borrowernumber, $cookie ) = get_template_and_user(
{
template_name => "opac-account-pay-error.tt",
query => $cgi,
type => "opac",
}
);
Koha::Plugins::Handler->run(
{
class => $payment_method,
method => 'opac_online_payment_begin',
cgi => $cgi,
}
);