https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=44029
Bug ID: 44029
Summary: A refused over-limit checkout always says the limit
came from the All / All / All rule
Initiative type: ---
Sponsorship ---
status:
Product: Koha
Version: Main
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P5 - low
Component: Circulation
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
CC: [email protected], [email protected]
Target Milestone: ---
With AllowTooManyOverride off, checking out more items than a circulation rule
allows is refused with "Too many checked out. N checked out, only N are
allowed." followed by "Maximum checkouts calculated from the circulation rule
for" and the rule's criteria. That box always reads "All item types / All
patron categories / All libraries", even when a specific rule (one item type,
one category, one library) set the limit, pointing staff at the wrong rule.
Cause: in C4::Circulation::CanBookBeIssued, the branch for AllowTooManyOverride
off sets $issuingimpossible{TOO_MANY}, current_loan_count and
max_loans_allowed, but stores the rule in
$needsconfirmation{circulation_rule_TOO_MANY}. circ/circulation.pl does not
pass needsconfirmation to the template when the checkout is impossible, so the
template's circulation_rule_TOO_MANY is empty and the criteria include shows
"All" for everything.
A side effect: the REST API's checkout availability returns this stray key in
"confirms" even though the checkout is blocked.
To reproduce:
1. AllowTooManyOverride: Don't allow.
2. Add a circulation rule for one library, one patron category and one item
type with Current checkouts allowed = 1.
3. Check out one item of that type to a patron of that category at that
library, then a second one.
4. The refusal's rule box says All item types / All patron categories / All
libraries.
Reproduced on Koha 26.05.02; the same code is on main.
--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
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/