<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
	<title>jQuery Grid Plugin - jqGrid - Topic: Column chooser with database</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/column-chooser-with-database</link>
	<description><![CDATA[Grid plugin]]></description>
	<generator>Simple:Press Version 5.7.5.3</generator>
	<atom:link href="http://www.trirand.com/blog/?page_id=393/help/column-chooser-with-database/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>tony on Column chooser with database</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/column-chooser-with-database#p30779</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/column-chooser-with-database#p30779</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>You can use </p>
<p><input type='button' class='sfcodeselect' name='sfselectit9043' value='Select Code' data-codeid='sfcode9043' /></p>
<div class='sfcode' id='sfcode9043'>$.ajax({<br />
  url: 'yoururl',<br />
  data: 'yourdata',<br />
  ...<br />
});
</div>
<p>See jQuery docs.</p>
<p>Regards</p>
]]></description>
        	        	<pubDate>Thu, 19 Jun 2014 12:00:31 +0300</pubDate>
        </item>
        <item>
        	<title>JqUsername on Column chooser with database</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/column-chooser-with-database#p30768</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/column-chooser-with-database#p30768</guid>
        	        	<description><![CDATA[<p>Hi,</p>
<p>Â </p>
<p>I have some cases where I have a lot of columns, so naturally - I use column chooser - but I also want that the DB backend to select the appropriate columns.</p>
<p>For that, I need to know each time column chooser submit - and the columns chosen.</p>
<p>I managed to do that...</p>
<p>jQuery("#scroll37").jqGrid ('navButtonAdd','#pscroll37',{<br />
Â  caption: "", buttonicon: "ui-icon-calculator", title: "choose columns",<br />
Â  onClickButton: function() {<br />
Â  Â  jQuery("#scroll37").jqGrid('columnChooser', {<br />
Â  Â  Â  done: function(perm) {<br />
Â  Â  Â  Â  Â if (perm) {<br />
Â  Â  Â  Â  Â  Â  Â alert("The column chooser closed with 'OK' button");<br />
Â  Â  Â  Â  Â  Â  Â var cols = [];<br />
Â  Â  Â  Â  Â  Â  Â $.each(<br />
Â  Â  Â  Â  Â  Â  Â $('#scroll37').jqGrid('getGridParam', 'colModel'),<br />
Â  Â  Â  Â  Â  Â  Â function () {<br />
Â  Â  Â  Â  Â  Â  Â if (!this.hidden &#38;&#38; !this.hidedlg) {<br />
Â  Â  Â  Â  Â  Â  Â  Â  Â cols.push(this.index);<br />
Â  Â  Â  Â  Â  Â  Â  Â  Â alert(this.index);<br />
Â  Â  Â  Â  Â  Â  Â  Â  Â alert(this.name);<br />
Â  Â  Â  Â  Â  Â  Â  Â  Â //problem here: $("#scroll37").trigger("reloadGrid");<br />
Â  Â  Â  Â  Â  Â  Â }<br />
Â  Â  Â  Â  Â }<br />
Â  Â  Â );<br />
Â  } else {</p>
<p>Â  Â alert("The column chooser closed with 'Cancel' button");</p>
<p>Â  Â  }<br />
 }});<br />
 }});</p>
<p>The problem is where it says "//problem here" in the code:Â After I know which columns were selected, I want to respond to the event. If I refresh the grid, it resets itself completley (even if I were at the bottom of the grid, it will load it all again)... So I'm looking for a way to trigger the call to the url - and of course I want to be able to pass parameters (to pass the columns).</p>
<p>Â </p>
<p>So something like this:</p>
<p>$("#grid").jqgrid('callUrl','myUrl?columns=a,b,c');</p>
<p>But haven't been able to find such API.</p>
<p>Thank you.</p>
]]></description>
        	        	<pubDate>Mon, 16 Jun 2014 09:08:35 +0300</pubDate>
        </item>
</channel>
</rss>