Bug 35901 - Tell library on About page when item-level_itypes is set but there are items with no itemtype in the database
Summary: Tell library on About page when item-level_itypes is set but there are items ...
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: About (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-01-24 22:08 UTC by Aleisha Amohia
Modified: 2024-02-20 09:56 UTC (History)
3 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Aleisha Amohia 2024-01-24 22:08:36 UTC
If item-level_itypes is set to 'specific item', using or accessing an item with no itype causes Koha to throw a 500 error.

There will be a more helpful warning in the logs, i.e. "[2024/01/25 08:59:52] [WARN] item-level_itypes set but no itemtype set for item (41984) at /usr/share/koha/lib/Koha/Schema/Result/Item.pm line 999."

But this isn't very helpful for the library.

It would be great to have a check that gets the value of the item-level_itypes system preference, if set to 'specific item', gets a list of any items with no itype, and displays this in the System Information tab in the About module, as a warning. Then the library can run a batch modification and give the items itypes, or change the system preference.