Hi,
Thank you. I will check it again. Do not have time to make all tests
Regards
Tony
Hi,
Thank you. You can send me the code or publish it here.
Regards
Tony
Hi,
You should perform this server side. An idea for this you can find in server.php file provided with the demo.
Regards
Tony
Or here is better solution:
Find editGridRow function.Within this function find
if( typeof p.beforeSubmit === ‘function’ ) ret = p.beforeSubmit(postdata);
Chenge to
if( typeof p.beforeSubmit === ‘function’ ) ret = p.beforeSubmit(postdata,frmgr));
Then define beforeSubmit event like this
beforeSubmit: function(aPostData, formid) {
if(!$(“#”+formid).valid() ) return [false,”Message to display”];
else return [true];
}
I think that this is more flexible solution and I will add this in the next release again with the my validation rules.
Regards and thank you
Tony
Ok,
if you want to implement the validation plugin here is it 🙂
Access editGridRow function and found :
$(“#sData”, “#”+frmtb).click(function(e){
After this add:
if( !$(“#”+frmgr).valid() ) return false;
Of course you should call the validation when intialize the form
Let me known if this work
Regards
Tony
heliotrope,
>> If the form contains errors and then you decide to close the modal window, if you reopen it the errors are still there
Thank you for this too. It will be corrected.
Now I have Idea how easy we can add client side validation. Just wait for the next release
Thank you
Regards
Tony
Hi,
I will try to make a validation addition to this. Any comment and sugestions are welcome. Currently do not change the type of the button from button to submit – it will not work. You can write your own validation using on beforeSubmit event. To this event is passed array of the posted values – so you can perform some type of checking.
Regards
Tony
Hi,
First look into the code of validate plugin –
You can try to set the validate plugin with options onsubmit : false. Default is true. Very interested on this feedback.
Regards
Tony
tonromeyn,
No problem. Maximum after two weeks it will be ready. I plan to publish something like SVN (my way) – so you can grab the latest version from Monday.
Regards and Thank you for help me to make jqGrid better.
Tony
Hi,
I will check this again, but I think your direction is right – add another option which tells us instead that the column is editable and hidden to show it in the form – this make sence.
Thank you
Tony
var grid_is constructed = false;
$(“#mybutton”).click(function(){
if (grid_is_constructed) {
$(“#mygrid”).trigger(“reloadGrid”)
} else {
$(“#mygrid”).jqGrid({…});
grid_is_constructed = true;
}
});
Hi,
Since there is no response for this problem I recommend you to do this (I it is not clear solution but…). Before constructing the grid you can do the following:
var myreader;
if ($.browser == ‘msie’) {
myreader = { //MSIE way
root:”m\:return”,
row: “m\:Incident”,
repeatitems: false,
id: “Reference”
}
} else { // other
myreader = {
root:”return”,
row: “Incident”,
repeatitems: false,
id: “Reference”
}
}
$(“#mygrid”)jqGrid({
…..
xmlReader : myreader,
…
});
Hope this help
Regards
Tony
Hi,
Since there is no response for this problem I recommend you to do this (I it is not clear solution but…). Before constructing the grid you can do the following:
var myreader;
if ($.browser == ‘msie’) {
myreader = { //MSIE way
root:”m\:return”,
row: “m\:Incident”,
repeatitems: false,
id: “Reference”
}
} else { // other
myreader = {
root:”return”,
row: “Incident”,
repeatitems: false,
id: “Reference”
}
}
$(“#mygrid”)jqGrid({
…..
xmlreader : myreader,
…
});
Hope this help
Regards
Tony
Hi,
It is possible to change this behavior, but I recommend you to have a hidden row with different name which holds the id.
Regards
Tony
Hi,
Please include jqModal.css, jqModal.js and jqDnR.js to wor this
Regards
Tony
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top