From 953980a5dd1866bc24316be3dc0a37736466221f Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Tue, 27 Oct 2020 14:01:47 -0400 Subject: [PATCH] Bug 26633: (QA follow-up) Action buttons should not remain grayed out if the same action is used multiple times in a row Signed-off-by: Katrin Fischer Signed-off-by: Tomas Cohen Arazi Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart --- .../prog/en/modules/admin/transfer_limits.tt | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/transfer_limits.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/transfer_limits.tt index dbf812678b..d652fb987e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/transfer_limits.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/transfer_limits.tt @@ -359,10 +359,12 @@ checkbox.attr('checked', false); $(`#spinner-${id}`).hide(); checkbox.show(); - $('.limit-action').removeClass('disabled'); - $('#value_selector').prop('disabled',false); } }, + complete: function() { + $('.limit-action').removeClass('disabled'); + $('#value_selector').prop('disabled',false); + }, error: function(xhr, status, error) { var errorMessage = xhr.status + ': ' + xhr.statusText alert('Error - ' + errorMessage); @@ -389,10 +391,12 @@ checkbox.attr('checked', true); $(`#spinner-${id}`).hide(); checkbox.show(); - $('.limit-action').removeClass('disabled'); - $('#value_selector').prop('disabled',false); } }, + complete: function() { + $('.limit-action').removeClass('disabled'); + $('#value_selector').prop('disabled',false); + }, error: function(xhr, status, error) { var errorMessage = xhr.status + ': ' + xhr.statusText alert('Error - ' + errorMessage); -- 2.39.5