Summary: | When calling the effective rule (allowed reserves), the undef is now set at 0 versus undef | ||
---|---|---|---|
Product: | Koha | Reporter: | Kelly McElligott <kelly> |
Component: | Hold requests | Assignee: | Bugs List <koha-bugs> |
Status: | In Discussion --- | QA Contact: | Testopia <testopia> |
Severity: | normal | ||
Priority: | P5 - low | CC: | gmcharlt, nick |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
See Also: |
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18936 https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26911 https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30794 |
||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: |
Description
Kelly McElligott
2020-11-03 14:42:03 UTC
Can you provide a step by step plan to recreate the issue please?
I edited the main circulation rule, filled "Holds allowed (total)" with an empty string, saved => "" is set in DB and I am able to place hold on items.
Do you mean you have NULL in DB?
What is the return of
> select rule_value from circulation_rules where rule_name="reservesallowed";
Found from bug 26911 Set some other values for a rule in the circ matrix then DELETE FROM circulation_rules WHERE rule_name = 'reservesallowed'; The rules now appear as unlimited, but act as if 0 This line: 427 $allowedreserves = $rights->{reservesallowed} // $allowedreserves; Previously it did not assign to allowed reserves which is defaulted to 0 at the beginning of CanItemBeReserved So it does not happen if the upgrade does not fail? To recreate: 1 - Remove any All/All rules from circulation rules 2 - Set a circ rule for a specific itemtype with Holds allowed (total) set to 5 3 - Attempt to place a hold on an itemtype without the rules 4 - Too many holds: Edna Acosta can only place a maximum of 0 total holds. Turns out, this behaviour is consistent in my testing, so the problem was the upgrade only There is a question whether no rules set should allow unlimited holds, or 0 holds but that's not necessarily a bug. Currently we set "" for unlimited, and the rule not existing means that holds are not allowed. |