• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

rich:dataTable is only showing header not Table record

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
 <rich:dataTable var="_log_kommun_fb" value="#{kommunProducer.singlekommunlog(kommunProducer.selected.kommun)}" id="kommunlogtable" styleClass="stable">  
                                                     
                                                      <rich:column headerClass="listtable-subheadercell">
                                                             <f:facet name="header">Added_Date</f:facet>
                                                             <h:outputLabel value="#{_log_kommun_fb.addedDate}" >    
                                                                    <f:convertDateTime pattern="yyyy-MM-dd" />
                                                             </h:outputLabel>                                              
                                                      </rich:column>
                                                     
                                                        <rich:column headerClass="listtable-subheadercell">
                                                             <f:facet name="header">Changed_Date</f:facet>
                                                             <h:outputLabel value="#{_log_kommun_fb.changedDate}">  
                                                                    <f:convertDateTime pattern="yyyy-MM-dd" />
                                                             </h:outputLabel>                                              
                                                      </rich:column>
                                                     
                                                     
                                                     
                                 </rich:dataTable>    
 
Saloon Keeper
Posts: 27807
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the JavaRanch, Ramamurthi!

The "value=" attribute of the rich:dataTable should not be a method call, it should be a reference to a backing bean property. That property should be of type javax.faces.DataModel or something such as an Array, List or other ordered collection that can be wrapped in a DataModel.

Also, the convention for J2EE object names (including JSF backing beans) is that the bean name should start with a lowercase letter. An underscore not only violates that convention, it can potentially cause the application to work improperly.
 
ramamurthi mogilipalli
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
<rich:dataTable var="_log_fb" value="#{ammvPrestandaListProducer.singleAddressFMO_log(singleAdressFMOControlBean.adress.punktId)}" id="adress_fb_leveransomr_changelog_table" >  
                                               
                                           <rich:column headerClass="listtable-subheadercell">
                                                      <f:facet name="header">Datum</f:facet>
                                                      <h:outputLabel value="#{_log_fb.actionDate}">  
                                                             <f:convertDateTime pattern="yyyy-MM-dd" />
                                                      </h:outputLabel>                                              
                                               </rich:column>
                                 
                                               <rich:column headerClass="listtable-subheadercell">
                                                      <f:facet name="header">Åtgärd</f:facet>
                                                      <h:outputLabel value="#{_log_fb.actionText}">
                                                      </h:outputLabel>
                                               </rich:column>
                         
                          </rich:dataTable>

i have used above code in some other page with method call and it's working fine.
 
ramamurthi mogilipalli
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for the reply.
<rich:dataTable var="_log_fb" value="#{ammvPrestandaListProducer.singleAddressFMO_log(singleAdressFMOControlBean.adress.punktId)}" id="adress_fb_leveransomr_changelog_table" >  
                                               
                                           <rich:column headerClass="listtable-subheadercell">
                                                      <f:facet name="header">Datum</f:facet>
                                                      <h:outputLabel value="#{_log_fb.actionDate}">  
                                                             <f:convertDateTime pattern="yyyy-MM-dd" />
                                                      </h:outputLabel>                                              
                                               </rich:column>
                                 
                                               <rich:column headerClass="listtable-subheadercell">
                                                      <f:facet name="header">Åtgärd</f:facet>
                                                      <h:outputLabel value="#{_log_fb.actionText}">
                                                      </h:outputLabel>
                                               </rich:column>
                         
                          </rich:dataTable>

i have used above code in some other page with method call and it's working fine.
 
Tim Holloway
Saloon Keeper
Posts: 27807
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm afraid "It's working fine" doesn't mean anything when you violate standards.

Not every standards violation causes instant and catastrophic failure. Sometimes the offense can go for years working "just fine" and then explode catastrophically. I very nearly ended up in Chicago at 3 a.m. once because of that, in fact.
reply
    Bookmark Topic Watch Topic
  • New Topic