https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43378
Bug ID: 43378
Summary: Wrong hold can be selected when LocalHoldsPriority set
to GiveLibraryAndGroup
Initiative type: ---
Sponsorship ---
status:
Product: Koha
Version: Main
Hardware: All
OS: All
Status: NEW
Severity: major
Priority: P5 - low
Component: Hold requests
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
CC: [email protected], [email protected],
[email protected]
Target Milestone: ---
In C4::Reserves::CheckReserves:
if ( !$local_hold_match && $LocalHoldsPriority eq ('GiveLibraryAndGroup') )
{ # If there's no match at the library level, check hold groups
$local_hold_group_match = Koha::Libraries->find( {
branchcode => $local_holds_priority_item_branchcode }
)->validate_hold_sibling(
{ branchcode => $local_holds_priority_patron_branchcode } );
}
Then:
# See if this item is more important than what we've got so far
if ( ( $res->{'priority'} && $res->{'priority'} < $priority )
|| $local_hold_match
|| $local_hold_group_match )
{
next
Then:
last
if $local_hold_match
|| ( ( $LocalHoldsPriority eq 'GiveLibraryGroup' ) &&
$local_hold_group_match );
That last condition needs to OR "eq 'GiveLibraryAndGroup'" - otherwise we are
setting local_hold_group_match, but not exiting the loop, and we pick the local
hold group match with the highest priority
--
You are receiving this mail because:
You are the assignee for the bug.
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/