<?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: Appending post data during beforeSearch not working</title>
	<link>http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working</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/bugs/appending-post-data-during-beforesearch-not-working/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>tony on Appending post data during beforeSearch not working</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p9047</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p9047</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>Could you please try this way:</p>
<p>....</p>
<p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; beforeSearch: function() {<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; $(<strong>"#mygrid</strong><strong></strong>").<span style="color: #ff0000;">setGridParam</span>({postData:{ _search: true, Contact: $(&#39;#Contact&#39;).val() }});<br />&#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;&#160;&#160; }</p>
</p>
<p>Note the call of grid and the setGridParam. I feel that something is not good with $(item)...</p>
</p>
<p>Best Regards</p>
<p>Tony</p>
]]></description>
        	        	<pubDate>Sun, 30 Aug 2009 09:54:48 +0300</pubDate>
        </item>
        <item>
        	<title>Renso on Appending post data during beforeSearch not working</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p8957</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p8957</guid>
        	        	<description><![CDATA[<p>Yes Tony that seems to be the case. As long as I sort, page, etc, it works just fine, but as soon as I use the toolbar to enter a search value and hit the search icon or select a value from the toolbar&#39;s drop downs with auto search enabled, the append is not adding the value, my guess is the filtergrid event it is not firing at all. It also does not work when clicking the Reload icon and am not sure if it is supposed to. No Martin I never investigated it more, if it is a bug I am sure there is a way to code around it but wanted to get feedback from Tony first. Sorry for the delayed response I was on vacation.</p>
<p>Renso.</p></p>
]]></description>
        	        	<pubDate>Tue, 25 Aug 2009 10:29:28 +0300</pubDate>
        </item>
        <item>
        	<title>tony on Appending post data during beforeSearch not working</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p8669</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p8669</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>Not sure what you try to do. Also if I understand right?</p>
<p>1. You use filterGrid and send expra parameters appending them to posData (beforeSearch)</p>
<p>2. In the same way you use filterToolbar.</p>
<p>3. When you search with filter grid all is ok, but when you try to serch with filterToolbar the data appended from filterGrid does not appear when you perform search with it.</p>
<p>Is this the case?</p>
<p>Regards</p>
<p>Tony</p>
]]></description>
        	        	<pubDate>Mon, 17 Aug 2009 06:40:41 +0300</pubDate>
        </item>
        <item>
        	<title>Martin on Appending post data during beforeSearch not working</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p8655</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p8655</guid>
        	        	<description><![CDATA[</p>
<p>Hi, DId you ever get this resolved?&#160; I&#39;m having a similar problem...</p>
]]></description>
        	        	<pubDate>Sun, 16 Aug 2009 12:19:01 +0300</pubDate>
        </item>
        <item>
        	<title>Renso on Appending post data during beforeSearch not working</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p7904</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/appending-post-data-during-beforesearch-not-working#p7904</guid>
        	        	<description><![CDATA[<p>When I setup my post data during a call-back to the beforeSearch event it does not send the newly appended search data:</p>
<p><strong>My HTML:</strong></p>
<p><input type='button' class='sfcodeselect' name='sfselectit6317' value='Select Code' data-codeid='sfcode6317' /></p>
<div class='sfcode' id='sfcode6317'>&#60;table id="ListPhoneTypeCalls" class="scroll" cellpadding="0" cellspacing="0"&#62;&#60;/table&#62; <br />&#60;div id="ListPhoneTypeCallsPager" class="scroll" style="text-align:center;"&#62;&#60;/div&#62;</div>
<p><strong>My filterGrid (<span style="color: #3366ff;">item </span>= <span style="color: #3366ff;">#ListPhoneTypeCalls</span></strong><strong>:</strong></p>
<p>$(<span style="color: #3366ff;">item</span>.replace(&#39;#&#39;, &#39;#t_&#39;)).<span style="color: #ff0000;">filterGrid</span>(item, {<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; gridModel: true,<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; beforeSearch: function() {<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; $(<span style="color: #3366ff;">item</span>).<span style="color: #ff0000;">appendPostData</span>({ _search: true, Contact: $(&#39;#Contact&#39;).val() });<br />&#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;&#160;&#160; }<br />});</p>
</p>
<p>Actually I am not sure if this is the best way to dynamically change my postdata. What I want to ultimately do is to be able to change my search data because I use the grid to show a list of calls for an Account, and then also the same grid for a filtered list of calls for a particular Contact in that Account. So what I have done is I setup the postData to contain the extra Contact&#39;s id if I am on the contact screen. When on the server-side it sees the contact parm also, it simply filters it by the contact. This way I can define one grid and use it on two different screens, one for all calls on the account screen, and another for all calls for a specific contact on the contact screen. Unfortunately once I have set the postData with the contact&#39;s id in it (#Contact), it gets overridden during search and that is why I also wanted to set ut during the beforeSearch event. Not sure if this is the best way.</p>
<p>My Json object sent to the server when the grid loads:</p>
<table class="netInfoParamsText netInfoText netInfoParamsTable " style="height: 180px;" border="0" cellspacing="0" cellpadding="0" width="333">
<tbody class=" ">
<tr class=" ">
<td class="netInfoParamName "><span style="color: #ff0000;">Contact</span></td>
<td class="netInfoParamValue ">
<pre class=" ">111</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">_search</td>
<td class="netInfoParamValue ">
<pre class=" ">true</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">accountId</td>
<td class="netInfoParamValue ">
<pre class=" ">1</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">nd</td>
<td class="netInfoParamValue ">
<pre class=" ">1248103740125</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">page</td>
<td class="netInfoParamValue ">
<pre class=" ">1</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">phoneType</td>
<td class="netInfoParamValue ">
<pre class=" ">true</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">rows</td>
<td class="netInfoParamValue ">
<pre class=" ">5</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">sidx</td>
<td class="netInfoParamValue ">
<pre class=" ">CallDateUrl</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">sord</td>
<td class="netInfoParamValue ">
<pre class=" ">asc</pre>
</td>
</tr>
</tbody>
</table>
<p>When I search via the gridToolbar it looks like this (note <span style="color: #ff0000;">Contact </span>is missing):</p>
<table class="netInfoParamsText netInfoText netInfoParamsTable " style="height: 180px;" border="0" cellspacing="0" cellpadding="0" width="334">
<tbody class=" ">
<tr class=" ">
<td class="netInfoParamName ">CallStatus</td>
<td class="netInfoParamValue ">
<pre class=" ">3</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">_search</td>
<td class="netInfoParamValue ">
<pre class=" ">true</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">accountId</td>
<td class="netInfoParamValue ">
<pre class=" ">1</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">nd</td>
<td class="netInfoParamValue ">
<pre class=" ">1248103849270</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">page</td>
<td class="netInfoParamValue ">
<pre class=" ">1</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">phoneType</td>
<td class="netInfoParamValue ">
<pre class=" ">true</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">rows</td>
<td class="netInfoParamValue ">
<pre class=" ">5</pre>
</td>
</tr>
<tr class=" ">
<td class="netInfoParamName ">sidx</td>
<td class="netInfoParamValue ">
<pre class=" ">CallDateUrl</pre>
</td>
</tr>
</tbody>
</table>
]]></description>
        	        	<pubDate>Mon, 20 Jul 2009 10:33:20 +0300</pubDate>
        </item>
</channel>
</rss>