Bug 11450: Hold Request Confirm Deletion

==TEST PLAN==
1) Go to an item with a hold and click on the holds tab on the
left
2) Click the red 'X'
3) The hold will be deleted immediately
4) Apply patch
5) Return to an item with a hold and click the 'X'
6) There will now be a confirmation dialog
7) Click cancel and the dialog will disappear and the hold will not be
deleted
8) Click OK and the hold will be deleted

Restored indentations - Mark Tompsett

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 6ce97d9b06)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
This commit is contained in:
Luke Honiss 2017-01-19 02:55:31 +00:00 committed by Katrin Fischer
parent 3f1c6b05fa
commit 2d363f136d
1 changed files with 6 additions and 1 deletions

View File

@ -168,6 +168,11 @@ function checkMultiHold() {
$("#" + fieldID).val("");
});
// Confirm cancelation of hold
$(".cancel-hold").on("click",function(e) {
return confirmDelete(MSG_CONFIRM_DELETE_HOLD);
});
[% UNLESS ( borrowernumber || borrowers || noitems ) %]
[% IF ( CircAutocompl ) %]
@ -855,7 +860,7 @@ function checkMultiHold() {
[% END %]
<td>
<a title="Cancel hold" href="request.pl?action=cancel&amp;borrowernumber=[% reserveloo.borrowernumber %]&amp;biblionumber=[% reserveloo.biblionumber %]&amp;reserve_id=[% reserveloo.reserve_id %]&amp;date=[% reserveloo.date %]">
<a class="cancel-hold" title="Cancel hold" href="request.pl?action=cancel&amp;borrowernumber=[% reserveloo.borrowernumber %]&amp;biblionumber=[% reserveloo.biblionumber %]&amp;reserve_id=[% reserveloo.reserve_id %]&amp;date=[% reserveloo.date %]">
<img src="[% interface %]/[% theme %]/img/x.png" alt="Cancel" />
</a>
</td>