<?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 3.8, Groups, and AfterInsertRow</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/jqgrid-3-8-groups-and-afterinsertrow</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/jqgrid-3-8-groups-and-afterinsertrow/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>Greg B on jqGrid 3.8, Groups, and AfterInsertRow</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/jqgrid-3-8-groups-and-afterinsertrow#p19968</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/jqgrid-3-8-groups-and-afterinsertrow#p19968</guid>
        	        	<description><![CDATA[<p>Figured it out so for anyone interested...</p>
</p>
<p>Instead of hooking into the &#39;afterInsertRow&#39; event, since using groups, this won&#39;t fire, so using the &#39;loadComplete&#39; event with a function such as:</p>
</p>
<p>function myLoadCompleteFunction(data) {</p>
<p>&#160;&#160;&#160; <br />&#160;&#160; &#160;if (data.records&#62;0) { // there&#39;s data worth scanning<br />&#160;&#160; &#160;&#160;&#160; <br />&#160;&#160; &#160;&#160;&#160; &#160;for ( var rowno in data.rows ) {<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;var row = data.rows[rowno];<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;if ($(POL.currentGrid).getCell(row.id,"order_cancelled")=="true") {<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;$(&#39;#&#39; + row.id+" td").addClass("ordercancelled");<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;}<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;else if ($(POL.currentGrid).getCell(row.id,"orderonhold")=="true") {<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;$(&#39;#&#39; + row.id+" td").addClass("orderonhold");&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;}&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;else if ($(POL.currentGrid).getCell(row.id,"isitchanged")=="true") {<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;$(&#39;#&#39; + row.id+" td").addClass("orderchanged");<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;}<br />&#160;&#160; &#160;&#160;&#160; &#160;}<br />&#160;&#160; &#160;}<br />}</p>
</p>
<p>Greg</p>
]]></description>
        	        	<pubDate>Thu, 23 Sep 2010 23:02:42 +0300</pubDate>
        </item>
        <item>
        	<title>Greg B on jqGrid 3.8, Groups, and AfterInsertRow</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/jqgrid-3-8-groups-and-afterinsertrow#p19962</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/jqgrid-3-8-groups-and-afterinsertrow#p19962</guid>
        	        	<description><![CDATA[<p>Hi</p>
</p>
<p>I&#39;m using jqGrid in an application that colors the resulting text (via classes) depending on their values. Prior to 3.8, I had a colorow() function as the parameter value passed to AfterInsertRow and always set gridview to false. Everything worked well.</p>
</p>
<p>With version 3.8, I wanted to take advantage of Groups and have all that working nicely as well however this conflicts with using AfterInsertRow since gridview is set to true (per <a href="http://www.trirand.com/jqgridwiki/doku.php?id=wiki:grouping" rel="nofollow" target="_blank"><a href="http://www.trirand.com/jqgridw" rel="nofollow">http://www.trirand.com/jqgridw</a>.....i:grouping</a>)</p>
</p>
<p>Can someone recommend a strategy to get the same effect? (setting classes according to a particular row value)</p>
</p>
<p>Thank you</p>
<p>Greg</p>
</p>
<p>By the way, jqGrid is truly an amazingingly powerful plugin!!</p>
]]></description>
        	        	<pubDate>Thu, 23 Sep 2010 20:37:49 +0300</pubDate>
        </item>
</channel>
</rss>