Bug 15774: Add additional fields to order baskets
[koha.git] / acqui / acqui-home.pl
index 4da1eaf..9c70773 100755 (executable)
@@ -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;
@@ -73,18 +72,12 @@ foreach my $budget ( @{$budget_arr} ) {
 
     my $patron = Koha::Patrons->find( $budget->{budget_owner_id} );
     if ( $patron ) {
-        # FIXME should pass the entire object into budget_owner
-        $budget->{budget_owner_firstname} = $patron->firstname;
-        $budget->{budget_owner_surname} = $patron->surname;
-        $budget->{budget_owner_borrowernumber} = $patron->borrowernumber;
+        $budget->{budget_owner} = $patron;
     }
 
     if ( !defined $budget->{budget_amount} ) {
         $budget->{budget_amount} = 0;
     }
-
-    $budget->{'budget_ordered'} = GetBudgetOrdered( $budget->{'budget_id'} );
-    $budget->{'budget_spent'}   = GetBudgetSpent( $budget->{'budget_id'} );
     if ( !defined $budget->{budget_spent} ) {
         $budget->{budget_spent} = 0;
     }