From e269d6e6e6c9d1e3e11ae43a7773f3026f4d801a Mon Sep 17 00:00:00 2001 From: Fridolin Somers Date: Wed, 31 May 2017 16:24:51 +0200 Subject: [PATCH] Bug 18707: Background jobs post disabled inputs For example, in Tools > Batch item modification input of deleted subfields are disabled. This form is posted using background job via JS code. Looks like this JS code converts a POST form into a GET URL, including inputs that are disabled : koha-tmpl/intranet-tmpl/prog/js/background-job-progressbar.js function submitBackgroundJob(f) { ... $(':input', f).each(function() { ... This patch add a :enabled to selector Test plan : Signed-off-by: Kyle M Hall Signed-off-by: Katrin Fischer Signed-off-by: Martin Renvoize --- .../prog/js/background-job-progressbar.js | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/background-job-progressbar.js b/koha-tmpl/intranet-tmpl/prog/js/background-job-progressbar.js index df40e13..5ddb405 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/background-job-progressbar.js +++ b/koha-tmpl/intranet-tmpl/prog/js/background-job-progressbar.js @@ -42,7 +42,7 @@ function submitBackgroundJob(f) { // gather up form submission var inputs = []; - $(':input', f).each(function() { + $(':input:enabled', f).each(function() { if (this.type == 'radio' || this.type == 'checkbox') { if (this.checked) { inputs.push(this.name + '=' + encodeURIComponent(this.value)); -- 1.7.2.5