Commit 33578cd9 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Update GridWithFilter to activate the filtering when the ENTER key is pressed.

parent 88e90e5f
......@@ -26,6 +26,11 @@ Ext.define("Dbui.panel.GridWithFilter", {
filter: null,
grid: null,
// private key map
keyMap: {
ENTER: "onEnterKey"
},
// Private properties for internationalization
textLoad: "Loading...",
......@@ -46,6 +51,7 @@ Ext.define("Dbui.panel.GridWithFilter", {
// connect buttons
if (me.filterOnChange) {
me.keyMapEnabled = false;
me.goButton.hide();
} else {
......@@ -76,7 +82,19 @@ Ext.define("Dbui.panel.GridWithFilter", {
me.resetButton.un("click", me.filter.onReset, me.filter);
me.callParent(arguments);
}
},
// jshint strict: true
/**
* Handler to click on the Go button when the ENTER key is pressed
*
*/
onEnterKey: function () {
"use strict";
var me = this;
me.goButton.click();
}
});
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment