Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Michael Bartos on Oct 20, 2008 07:03
open dhtmlx forum
Icons for sorting direction in wrong column

Hello, when using the grid's sorting function, the icon indication the sort direction is put into the wrong column. It works find with all columns before the auto-size column. All following-columms are not correct.

You can see the example here:
http://www.########.com/de/grid.php

Sorting on "Hersteller" (=manufacturer) works fine. Sorting on "Product" or "Price" puts the icon into the next column.

Any idea?

Thank you,
Mike
Answer posted by Support on Oct 21, 2008 09:57
Problem with sorting marker and flexible columns confirmed. 
As fast solution change existing code 
  mygrid.loadXML(gridQString+(gridQString.indexOf("?")>=0?"&":"?")+"orderby="+ind+"&direct="+direct);
  mygrid.setSortImgState(true,ind,direct);

To the 

mygrid.loadXML(gridQString+(gridQString.indexOf("?")>=0?"&":"?")+"orderby="+ind+"&direct="+direct,function(){
         mygrid.setSortImgState(true,ind,direct);
});