[Koha-patches] [PATCH] bug: chargelostitem() didn't unset onloan on the item record.

Michael Hafen mdhafen at tech.washk12.org
Tue Sep 2 21:57:09 CEST 2008


I don't think this is left set intentionally.

If an item is set lost and it's on loan it's marked returned, but it
wasn't set as not on loan.
---
 C4/Accounts.pm |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/C4/Accounts.pm b/C4/Accounts.pm
index 28d0b12..499771f 100644
--- a/C4/Accounts.pm
+++ b/C4/Accounts.pm
@@ -313,6 +313,8 @@ sub chargelostitem{
         #FIXME : Should probably have a way to distinguish this from an item that really was returned.
         warn " $issues->{'borrowernumber'}  /  $itemnumber ";
         C4::Circulation::MarkIssueReturned($issues->{borrowernumber},$itemnumber);
+	#  Shouldn't MarkIssueReturned do this?
+        ModItem({ onloan => undef }, undef, $itemnumber);
     }
     $sth->finish;
 }
-- 
1.5.4.3




More information about the Koha-patches mailing list