To recreate: - create a bib - add an item - create a volume - add item to volume - in the Holdings table on detail.pl, check the box to select your item and pick Delete selected items - on the next page, do not check "Delete records if no items remain" - click Delete selected items - return to your bib. the item and volume are both gone I don't think we should automatically delete the volume when removing the last item. I'd like to see another check box on the batch deletion screen -- "delete volumes if no items remain" to parallel "delete records if no items remain"
That functionality was actually a specific request from the sponsor. If we want to change it, we'll need to use a syspref.
I think deleting the volume with the last item makes sense, but maybe I am missing a use case here?
If there is a hold on the item group that gets automatically deleted, the hold reverts to "next available item," which is not what a patron would want. Also, moving the last item in one item group to a different one, leaves behind an empty item group without deleting it. I would prefer this be a system preference with the option to batch delete empty item groups rather than have some automatically delete and some get left behind, although that might be a separate bug.