Bug 40588 - Clarify impact of edit_any_item permission when no library groups are defined
Summary: Clarify impact of edit_any_item permission when no library groups are defined
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on: 20256
Blocks:
  Show dependency treegraph
 
Reported: 2025-08-04 14:29 UTC by Andrew Fuerste-Henry
Modified: 2025-08-04 23:28 UTC (History)
3 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Fuerste-Henry 2025-08-04 14:29:50 UTC
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20256#c342

Per discussion on Bug 20256, the intended behavior is that when no library groups are defined a user with edit_items but not edit_any_item should only be able to edit items with a homebranch matching the user's logged in branch. Koha's doing this successfully, but the permissions and manual aren't clear about what the user should expext.

The edit_items permission says: "Edit items (not including items restricted by library group) (edit_items)"

The edit_any_item permissions says "Edit any item including items that would otherwise be restricted"

The manual says of edit_any_item "This permission grants the ability to edit items belonging to libraries from other library groups."

Together, these imply the assumption that item edits are unrestricted *unless* one defines library groups with the "Limit item edits" option set.
Comment 1 Andrew Fuerste-Henry 2025-08-04 14:59:27 UTC
Testing reveals a complication that I *think* is a bug. To recreate:

- have a user with edit_items but not edit_any_item, user library Centerville
- have no library groups defined
- have a bib with 3 items
 -- item 1: homebranch and holdingbranch Centerville
 -- item 2: homebranch and holdingbranch Fairfield
 -- item 3: homebranch and holdingbranch Liberty

- Log in as your user, at Centerville
- navigate to /cgi-bin/koha/cataloguing/additem.pl for your bib
- confirm the Actions buttons for your items only show the Edit option for the Centerville item

- create a library group, do not check "Limit item editing by group" or any other feature
- reload your item edit page, confirm you can still only edit the Centerville item
- add Fairfield to your library group
- reload your item edit page, confirm you can still only edit the Centerville item
- add Centerville to your library group
- reload your item edit page, confirm you can now edit the Centerville, Fairfield, AND Liberty items
** Only groups with "Limit item editing" checked should impact which items can be edited


- remove Fairfield from your group
- make a new group, select "Limit item editing by group"
- add Fairfield and Liberty to your new group
- reload your item edit page, confirm your user can still edit any item
** The existence of a group that contains the users' library and does not have "limit item editing by group" checked should not override the existence of other groups that do have "limit item editing" checked