ListShuttle in ModalPanel
weismantelf Jan 10, 2008 4:29 AMWhen a ListShuttle is in a ModalPanel, the a4j:commandButton does not work any more. In the following code you will find an a4j:commandButton which should call the action method "saveAction". But when i press the button ajax will hangup. The browse does not react anymore. Without a ModalPanel it will work without any problems
CODE
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xml:lang="en" lang="en"
xmlns:a4j="http://richfaces.org/a4j" xmlns:rich="http://richfaces.org/rich">
<ui:composition>
<rich:modalPanel id="dialogAssignDevice" width="500" height="300">
<f:facet name="header">
<h:outputText id="dialogAssignDeviceTitle" value="#{title}"></h:outputText>
</f:facet>
<f:facet name="controls">
<h:graphicImage value="/images/close.gif" style="cursor:pointer"
onclick="Richfaces.hideModalPanel('dialogAssignDevice')"></h:graphicImage>
</f:facet>
<a4j:form id="formAssignment">
<h:panelGrid>
<rich:messages style="color: red;" />
<rich:listShuttle sourceValue="#{societyDeviceEdit.freeDevices}" targetValue="#{societyDeviceEdit.assignedDevices}"
var="items" listHeight="300" listWidth="400" copyControlLabel="#{msg.addOneLabel}"
copyAllControlLabel="#{msg.addAllLabel}" removeAllControlLabel="#{msg.removeAllLabel}"
removeControlLabel="#{msg.removeOneLabel}" sourceCaptionLabel="#{msg.deviceNotAssignedLabel}"
targetCaptionLabel="#{msg.deviceAssignedLabel}" orderControlsVisible="false" fastOrderControlsVisible="false"
converter="DeviceConverter">
<rich:column>
<f:facet name="header">
<h:outputText value="#{msg.deviceSerialNoLabel}" />
</f:facet>
<h:outputText value="#{items.serialno}" />
</rich:column>
</rich:listShuttle>
<h:panelGrid columns="2" cellpadding="2" cellspacing="1">
<a4j:commandButton action="#{societyDeviceEdit.saveAction}" value="#{msg.saveLabel}" >
</a4j:commandButton>
<a4j:commandButton value="#{msg.cancelLabel}"
onclick="Richfaces.hideModalPanel('dialogAssignDevice')">
</a4j:commandButton>
</h:panelGrid>
</h:panelGrid>
</a4j:form>
</rich:modalPanel>
</ui:composition>