<?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: Where to Add beforeInitData: function edit dialog</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/where-to-add-beforeinitdata-function-edit-dialog</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/where-to-add-beforeinitdata-function-edit-dialog/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>tony on Where to Add beforeInitData: function edit dialog</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/where-to-add-beforeinitdata-function-edit-dialog#p8918</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/where-to-add-beforeinitdata-function-edit-dialog#p8918</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p><a href="http://www.trirand.com/jqgridwiki/doku.php?id=wiki:form_editing#editgridrow" rel="nofollow" target="_blank"><a href="http://www.trirand.com/jqgridw" rel="nofollow">http://www.trirand.com/jqgridw</a>.....ditgridrow</a></p>
<p>Regards</p>
<p>Tony</p>
]]></description>
        	        	<pubDate>Sat, 22 Aug 2009 02:42:19 +0300</pubDate>
        </item>
        <item>
        	<title>bootini on Where to Add beforeInitData: function edit dialog</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/where-to-add-beforeinitdata-function-edit-dialog#p8905</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/where-to-add-beforeinitdata-function-edit-dialog#p8905</guid>
        	        	<description><![CDATA[<p>I need to replace the editoptions values for column Geography. I am passing an string into userdata formated correctly. Where do I add</p>
<p>beforeInitData: function(formId) {<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; jQuery("#list").setColProp(&#39;Geography&#39;, { editoptions: { value: jQuery("#list").getGridParam(&#39;userData&#39;)[0]} });<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; }</p>
</p>
<p>in the code below? thanks</p>
</p>
<p><span style="font-size: x-small;"></p>
<p></span></p>
<p><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">&#60;</span></span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">script</span></span><span style="font-size: x-small;"> </span><span style="font-size: x-small; color: #ff0000;"><span style="font-size: x-small; color: #ff0000;">type</span></span></p>
<p><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">="text/javascript"&#62;</span></span></p>
<p><span style="font-size: x-small;"></p>
<p></span></p>
<p><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">var</span></span></p>
<p><span style="font-size: x-small;"> lastsel2</span></p>
<p>jQuery(document).ready(</p>
</p>
<p>
<span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">function</span></span></p>
<p><span style="font-size: x-small;">() {</span></p>
<p>jQuery(</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"#list"</span></span></p>
<p><span style="font-size: x-small;">).jqGrid({</span></p>
<p>url:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;/Grid/DynamicGridData/&#39;</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>datatype:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;json&#39;</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>mtype:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;GET&#39;</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>colNames: [</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;First Name&#39;</span></span><span style="font-size: x-small;">, </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Middle Initial&#39;</span></span><span style="font-size: x-small;">,</span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Last Name&#39;</span></span><span style="font-size: x-small;">, </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Email&#39;</span></span><span style="font-size: x-small;">, </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Birth Date&#39;</span></span><span style="font-size: x-small;">, </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Gender&#39;</span></span><span style="font-size: x-small;">,</span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Geography&#39;</span></span></p>
<p><span style="font-size: x-small;">],</span></p>
<p>colModel: [</p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;FirstName&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;FirstName&#39;</span></span><span style="font-size: x-small;">, width: 100, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">, editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">, editoptions:{size:100}},</span></p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;MiddleName&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;MiddleName&#39;</span></span><span style="font-size: x-small;">, width: 80, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">, editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">, editoptions:{size:10}},</span></p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;LastName&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;LastName&#39;</span></span><span style="font-size: x-small;">, width: 100, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">, editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">, editoptions:{size:100}},</span></p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Email&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;EmailAddress&#39;</span></span><span style="font-size: x-small;">, width: 200, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">, editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">, editoptions:{size:100}},</span></p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;BirthDate&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;BirthDate&#39;</span></span><span style="font-size: x-small;">, width: 100, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">,editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">,editoptions:{size:25}},</span></p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Gender&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Gender&#39;</span></span><span style="font-size: x-small;">, width: 60, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">,editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">, editoptions:{size:10}},</span></p>
<p>{ name:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Geography&#39;</span></span><span style="font-size: x-small;">, index: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;Geography&#39;</span></span><span style="font-size: x-small;">, width: 150, align: </span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;left&#39;</span></span><span style="font-size: x-small;">,editable:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span><span style="font-size: x-small;">, edittype:</span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"select"</span></span><span style="font-size: x-small;">,editoptions:{value:</span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"FE:FedEx;TN:TNT"</span></span></p>
<p><span style="font-size: x-small;">}},],</span></p>
<p>pager: jQuery(</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;#pager&#39;</span></span></p>
<p><span style="font-size: x-small;">),</span></p>
<p>rowNum: 10,</p>
<p>rowList: [5, 10, 20, 50],</p>
<p>sortname:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;CustomerKey&#39;</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>sortorder:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"desc"</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>viewrecords:</p>
</p>
<p>
<span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">true</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>imgpath:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;/scripts/themes/steel/images&#39;</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>caption:</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;My first grid&#39;</span></span></p>
<p><span style="font-size: x-small;">,</span></p>
<p>editurl:</p>
</p>
<p><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"/Grid/DynamicGridData/Edit"</span></span></p>
<p><span style="font-size: x-small;"></span></p>
<p>});</p>
</p>
<p>$(</p>
<p><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"#bedata"</span></span><span style="font-size: x-small;">).click(</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">function</span></span></p>
<p><span style="font-size: x-small;">(){</p>
<p></span></p>
<p>
<span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">var</span></span><span style="font-size: x-small;"> gr = jQuery(</span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"#list"</span></span><span style="font-size: x-small;">).getGridParam(</span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">&#39;selrow&#39;</span></span></p>
<p><span style="font-size: x-small;">);</p>
<p></span></p>
<p>
<span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">if</span></span><span style="font-size: x-small;">( gr != </span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">null</span></span></p>
<p><span style="font-size: x-small;"> )</span></p>
<p>{</p>
<p>jQuery(</p>
</p>
<p>
<span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"#list"</span></span><span style="font-size: x-small;">).editGridRow(gr,{height:280,reloadAfterSubmit:</span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">false</span></span></p>
<p><span style="font-size: x-small;">});</span></p>
<p>}</p>
</p>
<p><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">else</span></span></p>
<p><span style="font-size: x-small;"></span></p>
<p>{</p>
<p>alert(</p>
<p><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">"Please Select Row"</span></span></p>
<p><span style="font-size: x-small;">);</span></p>
<p>}</p>
</p>
<p>});</p>
</p>
<p>});</p>
</p>
<p>
<span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">&#60;/</span></span><span style="font-size: x-small; color: #a31515;"><span style="font-size: x-small; color: #a31515;">script</span></span><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">&#62;</span></span></p>
<p><span style="font-size: x-small;"> </span></p>
]]></description>
        	        	<pubDate>Fri, 21 Aug 2009 14:07:50 +0300</pubDate>
        </item>
</channel>
</rss>