<?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: treegrid with local data and issue with jsonmap</title>
	<link>http://www.trirand.com/blog/?page_id=393/treegrid/treegrid-with-local-data-and-issue-with-jsonmap</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/treegrid/treegrid-with-local-data-and-issue-with-jsonmap/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>OlegK on treegrid with local data and issue with jsonmap</title>
        	<link>http://www.trirand.com/blog/?page_id=393/treegrid/treegrid-with-local-data-and-issue-with-jsonmap#p28751</link>
        	<category>TreeGrid</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/treegrid/treegrid-with-local-data-and-issue-with-jsonmap#p28751</guid>
        	        	<description><![CDATA[<p>One can find the answer of the problem in <a href="http://stackoverflow.com/a/16468439/315935" target="_blank">my answer</a> on the stackoverflow. The main advice one have to use <strong>datatype: "jsonstring"</strong> instead of <strong>datatype: "local"</strong> to have support of <strong>jsonmap</strong> property in <strong>colModel</strong>.</p>
]]></description>
        	        	<pubDate>Fri, 10 May 2013 16:25:06 +0300</pubDate>
        </item>
        <item>
        	<title>RRK on treegrid with local data and issue with jsonmap</title>
        	<link>http://www.trirand.com/blog/?page_id=393/treegrid/treegrid-with-local-data-and-issue-with-jsonmap#p28747</link>
        	<category>TreeGrid</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/treegrid/treegrid-with-local-data-and-issue-with-jsonmap#p28747</guid>
        	        	<description><![CDATA[<div class="post-text">
<p>I am loading a treegrid using local data. For some reason,  jqGrid is displaying cell values</p>
<p>based on "name" property and not  "jsonmap" property of the colModel.</p>
<p>Here is a simplified version of the grid and the local data. With the  below configuration,</p>
<p>I get empty values in the "Qty" column. However,  if in "mydata" I change "qty1&#8243; to "qty"</p>
<p>I get values in the "Qty"  column.</p>
<pre><p><input type='button' class='sfcodeselect' name='sfselectit7966' value='Select Code' data-codeid='sfcode7966' /></p><div class='sfcode' id='sfcode7966'>var mydata =  {&#34;rows&#34;:[
    {id: 1221,name: &#34;P1&#34;,qty1: &#34;1&#34;, level: 0,parent: &#34;NULL&#34;,isLeaf: false, <br />loaded: true, expanded: true},
    {id: 1222,name: &#34;P1-Child&#34;,qty1: &#34;2&#34;, level: 1,parent: 1221,isLeaf: true, <br />loaded: true, expanded: true}
]};

jQuery(&#34;#bomTable&#34;).jqGrid({
       treeGrid:true,
       treeGridModel:&#39;adjacency&#39;,
       ExpandColumn:&#39;name&#39;,
       treedatatype: &#34;local&#34;,
       datatype: &#34;local&#34;,
       data: mydata,
       jsonReader: {
           repeatitems: false
       },
       colNames:[&#39;ID&#39;, &#39;Name&#39;, &#39;Qty&#39;],
       colModel:[
           {name:&#39;id&#39;, hidden: true},
           {name:&#39;name&#39;, index:&#39;name&#39;},
           {name: &#39;qty&#39;, jsonmap: &#39;qty1&#39;, index: &#39;qty&#39;}
       ],
       width:&#39;auto&#39;,
       height:&#39;auto&#39;,
       shrinkToFit:false
   });

   jQuery(&#34;#bomTable&#34;)[0].addJSONData({
       total: 1,
       page: 1,
       records: mydata.rows.length,
       rows: mydata.rows
   }) ;
</div></pre>
<p>Would greatly appreciate any inputs!</p>
</div>
]]></description>
        	        	<pubDate>Thu, 09 May 2013 19:33:20 +0300</pubDate>
        </item>
</channel>
</rss>