From cc37c04bf3cd7afb61e53cffd58c079fa43af4f2 Mon Sep 17 00:00:00 2001 From: Charlotte Cordwell Date: Thu, 18 Jan 2018 00:48:55 +0000 Subject: [PATCH] Bug 19993: use Modern::Perl in Acquisition perl scripts Test Case: Check the following files have been updated from use strict; use warnings; to use Modern::Perl; acqui-home.pl addorder.pl basketgroup.pl basketheader.pl booksellers.pl check_budget_total.pl check_duplicate_barcode_ajax.pl edi_ean.pl edifactmsgs.pl edimsg.pl finishreceive.pl histsearch.pl invoice.pl invoices.pl neworderbiblio.pl neworderempty.pl newordersuggestion.pl ordered.pl orderreceive.pl parcel.pl parcels.pl pdfformat/layout2pages.pm pdfformat/layout2pagesde.pm pdfformat/layout3pages.pm pdfformat/layout3pagesfr.pm spent.pl supplier.pl uncertainprice.pl updatesupplier.pl z3950_search.pl Signed-off-by: Owen Leonard Corrected a single semicolon in edimsg.pl during signoff. Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart --- acqui/acqui-home.pl | 3 +-- acqui/addorder.pl | 3 +-- acqui/basketgroup.pl | 3 +-- acqui/basketheader.pl | 3 +-- acqui/booksellers.pl | 3 +-- acqui/check_budget_total.pl | 3 +-- acqui/check_duplicate_barcode_ajax.pl | 3 +-- acqui/edi_ean.pl | 3 +-- acqui/edifactmsgs.pl | 3 +-- acqui/edimsg.pl | 3 +-- acqui/finishreceive.pl | 3 +-- acqui/histsearch.pl | 3 +-- acqui/invoice.pl | 3 +-- acqui/invoices.pl | 3 +-- acqui/neworderbiblio.pl | 3 +-- acqui/neworderempty.pl | 3 +-- acqui/newordersuggestion.pl | 3 +-- acqui/ordered.pl | 3 +-- acqui/orderreceive.pl | 3 +-- acqui/parcel.pl | 3 +-- acqui/parcels.pl | 3 +-- acqui/pdfformat/layout2pages.pm | 3 +-- acqui/pdfformat/layout2pagesde.pm | 3 +-- acqui/pdfformat/layout3pages.pm | 3 +-- acqui/pdfformat/layout3pagesfr.pm | 3 +-- acqui/spent.pl | 3 +-- acqui/supplier.pl | 3 +-- acqui/uncertainprice.pl | 3 +-- acqui/updatesupplier.pl | 3 +-- acqui/z3950_search.pl | 3 +-- 30 files changed, 30 insertions(+), 60 deletions(-) diff --git a/acqui/acqui-home.pl b/acqui/acqui-home.pl index 4da1eaf2dc..cbb8896804 100755 --- a/acqui/acqui-home.pl +++ b/acqui/acqui-home.pl @@ -26,8 +26,7 @@ this script is the main page for acqui =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; diff --git a/acqui/addorder.pl b/acqui/addorder.pl index c102779de7..16fc89c1eb 100755 --- a/acqui/addorder.pl +++ b/acqui/addorder.pl @@ -119,8 +119,7 @@ if it is an order from an existing suggestion : the id of this suggestion. =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; # get_template_and_user use C4::Acquisition; # ModOrder diff --git a/acqui/basketgroup.pl b/acqui/basketgroup.pl index 0e8a9a197a..8c0e4c4bd5 100755 --- a/acqui/basketgroup.pl +++ b/acqui/basketgroup.pl @@ -43,8 +43,7 @@ The bookseller who we want to display the baskets (and basketgroups) of. =cut -use strict; -use warnings; +use Modern::Perl; use Carp; use C4::Auth; diff --git a/acqui/basketheader.pl b/acqui/basketheader.pl index 6de0a4d47b..f4650e8aaa 100755 --- a/acqui/basketheader.pl +++ b/acqui/basketheader.pl @@ -45,8 +45,7 @@ If it exists, C<$basketno> is the basket we edit =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; use C4::Auth; diff --git a/acqui/booksellers.pl b/acqui/booksellers.pl index 8a35b04bd0..b0ec7285b1 100755 --- a/acqui/booksellers.pl +++ b/acqui/booksellers.pl @@ -51,8 +51,7 @@ The id of the supplier whose baskets we will display =cut -use strict; -use warnings; +use Modern::Perl; use C4::Auth; use C4::Biblio; use C4::Budgets; diff --git a/acqui/check_budget_total.pl b/acqui/check_budget_total.pl index f8447f26cf..4981b83e07 100755 --- a/acqui/check_budget_total.pl +++ b/acqui/check_budget_total.pl @@ -17,8 +17,7 @@ # You should have received a copy of the GNU General Public License # along with Koha; if not, see . -use strict; -#use warnings; FIXME - Bug 2505 +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; use C4::Output; diff --git a/acqui/check_duplicate_barcode_ajax.pl b/acqui/check_duplicate_barcode_ajax.pl index 1655ac4be1..0c283bc6fd 100755 --- a/acqui/check_duplicate_barcode_ajax.pl +++ b/acqui/check_duplicate_barcode_ajax.pl @@ -17,8 +17,7 @@ # You should have received a copy of the GNU General Public License # along with Koha; if not, see . -use strict; -#use warnings; FIXME - Bug 2505 +use Modern::Perl; use CGI qw ( -utf8 ); use CGI::Cookie; use JSON; diff --git a/acqui/edi_ean.pl b/acqui/edi_ean.pl index 4ceda877ba..4520aaab09 100755 --- a/acqui/edi_ean.pl +++ b/acqui/edi_ean.pl @@ -21,8 +21,7 @@ # but as all sites so far are single ordering ean its not clear what we should # replace it with # -use strict; -use warnings; +use Modern::Perl; use C4::Auth; use C4::Koha; diff --git a/acqui/edifactmsgs.pl b/acqui/edifactmsgs.pl index 608eaff0a9..c706d9248b 100755 --- a/acqui/edifactmsgs.pl +++ b/acqui/edifactmsgs.pl @@ -16,8 +16,7 @@ # with Koha; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -use strict; -use warnings; +use Modern::Perl; use CGI; use Koha::Database; diff --git a/acqui/edimsg.pl b/acqui/edimsg.pl index c3547f025b..acc5beadb1 100755 --- a/acqui/edimsg.pl +++ b/acqui/edimsg.pl @@ -16,8 +16,7 @@ # with Koha; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -use strict; -use warnings; +use Modern::Perl; use CGI; use Koha::Database; diff --git a/acqui/finishreceive.pl b/acqui/finishreceive.pl index 7bec8658df..8c1439c2c8 100755 --- a/acqui/finishreceive.pl +++ b/acqui/finishreceive.pl @@ -20,8 +20,7 @@ # You should have received a copy of the GNU General Public License # along with Koha; if not, see . -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; use C4::Output; diff --git a/acqui/histsearch.pl b/acqui/histsearch.pl index 9261379493..b30eda31dd 100755 --- a/acqui/histsearch.pl +++ b/acqui/histsearch.pl @@ -49,8 +49,7 @@ to filter on ended date. =cut -use strict; -#use warnings; FIXME - Bug 2505 +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; # get_template_and_user use C4::Output; diff --git a/acqui/invoice.pl b/acqui/invoice.pl index 1ed46cffef..0f2933aa0c 100755 --- a/acqui/invoice.pl +++ b/acqui/invoice.pl @@ -26,8 +26,7 @@ Invoice details =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; diff --git a/acqui/invoices.pl b/acqui/invoices.pl index 3c10e7a1ec..8ab7a3256d 100755 --- a/acqui/invoices.pl +++ b/acqui/invoices.pl @@ -26,8 +26,7 @@ Search for invoices =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; diff --git a/acqui/neworderbiblio.pl b/acqui/neworderbiblio.pl index a2a3c7a94b..f083398e4f 100755 --- a/acqui/neworderbiblio.pl +++ b/acqui/neworderbiblio.pl @@ -55,8 +55,7 @@ the basket number to know on which basket this script have to add a new order. =cut -use strict; -#use warnings; FIXME - Bug 2505 +use Modern::Perl; use C4::Search; use CGI qw ( -utf8 ); diff --git a/acqui/neworderempty.pl b/acqui/neworderempty.pl index ab92985b7b..680be6ab45 100755 --- a/acqui/neworderempty.pl +++ b/acqui/neworderempty.pl @@ -66,8 +66,7 @@ the item's id in the breeding reservoir =cut -use warnings; -use strict; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; diff --git a/acqui/newordersuggestion.pl b/acqui/newordersuggestion.pl index c182ed343a..6bc0a6462f 100755 --- a/acqui/newordersuggestion.pl +++ b/acqui/newordersuggestion.pl @@ -88,8 +88,7 @@ can be equal to =cut -use strict; -#use warnings; FIXME - Bug 2505 +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; # get_template_and_user diff --git a/acqui/ordered.pl b/acqui/ordered.pl index 5c2cc6dd7e..a976cc9351 100755 --- a/acqui/ordered.pl +++ b/acqui/ordered.pl @@ -28,8 +28,7 @@ this script is to show orders ordered but not yet received =cut use C4::Context; -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; use C4::Output; diff --git a/acqui/orderreceive.pl b/acqui/orderreceive.pl index 7952e1dd8f..e876942884 100755 --- a/acqui/orderreceive.pl +++ b/acqui/orderreceive.pl @@ -58,8 +58,7 @@ The biblionumber of this order. =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Context; diff --git a/acqui/parcel.pl b/acqui/parcel.pl index b01e591953..5bec6f1324 100755 --- a/acqui/parcel.pl +++ b/acqui/parcel.pl @@ -54,8 +54,7 @@ To filter the results list on this given date. =cut -use strict; -use warnings; +use Modern::Perl; use C4::Auth; use C4::Acquisition; diff --git a/acqui/parcels.pl b/acqui/parcels.pl index d0e6e2b099..c0a330b479 100755 --- a/acqui/parcels.pl +++ b/acqui/parcels.pl @@ -66,8 +66,7 @@ To know how many results have to be display / page. =cut -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); use C4::Auth; use C4::Output; diff --git a/acqui/pdfformat/layout2pages.pm b/acqui/pdfformat/layout2pages.pm index 7e7bc3d63c..0d2a6e7a6d 100644 --- a/acqui/pdfformat/layout2pages.pm +++ b/acqui/pdfformat/layout2pages.pm @@ -24,8 +24,7 @@ package pdfformat::layout2pages; use vars qw(@ISA @EXPORT); use MIME::Base64; -use strict; -use warnings; +use Modern::Perl; use utf8; use Koha::Number::Price; diff --git a/acqui/pdfformat/layout2pagesde.pm b/acqui/pdfformat/layout2pagesde.pm index 08924d33e1..63269df32f 100644 --- a/acqui/pdfformat/layout2pagesde.pm +++ b/acqui/pdfformat/layout2pagesde.pm @@ -24,8 +24,7 @@ package pdfformat::layout2pagesde; use vars qw(@ISA @EXPORT); use MIME::Base64; -use strict; -use warnings; +use Modern::Perl; use utf8; use Koha::Number::Price; diff --git a/acqui/pdfformat/layout3pages.pm b/acqui/pdfformat/layout3pages.pm index f825ed35f7..8f80fe26a6 100644 --- a/acqui/pdfformat/layout3pages.pm +++ b/acqui/pdfformat/layout3pages.pm @@ -25,8 +25,7 @@ package pdfformat::layout3pages; use vars qw(@ISA @EXPORT); use MIME::Base64; use List::MoreUtils qw/uniq/; -use strict; -use warnings; +use Modern::Perl; use utf8; use Koha::Number::Price; diff --git a/acqui/pdfformat/layout3pagesfr.pm b/acqui/pdfformat/layout3pagesfr.pm index 14b0cc0c38..5568e0157b 100644 --- a/acqui/pdfformat/layout3pagesfr.pm +++ b/acqui/pdfformat/layout3pagesfr.pm @@ -24,8 +24,7 @@ package pdfformat::layout3pagesfr; use vars qw(@ISA @EXPORT); use MIME::Base64; use List::MoreUtils qw/uniq/; -use strict; -use warnings; +use Modern::Perl; use utf8; use Koha::Number::Price; diff --git a/acqui/spent.pl b/acqui/spent.pl index f31b283060..9a1c8059ec 100755 --- a/acqui/spent.pl +++ b/acqui/spent.pl @@ -32,8 +32,7 @@ this script is designed to show the spent amount in budgets use C4::Context; use C4::Auth; use C4::Output; -use strict; -use warnings; +use Modern::Perl; use CGI qw ( -utf8 ); my $dbh = C4::Context->dbh; diff --git a/acqui/supplier.pl b/acqui/supplier.pl index e0addbca2d..40235dfacd 100755 --- a/acqui/supplier.pl +++ b/acqui/supplier.pl @@ -40,8 +40,7 @@ To know the bookseller this script has to display details. =cut -use strict; -use warnings; +use Modern::Perl; use C4::Auth; use C4::Contract; use C4::Biblio; diff --git a/acqui/uncertainprice.pl b/acqui/uncertainprice.pl index 7fa95ab417..4a559e3691 100755 --- a/acqui/uncertainprice.pl +++ b/acqui/uncertainprice.pl @@ -43,8 +43,7 @@ The bookseller who we want to display the orders of. =cut -use strict; -use warnings; +use Modern::Perl; use C4::Auth; use C4::Output; diff --git a/acqui/updatesupplier.pl b/acqui/updatesupplier.pl index 18912ddee2..5b077f171e 100755 --- a/acqui/updatesupplier.pl +++ b/acqui/updatesupplier.pl @@ -46,8 +46,7 @@ contact_serialsprimary. =cut -use strict; -use warnings; +use Modern::Perl; use List::Util; use C4::Context; use C4::Auth; diff --git a/acqui/z3950_search.pl b/acqui/z3950_search.pl index 59f9f3637c..98a81fdca2 100755 --- a/acqui/z3950_search.pl +++ b/acqui/z3950_search.pl @@ -19,8 +19,7 @@ # You should have received a copy of the GNU General Public License # along with Koha; if not, see . -use warnings; -use strict; +use Modern::Perl; use CGI qw/-utf8/; use C4::Auth; -- 2.39.5