[jboss-user] [JBoss Seam] - Re: Getting selectitems from the generated EntityList object
lowecg2004
do-not-reply at jboss.com
Sat Jun 2 11:26:51 EDT 2007
What's wrong with Seam's solution?
<h:selectOneMenu value="#{sysUsersHome.instance.tbCompany}" required="true">
| <s:selectItems value="#{companies}" var="company" label="#{company.descr}" noSelectionLabel="Select..." hideNoSelectionLabel="true"/>
| <s:convertEntity />
| </h:selectOneMenu>
convertEntity looks for an entity's @Id field as the option id and the label comes from selectItem.label. Very flexible and no need to adhere to getId() and getName() conventions. The noSelectionLabel functionality is also very handy.
Best Regards,
Chris.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4050677#4050677
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4050677
More information about the jboss-user
mailing list