Bug 30933: Adjust pref description, include ListOwnerDesignated
[srvgit] / acqui / lateorders.pl
index bd03be4..a47088c 100755 (executable)
@@ -45,24 +45,21 @@ To know on which branch this script have to display late order.
 
 use Modern::Perl;
 use CGI qw ( -utf8 );
-use C4::Auth;
-use C4::Koha;
-use C4::Output;
+use C4::Auth qw( get_template_and_user );
+use C4::Output qw( output_html_with_http_headers );
 use C4::Context;
-use C4::Acquisition;
-use C4::Letters;
-use Koha::DateUtils;
-use Koha::Acquisition::Orders;
+use C4::Letters qw( SendAlerts GetLetters );
+use Koha::DateUtils qw( dt_from_string output_pref );
+use Koha::Acquisition::Orders qw( filter_by_lates );
 use Koha::CsvProfiles;
 
-my $input = new CGI;
+my $input = CGI->new;
 my ($template, $loggedinuser, $cookie) = get_template_and_user(
     {
         template_name   => "acqui/lateorders.tt",
         query           => $input,
         type            => "intranet",
         flagsrequired   => { acquisition => 'order_receive' },
-        debug           => 1,
     }
 );
 
@@ -160,6 +157,6 @@ $template->param(
     estimateddeliverydatefrom => $estimateddeliverydatefrom,
     estimateddeliverydateto   => $estimateddeliverydateto,
        intranetcolorstylesheet => C4::Context->preference("intranetcolorstylesheet"),
-    csv_profiles         => [ Koha::CsvProfiles->search({ type => 'sql', used_for => 'late_orders' }) ],
+    csv_profiles         => Koha::CsvProfiles->search({ type => 'sql', used_for => 'late_orders' }),
 );
 output_html_with_http_headers $input, $cookie, $template->output;