Is there a way to trigger `preSubmit` more than once?
Is there a way to trigger `preSubmit` more than once?
terrasvc
Posts: 8Questions: 2Answers: 1
I have preSubmit
firing on an editable DataTable, but it only fires the first time the row is edited.
fooBarEditor
.on('preSubmit', function (e, data) {
someFunction(data);
return false;
});
Is there a way to make it fire after every edit, or should I be using a different event?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
You are always returning
false
from the function, so the first submit would never complete. Is yoursomeFunction
actually updating the table? If so,preSubmit
isn't how to do this - useajax
to override the submission process.Allan
Aha, that makes sense. I was trying to tie in to all those events (like
preEdit
andpreSubmit
), but usingajax
will work for our needs! Thank you!