Fix for Bug 3397 - Deleting item record leaves a hole in patron's reading history

Excluding entries in old_issues which have a NULL itemnumber

Signed-off-by: Magnus Enger <magnus@enger.priv.no>
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
This commit is contained in:
Owen Leonard 2011-05-18 10:20:51 -04:00 committed by Chris Cormack
parent f2fa6c893c
commit 9047bd2ddf

View file

@ -1123,7 +1123,7 @@ sub GetAllIssues {
LEFT JOIN items on items.itemnumber=old_issues.itemnumber
LEFT JOIN biblio ON items.biblionumber=biblio.biblionumber
LEFT JOIN biblioitems ON items.biblioitemnumber=biblioitems.biblioitemnumber
WHERE borrowernumber=?
WHERE borrowernumber=? AND old_issues.itemnumber IS NOT NULL
order by $order";
if ( $limit != 0 ) {
$query .= " limit $limit";