[ 
https://jira.jboss.org/jira/browse/RF-6862?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Nick Belaevski resolved RF-6862.
--------------------------------

    Resolution: Won't Fix
      Assignee: Tsikhon Kuprevich


You have a bug in the page code, here is the working one:

<%@ taglib uri="http://java.sun.com/jsf/core"; prefix="f"%>
<%@ taglib uri="http://java.sun.com/jsf/html"; prefix="h"%>
<%@ taglib uri="http://richfaces.org/a4j"; prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich"; prefix="rich"%>

<html>
<head>
<title>Picklist Test Page</title>
</head>
<body>

<f:view>
        <h1>Test Picklist Refresh</h1>

        <h:messages style="color: red" />

        <h:form id="pickListForm">

                <h:selectOneListbox id="applicationSelectionList"
                        styleClass="ApplicationSelectionList"
                        value="#{testPickList.selectedApplication}" size="8"
                        
valueChangeListener="#{testPickList.loadRoleComponentsForApplicationSelection}">
                        <f:selectItems id="applicationList"
                                value="#{testPickList.applications}" />
                        <a4j:support ajaxSingle="true" event="onchange"
                                reRender="rolePicklist" />
                </h:selectOneListbox>

                <rich:pickList id="rolePicklist" styleClass="RolePicklist"
                        value="#{testPickList.assignedRoles}">
                        <f:selectItems id="assignedRoles"
                                value="#{testPickList.availableRoles}" />
                </rich:pickList>

        </h:form>
</f:view>
</body>
</html>

This page works ok with TestRichFacesPicklistWithoutBinding application; JSF 
1.2_12; RF 3.3.0.GA.

Please ask at users forum in the future before posting JIRA issues if you are 
not 100% sure that's a bug.

> RF picklist does not update target list after onchange event
> ------------------------------------------------------------
>
>                 Key: RF-6862
>                 URL: https://jira.jboss.org/jira/browse/RF-6862
>             Project: RichFaces
>          Issue Type: Bug
>    Affects Versions: 3.2.2, 3.3.0
>         Environment:  JBoss AS 4.2.3 (Ubuntu Linux 8.04)
>            Reporter: Brendan Farragher
>            Assignee: Tsikhon Kuprevich
>         Attachments: TestRichFacesPicklistWithBinding.tar, 
> TestRichFacesPicklistWithoutBinding.tar
>
>
> The RichFaces picklist component does not re-load it's pre-selected (target) 
> data correctly when an onchange event of a dependent selectonelistbox 
> component is raised. If a valuechangelistener method is set on the 
> selectonelistbox, and that method loads the picklist's source and target 
> lists with new data, the target list is not populated when the page is 
> re-displayed (in this case, the target list in the backing bean maps to the 
> value attribute of the picklist tag). I even tried wrapping the picklist in 
> an a4j:outputPanel with an a4j:support event=onchange reRender=pickListName 
> tag placed inside of the selectonelistbox tag, but the target list is never 
> populated.
> I have a JSF test application developed that I can provide you with that 
> demonstrates the problem, and a second JSF test application that contains a 
> workaround using a bound HtmlPickList (the workaround is not really 
> appropriate for Seam integration, though). (Please update the JIRA with a 
> forwarding address if you would like my test apps)
> Please note that this bug has more important implications for Seam 
> integration, since JSF component binding is discouraged. As a result, the 
> value attribute of the picklist (the target data) needs to be refreshed via 
> the picklist tag value attribute (or via some a4j help).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
https://jira.jboss.org/jira/secure/Administrators.jspa
-
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

Reply via email to