# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
# Suite 330, Boston, MA 02111-1307 USA
-# $Id$
=head1 NAME
my ( $flags, $homebranch )= ($borrower->{'flags'},$borrower->{'branchcode'});
my @results = GetBookFunds($homebranch);
+
my $count = scalar @results;
my $classlist = '';
my @loop_budget = ();
for (my $i=0; $i<$count; $i++){
- my ($spent,$comtd)=GetBookFundBreakdown($results[$i]->{'bookfundid'},$results[$i]->{'startdate'},$results[$i]->{'enddate'});
+ my ($spent,$comtd)=GetBookFundBreakdown($results[$i]->{'aqbudgetid'},$results[$i]->{'startdate'},$results[$i]->{'enddate'});
my $avail=$results[$i]->{'budgetamount'}-($spent+$comtd);
my %line;
$line{bookfundname} = $results[$i]->{'bookfundname'};
$line{budgetamount} = $results[$i]->{'budgetamount'};
+ $line{aqbudgetid} = $results[$i]->{'aqbudgetid'};
+ $line{bookfundid} = $results[$i]->{'bookfundid'};
+ $line{sdate} = $results[$i]->{'startdate'};
+ $line{edate} = $results[$i]->{'enddate'};
$line{spent} = sprintf ("%.2f", $spent);
$line{comtd} = sprintf ("%.2f",$comtd);
$line{avail} = sprintf ("%.2f",$avail);