title: jqGrid showCol/hideCol not working after sorting
body: <p>The below given code illustrates what I have done fro hide/show. It does work on load but wouldn't work after sorting          </p>
  
  <pre><code>grid.jqGrid({
      url: "processing.php",
      datatype: "json",
      mtype: "POST",
      postData: { "sessionTicket": "&lt;?php echo $sessionTicket; ?&gt;" },
      colNames: ["Details", "Name", "Address", "Date"],
      colModel: [
          {
              id: "details", name: "Details", width: 200, classes: 'pointer wrap',
              formatter: function matterFormatter(cellvalue, options, rowObject) {
                  if (rowObject.properties == undefined) {
                      name = rowObject.name;
                      address = rowObject.address;
                  } else {
                      name = rowObject.properties.name;
                      address = rowObject.properties.address;
                  }
                  details = '&lt;strong&gt; ' + name + '&lt;/strong&gt; &lt;/br&gt;&lt;strong&gt; ' + address + '&lt;/strong&gt;';
                  return details;
              }, sorttype: function (cell, obj) {
                  name = obj.name;
                  return name;
              }
          },
          { name: "name", jsonmap: "properties.name", width: 200, classes: 'pointer wrap', hidden: true },
          { name: "address", jsonmap: "properties.address", width: 100, classes: 'wrap' },
          { name: "date", jsonmap: "properties.3", width: 55, formatter: 'date', formatoptions: { srcformat: 'u', newformat: 'd M Y' }, sortable: true, sorttype: 'date' }
      ],
      pager: "#pager",
      //rowNum: 20,
      rowNum: 100,
      rowList: [10, 20, 30],
      sortname: "matter",
      sortorder: 'asc',
      viewrecords: true,
      gridview: true,
      loadonce: true,
      autoencode: true,
      height: 'auto',
      hidegrid: false,
      caption: "Details",
      jsonReader: {
          repeatitems: false
      },
      loadComplete: function () {
          $("#list").setCaption('Jqgrid   &lt;input type="button" id="chooseField" value="Select Fields"  title="Click to Select Fields" /&gt;');
          var $dialog = $('&lt;div&gt;&lt;/div&gt;')
              .html('&lt;form id="myform" &gt;' +
              '&lt;input type="checkbox" id="selectAll" value="selectAll" onClick="allField()" /&gt;&lt;strong&gt;&lt;label for="selectAll"&gt;Select All&lt;/label&gt;&lt;/strong&gt;&lt;br /&gt;' +
              '&lt;input type="checkbox" id="details" value="details" checked /&gt;&lt;label for="details"&gt;Details&lt;/label&gt;&lt;br /&gt;' +
              '&lt;input type="checkbox" id="name" value="name" checked /&gt;&lt;label for="name"&gt;Name&lt;/label&gt;&lt;br /&gt;' +
              '&lt;input type="checkbox" id="address" value="address" checked/&gt;&lt;label for="address" checked&gt;Address&lt;/label&gt;&lt;br /&gt;' +
              '&lt;input type="checkbox" id="date" value="date" checked/&gt;&lt;label for="date" checked&gt;Date&lt;/label&gt;&lt;br /&gt;' +
              '&lt;/form&gt;')
          .dialog({
              autoOpen: false,
              title: 'Select Fields ',
              height: 300,
              width: 350,
              position: [2, 28],
              buttons: {
                  "OK": function () { field(); $(this).dialog("close"); },
                  "Cancel": function () { $(this).dialog("close"); }
              }
          });
  
          $('#chooseField').click(function () {
              $dialog.dialog('open');
              return false;
          });
  
          $('form#myform').submit(function () {
              $(this).find('input[type="checkbox"]').each(function () {
                  if ($(this).is(':checked') == true) {
                      alert($(this).val());
                  }
              })
          });
      }
  });
  
  function field() {
      if ($('#Details').is(':checked') == true) {
          $('#list').showCol('Details');
      } else {
          $('#list').hideCol('Details');
      }
  
      if ($('#name').is(':checked') == true) {
          $('#list').showCol('name');
      } else {
          $('#list').hideCol('name');
      }
  
      if ($('#address').is(':checked') == true) {
          $('#list').showCol('address');
      } else {
          $('#list').hideCol('address');
      }
  
      if ($('#date').is(':checked') == true) {
          $('#list').showCol('date');
      } else {
          $('#list').hideCol('date');
      }
  }
  </code></pre>
  
  <p>Any help is appreciated . I hope this would be a minor tweak would be excellent if someone could help me out in this 
  Thanks in advance </p>