Bug 27864: Visual feedback on overridden pickup locations when placing hold
authorTomas Cohen Arazi <tomascohen@theke.io>
Fri, 12 Mar 2021 21:01:28 +0000 (18:01 -0300)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Fri, 30 Apr 2021 15:19:01 +0000 (17:19 +0200)
commitfd5e603c3d80975867d95bdd7de714a16b58c0fd
tree667a6f72ee65bb8f2e2ce7ddf9c1b25f6a0d9d03
parent2db98432d85568943c92bb1cd092960edb1e64eb
Bug 27864: Visual feedback on overridden pickup locations when placing hold

This patch makes the form for placing a hold, use the API to retrieve
the valid pickup locations for a biblio.

To test:
1 - In Circulation and fines rules > Default checkout, hold and return policy, change 'Hold pickup library match' to 'item's home library'
2 - Set AllowHoldPolicyOverride system preference to Allow
3 - Try placing a hold on a biblio with several items.
    Ensure that there is one item with homebranch of the patrons branch and
    one at another branch
4 - Note the pickup location dropdown lists all branches, even those not matching the policy (Item's home library)
5 - FAIL: There's no sign they are overrides to rules
6 - Apply the patch
7 - Repeat 3
8 - SUCCESS: Same behavior as before all libraires listed, but there's a sign
    + tooltip for overridden ones.
9 - Sign off :-D

Note: styling follow-up coming

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt