:: Forum >> Version 1 >>

Cancel sort but not visual action

Well I think the title explains this one :)

I am using AJAX so I am quering server for sorted data so I just want the grid to update it's header correctly but stop the sort still since theres no point since I am gonna populate the grid with sorted data

any help is appreciated
Wednesday, July 20, 2005
ok found the solution to this though I would share :)

Grid.setAction("columnSort", function(src){
var i = src.getItemProperty("index");
var d = (this.getSortProperty("index") == i) && (this.getSortProperty("direction")=="ascending") ? "descending" : "ascending";
window.status = "Sorting...";

// Put your code in here to query server and load data back


this.setSortProperty("index", i);
this.setSortProperty("direction", d);
this.refresh();
this.timeout(function(){window.status = ""});
});
Wednesday, July 20, 2005



This topic is archived.

Back to support forum

Forum search