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

--- Comment #8 from Kyle M Hall (khall) <[email protected]> ---
Created attachment 211674
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=211674&action=edit
Bug 41698: (follow-up) Remove holds queue entries for holds that no longer
exist

When a patron with a title level hold checks out a different copy of the title
than the one the holds queue picked for them, the hold is filled but its entry
stays in the holds queue. Koha::Hold::fill doesn't touch tmp_holdsqueue or
hold_fill_targets, and AddIssue only removes queue entries for the item being
checked out. With RealTimeHoldsQueue disabled, the entry for the other copy
stays in the queue until the next full rebuild, so staff at that library are
asked to pull an item for a hold that has already been filled.

This patch makes the script also remove holds queue entries whose hold is no
longer in the reserves table.

Test Plan:
1) Disable RealTimeHoldsQueue
2) Find a record with two available items at two different libraries
3) Place a title level hold for a patron, with pickup at the library holding
the second item
4) Run misc/cronjobs/holds/build_holds_queue.pl
5) Browse to the holds queue ( /cgi-bin/koha/circ/view_holdsqueue.pl ), note
the hold is listed
   for one of the two items, make a note of which one
6) Check the *other* item out to the patron
7) Note the hold is now filled and no longer shows on the patron record
8) Browse to the holds queue, note the hold is still listed!
9) Apply this patch
10) Run misc/maintenance/fix_holds_waiting_and_issued.pl -c -v
11) Note the script reports removing the holds queue entry for that hold!
12) Browse to the holds queue, note the hold is gone!

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to