[Koha-bugs] [Bug 30636] ILS-DI shows incorrect availability when Notforloan by Itemtype

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon May 23 02:16:33 CEST 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30636

--- Comment #7 from David Cook <dcook at prosentient.com.au> ---
(In reply to Katrin Fischer from comment #6)
> I believe the new is_notforloan is not complete as is:
> 
> * You check for the notforloan status in the item
> * You check for the notforloan of the itemtype of the item
> 
> But: I think you need to use effective_itemtype here to catch itemtype on
> record level as well.

Nope. That's automagically handled by '$self->itemtype;'. See below:

=head3 itemtype

    my $itemtype = $item->itemtype;

    Returns Koha object for effective itemtype

=cut

sub itemtype {
    my ( $self ) = @_;
    return Koha::ItemTypes->find( $self->effective_itemtype );
}

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list