rich:popupPanel problem (listeners aren't called with the first click)
ikos2201 May 20, 2013 10:12 AMHi, guys !
I have the next problem with rich:popupPanel : any listener are not called with the first click on any component !
I have a popupPanel (modal) and a separate page which I include as a content for this popupPanel.
Content page looks like this :
<h:form id="contentPage">
// here I have radiobuttons, dropdowns, etc.
// e.g.
<h:selectOneMenu id="editingModePurpose"
value="#{debitCardClaimEditing.purposeId}"
styleClass="input-text1"
style="width: 200px;">
<f:selectItems value="#{debitCardClaimEditing.purposeList}"/>
<a4j:ajax event="valueChange"
listener="#{debitCardClaimEditing.purposeChangeListener()}" render="leftcol"
execute="@this" />
</h:selectOneMenu>
</h:form>
When I try to change smth., select radiobutton or change value for dropdawn listener aren't called with the first click , but with the second and the next and next everything is OK.
Then I close my popup, open again and have the same - first click doesn't work !
I have searched the solution , but with no success, but I have found people with the similar problem (https://community.jboss.org/thread/167869)
In output (I mean html code) I have :
<html>
<head></head>
<body>
<div id="MyPopupId" ... > ... </div>
// the rest code
<h:form> ... </h:form>
...
</doby>
</html>
Have you any ideas ???
Popup Window :
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:rich="http://richfaces.org/rich"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:a4j="http://richfaces.org/a4j"
xmlns:c="http://java.sun.com/jsp/jstl/core">
<ui:component>
<rich:popupPanel id="popup" modal="true"
resizeable="true" width="1024" height="768"
onmaskclick="#{rich:component('popup')}.hide()">
<f:facet name="header">
<h:outputText value=" Title " />
</f:facet>
<f:facet name="controls">
<h:form>
<h:commandLink value=""
onclick="#{rich:component('popup')}.hide(); return false;">
<h:outputText value="Close" style="font-weight: bold;" />
</h:commandLink>
</h:form>
</f:facet>
<!-- CONTENT PAGE -->
<ui:include
src="/content/pages/application/packageSelection/EditDebitCardClaim.xhtml" />
</rich:popupPanel>
</ui:component>
</html>
I HAVE FOUND VERY INTERESTING THING - I DON'T HAVE ViewState ID IN REQUEST WITH MY FIRST CLICK AND I DON'T KNOW WHY.