X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=acqui%2Fspent.pl;h=a47d119980e299c6f45d4eb1dd98b78f6f3d5696;hb=96e95bce3ccef8e342b30086f794d8ca1b9ab186;hp=89a71e50dc94d42f60e8765e1a3b6dc5fa55c14c;hpb=584f93a1d568b9f99bbb7cb195fb71cf596d9f92;p=koha.git diff --git a/acqui/spent.pl b/acqui/spent.pl index 89a71e50dc..a47d119980 100755 --- a/acqui/spent.pl +++ b/acqui/spent.pl @@ -12,7 +12,7 @@ use CGI; my $dbh = C4::Context->dbh; my $input = new CGI; -my $bookfund = $input->param('bookfund'); +my $budgetid = $input->param('aqbudgetid'); my $start = $input->param('start'); my $end = $input->param('end'); @@ -40,14 +40,14 @@ my $query = LEFT JOIN aqorderbreakdown USING (ordernumber) LEFT JOIN aqbasket USING (basketno) LEFT JOIN aqbudget USING (bookfundid) - WHERE bookfundid=? + WHERE aqbudgetid=? AND (datecancellationprinted IS NULL OR datecancellationprinted = '0000-00-00') AND closedate BETWEEN startdate AND enddate AND creationdate > startdate ORDER BY datereceived "; my $sth = $dbh->prepare($query); -$sth->execute( $bookfund); +$sth->execute( $budgetid ); my $total = 0; my $toggle;