Bug 32121: Show an alert when adding a checked out item to an item bundle
authorJulian Maurice <julian.maurice@biblibre.com>
Mon, 7 Nov 2022 13:30:34 +0000 (14:30 +0100)
committerTomas Cohen Arazi <tomascohen@theke.io>
Mon, 27 Mar 2023 10:50:02 +0000 (12:50 +0200)
commitde362442661cc5c2e66bd090a2eda474c19b2efb
tree6d91c611b819a7bbb0b4dc7ac71b7d29f0470128
parentf781fdb4a231e074b36099d0a724fad576518921
Bug 32121: Show an alert when adding a checked out item to an item bundle

When trying to add a checked out item to an item bundle, an alert
message will show up, giving the user a chance to return the item
immediately before adding it to the bundle

Test plan:
1. Create an item bundle (see bug 28854 comment 458)
2. Create a biblio with one item and check out this item.
3. Try to add the checked out item to the bundle
   You should see a message saying that the item is checked out. Next to
   this message should be a button "Check in and add to bundle".
4. Click on the button. There should be a message saying that the item
   was added to the bundle.
5. Close the modal window and verify that the item was correctly
   returned and added to the bundle

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Koha/Exceptions/Checkin.pm [new file with mode: 0644]
Koha/Exceptions/Item/Bundle.pm
Koha/Item.pm
Koha/REST/V1/Items.pm
api/v1/swagger/definitions/bundle_link.yaml
koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt
t/db_dependent/Koha/Item.t