<?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: afterCheckValues event needed</title>
	<link>http://www.trirand.com/blog/?page_id=393/feature-request/aftercheckvalues-event-needed</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/feature-request/aftercheckvalues-event-needed/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>OlegK on afterCheckValues event needed</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/aftercheckvalues-event-needed#p24625</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/aftercheckvalues-event-needed#p24625</guid>
        	        	<description><![CDATA[<p>Hello Ivan,</p>
<p>I agree with you that it is a problem.</p>
<p>Look at <a href="http://www.ok-soft-gmbh.com/jqGrid/SimpleLocalGridWithInlineEditing.htm" target="_blank">the demo</a> which I wrote for <a href="http://stackoverflow.com/questions/5988767/highlight-error-cell-or-input-when-validation-fails-in-jqgrid/6162086#6162086" target="_blank">the answer</a>. It shows how you can overwrite the standard <strong>$.jgrid.checkValues</strong> function and do some additional actions. The example uses inline editing, but you can easy modify it for the form editing.</p>
<p>I can add that one more important problem is that the field validating will be broken at the first error found. If one mark the fields having errors one can validate all fields. In dialog haveing many field it can improve the user expirience.</p>
<p>As the workaround I could suggest you to use <strong>beforeSubmit</strong> event. If you would returns from your version of <strong>$.jgrid.checkValues</strong> allways true, but set some error flag (varible), you can test the flag in your <strong>beforeSubmit</strong>&#160;event handler and returns the resulting [false, "your error message"]. Additionally you can add "ui-state-error" class to <em>all</em> field where the validation failed. Additionally you can set tooltips to the <strong>&#60;input&#62;</strong> elements which has validation errors, so that the tooltips describe the error exactly. You can choose different style of displaying of tooltips (see <a href="http://wiki.jqueryui.com/w/page/12138112/Tooltip" target="_blank">here</a>&#160;and <a href="http://view.jqueryui.com/master/demos/tooltip/default.html" target="_blank">here</a> for example)</p>
<p>I hope that Tony will improve the standard behavior on the field checking.</p>
<p>Best regards<br />Oleg&#160;</p>
]]></description>
        	        	<pubDate>Thu, 15 Sep 2011 13:43:23 +0300</pubDate>
        </item>
        <item>
        	<title>ivanchain on afterCheckValues event needed</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/aftercheckvalues-event-needed#p24619</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/aftercheckvalues-event-needed#p24619</guid>
        	        	<description><![CDATA[<p>In form eidt mode,&#160; there is an beforeCheckValues event. but I thinks an afterCheckValues event is needed.</p>
<p>because the default jqgrid checkvalue behavior is not very good. It show the error info on the top of the edit form, but don&#39;t make an obviously mark on which field is on error.&#160; So the user need to read the error info, and to FIND the corresponding field by himself. If there is a lot of field on the edit form, it&#39;s a hard work.</p>
</p>
<p>So I need the afterCheckValues event to return which field is on error, and I could code in this event to hightlight the field as I wish, just like mark the field&#39;s div as a red border.. etc.</p>
</p>
<p>Or I have exsiting way to do this?</p>
</p>
<p>yours,</p>
<p>Ivan</p>
]]></description>
        	        	<pubDate>Thu, 15 Sep 2011 09:11:49 +0300</pubDate>
        </item>
</channel>
</rss>