mirror of
https://github.com/Combodo/iTop.git
synced 2026-03-05 00:54:12 +01:00
Advanced search: Fix criteria closed after search modal.
SVN:trunk[5695]
This commit is contained in:
@@ -101,14 +101,6 @@ $(function()
|
||||
this._super( key, value );
|
||||
},
|
||||
|
||||
_initChooseDefaultOperator: function() {
|
||||
//if the class has an index, in order to maximize the performance, we force the default operator to "equal"
|
||||
if (this.options.field.has_index && typeof this.options.available_operators['='] == 'object')
|
||||
{
|
||||
this.options.operator = '=';
|
||||
this.options.available_operators['='].rank = -1;//we want it to be the first displayed
|
||||
}
|
||||
},
|
||||
// Protected methods
|
||||
// - Init operators by cleaning up available operators and ordering them.
|
||||
// Note: A null operator or an operator with a rank "false" will be removed.
|
||||
@@ -157,6 +149,15 @@ $(function()
|
||||
this.options.operator = Object.keys(this.operators)[0];
|
||||
}
|
||||
},
|
||||
_initChooseDefaultOperator: function()
|
||||
{
|
||||
//if the class has an index, in order to maximize the performance, we force the default operator to "equal"
|
||||
if (this.options.field.has_index && typeof this.options.available_operators['='] == 'object')
|
||||
{
|
||||
this.options.operator = '=';
|
||||
this.options.available_operators['='].rank = -1;//we want it to be the first displayed
|
||||
}
|
||||
},
|
||||
// - Bind external events
|
||||
_bindEvents: function()
|
||||
{
|
||||
|
||||
@@ -91,7 +91,9 @@ $(function()
|
||||
_onAddSelectedValues: function(oData)
|
||||
{
|
||||
this._addSelectedValues(oData);
|
||||
//this._apply();
|
||||
// Note: Selecting values elsewhere (eg. a popup) closes the criteria on the first click, so when the user goes back to the form, the criteria has the new values displayed but not selected. So as a workaround we apply and re-open the criteria.
|
||||
this._apply();
|
||||
this._open();
|
||||
},
|
||||
|
||||
// DOM element helpers
|
||||
|
||||
Reference in New Issue
Block a user