Bug 30213 - Hide Delete (aka Priority) column when user only has place_hold permission
Summary: Hide Delete (aka Priority) column when user only has place_hold permission
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on: 30207
Blocks:
  Show dependency treegraph
 
Reported: 2022-03-02 14:57 UTC by Sara Brown
Modified: 2023-12-28 20:42 UTC (History)
5 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:
22.11.00


Attachments
Bug 30213: Hide Delete (aka Priority) column when user only has place_hold permission (5.89 KB, patch)
2022-03-03 14:43 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 30213: Hide Delete (aka Priority) column when user only has place_hold permission (5.95 KB, patch)
2022-03-03 16:01 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 30213: Hide Delete (aka Priority) column when user only has place_hold permission (6.00 KB, patch)
2022-08-07 16:43 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Sara Brown 2022-03-02 14:57:12 UTC
With the change to holds permissions in Bug 29540, the Delete (or Priority, with full holds permissions) column isn't useful and is misleading for users with only the place_hold permission. They don't have the option to change holds' priority using the column, and if they select 'del' on a patron to delete their hold, they get locked out for having insufficient permissions when they click the Update Hold(s) button. But this is misleading because they *can* delete an individual  hold using the red X. It would be clearer if that entire column were hidden for users with only the place_hold permission.
Comment 1 Owen Leonard 2022-03-03 14:43:21 UTC Comment hidden (obsolete)
Comment 2 ByWater Sandboxes 2022-03-03 16:01:52 UTC
Created attachment 131336 [details] [review]
Bug 30213: Hide Delete (aka Priority) column when user only has place_hold permission

This patch changes the way the priority column displays when viewing a
list of holds as a user who doesn't have permission to change hold
priority.

To test:

- Apply the patch and log into the staff interface as a user with
  at least "place_hold" permission.
- Locate a record which can be put on hold and place multiple holds.
- View the list of holds.
- As a user with both "place_hold" and "modify_holds_priority"
  permission, you should see a "Priority" column with <select> fields
  allowing you to change hold priority. You should also see the arrow
  buttons for changing priority.
- As a user with only "place_hold" permission, the "Priority" column
  should show the priority as a number. You should not see the arrow
  buttons.
- In both cases, confirm that all operations work correctly: Changing
  hold date, expiration date, pickup library, suspended status;
  Cancelling holds.

Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
Comment 3 Christopher Brannon 2022-03-03 16:02:19 UTC
Works as described.
Comment 4 Katrin Fischer 2022-08-07 16:43:02 UTC
Created attachment 138761 [details] [review]
Bug 30213: Hide Delete (aka Priority) column when user only has place_hold permission

This patch changes the way the priority column displays when viewing a
list of holds as a user who doesn't have permission to change hold
priority.

To test:

- Apply the patch and log into the staff interface as a user with
  at least "place_hold" permission.
- Locate a record which can be put on hold and place multiple holds.
- View the list of holds.
- As a user with both "place_hold" and "modify_holds_priority"
  permission, you should see a "Priority" column with <select> fields
  allowing you to change hold priority. You should also see the arrow
  buttons for changing priority.
- As a user with only "place_hold" permission, the "Priority" column
  should show the priority as a number. You should not see the arrow
  buttons.
- In both cases, confirm that all operations work correctly: Changing
  hold date, expiration date, pickup library, suspended status;
  Cancelling holds.

Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 5 Tomás Cohen Arazi 2022-08-08 16:51:14 UTC
Pushed to master for 22.11.

Nice work everyone, thanks!