Hi all,
I have a a4j:support with an eventQueue attached:
<a4j:support event="onchange" actionListener="#{infController.infModified}"
reRender="avisoInfClose,saveInf,textoInf" ajaxSingle="true" eventsQueue="queueInf"/>
And the queue:
<a4j:queue name="queueInf"
requestDelay="500" ignoreDupResponses="true"
size="-1"
sizeExceededBehavior="dropNew"
disabled="false"
status="ajaxInfStatus"
/>
To minimize the request, I have a javascript function that is reRendered depending if the request have to be sent or not:
function infModified(){
.....
}
And I use this funcion to submit or not the request:
onsubmit="if (infModified()) return false"
If I set "onsubmit" in the a4j:queue, the request is sent even if it returns false (I checked that the function is invoked), but If I set "obsubmit" inside a4j:support the request is not sent, as expected. I checked that onsubmit in
Is my code using onsubmit the right way in a4j:queue? Does this attribute works as expected?