1

I want to create a dialog to enable/disable columns for my jqGrid. There was a module for this, but his is no longer supported as of jqGrid 4.x.

Is there a replacement for this module, I did not find one. Anything already existing I could reuse - or what would be the easiest way to realize it?

From the jqGrid documentation (here), this is what I need:

Show/Hide columns

Horst Walter
  • 13,663
  • 32
  • 126
  • 228

1 Answers1

3

You should use columnChooser. I would recommend you to use modified code of the method which I published in the answer (see the demo). It makes Column Chooser Dialog resizable. You can just include the code with $.jgrid.extend({columnChooser : function ... }); after jquery.jqGrid.min.js or jquery.jqGrid.src.js and overwrite the original version of columnChooser with the modified version.

Community
  • 1
  • 1
Oleg
  • 220,925
  • 34
  • 403
  • 798
  • Can you address the issue we're facing as mentioned at the end of the thread - http://stackoverflow.com/questions/9687201/jqgrid-column-chooser-modal-overlay/9688942. The last line in 'columnChooser' extension is causing error and commenting it seems to work fine! – Hemant Tank Nov 11 '15 at 19:10
  • @HemantTank: Sorry, but I'm not sure what you do. First of all, yo references really old questions. **Which version of jqGrid you use and which fork?** The problem with `selector.data('dialog').uiDialog` is solved since a lot ot time. The problem was in the usge **more recent** version of jQuery UI (published after I posted the old answer). So, what you do exactly? – Oleg Nov 11 '15 at 19:34