Sorting in apaged grid
Hi Everyone (especially Alex)
I need it the grid to be paged so I made the following modifications:
Now, when the results are sorted, this is done at the page level, and not at the whole set.
I need that the results to be sorted and reload the grid with the sorted data, and present the first page.
Regards,
I need it the grid to be paged so I made the following modifications:
// Begin modifications
obj.response=function(text){
this._rows=text.split(/\r*\n/);
if(!this._rows[this._rows.length-1]){
this._rows.pop()
}
this._data=[];
if(this.$owner){
this.$owner.clearScrollModel();
this.$owner.clearSelectedModel();
this.$owner.clearSortModel();
this.$owner.clearRowModel();
// Behavior if the number of rows is specified
if(number_of_rows == null){
this.$owner.setRowCount(this.getCount());
}else{
if(this.getCount() > 1){
this.$owner.setRowCount(number_of_rows);
}else{
this.$owner.setRowCount(this.getCount());
}
}
// End modifications[/b][/b]
this.$owner.refresh();
}
}
...
Now, when the results are sorted, this is done at the page level, and not at the whole set.
I need that the results to be sorted and reload the grid with the sorted data, and present the first page.
Regards,
Marius
September 13,