[ajax edition] freeze form button when calling validateForm, so it freeze nicely for e.g. comment submitting form stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Wed, 15 Jun 2011 19:19:36 +0200
branchstable
changeset 7517 a05bad3aec2e
parent 7516 9989b69e2a19
child 7518 2431e3e9a4f2
[ajax edition] freeze form button when calling validateForm, so it freeze nicely for e.g. comment submitting form
web/data/cubicweb.edition.js
--- a/web/data/cubicweb.edition.js	Wed Jun 15 19:15:55 2011 +0200
+++ b/web/data/cubicweb.edition.js	Wed Jun 15 19:19:36 2011 +0200
@@ -583,6 +583,7 @@
  * around the corresponding input fields.
  */
 function validateForm(formid, action, onsuccess, onfailure) {
+    freezeFormButtons(formid);
     try {
         var zipped = cw.utils.formContents(formid);
         var args = ajaxFuncArgs('validate_form', null, action, zipped[0], zipped[1]);