ParamQuery grid support forum

General Category => Help for ParamQuery Pro => Topic started by: rickpqu on June 15, 2016, 03:02:07 am

Title: Column header filtering behavior
Post by: rickpqu on June 15, 2016, 03:02:07 am
Hi, at http://, if you click "Variant" tab on the top left corner, and scroll the table to the bottom, and then type "r" in the column header filtration box under the column "HUGO symbol", then the table is filtered correctly, but I'd like to move the focus on the table to the top row of it. How can I do this?

I tried colModel's listeners, but it didn't seem to have any effect. For example, I tried the following.

var cm = grid.pqGrid('option', 'colModel');
cm[9].filter = {type: 'textbox', condition: 'contain', listeners:[ {'keyup': function(evt, ui) {alert('here');} ]};
grid.pqGrid('option', 'colModel', cm);

Then, typing a letter in the HUGO symbol column header filter box does not open the alert dialog.



Edit: url removed.
Title: Re: Column header filtering behavior
Post by: paramvir on June 15, 2016, 09:53:15 pm
I assume you mean scroll the view to show first row without losing focus in the filter textbox.

It can be done by scroll to first row in the filter event callback which can be added in the initialization object.

Code: [Select]
filter: function(){
this.scrollRow( { rowIndxPage: 0 });
},
Title: Re: Column header filtering behavior
Post by: rickpqu on June 15, 2016, 10:07:50 pm
Thanks. That worked.