Bug 29115 - Placing a club hold is not showing warnings when unable to place a hold
Summary: Placing a club hold is not showing warnings when unable to place a hold
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Joonas Kylmälä
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-09-26 15:36 UTC by Joonas Kylmälä
Modified: 2022-02-02 17:27 UTC (History)
7 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Text to go in the release notes:
This fixes placing club holds so that checks are correctly made and warning messages displayed when patrons are debarred or have outstanding fees and charges.
Version(s) released in:
22.05.00,21.11.01,21.05.08


Attachments
Bug 29115: Fix syntax errors in club hold functionality (3.90 KB, patch)
2021-09-26 15:51 UTC, Joonas Kylmälä
Details | Diff | Splinter Review
Bug 29115: Fix syntax errors in club hold functionality (3.95 KB, patch)
2021-10-12 09:48 UTC, David Nind
Details | Diff | Splinter Review
Bug 29115: Fix syntax errors in club hold functionality (4.02 KB, patch)
2021-12-01 14:50 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Joonas Kylmälä 2021-09-26 15:36:24 UTC
The code that is supposed to show warnings if someone in a club cannot reserve the item when placing a club hold is broken and not showing the warnings.
Comment 1 Joonas Kylmälä 2021-09-26 15:51:23 UTC
Created attachment 125340 [details] [review]
Bug 29115: Fix syntax errors in club hold functionality

The code didn't previously correctly do the checks for patron
debarment status and whether the patron has fees, this caused the
intended warnings messages to not appear when they should have.

To test:
 1) Create a new club and add a patron to it who has manual debarment
    and a manual charge of over $5 (more than the maxoutstanding syspref).
 2) Try to create a new club hold for the previously created club and
    notice no warnings are listed for the patron.
 3) Apply patch
 4) Try to create now the club hold again and notice the warnings
    being shown in the hold page.
Comment 2 David Nind 2021-10-12 09:48:12 UTC
Created attachment 126083 [details] [review]
Bug 29115: Fix syntax errors in club hold functionality

The code didn't previously correctly do the checks for patron
debarment status and whether the patron has fees, this caused the
intended warnings messages to not appear when they should have.

To test:
 1) Create a new club and add a patron to it who has manual debarment
    and a manual charge of over $5 (more than the maxoutstanding syspref).
 2) Try to create a new club hold for the previously created club and
    notice no warnings are listed for the patron.
 3) Apply patch
 4) Try to create now the club hold again and notice the warnings
    being shown in the hold page.

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 Jonathan Druart 2021-12-01 14:50:16 UTC
Created attachment 128130 [details] [review]
Bug 29115: Fix syntax errors in club hold functionality

The code didn't previously correctly do the checks for patron
debarment status and whether the patron has fees, this caused the
intended warnings messages to not appear when they should have.

To test:
 1) Create a new club and add a patron to it who has manual debarment
    and a manual charge of over $5 (more than the maxoutstanding syspref).
 2) Try to create a new club hold for the previously created club and
    notice no warnings are listed for the patron.
 3) Apply patch
 4) Try to create now the club hold again and notice the warnings
    being shown in the hold page.

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 4 Fridolin Somers 2021-12-11 07:32:22 UTC
Pushed to master for 22.05, thanks to everybody involved 🦄
Comment 5 Kyle M Hall 2021-12-17 13:43:33 UTC
Pushed to 21.11.x for 21.11.01
Comment 6 Andrew Fuerste-Henry 2021-12-17 20:16:48 UTC
Pushed to 21.05.x for 21.05.08
Comment 7 Victor Grousset/tuxayo 2021-12-22 21:39:23 UTC
Not backported to oldoldstable (20.11.x). Feel free to ask if it's needed.