[jboss-user] [JBoss Seam] - All my HtmlSelectOneRadio's are broken with Seam 1.1 (worked
ngeadah
do-not-reply at jboss.com
Mon Nov 6 17:06:14 EST 2006
I know about the @SelectItems that is available and how that could be a potential solution, but I would instead like to understand why something that was working perfectly in Seam 1.0 is broken when I moved to 1.1.
I have a SFSB that exposes a List attribute. The getter populates that List and the contents of the list are displayed using an h:selectOneRadio with f:selectItems.
| @Stateful
| @Scope(ScopeType.CONVERSATION)
| @Name("loginClient")
| public class LoginClientBean implements LoginClient {
| ...
| private List<SelectItem> customerTypes;
|
| public List<SelectItem> getCustomerTypes() {
| customerTypes = new LinkedList<SelectItem>();
| ... Adding to customerTypes
| return customerTypes;
| }
|
| public void setCustomerTypes(List<SelectItem> customerTypes) {
| this.customerTypes = customerTypes;
| }
|
And the JSF:
| <h:selectOneRadio id="customerType" value="#{loginClient.selectedCustomerType}" required="true">
| <f:selectItems value="#{loginClient.customerTypes}" />
| </h:selectOneRadio>
|
Upon submit, I now get a nasty exception:
| java.lang.IllegalArgumentException: Value binding '#{userMaintenanceClient.usersSelectItems}'of UISelectItems with component-path {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /UserMaintenance.xhtml][Class: javax.faces.component.html.HtmlForm,Id: userMaintenance][Class: javax.faces.component.html.HtmlPanelGrid,Id: _id23][Class: javax.faces.component.html.HtmlPanelGroup,Id: _id24][Class: javax.faces.component.html.HtmlSelectOneRadio,Id: selectRadio][Class: javax.faces.component.UISelectItems,Id: _id25]} does not reference an Object of type SelectItem, SelectItem[], Collection or Map but of type : null
|
Worked just fine in Seam 1.0.1. Something must have changed in 1.1 to break this. Thanks for any insights.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3983581#3983581
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3983581
More information about the jboss-user
mailing list