Koha-clms/t/db_dependent/Koha
Aleisha Amohia 16ee649023 Bug 32129: Use patron category when checking if item can fill recall
This patch uses the patron category of the patron who requested the most
relevant recall to check for more specific circulation rules relating to
recalls. This ensures that patrons who are allowed to place recalls are
able to fill their recalls, especially when recalls are not generally
available for all patron categories.

To test:
1) Go to Administration -> System preferences and enable UseRecalls
2) Go to Administration -> Circulation and fines rules and set a general
All/All rule and a Category A/Itemtype A rule. All values can be set
however you like except for these recalls rules:

All/All rule:
Recalls allowed: 0
Recalls per record: 0
On shelf recalls allowed: if any unavailable

Category A/Itemtype A rule:
Recalls allowed: 5
Recalls per record: 5
On shelf recalls allowed: if any unavailable

3) Find an item of Itemtype A. Check it out to Patron A (any category).
4) Log into the OPAC as Patron B (of Category A). Find the item and
place a recall on the item.
5) Back in the staff interface, check in the item. This should trigger
the recalls process so you can allocate the item to Patron B's recall,
however the pop-up box to confirm the recall does not show. This is the
bug.

6) Apply the patch and restart services

7) Check in the item again. Confirm the pop-up box to confirm the recall
shows and you are able to allocate the item to Patron B's recall.
8) Confirm tests pass t/db_dependent/Koha/Item.t

Sponsored-by: Auckland University of Technology
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 6cf8c901f5)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit a104de7094)
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
2023-06-15 19:35:49 +00:00
..
Account Revert "Bug 29021: (QA follow-up) Fix for new parameter, add unit test" 2023-02-02 16:54:12 +00:00
Acquisition Bug 30204: Add unit test 2022-04-20 20:43:15 -10:00
Auth Bug 28998: (follow-up) Check missing encryption key in script and module 2022-05-04 05:18:31 -10:00
BackgroundJob Bug 32394: [22.05.x] Regression tests 2023-02-01 18:19:34 +00:00
BackgroundJobs Bug 31351: (QA follow-up) Adjust tests accordingly 2022-10-14 21:36:09 +00:00
Biblio
…
BiblioUtils
…
Cash
…
Charges
…
Checkouts
…
CirculationRules Bug 29705: In test suite merge IssuingRules with CirculationRules 2022-05-06 10:33:10 -10:00
Club
…
Config
…
Edifact Bug 30135: Unit tests 2022-04-13 15:55:39 +02:00
Filter Bug 15187: (QA follow-up) Fix test permissions 2022-09-02 17:56:54 +00:00
Import Bug 30830: Add Koha Objects for Koha Import Items 2022-06-06 14:30:40 +00:00
Item Bug 31196: Remove 'default_value_for_mod_marc-' clear_from_cache calls 2022-12-05 23:19:21 +00:00
Items
…
Library
…
Objects/Mixin
…
Old Bug 26648: Add tests 2022-12-05 18:38:30 +00:00
Patron Bug 29924: Unit tests 2022-05-06 10:33:09 -10:00
Patrons Bug 29005: Unit tests 2022-04-20 09:03:39 -10:00
Plugins Bug 31223: Regression tests 2022-09-12 14:56:22 +00:00
REST Bug 30194: (26351 follow-up) Silence useless warning 2022-03-29 16:44:31 +02:00
SMTP
…
SearchEngine Bug 33206: Unit test 2023-06-15 16:52:43 +00:00
Subscription
…
Tags
…
Template/Plugin Bug 32539: Add tests 2023-02-15 22:07:18 +00:00
UI/Form/Builder Bug 31196: Remove 'default_value_for_mod_marc-' clear_from_cache calls 2022-12-05 23:19:21 +00:00
XSLT
…
Z3950Responder
…
Account.t
…
ActionLogs.t
…
AdditionalContents.t
…
ApiKey.t
…
ArticleRequest.t
…
ArticleRequests.t
…
Authorities.t
…
BackgroundJob.t Bug 32394: [22.05.x] Add tests 2023-02-01 18:19:34 +00:00
BackgroundJobs.t Bug 30982: [22.05.x] Use the REST API for background job list view 2022-11-01 21:40:18 +00:00
Biblio.t Bug 31196: Remove 'default_value_for_mod_marc-' clear_from_cache calls 2022-12-05 23:19:21 +00:00
BiblioFrameworks.t
…
Biblios.t
…
Checkout.t
…
Checkouts.t
…
CirculationRules.t Bug 29705: In test suite merge IssuingRules with CirculationRules 2022-05-06 10:33:10 -10:00
Cities.t
…
ClassSortRules.t
…
ClassSources.t
…
ClassSplitRules.t
…
CoverImages.t
…
CsvProfiles.t
…
Database.t
…
Desks.t
…
Encryption.t Bug 28998: (follow-up) Check missing encryption key in script and module 2022-05-04 05:18:31 -10:00
Hold.t Bug 31086: (QA follow-up) Add unit tests 2022-09-02 17:08:24 +00:00
Holds.t Bug 31086: (QA follow-up) Fix failing tests 2022-09-02 17:08:06 +00:00
Item.t Bug 32129: Use patron category when checking if item can fill recall 2023-06-15 19:35:49 +00:00
ItemTypes.t
…
Items.t Bug 31473: Fix fragile test about bad OpacHiddenItems conf 2022-10-04 16:28:40 +00:00
KeyboardShortcuts.t
…
Libraries.t
…
Library.t
…
MarcSubfieldStructures.t
…
Notices.t
…
Object.t
…
Objects.t
…
Old.t
…
Patron.t Bug 30399: Make Patron.t pass even if mandatory attributes exist 2022-07-13 19:07:43 +00:00
Patrons.t Bug 29059: Keep non-repeatable attribute from patron to preserve when merging 2022-04-08 15:49:17 +02:00
Pseudonymization.t Bug 31201: Prevent Pseudonymization.t to fail 2022-09-02 14:32:08 +00:00
Quotes.t
…
Ratings.t
…
Recall.t Bug 30291: Changes to tests 2022-05-05 11:17:36 -10:00
Recalls.t Bug 30291: (QA follow-up) Fix for revert to recall_id 2022-05-05 11:17:36 -10:00
Reports.t
…
Reviews.t
…
SMS_Providers.t
…
SearchField.t
…
SharedContent.t
…
Statistics.t
…
Subscription.t
…
Suggestion.t
…
Suggestions.t Bug 30663: Add Koha::Suggestions helper methods 2022-05-05 10:26:41 -03:00
Tags.t
…
Z3950Servers.t
…