<?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: JQGrid:  Get The Entire Data collection for Posting</title>
	<link>http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting</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/discussion/jqgrid-get-the-entire-data-collection-for-posting/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>Jose on JQGrid:  Get The Entire Data collection for Posting</title>
        	<link>http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26094</link>
        	<category>Discussion</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26094</guid>
        	        	<description><![CDATA[<p>Hello Tony,</p>
<p>Me again.&#160; If I add a function to jqGrid like this then I have access to the entire collection.</p>
<p><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;"></span></span></p>
<p>getJosesData:</p>
</p>
<p><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;">function</span></span></span><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;"> () {</p>
<p></span></p>
<p></span></p>
<p><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;">&#160;&#160;&#160;&#160; return</span></span></span><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;"> </span></span><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;">this</span></span></span><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;">[0].p.data;</span></span></p>
<p>},</p>
</p>
<p>then in my js file I call it like this:</p>
<p>
<span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"><span style="font-family: Consolas; color: #0000ff; font-size: x-small;"></span></span></span></p>
<p>var</p>
</p>
<p><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;"> d = $(</span></span><span style="font-family: Consolas; color: #800000; font-size: x-small;"><span style="font-family: Consolas; color: #800000; font-size: x-small;"><span style="font-family: Consolas; color: #800000; font-size: x-small;">&#39;#results-grid&#39;</span></span></span><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;">).jqGrid(</span></span><span style="font-family: Consolas; color: #800000; font-size: x-small;"><span style="font-family: Consolas; color: #800000; font-size: x-small;"><span style="font-family: Consolas; color: #800000; font-size: x-small;">&#39;getJosesData&#39;</span></span></span><span style="font-family: Consolas; font-size: x-small;"><span style="font-family: Consolas; font-size: x-small;">);</span></span></p>
</p>
<p>I could make it better and do it getting all ids then traverse the data...&#160; but this is not desirable.&#160; I understand your approach of doing the paging and updates on the server using the editUrl and posting.&#160; I tried to negotiate with the BA but the requirement continues to be "save once in a batch when the user clicks Save".&#160; This forces me to:</p>
<p>1.&#160; do a loadonce</p>
<p>2. cellsubmit: clientArray</p>
</p>
<p>The control works great if I only need to display under my requirementes, but I need to save and that is my problem.</p>
</p>
<p>How does JQGrid support saving the way I have mentioned?</p>
</p>
<p>Best Regards</p>
<p>Jose</p>
]]></description>
        	        	<pubDate>Thu, 08 Mar 2012 03:59:17 +0200</pubDate>
        </item>
        <item>
        	<title>Jose on JQGrid:  Get The Entire Data collection for Posting</title>
        	<link>http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26084</link>
        	<category>Discussion</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26084</guid>
        	        	<description><![CDATA[<p>Tony,</p>
<p>Thanks for your response.&#160; I am doing a loadonce and paginate.</p>
</p>
<p>Do you think that I should be posting to the server on some sort of event handler when the user completes navigation to the next view?&#160; The data is in memory already because the control loads it from page to page and when a change is made the clientArray gets is and it remembers if the user returns to that page.</p>
</p>
<p>Is there a way to acces "clientArray"?</p>
</p>
<p>Thanks</p>
]]></description>
        	        	<pubDate>Wed, 07 Mar 2012 18:14:48 +0200</pubDate>
        </item>
        <item>
        	<title>tony on JQGrid:  Get The Entire Data collection for Posting</title>
        	<link>http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26077</link>
        	<category>Discussion</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26077</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>This method using this way do exactley waht you want.</p>
<p>You should make a diffrence between client side data (this is partial data)</p>
<p>and server side data (this can be the whole data)</p>
</p>
<p>Regards</p>
]]></description>
        	        	<pubDate>Wed, 07 Mar 2012 15:43:08 +0200</pubDate>
        </item>
        <item>
        	<title>Jose on JQGrid:  Get The Entire Data collection for Posting</title>
        	<link>http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26067</link>
        	<category>Discussion</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26067</guid>
        	        	<description><![CDATA[<p>If I use:</p>
<p>var gr = $(&#39;#results-grid&#39;).jqGrid(&#39;getRowData&#39;); &#160;I only get the current view as well. &#160;It was suggested that usining getRowData, without parameters would return the entire collection but this does not work for me.</p>
</p>
<p>Any idea?</p>
]]></description>
        	        	<pubDate>Wed, 07 Mar 2012 04:28:47 +0200</pubDate>
        </item>
        <item>
        	<title>Jose on JQGrid:  Get The Entire Data collection for Posting</title>
        	<link>http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26066</link>
        	<category>Discussion</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/discussion/jqgrid-get-the-entire-data-collection-for-posting#p26066</guid>
        	        	<description><![CDATA[<p>Hello Everyone,</p>
<p>PRE: &#160;The grid contains several pages</p>
</p>
<p>PROBLEM: &#160;</p>
<p>1. The user navigates throught the grid and edits values on different pages</p>
<p>2. The user clicks "Save" button expecting to save the changes</p>
</p>
<p>RESULT:</p>
<p>Only records on the current view are saved</p>
<p>Here are things that I have done:</p>
</p>
<p>var batch = new Array();</p>
<p>var dataIds = $(&#39;#results-grid&#39;).jqGrid(&#39;getDataIDs&#39;);</p>
<p>for (var i = 0; i &#60; dataIds.length; i++) {</p>
<p><span style="white-space: pre;"> </span>var data = $(&#39;#results-grid&#39;).jqGrid(&#39;getRowData&#39;, dataIds[i]);</p>
<p><span style="white-space: pre;"> </span>batch.push(data);</p>
<p>}</p>
</p>
<p>Only the &#160;current view records are retrieved. &#160;Alternatively, I tried to hash the records by getting the getGridParam(&#39;records&#39;). &#160;This does not work either because when I try to get the record outside of the scope of the current view, using a loop, the row is undefined (getRowData(i)).</p>
</p>
<p>Is there a way to get all the data from the grid?</p>
<p>Is there a way to manually paginate?</p></p>
]]></description>
        	        	<pubDate>Wed, 07 Mar 2012 04:06:06 +0200</pubDate>
        </item>
</channel>
</rss>