[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-3254) <s:selectItems> broken in NumberGuess example

Stan Silvert (JIRA) jira-events at lists.jboss.org
Mon Aug 11 19:41:49 EDT 2008


<s:selectItems> broken in NumberGuess example
---------------------------------------------

                 Key: JBSEAM-3254
                 URL: https://jira.jboss.org/jira/browse/JBSEAM-3254
             Project: Seam
          Issue Type: Bug
          Components: JSF Controls
    Affects Versions: 2.1.0.A1
            Reporter: Stan Silvert


When you run the Numberguess example, you get to a point where the numberGuess page switches to showing a dropdown of choices:
        <h:selectOneMenu value="#{numberGuess.currentGuess}" id="selectGuessMenu" required="true"
                       rendered="#{(numberGuess.biggest-numberGuess.smallest) le 20 and (numberGuess.biggest-numberGuess.smallest) gt 4}">
          <s:selectItems value="#{numberGuess.possibilities}" var="i" label="#{i}" />
        </h:selectOneMenu>
        <h:selectOneRadio value="#{numberGuess.currentGuess}" id="selectGuessRadio" required="true"
                       rendered="#{(numberGuess.biggest-numberGuess.smallest) le 4}">
          <s:selectItems value="#{numberGuess.possibilities}" var="i" label="#{i}" />
        </h:selectOneRadio>

At that point, you will get an IllegalArgumentException as similar to the last comment of JBSEAM-880:
java.lang.IllegalArgumentException: Expected a child component type of UISelectItem/UISelectItems for component type javax.faces.SelectOne(selectGuessMenu).  Found java.lang.String.
	com.sun.faces.renderkit.RenderKitUtils.getSelectItems(RenderKitUtils.java:357)

 If I add a noSelectionLabel to each <s:selectItems> then the IllegalArgumentException will go away, but the values do not populate the dropdown.

It looks like there might be something wrong deep inside <s:selectItems> ?

-- 
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

        



More information about the seam-issues mailing list