From edd98f946b079db9257a88145816b3ea3a29b655 Mon Sep 17 00:00:00 2001 From: Fiona Ebner Date: Mon, 20 Nov 2023 15:53:56 +0100 Subject: [PATCH] notification matcher: fix inverted match modes The 'not' prefix is already stripped in the set() method of the view model's 'rootMode' and not present anymore when updating the store. The information about whether the mode is inverted or not is present in the 'invert' data member. Signed-off-by: Fiona Ebner --- src/window/NotificationMatcherEdit.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/window/NotificationMatcherEdit.js b/src/window/NotificationMatcherEdit.js index 5a88288..ee08c16 100644 --- a/src/window/NotificationMatcherEdit.js +++ b/src/window/NotificationMatcherEdit.js @@ -778,12 +778,8 @@ Ext.define('Proxmox.panel.NotificationMatchRuleTree', { matchCalendarStmts.push(data.value); break; case 'mode': - if (data.value.startsWith('not')) { - modeStmt = data.value.substring(3); // after 'not'' - invertMatchStmt = true; - } else { - modeStmt = data.value; - } + modeStmt = data.value; + invertMatchStmt = data.invert; break; }