[
https://issues.jboss.org/browse/RF-13605?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Brian Leathem updated RF-13605:
-------------------------------
Description:
Clicking on the submit button of a form containing input elements with
valuechange event listeners triggers only the execution of the event listeners
of the corresponding input elements, but the button click event apparently gets
lost and the form isn't actually being submitted. The user has to click on the
button again to finally submit it. Explicitly setting the requestDelay of an
associated a4j:queue to say 200ms for all events seems to preserve the click
event and the form gets submitted as expected in our specific test environment.
This isn't a generally acceptable workaround though, as it introduces redundant
global delay and hardly preserves the click event reliably across environments
with different timing constraints.
Attached a testcase to isolate the problem, see the attached zip file
containing a minimal JSF application with a simple RichFaces-enabled form which
reproduces the undesired behavior.
{code}
<h:panelGroup id="greeting">
<h:outputText value="Hello #{richBean.name}!" rendered="#{not empty
richBean.name}" style="font-size:2em" />
</h:panelGroup>
<!-- <a4j:queue name="org.richfaces.queue.global" requestDelay="200" /> -->
<h:form>
<h:panelGrid id="panel" columns="2" border="0" cellpadding="0"
cellspacing="10">
<h:outputLabel value="Name:" for="nameInput" />
<h:inputText id="nameInput" value="#{richBean.name}">
<a4j:ajax event="change"
listener="#{richBean.normalizeName}" render="@form" />
</h:inputText>
<f:facet name="footer">
<h:panelGroup style="display:block; text-align:right">
<a4j:commandButton id="submit" value="Submit"
render="greeting" />
</h:panelGroup>
</f:facet>
</h:panelGrid>
</h:form>
{code}
was:
Clicking on the submit button of a form containing input elements with
valuechange event listeners triggers only the execution of the event listeners
of the corresponding input elements, but the button click event apparently gets
lost and the form isn't actually being submitted. The user has to click on the
button again to finally submit it. Explicitly setting the requestDelay of an
associated a4j:queue to say 200ms for all events seems to preserve the click
event and the form gets submitted as expected in our specific test environment.
This isn't a generally acceptable workaround though, as it introduces redundant
global delay and hardly preserves the click event reliably across environments
with different timing constraints.
Attached a testcase to isolate the problem, see the attached zip file
containing a minimal JSF application with a simple RichFaces-enabled form which
reproduces the undesired behavior.
{code}
<h:panelGroup id="greeting">
<h:outputText value="Hello #{richBean.name}!" rendered="#{not empty
richBean.name}" style="font-size:2em" />
</h:panelGroup>
<!-- <a4j:queue name="org.richfaces.queue.global" requestDelay="200" /> -->
<h:form>
<h:panelGrid id="panel" columns="2" border="0" cellpadding="0"
cellspacing="10">
<h:outputLabel value="Name:" for="nameInput" />
<h:inputText id="nameInput" value="#{richBean.name}">
<a4j:ajax event="change"
listener="#{richBean.normalizeName}" render="@form" />
</h:inputText>
<f:facet name="footer">
<h:panelGroup style="display:block; text-align:right">
<a4j:commandButton id="submit" value="Submit"
render="greeting" />
</h:panelGroup>
</f:facet>
</h:panelGrid>
</h:form>
{code}
> a4j:ajax button click event gets lost
> -------------------------------------
>
> Key: RF-13605
> URL: https://issues.jboss.org/browse/RF-13605
> Project: RichFaces
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: component-a4j-core
> Affects Versions: 4.3.6
> Reporter: abhishek vijra
> Attachments: queue.zip
>
>
> Clicking on the submit button of a form containing input elements with
> valuechange event listeners triggers only the execution of the event
> listeners of the corresponding input elements, but the button click event
> apparently gets lost and the form isn't actually being submitted. The user
> has to click on the button again to finally submit it. Explicitly setting the
> requestDelay of an associated a4j:queue to say 200ms for all events seems to
> preserve the click event and the form gets submitted as expected in our
> specific test environment. This isn't a generally acceptable workaround
> though, as it introduces redundant global delay and hardly preserves the
> click event reliably across environments with different timing constraints.
> Attached a testcase to isolate the problem, see the attached zip file
> containing a minimal JSF application with a simple RichFaces-enabled form
> which reproduces the undesired behavior.
> {code}
> <h:panelGroup id="greeting">
> <h:outputText value="Hello #{richBean.name}!" rendered="#{not empty
> richBean.name}" style="font-size:2em" />
> </h:panelGroup>
> <!-- <a4j:queue name="org.richfaces.queue.global" requestDelay="200" /> -->
> <h:form>
> <h:panelGrid id="panel" columns="2" border="0" cellpadding="0"
> cellspacing="10">
> <h:outputLabel value="Name:" for="nameInput" />
> <h:inputText id="nameInput" value="#{richBean.name}">
> <a4j:ajax event="change"
> listener="#{richBean.normalizeName}" render="@form" />
> </h:inputText>
> <f:facet name="footer">
> <h:panelGroup style="display:block; text-align:right">
> <a4j:commandButton id="submit" value="Submit"
> render="greeting" />
> </h:panelGroup>
> </f:facet>
> </h:panelGrid>
> </h:form>
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
_______________________________________________
richfaces-issues mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/richfaces-issues