Bug 18001

Summary: LocalHoldsPriority can cause multiple holds queue lines for same hold request
Product: Koha Reporter: Kyle M Hall (khall) <kyle>
Component: Hold requestsAssignee: Kyle M Hall (khall) <kyle>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: critical    
Priority: P5 - low CC: barton, george, gmcharlt, jonathan.druart, jsasse, m.de.rooy, marjorie.barry-vila, nick
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on:    
Bug Blocks: 23934    
Attachments: Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request
Bug 18001 - Unit Test
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request
Bug 18001 - Unit Test
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request

Description Kyle M Hall (khall) 2017-01-26 17:29:46 UTC
If LocalHoldsPriority is enabled, and a record level request has more than one item that could fill that hold, there is a possibility that a holds queue row will be generated for the request for each of the available items!
Comment 1 Kyle M Hall (khall) 2017-01-26 19:05:21 UTC
Created attachment 59588 [details] [review]
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request

If LocalHoldsPriority is enabled, and a record level request has more
than one item that could fill that hold, there is a possibility that a
holds queue row will be generated for the request for each of the
available items!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Joel Sasse <jsasse@plumcreeklibrary.net>
Comment 2 Nick Clemens (kidclamp) 2017-02-07 17:12:08 UTC
Created attachment 59990 [details] [review]
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request

If LocalHoldsPriority is enabled, and a record level request has more
than one item that could fill that hold, there is a possibility that a
holds queue row will be generated for the request for each of the
available items!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Joel Sasse <jsasse@plumcreeklibrary.net>
Comment 3 Jonathan Druart 2017-03-29 19:12:45 UTC
Please provide tests.
Comment 4 Barton Chittenden 2017-04-17 20:24:02 UTC
I'm pushing this to critical; this will cause item-level holds to be filled by different items.
Comment 5 Kyle M Hall (khall) 2017-04-18 11:46:57 UTC
Created attachment 62268 [details] [review]
Bug 18001 - Unit Test
Comment 6 Kyle M Hall (khall) 2017-04-18 11:47:04 UTC
Created attachment 62269 [details] [review]
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request

If LocalHoldsPriority is enabled, and a record level request has more
than one item that could fill that hold, there is a possibility that a
holds queue row will be generated for the request for each of the
available items!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Joel Sasse <jsasse@plumcreeklibrary.net>
Comment 7 Jonathan Druart 2017-04-18 18:40:58 UTC
Created attachment 62318 [details] [review]
Bug 18001 - Unit Test

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 8 Jonathan Druart 2017-04-18 18:41:03 UTC
Created attachment 62320 [details] [review]
Bug 18001 - LocalHoldsPriority can cause multiple holds queue lines for same hold request

If LocalHoldsPriority is enabled, and a record level request has more
than one item that could fill that hold, there is a possibility that a
holds queue row will be generated for the request for each of the
available items!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Joel Sasse <jsasse@plumcreeklibrary.net>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 9 Kyle M Hall (khall) 2017-04-21 11:30:35 UTC
Pushed to master for 17.05!
Comment 10 Katrin Fischer 2017-04-21 22:14:35 UTC
These patches have been pushed to 16.11.x and will be in 16.11.07.