-
-
Save anonymous/f689261241ecd50e25a4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//use the temporarily stored executeOptions | |
var executeIds = executeOptions.split(/[ ]+/); | |
//this function checks whether the given element-name is part of the | |
//"execute"-property of the ajax-request. | |
//The given parameter is the name of the currently iterated form-element | |
var isFieldExecutable = function (name) { | |
//submit nothing if execute @none is set | |
if (executeNone) { | |
return false; | |
} | |
//submit all values if @all or @form is set as execute option | |
if (executeAll || executeForm) { | |
return true; | |
} | |
//form-name is always submitted (if execute @none is not set) | |
if (name === form.name) { | |
return true; | |
} | |
//check whether the given element-name was set in the "execute" | |
//section of the ajax request | |
return arrayContains(executeIds, name); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment