Bug 25786: Holds Queue building may target the wrong item for item level requests...
authorKyle M Hall <kyle@bywatersolutions.com>
Wed, 17 Jun 2020 16:53:36 +0000 (12:53 -0400)
committerAleisha Amohia <aleishaamohia@hotmail.com>
Wed, 19 Aug 2020 05:56:59 +0000 (17:56 +1200)
commit5646b2a6f7f1530a6853b493e10b1e3e8fc09995
tree1f47bb7ae59cd2fe637ea28040c5313150d4a641
parent85a648431bfa45de3bf1978319cd46f0632f5c98
Bug 25786: Holds Queue building may target the wrong item for item level requests that match holds queue priority

Bug 23934 removed the limitation that prevented item level holds from
getting local holds priority. The problem is the code has never checked
if the item level hold matches the given item! This means the wrong item
may be requested to fill an item level hold.

Test Plan:
1) Create 3 items on a record
2) Place a hold for the 2nd item you created
4) Ensure that hold would be picked up by local holds priority
5) Build the holds queue
6) Note the holds queue is asking for the wrong item!
7) Apply this patch
8) Rebuild the holds queue
9) Holds queue should now be asking for the correct item!

Signed-off-by: Kim Peine <kim@williston.lib.vt.us>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit b17a04dd077bb118086ad9e4bb58eee81ade2cdd)
(cherry picked from commit c6a1277fdb84df93be2cfa5cb0fa47c950116c20)

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
C4/HoldsQueue.pm
t/db_dependent/HoldsQueue.t