[jboss-user] [JBoss Seam] - Re: @DataModel on Stateful beans (broken?)

tcavaleiro do-not-reply at jboss.com
Fri Jul 27 19:03:17 EDT 2007


Not an expert, but I think that the write way to do it is like


  | @DataModel
  | private List<Hotel> hotels;
  | 

(booking example)


the XHTML page or JSF (JSP style) page would have a reference like 



  | <a:outputPanel id="searchResults">
  |   <div class="section">
  | 	<h:outputText value="No Hotels Found" rendered="#{hotels != null and hotels.rowCount==0}"/>
  | 	<h:dataTable id="hotels" value="#{hotels}" var="hot" rendered="#{hotels.rowCount>0}">
  | 		<h:column>
  | 			<f:facet name="header">Name</f:facet>
  | 			#{hot.name}
  | 		</h:column>
  | ...
  | 


I don't know if your way is possible to do the work, but on the booking example (what I've been writing) the stuff works.


-------


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4068395#4068395

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4068395



More information about the jboss-user mailing list