<<

NAME

Koha::Recalls - Koha Recalls Object set class

API

Class methods

filter_by_current

    my $current_recalls = $recalls->filter_by_current;

Returns a new resultset, filtering out finished recalls.

filter_by_finished

    my $finished_recalls = $recalls->filter_by_finished;

Returns a new resultset, filtering out current recalls.

add_recall

    my ( $recall, $due_interval, $due_date ) = Koha::Recalls->add_recall({
        patron => $patron_object,
        biblio => $biblio_object,
        branchcode => $branchcode,
        item => $item_object,
        expirationdate => $expirationdate,
        interface => 'OPAC',
    });

Add a new requested recall. We assume at this point that a recall is allowed to be placed on this item or biblio. We are past the checks and are now doing the recall. Interface param is either OPAC or INTRANET Send a RETURN_RECALLED_ITEM notice. Add statistics and logs. #FIXME: Add recallnotes and priority when staff-side recalls is added

move_recall

    my $message = Koha::Recalls->move_recall({
        recall_id = $recall_id,
        action => $action,
        item => $item_object,
        borrowernumber => $borrowernumber,
    });

A patron is attempting to check out an item that has been recalled by another patron. If the recall is requested/overdue, they have the option of cancelling the recall. If the recall is waiting, they also have the option of reverting the waiting status.

We can also fulfill the recall here if the recall is placed by this borrower.

recall_id = ID of the recall to perform the action on action = either cancel or revert item = item object that the patron is attempting to check out borrowernumber = borrowernumber of the patron that is attemptig to check out

Internal methods

_type

object_class

<<