tonytomov/jqGrid — comment on commit ade910682a03d633737ef1499f46675122d1b86e
File:  line 0
By OlegKi:

Hello Tony,

I like also short and good readable code, but first of all one should make the code work correctly and then simplify/improve it. At the beginning I didn't want to implement column resorting at all, but then I found one problem. The only official supported column hider/shower dialog is `columnChooser` and it has one important problem. If some hidden column exist (like Tax or Id columns in the demo) and one want just to show the hidden columns the `columnChooser` adds the columns **at the end** of the column list and not at the original position. This behavior makes the implementation of `remapColumns` as required.

By the way. The current implementation has one bug which I didn't yet fixed. To reproduce the bug one should do the following steps in [the demo](http://www.ok-soft-gmbh.com/jqGrid/SimpleLocalGridHeadersNew4.htm):
1) create the grid with the standard settings and add column headers using `useColSpanStyle:true`
2) using the `columnChooser` move the "Date" column between "Shipping" and "Notes" and click OK.
3) using the `columnChooser` move the "Date" column between "Total" and "Closed" and click OK. If any hidden column exists in the bottom header row (like "Tax"), the header movement work incorrect.

I have to drive to my customer now. If you would have time you can examine the problem. It would be additionally very good if you could change the behavior of the `columnChooser` so that it places the hidden column at it's original position if the user just click on the "+" on the right of the hidden column.

Best regards
Oleg