Bug 20948: Only display item-level hold info if first hold
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Mon, 18 Nov 2019 09:30:04 +0000 (10:30 +0100)
committerHayley Mapley <hayleymapley@catalyst.net.nz>
Thu, 9 Jan 2020 22:58:19 +0000 (11:58 +1300)
commit0db0fe92f00252eed007258034f4a8508c756b3c
tree2d852045ec1da02d04de40cb5b8edea885467ad7
parentcaf97029df8266f9c0ccba090cd75285fafd1224
Bug 20948: Only display item-level hold info if first hold

On the item list of the catalogue detail page we display next item-level
hold info even if it is not the next hold. That leads to confusion as it
will not necessarily be the accurate info.

This patch makes the following changes:
- Display the item-level hold only if it is the next hold (priority ==
1)
- Display "There is an item level hold on this item (priority=X)"
if there is at least 1 item-level hold placed on this item

Test plan:
- Place several next available holds on a single item record
- Place an item level hold on the item
- Go the the biblio detail page
=> Without this patch, the item will show the item level hold
=> With the patch you see "There is an item level hold on this item"
- Check the item in, confirm the hold
=> No changes, the item will show the waiting hold info
- Cancel all the holds except the item-level one
=> No changes, the item will how the item-level one

Signed-off-by: Lisette Scheer <lisetteslatah@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
(cherry picked from commit 6998a32ca4e29313a02b020d9e36c0c75f129fb1)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit e46289d12c99f3fabf0d00cdd71ec8f921d69be2)
Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>
koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt