Bug 35188 - force_checkout permission can override all blocks on a patron account but only shows when they are restricted
Summary: force_checkout permission can override all blocks on a patron account but onl...
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Nick Clemens (kidclamp)
QA Contact: Testopia
URL:
Keywords: Sandbox
: 34588 (view as bug list)
Depends on: 643
Blocks:
  Show dependency treegraph
 
Reported: 2023-10-30 12:45 UTC by Nick Clemens (kidclamp)
Modified: 2024-08-21 17:41 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00
Circulation function:


Attachments
Bug 35188: Show checkout override for all noisseus statuses (2.89 KB, patch)
2023-10-30 12:49 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 35188: Show checkout override for all noisseus statuses (2.97 KB, patch)
2023-11-02 16:02 UTC, Matt Blenkinsop
Details | Diff | Splinter Review
Bug 35188: Show checkout override for all noisseus statuses (3.01 KB, patch)
2023-11-05 00:04 UTC, Victor Grousset/tuxayo
Details | Diff | Splinter Review
Bug 35188: [23.05.x] Show checkout override for all noissues statuses (2.99 KB, patch)
2023-11-10 11:57 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Clemens (kidclamp) 2023-10-30 12:45:06 UTC
When the force_checkout permission was added, the script circulation.pl was altered to allow overriding any block on the patron's account (expired, gonenoaddress, etc)

The last follow-up on that bug, however, moved the button to override into the section for restrictions, limiting the scope for users to the case where a patron had a debarment.

To recreate:
1 - Log in to Koha with a user with force_checkout permission (superlibrarian ok too)
2 - Mark a patron as expired, lost card, gone no address
3 - Go to 'Check out' page for the patorn
4 - Note you cannot override the restrictions
5 - Add a manual restriction/debarment
6 - Go to checkout again, now you can override
7 - Remove the debarment
8 - Add manually ot URL of checkout page '&foreallow=1'
9 - Note you can now override the other restrictions

I think the intent here should be that 'force_checkout' allows overriding any of the statuses
Comment 1 Nick Clemens (kidclamp) 2023-10-30 12:49:59 UTC
Created attachment 158062 [details] [review]
Bug 35188: Show checkout override for all noisseus statuses

This patch moves the override button up one level into the list of noissues in order to allow
overriding any blocking status

To test:
1 - Log in to Koha with a user with force_checkout permission (superlibrarian ok too)
2 - Mark a patron as expired, lost card, gone no address
3 - Go to 'Check out' page for the patorn
4 - Note you cannot override the restrictions
5 - Add a manual restriction/debarment
6 - Go to checkout again, now you can override
7 - Remove the debarment
8 - Add manually ot URL of checkout page '&foreallow=1'
9 - Note you can now override the other restrictions
10 - Apply patch
11 - Reload patron
12 - Note you now see the override button on the check out screen
13 - Add a debarment
14 - Confirm the button is still there
15 - Confirm overriding allows the checkout (with or without a debarment)
Comment 2 Nick Clemens (kidclamp) 2023-10-30 12:51:21 UTC
*** Bug 34588 has been marked as a duplicate of this bug. ***
Comment 3 Matt Blenkinsop 2023-11-02 16:02:39 UTC
Created attachment 158271 [details] [review]
Bug 35188: Show checkout override for all noisseus statuses

This patch moves the override button up one level into the list of noissues in order to allow
overriding any blocking status

To test:
1 - Log in to Koha with a user with force_checkout permission (superlibrarian ok too)
2 - Mark a patron as expired, lost card, gone no address
3 - Go to 'Check out' page for the patorn
4 - Note you cannot override the restrictions
5 - Add a manual restriction/debarment
6 - Go to checkout again, now you can override
7 - Remove the debarment
8 - Add manually ot URL of checkout page '&foreallow=1'
9 - Note you can now override the other restrictions
10 - Apply patch
11 - Reload patron
12 - Note you now see the override button on the check out screen
13 - Add a debarment
14 - Confirm the button is still there
15 - Confirm overriding allows the checkout (with or without a debarment)

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Comment 4 Victor Grousset/tuxayo 2023-11-05 00:04:43 UTC
Created attachment 158413 [details] [review]
Bug 35188: Show checkout override for all noisseus statuses

This patch moves the override button up one level into the list of noissues in order to allow
overriding any blocking status

To test:
1 - Log in to Koha with a user with force_checkout permission (superlibrarian ok too)
2 - Mark a patron as expired, lost card, gone no address
3 - Go to 'Check out' page for the patorn
4 - Note you cannot override the restrictions
5 - Add a manual restriction/debarment
6 - Go to checkout again, now you can override
7 - Remove the debarment
8 - Add manually ot URL of checkout page '&foreallow=1'
9 - Note you can now override the other restrictions
10 - Apply patch
11 - Reload patron
12 - Note you now see the override button on the check out screen
13 - Add a debarment
14 - Confirm the button is still there
15 - Confirm overriding allows the checkout (with or without a debarment)

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Comment 5 Victor Grousset/tuxayo 2023-11-05 00:04:58 UTC
Works, makes sense, QA script happy, code looks good, passing QA :)
Comment 6 Tomás Cohen Arazi (tcohen) 2023-11-06 14:36:56 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 7 Fridolin Somers 2023-11-10 07:49:54 UTC
Does not apply on 23.05.x
Please provide rebased patch
Comment 8 Nick Clemens (kidclamp) 2023-11-10 11:57:47 UTC
Created attachment 158803 [details] [review]
Bug 35188: [23.05.x] Show checkout override for all noissues statuses

This patch moves the override button up one level into the list of noissues in order to allow
overriding any blocking status

To test:
1 - Log in to Koha with a user with force_checkout permission (superlibrarian ok too)
2 - Mark a patron as expired, lost card, gone no address
3 - Go to 'Check out' page for the patorn
4 - Note you cannot override the restrictions
5 - Add a manual restriction/debarment
6 - Go to checkout again, now you can override
7 - Remove the debarment
8 - Add manually ot URL of checkout page '&foreallow=1'
9 - Note you can now override the other restrictions
10 - Apply patch
11 - Reload patron
12 - Note you now see the override button on the check out screen
13 - Add a debarment
14 - Confirm the button is still there
15 - Confirm overriding allows the checkout (with or without a debarment)

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>