From c93a8de89d7ea46484e4eb6acde522701111824a Mon Sep 17 00:00:00 2001 From: Thomas Lamprecht Date: Tue, 15 Nov 2022 15:26:05 +0100 Subject: [PATCH] ui: prune job edit: fix disabling jobs The backend doesn't have an 'enable' option, but 'disable'. Convert it to avoid a negative value that is checked "enabled". Signed-off-by: Thomas Lamprecht --- www/window/PruneJobEdit.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/www/window/PruneJobEdit.js b/www/window/PruneJobEdit.js index 87be71ade..29ec56848 100644 --- a/www/window/PruneJobEdit.js +++ b/www/window/PruneJobEdit.js @@ -56,6 +56,16 @@ Ext.define('PBS.window.PruneJobEdit', { values.delete = values.delete.split(','); } } + values.disable = !values.enable; + delete values.enable; + + return values; + }, + onSetValues: function(values) { + let me = this; + values.enable = !values.disable; + delete values.disable; + return values; }, column1: [