From d04fb645ec6732458926034b0931c67887178239 Mon Sep 17 00:00:00 2001 From: Bruno Da Silva Date: Tue, 20 Mar 2018 10:04:33 +0000 Subject: [PATCH] search widget : delete the "oql" parameter once the widget is modified SVN:b1162[5463] --- js/search/search_form_criteria.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/js/search/search_form_criteria.js b/js/search/search_form_criteria.js index 9b74a2a951..9dcb63aee7 100644 --- a/js/search/search_form_criteria.js +++ b/js/search/search_form_criteria.js @@ -242,10 +242,17 @@ $(function() // Update widget this.options.operator = oActiveOpElem.find('.sfc_op_radio').val(); - this.options.values = aValues; - this._setTitle(); + + if (JSON.stringify(this.options.values) != JSON.stringify(aValues)) + { + this.is_modified = true; + this.options.oql = ''; + this.options.values = aValues; + this._setTitle(); + } this._unmarkAsDraft(); + // Trigger event to handler this.handler.triggerHandler('itop.search.criteria.value_changed'); },