0

I know you can go one by one and disable sorting of columns. How can you disable it globally? Or is it simply impossible? Did I mention that this was an HTML table initially and converted to a jqgrid with the expansion function they have.

Thanks.

Robert Harvey
  • 178,213
  • 47
  • 333
  • 501
SoftwareSavant
  • 9,467
  • 27
  • 121
  • 195

1 Answers1

1

You can use column template. To set sortable: false for all columns of jqGrid or just to set it as the default value for the sortable property you can use

cmTemplate: {sortable: false}

as additional jqGrid option. If you use tableToGrid then you should just add the same option to the second parameter of tableToGrid:

tableToGrid('#list', {cmTemplate: {sortable: false}});

UPDATED: I don't understand where you have any problem. Here you will find very simple demo which work. If you would click on any column header the grid will be not sorted.

Community
  • 1
  • 1
Oleg
  • 220,925
  • 34
  • 403
  • 798
  • cmTemplate... That sounds like something worth trying. So far, nothing has worked, including attempting to make each row unsortable – SoftwareSavant Oct 28 '11 at 10:50
  • @DmainEvent. I posted demo example for you. See "UPDATED" part of my answer. – Oleg Oct 28 '11 at 11:17