https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39977
Adolfo Rodríguez Taboada <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #182753|0 |1 is obsolete| | --- Comment #8 from Adolfo Rodríguez Taboada <[email protected]> --- Created attachment 202091 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=202091&action=edit Add third option to AllowHoldsOnPatronsPossessions: allow holds on other copies but not on the specific item checked out to the patron This patch adds a third value to AllowHoldsOnPatronsPossessions , updating the choice labels to describe all three options: * allow holds on any item (existing behaviour, value 1) * allow holds on other items only (new, value 2) — holds on the bibliographic record are allowed, but CanItemBeReserved returns alreadypossession if the patron already has that specific item checked out * do not allow holds (existing behaviour, value 0) The item-level check uses Koha::Checkouts to look up whether the specific item is currently issued to the requesting patron. The bib-level check in CanBookBeReserved is unchanged: with value 2 it evaluates as truthy, so no bib-level block is applied, and other copies remain holdable. The template reserve/request.tt is also updated to display a human-readable message ("Item is checked out to this patron") instead of the raw alreadypossession status key, which previously fell through to the catch-all and was rendered verbatim. Tests: the existing AllowHoldOnPatronPossession test subtest in t/db_dependent/Reserves.t is extended with 3 new cases covering value 2 (bib-level allowed, checked-out item blocked, second copy allowed). Greetings, Adolfo. -- 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/
