<?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: New grid from cell link</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/new-grid-from-cell-link</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/new-grid-from-cell-link/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>smackYYZ on New grid from cell link</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/new-grid-from-cell-link#p22967</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/new-grid-from-cell-link#p22967</guid>
        	        	<description><![CDATA[<p>Okay I&#39;m almost there. I have create a new grid in tab working using the OnSelectRow.</p>
<p>But I need to get this to work utilizing individual cells or icons. I&#39;ve not been able to find a simale function as OnSelectRow for a single cell.</p>
</p>
<p>Here is my code:</p>
</p>
<p>&#60;script type="text/javascript"&#62;</p>
<p>var mygrid = jQuery("#calllisting2").jqGrid({</p>
<p>url: &#39;server.php?q=calllisting&#39;,</p>
<p>datatype: "json",</p>
<p>mtype: "GET",</p>
<p>height: 400,</p>
<p>width: 750,</p>
<p>colNames:["id","Call#","View","Region","Sales Office", "Team", "Manager", "Property", "Period", "Call Date", "Score"],</p>
<p>colModel:[</p>
<p>{name: &#39;id&#39;,index:&#39;id&#39;, width:1,hidden:true,key:true},</p>
<p>{name: &#39;callnumber&#39;,index:&#39;callnumber&#39;, width:55, align:"right"},</p>
<p>{name: &#39;view&#39;, width: 30, sortable: false, search: false, align: "center",</p>
<p>formatter:function(cellvalue){</p>
<p>return "&#60;a class=&#39;ui-icon ui-icon-document&#39; &#62;View Call Report&#60;/a&#62;";</p>
<p>}},</p>
<p>{name: &#39;region&#39;,index:&#39;region&#39;, width:80, align:"left",</p>
<p>stype:&#39;select&#39;, editoptions:{value:":All;&#60;?php</p>
<p>echo $region;</p>
<p>?&#62;"} },</p>
<p>{name: &#39;salesoffice&#39;,index:&#39;salesoffice&#39;, width:80, align:"left",</p>
<p>stype:&#39;select&#39;, editoptions:{value:":All;&#60;?php</p>
<p>echo $salesoffice;</p>
<p>?&#62;"} },</p>
<p>{name: &#39;manager&#39;,index:&#39;manager&#39;, width:80, align:"left",</p>
<p>stype:&#39;select&#39;, editoptions:{value:":All;&#60;?php</p>
<p>echo $manager;</p>
<p>?&#62;"} },</p>
<p>{name: &#39;agent&#39;,index:&#39;agent&#39;, width:120, align:"left",</p>
<p>stype:&#39;select&#39;, editoptions:{value:":All;&#60;?php</p>
<p>echo $agent;</p>
<p>?&#62;"} },</p>
<p>{name: &#39;property&#39;,index:&#39;property&#39;, width:70, align:"left",</p>
<p>stype:&#39;select&#39;, editoptions:{value:":All;&#60;?php</p>
<p>echo $property;</p>
<p>?&#62;"} },</p>
<p>{name: &#39;periodid&#39;,index:&#39;periodid&#39;, width:60, align:"center", stype:&#39;select&#39;,</p>
<p>editoptions:{value:":All;2007-02:2007-02;2007-03:2007-03"}},</p>
<p>{name: &#39;reportdate&#39;,index:&#39;reportdate&#39;, width:70, align:"center", sorttype:&#39;date&#39;, datefmt:"Y-m-d",</p>
<p>searchoptions:{dataInit:function(el){$(el).datepicker({dateFormat:&#39;yyyy-mm-dd&#39;});} }},</p>
<p>{name: &#39;score&#39;,index:&#39;score&#39;, width:54, align:"right", sorttype:&#39;number&#39;, formatter:&#39;number&#39;,formatoptions:{decimalPlaces:1, suffix: " %"} }</p>
<p>],</p>
<p>rowNum: 50,</p>
<p>rowList : [20,30,50,100],</p>
<p>rownumbers: true,</p>
<p>rownumWidth: 40,</p>
<p>gridview: true,</p>
<p>sortname: &#39;callnumber&#39;,</p>
<p>viewrecords: true,</p>
<p>sortorder: "asc",</p>
<p>pager : "#pcalllisting2",</p>
<p>userdata: "userdata",</p>
<p>caption: "Call Listing Report",</p>
<p>recordtext: "View {0} - {1} of {2} &#60;span id=avgscore&#62;Avg Score 100%&#60;/span&#62;",</p>
<p>emptyrecords: "No records to view &#60;span id=avgscore&#62;Avg Score 100%&#60;/span&#62;",</p>
<p>loadComplete: function printAvg() {</p>
<p>var txt = document.getElementById(&#39;avgscore&#39;);</p>
<p>txt.innerHTML = "Avg: "+jQuery("#calllisting2").jqGrid(&#39;getGridParam&#39;, &#39;userData&#39; )[&#39;avgscore&#39;] +" %";</p>
<p>},</p>
<p>onSelectRow: function(rowid) {</p>
<p>var rowdata = $("#calllisting2").jqGrid(&#39;getRowData&#39;,rowid);</p>
<p>var callurl = "./calldetail.php?callnumber="+rowdata.callnumber;</p>
<p>var st = "#t"+rowdata.callnumber;</p>
<p>if($(st).html() != null ) {</p>
<p>maintab.tabs(&#39;select&#39;,st);</p>
<p>} else {</p>
<p>maintab.tabs(&#39;add&#39;,st, rowdata.callnumber);</p>
<p>$.ajax({</p>
<p>url: callurl,</p>
<p>type: "GET",</p>
<p>dataType: "html",</p>
<p>complete : function (req, err) {</p>
<p>$(st,"#tabs").append(req.responseText);</p>
<p>$(st,"#tabs");</p>
<p>}</p>
<p>});</p>
<p>}</p>
<p>}</p>
<p>});</p>
]]></description>
        	        	<pubDate>Thu, 28 Apr 2011 19:23:58 +0300</pubDate>
        </item>
        <item>
        	<title>smackYYZ on New grid from cell link</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/new-grid-from-cell-link#p22940</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/new-grid-from-cell-link#p22940</guid>
        	        	<description><![CDATA[<p>Hi, I&#39;m new to using javascript, jqGrid and jQuery. What I&#39;m trying to acheive is the ability to use a link in my jqgrid, to open a new tab, that will be populated with a new jqGrid.</p>
</p>
<p>I have mimiced the jqgrid demo site, and have the left treegrid menu operating and creating new tabs, with jqgrids dynamically. I can see the code in the treegrid for the links but have been unsuccessful in trying to embed this logic in my gridview.</p>
</p>
<p>You can see code in action here: <a href="http://demo.qualitytrack.com/report" rel="nofollow" target="_blank">http://demo.qualitytrack.com/report</a></p>
</p>
<p>By viewing source you should be able to see any code. Any inut would be appreciated.</p>
</p>
<p>Mike</p>
]]></description>
        	        	<pubDate>Tue, 26 Apr 2011 19:23:49 +0300</pubDate>
        </item>
</channel>
</rss>