jqgrid 的编辑信息提示

在编辑时,无外乎两种结果:成功和失败。在form edit的弹出编辑窗体中隐藏了两个单元(td),一个的ID是FormError,另一个没有id,有class叫做topinfo。就是这两个家伙可以分别来显示错误信息和操作成功的信息。

以下在firebug中截图:

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAnUAAACRCAIAAAAq39m+AAAgAElEQVR4nO2dP2wbSZb/GTp0ZuGCg3GRgcVBPihxcAEzO7hA2OCgDQgTjoSBAuEHmKPgAB4cnChAR2JwAKlkbUNzlIKf52fhaK6g0QIU1uJqdrw47cCCKEoUZWs8Ii1jTS00IwrYHbxfUN3V1V3V3UWyKf7x94OGQZequ6tfNevL97q6XogAAAAAEDShXjcAAAAAGEKgrwAAAEDwQF8BAACA4HHq629f7c8tbcjbb1/t96R9vSIZyTyY22T/9rotfcGgGGRQ2qnP8F1RN9C3Euypwydiz25fplNf55Y2lPXcykXqO5sPWzRxMkI3RqkulT8YpVCIxiItHczZmBuhTFkqL6+8CIUSyZWKx77llRdjkRf1nc3R0azRtpUkhULWNvqAiCgyZnywn5lGb1AoRJGk46jm7jdoR75iOzt5Co0pylkzVuTL8j27+zE1UBikBd4/GE2FQomxyIv2zq6Pop2RMVvHzeVtO8j21LGS8mZQ0todondFnaLsjqvrI3L/braNi5XKcqcPlj2Vg5Vc2P/2TEYyN4IwuM7o3dLROrjMSkSjcxX6+vPPf7Nvf728/MlXX2UTl1cov+PbALqr0lciqu/Q3Q701YP8XNazh97PzX1N9P5h5P9aDZubIyLayRtjIvsvlV3HVl7ToE6jo4as7uQ9BdKPuQf+uzvP3iIrj+2/AFQGaZH6zubdro/dynbWafSu9Tny0LmTjj0dBlHfDEr07xAlAVheibI7rqSPuoFbv9+glbLwwa1mAHTPnsrBym8E65Bu2LNyN6AfNMFde6eXyUTX+xwKfb28bF5eNi8vL9h2fv7x/ckbb31V/n5JRgZUX91xjonao+dK0uk5tc0V6Gvkrr+H3SK9G7tFfVWhY0+lQbSM3KG+dovh0lcV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q4vziqSYAAAA/BlmfSVJYt0yYpr6erG68YGVuOgrxBUAAIAWQ66vZJNY17iuOY9pn3mxbH4T277c4KnEIa4AAAB0GX595bg5rwAAAEDgfEL6CgAAAFwZ0FcAAAAgeKCvAAAAQPBAXwEAAIDg+f87XKzXWGS/jQAAAABJRU5ErkJggg==" alt="" />
FormError在topinfo的上面,因此如果第一次操作成功(true),如果窗体不消失,在窗体上再次编辑后提交失败(false),则错误信息会出现在第一次成功信息的上面!

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAS8AAADmCAIAAAALLJRHAAATTUlEQVR4nO2dXXMb1RnHueZj8AFyycBtKLnBnSnwBbiuJ4GStkB4ayCNYEpbpjd0oPVMQykiTuIkjmQgBWYICTTEgcRWLNkJcUIS2bHs+C224xepF8fePTrnPM+elbR7jqL/f36jWR+dPfvs7vlpJTvRPtB1YBwA4AMPrG9sAAB8ADYC4AuwEQBf2LSx78fJJ3uK298bAQCkzJM9xf+cLYc2PtVT3H249PbAKAAgZZ4/XPrVP0dCG7e/N/LWwCgAwAnb34u0Mc8u56XGvNYnCYzjK5vW+9i0JFFhM1sx7o7lgM3vXWMjtGrfk967xkaOO8Nj9tRszI8CAJxgsDGTH83kR9/aegxaMtrKGelZpVEnow2oP5XRRqb66wNSBTMjU6Uae2a0Z/UOVB9qOWPaC2V147BUSZHHmSnPuMBXqG898lxTnZWdpU5oxrSKcaZRfZiDbCyAajSuzh8Kqs5gWbWxfvRSJl/aWjDXrfWnGqmnSqZlfcUSuwmqmMi1qNpsNmeslhmBr6GBIqnjpnQumTrrR7UkLRjbbY6/vjp1fJgzayyS3/3I08TPTP4AUkePOraRlZfqhwo76DZudq3VarVaTVrT0KK017RErmscypjIdQFod6JtjNRD6ak02gzIlwgbQYeg2rg/X9qfL9VqtYm5lWC5VquJZaVFNurMlWlds2CVjLSQ0YaSGxn59xPoT2VMjZHrZugBIzsYV1H621RlrIfqmWF/jBzB8uAYh80Qu6PsacZ00BqujZpF1HHgD6b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3r+esLwpi7oI5aNqxuf0udMC8sOti4qDwowFqM0xqpZDmnjzfkNeygbmx8EcZK4584Vuo3OS2pmnpP/o+pKZaW8sGEJZaP9CJenVs6NzzY5h5BWJda5c4huo/OSGpNFxGzjxNzKuXT/t/G58dmbs/eanENIq3J6rDKxuOE/uo3OS4pbsxx8EwdiSKv++XXSJPSvxtOsWQ5sRAw5PVaZurvhP7qNzkuKW7Mc2IgYcv7a7PjMSmVpw2euTq8M1v+uwf+y9ZrlwEbEkMm5Fc+/Jvj0WGVwfPbW3L32KluueWpxdccHV+T6YSOCOIhQcWpxVW6EjQiSdgIVcW1EEJeRVcS1EUGcRVER10YEcRNexSpsRJDUwqtYhY0I4k9gI4L4EtiIIL4ENiKIL4GNCOJLHug6MA4A8IH/A+ntvlfJCBCfAAAAAElFTkSuQmCC" alt="" />
所以要在提交失败的语句段中清除成功信息。

以下是javascript代码:

  function Z_AfterSubmit_Edit(response, postdata) {
var DialogVars = $.parseJSON(response.responseText);//响应信息
$infoTr = $("#TblGrid_" + $.jgrid.jqID(this.id) + ">tbody>tr.tinfo"),
$infoTd = $infoTr.children("td.topinfo");//信息栏
if (DialogVars.success) {
var myInfo = '<div class="ui-state-highlight ui-corner-all">' +
'<span class="ui-icon ui-icon-info" style="float: left; margin-right: .3em;"></span>' +
DialogVars.message +
'</div>'
$infoTd.html(myInfo);
$infoTr.show();
return [true, myInfo, ""];
} else {
var myInfo = //'<div class="ui-state-highlight ui-corner-all">' +
'<span class="ui-icon ui-icon-alert" style="float: left; margin-right: .3em;"></span>' +
DialogVars.message +
'</div>'
//错误信息是在id为FormError的单元格显示
$infoTr.hide();//隐藏信息栏以免同时显示info和FormError
return [false, myInfo, ""];
}
}

在jqgrid中调用:

 afterSubmit: Z_AfterSubmit_Edit

窗体在编辑后是保持显示还是消失,可以通过设置closeAfterEdit的值为true或false来实现。默认的是成功消失,失败时窗体不消失。如果想不管成功还是失败都显示窗体,可以把closeAfterEdit设为false。

 closeAfterEdit: false

--END--

上一篇:Linux网络设备驱动之参数设置和统计数据(八)


下一篇:JS 骚操作整理