[Koha-patches] [PATCH] bug: chargelostitem() didn't unset onloan on the item record.
Andrew Moore
andrew.moore at liblime.com
Wed Sep 3 18:24:46 CEST 2008
Good catch, Michael.
I wish that C4::Accounts::chargelostitem could use
C4::Circulation::AddReturn instead of C4::MarkIssueReturned, or that
there was another C4::Circulation function that would take care if
indicating that an item was lost. Then, we could consider
MarkIssueReturned a private method and make actions like this more
consistent.
-Andy
On Tue, Sep 2, 2008 at 2:57 PM, Michael Hafen <mdhafen at tech.washk12.org> wrote:
> 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
>
> _______________________________________________
> Koha-patches mailing list
> Koha-patches at lists.koha.org
> http://lists.koha.org/mailman/listinfo/koha-patches
>
More information about the Koha-patches
mailing list